multiclass-multioutput classification I am new in ML field and I got this question when classifying the DEAP data with sklearn. There is my data set description.

The whole data is a (1280*322) matrix，which the last two columns are the labels and the rest of it is the feature（1280*320).  Because the output of the labels has three categorical values, I try to predict this problem with RandomForestClassifier. However, the mean accuracy of the result is just 0.222656250. Would you give me any clues about this problem? Thanks for your patience. the detail code as follows:



RandomForestClassifier

import scipy.io
from sklearn.datasets import make_classification
from sklearn.multioutput import MultiOutputClassifier
from sklearn.ensemble import RandomForestClassifier
from sklearn.utils import shuffle
import numpy as np

def mydata():
    data = scipy.io.loadmat('/home/jdang/Documents/RenKaimeng/EEGfile/Classification-for-DEAP/whole.mat')

    # initialization

    x_vals = data['all_data'][:,0:320]

    y_vals_Valence = np.array([0 if each=='Neg'  else 1 if each =='Neu' else 2 for each in data['all_data'][:,320]])
    y_vals_Arousal = np.array([0 if each=='Pas'  else 1 if each =='Neu' else 2 for each in data['all_data'][:,321]])

    Y = np.vstack((y_vals_Valence, y_vals_Arousal)).T

    DEAP_x_train = x_vals[:-256] #using 80% of whole data for training
    DEAP_x_test = x_vals[-256:]  #using 20% of whole data for testing
    DEAP_y_train = Y[:-256]
    DEAP_y_test = Y[-256:]


    forest = RandomForestClassifier(n_estimators=100, max_depth=2,random_state=1)
    multi_target_forest = MultiOutputClassifier(forest, n_jobs=-1)
    multi_target_forest.fit(DEAP_x_train, DEAP_y_train)

    print("the result of MutliOutput-classification-using-RandomForest ")
    print('The mean square error %10.9f ' % np.mean((multi_target_forest.predict(DEAP_x_test)-DEAP_y_test)**2))  # The mean square error

    print('the mean accuracy on the given test data and labels %10.9f'% multi_target_forest.score(DEAP_x_test, DEAP_y_test))
Increasing the max_depth and the n_estimators might help. Especially the max_depth (2 is way too low). Take a look at that.