import KNN
from numpy import *
def createDataSet():
group = [[1.0,1.1],[1.0,1.0],[0,0],[0,0.1]]
labels = ["A","A","B","B"]
return group,labels
group,labels = KNN.createDataSet()
print (createDataSet())
error running Times
C:\Users\17578\venv\Scripts\python.exe C:/Users/17578/.PyCharm2018.3/config/.py
Traceback (most recent call last):
File "C:/Users/17578/.PyCharm2018.3/config/.py", line 2, in <module>
import KNN
File "C:\Users\17578\venv\lib\site-packages\KNN.py", line 24
print(sortedDistIndicies[i])
^
TabError: inconsistent use of tabs and spaces in indentation
conventional solutions to TabError have been tried. "import KNN" may still be a problem in this place.