MCPcopy Create free account
hub / github.com/ddbourgin/numpy-ml / predict

Method predict

numpy_ml/trees/losses.py:22–25  ·  view source on GitHub ↗
(self, X)

Source from the content-addressed store, hash-verified

20 self.avg = np.mean(y)
21
22 def predict(self, X):
23 pred = np.empty(X.shape[0], dtype=np.float64)
24 pred.fill(self.avg)
25 return pred
26
27
28#######################################################################

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected