Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/AssemblyAI-Community/Machine-Learning-From-Scratch
/ fit
Method
fit
01 KNN/KNN.py:12–14 ·
view source on GitHub ↗
(self, X, y)
Source
from the content-addressed store, hash-verified
10
self.k = k
11
12
def
fit(self, X, y):
13
self.X_train = X
14
self.y_train = y
15
16
def
predict(self, X):
17
predictions = [self._predict(x)
for
x in X]
Callers
1
train.py
File · 0.45
Calls
no outgoing calls
Tested by
no test coverage detected