src.clean package

Submodules

src.clean.combine module

Combines all outputs together

src.clean.combine.combine_output(input_dir: str, output_dir: str, zoom_arr=None, dump_pickle: bool = True, **kwargs) list

Combines data streams together into list of dictionaries per trial (one dictionary per condition/performer)

src.clean.combine.save_questionnaire(xls_path: str, df_list: list) None

Saves the questionnaire to the processed data folder

src.clean.gen_pretty_midi module

Generates MIDI data in Python-compatible form and cleans

src.clean.gen_pretty_midi.gen_pm_output(input_dir, **kwargs) list

Iterates through MIDI BPM files in input directory and extracts data (onset, pitch, velocity) using PrettyMIDI

src.clean.gen_pretty_midi.gen_raw_midi_output(input_dir, **kwargs) list

Iterates through raw MIDI files in input directory and extracts data (onset, pitch, velocity) using PrettyMIDI

src.clean.gen_questionnaire module

Generates questionnaire data and formats

src.clean.gen_questionnaire.gen_perceptual_study_output(input_dir: str, file_pre: str = 'Database View ', file_post: str = ' -  Dashboard') dict

Clean perceptual study output: return as dictionary, with experimental conditions as keys and answers as values

src.clean.gen_questionnaire.gen_questionnaire_output(input_dir: str) list

Clean questionnaire output: return as list of dataframes, one dataframe per trial (both participants)

src.clean.make_dataset module

Central file for running all analysis functions, called by run.cmd

Module contents

Scripts to generate final dataset from raw data