def METHOD_NAME():
    mode2_x, mode2_y = readfile("mode2.csv", 0)
    mode3_x, mode3_y = readfile("mode3.csv", 1)
    mode4_x, mode4_y = readfile("mode4.csv", 2)
    # Merge two sample sets
    x = np.concatenate((mode2_x, mode3_x, mode4_x), axis=0)
    y = np.concatenate((mode2_y, mode3_y, mode4_y), axis=0)
    # Inspect
    # fs = 256000
    # frame = 30
    # x_seg = mode2_x[frame,:]
    # spec_data(x_seg, fs, True)
    # x_seg = mode3_x[frame,:]
    # spec_data(x_seg, fs, True)
    # x_seg = mode3_x[frame,:]
    # spec_data(x_seg, fs, True)
    # Transform
    fs = 256000
    for i in range(x.shape[0]):
        x_seg = x[i, :]
        sxx = spec_data(x_seg, fs) / x_seg.shape[0]
        sxx = sxx.reshape((1, sxx.shape[0], sxx.shape[1]))
        if i == 0:
            x_sxx = sxx
        else:
            x_sxx = np.vstack((x_sxx, sxx))
    x = x_sxx
    print("max", np.max(x))
    print("min", np.min(x))
    print("shape", x.shape)
    # Split into train and test
    train_percent = 0.5
    columns = x.shape[0]
    train_columns = int(np.floor(train_percent * columns))
    print(train_columns)
    # Shuffle
    idx = np.random.permutation(len(y))
    x = x[idx]
    y = y[idx]
    x_train = x[:train_columns, :]
    y_train = y[:train_columns]
    x_test = x[train_columns:, :]
    y_test = y[train_columns:]
    num_classes = len(np.unique(y))
    y_train = np_utils.to_categorical(y_train, num_classes)
    y_test = np_utils.to_categorical(y_test, num_classes)
    # Add a fourth column for input spec
    x_train = x_train.reshape((x_train.shape[0], x_train.shape[1], x_train.shape[2], 1))
    x_test = x_test.reshape((x_test.shape[0], x_test.shape[1], x_test.shape[2], 1))
    print("num_classes", num_classes)
    return x_train, y_train, x_test, y_test, num_classes