Skip to content

Getting an error with Knn and Svm  #2

Description

@MouliBhaskaran

File "C:\Users\mouli.bhaskaran\Desktop\Python\Digital Clock\venv\lib\site-packages\streamlit\scriptrunner\script_runner.py",
line 475, in _run_script
exec(code, module.dict)
File "C:\Users\mouli.bhaskaran\Desktop\Python\Digital Clock\ml_app.py", line 80, in
clf.fit(X_train, y_train)
File "C:\Users\mouli.bhaskaran\Desktop\Python\Digital Clock\venv\lib\site-packages\sklearn\neighbors_classification.py", line 200, in fit
return self._fit(X, y)
File "C:\Users\mouli.bhaskaran\Desktop\Python\Digital Clock\venv\lib\site-packages\sklearn\neighbors_base.py", line 543, in
_fit
and self.n_neighbors >= self._fit_X.shape[0] // 2
TypeError: '>=' not supported between instances of 'list' and 'int'

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions