Код
import pandas
from sklearn import tree
table = pandas.read_csv('weather.csv')
X = table.loc[:, ['humidity', 'pressure']]
y = table['label']
classifier = tree.DecisionTreeClassifier(max_depth=2)
classifier.fit(X, y)
prediction = classifier.predict([[80, 1009]])
print(prediction)
Ошибка
NameError: name 'table' is not defined
FileNotFoundError: File b'weather.csv' does not exist
NameError: name 'table' is not defined
NotFittedError: This DecisionTreeClassifier instance is not fitted yet. Call 'fit' with appropriate arguments before using this method.