Exemplo n.º 1
0
def main():
    # Load the data and build preprocessor
    p_train = Preprocessor('train')
    p_test = Preprocessor('test')

    # Get feature vectors and labels for both training and testing data
    X_train, y_train = p_train.get_values_all()
    X_test, y_test = p_test.get_values_all()

    print('==========Classification==========')
    # Random forest
    random_forest(X_train, y_train, X_test, y_test)

    # Logistic regression
    logistic_regression(X_train, y_train, X_test, y_test)

    # XGboost
    XGboost(X_train, y_train, X_test, y_test)

    print('==========Voting==========')
    # Voting
    voting(X_train, y_train, X_test, y_test)