➜ test ✗ cat DecisionTree.py from sklearn import tree # 训练集 X = [[0, 0], [1, 1]] Y = [0, 1] # 定义一个DecisionTreeClassifier分类器 clf =…
Keep Learning
➜ test ✗ cat DecisionTree.py from sklearn import tree # 训练集 X = [[0, 0], [1, 1]] Y = [0, 1] # 定义一个DecisionTreeClassifier分类器 clf =…