model_selection
X_train, X_test, y_train, y_test = train_test_split( X, y,
test_size=0.33,
shuffle=False
random_state=42)
Metrics
from sklearn.metrics import classification_report,accuracy_score
y_prob = self.model.predict(self.X_train)
y_pred = np.argmax(y_prob,axis=1)
y_true = np.argmax(self.y_train,axis=1)
# label_list 是一个标签列表
res = classification_report(y_true,y_pred,target_names=label_list)