# Path: src/main/config.py
# TRAIN_SPLIT_FILE = os.path.join('data','classification_data','training_split.csv')
# TEST_SPLIT_FILE = os.path.join('data','classification_data','test_split.csv')
# VAL_SPLIT_FILE = os.path.join('data','classification_data','dev_split.csv')
# D_ND_DIR = os.path.join('data','disc_nondisc')
# POS_NEG_DIR = os.path.join('data','pos_neg')
# SEL_FEAT_TRAIN_REGULAR_CLASSIFY = os.path.join('data','selected_features','regular','classify','train')
# SEL_FEAT_TEST_REGULAR_CLASSIFY = os.path.join('data','selected_features','regular','classify','test')
# SEL_FEAT_VAL_REGULAR_CLASSIFY = os.path.join('data','selected_features','regular','classify','val')
# SEL_FEAT_TRAIN_REGULAR_ESTIMATE = os.path.join('data','selected_features','regular','estimate','train')
# SEL_FEAT_VAL_REGULAR_ESTIMATE = os.path.join('data','selected_features','regular','estimate','val')
# SEL_FEAT_TEST_REGULAR_ESTIMATE = os.path.join('data','selected_features','regular','estimate','test')
# ALL_FEAT_TRAIN_REGULAR_CLASSIFY = os.path.join('data','all_features','regular','classify','train')
# ALL_FEAT_TEST_REGULAR_CLASSIFY = os.path.join('data','all_features','regular','classify','test')
# ALL_FEAT_VAL_REGULAR_CLASSIFY = os.path.join('data','all_features','regular','classify','val')
# ALL_FEAT_TRAIN_REGULAR_ESTIMATE = os.path.join('data','all_features','regular','estimate','train')
# ALL_FEAT_VAL_REGULAR_ESTIMATE = os.path.join('data','all_features','regular','estimate','val')
# ALL_FEAT_TEST_REGULAR_ESTIMATE = os.path.join('data','all_features','regular','estimate','test')
# SEL_FEAT_TRAIN_NORMALIZED_CLASSIFY = os.path.join('data','selected_features','normalize','classify','train')
# SEL_FEAT_VAL_NORMALIZED_CLASSIFY = os.path.join('data','selected_features','normalize','classify','val')
# SEL_FEAT_TRAIN_NORMALIZED_ESTIMATE = os.path.join('data','selected_features','normalize','estimate','train')
# SEL_FEAT_VAL_NORMALIZED_ESTIMATE = os.path.join('data','selected_features','normalize','estimate','val')
# RESULTS_CLASSIFY = os.path.join('results','grid_search','classification')
# RESULTS_ESTIMATE = os.path.join('results','grid_search','regression')
# SEL_FEAT = os.path.join('data','selected_features')
# ALL_FEAT = os.path.join('data','all_features')
# ANOVA_DIR = os.path.join('results','anova')
# GRID_SEARCH_CLF_DIR = os.path.join('results','grid_search','classification')
# GRID_SEARCH_REG_DIR = os.path.join('results','grid_search','regression')


import pandas as pd
import os
from ..main import config

def add_labels():
	split_file = config.TEST_SPLIT_FILE
	split_df = pd.read_csv(split_file)
	combined_file = os.path.join('data','classification_data','combined_WoZ+AI+Framing+PDHA_meta.csv')
	combined_df = pd.read_csv(combined_file)
	test_ids = split_df['participant_ID'].tolist()
	combined_df = combined_df[combined_df['Participant'].isin(test_ids)]
	combined_df = combined_df[['Participant','PTSD_binary','PTSD_score']]
	combined_df.rename(columns={'Participant':'Participant_ID' , 'PTSD_binary':'PHQ_Binary' , 'PTSD_score':'PHQ_Score'}, inplace=True)
	#print combined_df

# Path: src/main/config.py
# TRAIN_SPLIT_FILE = os.path.join('data','classification_data','training_split.csv')
# TEST_SPLIT_FILE = os.path.join('data','classification_data','test_split.csv')
# VAL_SPLIT_FILE = os.path.join('data','classification_data','dev_split.csv')
# D_ND_DIR = os.path.join('data','disc_nondisc')
# POS_NEG_DIR = os.path.join('data','pos_neg')
# SEL_FEAT_TRAIN_REGULAR_CLASSIFY = os.path.join('data','selected_features','regular','classify','train')
# SEL_FEAT_TEST_REGULAR_CLASSIFY = os.path.join('data','selected_features','regular','classify','test')
# SEL_FEAT_VAL_REGULAR_CLASSIFY = os.path.join('data','selected_features','regular','classify','val')
# SEL_FEAT_TRAIN_REGULAR_ESTIMATE = os.path.join('data','selected_features','regular','estimate','train')
# SEL_FEAT_VAL_REGULAR_ESTIMATE = os.path.join('data','selected_features','regular','estimate','val')
# SEL_FEAT_TEST_REGULAR_ESTIMATE = os.path.join('data','selected_features','regular','estimate','test')
# ALL_FEAT_TRAIN_REGULAR_CLASSIFY = os.path.join('data','all_features','regular','classify','train')
# ALL_FEAT_TEST_REGULAR_CLASSIFY = os.path.join('data','all_features','regular','classify','test')
# ALL_FEAT_VAL_REGULAR_CLASSIFY = os.path.join('data','all_features','regular','classify','val')
# ALL_FEAT_TRAIN_REGULAR_ESTIMATE = os.path.join('data','all_features','regular','estimate','train')
# ALL_FEAT_VAL_REGULAR_ESTIMATE = os.path.join('data','all_features','regular','estimate','val')
# ALL_FEAT_TEST_REGULAR_ESTIMATE = os.path.join('data','all_features','regular','estimate','test')
# SEL_FEAT_TRAIN_NORMALIZED_CLASSIFY = os.path.join('data','selected_features','normalize','classify','train')
# SEL_FEAT_VAL_NORMALIZED_CLASSIFY = os.path.join('data','selected_features','normalize','classify','val')
# SEL_FEAT_TRAIN_NORMALIZED_ESTIMATE = os.path.join('data','selected_features','normalize','estimate','train')
# SEL_FEAT_VAL_NORMALIZED_ESTIMATE = os.path.join('data','selected_features','normalize','estimate','val')
# RESULTS_CLASSIFY = os.path.join('results','grid_search','classification')
# RESULTS_ESTIMATE = os.path.join('results','grid_search','regression')
# SEL_FEAT = os.path.join('data','selected_features')
# ALL_FEAT = os.path.join('data','all_features')
# ANOVA_DIR = os.path.join('results','anova')
# GRID_SEARCH_CLF_DIR = os.path.join('results','grid_search','classification')
# GRID_SEARCH_REG_DIR = os.path.join('results','grid_search','regression')


# Path: src/helpers/add_test_labels.py
import pandas as pd
import os
from ..main import config


def add_labels():
	split_file = config.TEST_SPLIT_FILE
	split_df = pd.read_csv(split_file)
	combined_file = os.path.join('data','classification_data','combined_WoZ+AI+Framing+PDHA_meta.csv')
	combined_df = pd.read_csv(combined_file)
	test_ids = split_df['participant_ID'].tolist()
	combined_df = combined_df[combined_df['Participant'].isin(test_ids)]
	combined_df = combined_df[['Participant','PTSD_binary','PTSD_score']]
	combined_df.rename(columns={'Participant':'Participant_ID' , 'PTSD_binary':'PHQ_Binary' , 'PTSD_score':'PHQ_Score'}, inplace=True)
	#print combined_df

	combined_df.to_csv(config.TEST_SPLIT_FILE, index=False)