@@ -0,0 +1,1403 @@
+import pandas as pd%0A%0Adef get_features(data):%0A    grouped = data.groupby('video')%0A    X = %5B%5D%0A    y = %5B%5D%0A    for video, group in grouped:%0A        X_person = %5B%5D%0A        y_person = %5B%5D%0A        for i in range(len(group)):%0A            X_person.append(group.iloc%5Bi%5D.tolist()%5B1:-1%5D)%0A            y_person.append(group.iloc%5Bi%5D%5B'label'%5D)%0A        X.append(X_person)%0A        y.append(y_person)%0A    return X, y%0A%0Adef discriminative_feature(mode):%0A    if mode == %22visual%22:%0A        file = %22data/selected_features/discriminative_visual_selected.csv%22%0A    elif mode == %22acoustic%22:%0A        file = %22data/selected_features/discriminative_acoustic_selected.csv%22%0A    elif mode == %22linguistic%22:%0A        file = %22data/selected_features/discriminative_linguistic_selected.csv%22%0A    # else:%0A    #     file = %22data/selected_features/dummy.csv%22%0A    data = pd.read_csv(file)%0A    return get_features(data)%0A%0A%0Adef non_discriminative_feature(mode):%0A    if mode == %22visual%22:%0A        file = %22data/selected_features/nondiscriminative_visual_selected.csv%22%0A    elif mode == %22acoustic%22:%0A        file = %22data/selected_features/nondiscriminative_acoustic_selected.csv%22%0A    elif mode == %22linguistic%22:%0A        file = %22data/selected_features/nondiscriminative_linguistic_selected.csv%22%0A    # else:%0A    #     file = %22data/selected_features/dummy.csv%22%0A    data = pd.read_csv(file)%0A    return get_features(data)%0A%0A#print non_discriminative_feature(%22dummy%22)%0A%0A

read labels