一、随机划分
import numpy as np
from sklearn import datasets
iris = datasets.load_iris()
X = iris.data
y = iris.target
# 1)归一化前,将原始数据分割
from sklearn.model_selection import train_test_split
X_train,X_test,y_train,y_test = train_test_split(X, y, test_size=0.2,
2022-03-28 21:56:36
136KB
ar
ed
ff
1