def main(path, config, reprep=False): if reprep: culled_dataset = prep_dataset.main(path, config) dataset = culled_dataset else: culled_dataset_filename = os.path.join(path, config.culled_datasets_path, config.culled_dataset_name) culled_dataset = fad.load(culled_dataset_filename) dataset = culled_dataset if 0: raw_dataset_name = os.path.join(path, config.raw_datasets_path, config.raw_dataset_name) raw_dataset = fad.load(raw_dataset_name) prep_dataset.prep_data(raw_dataset, path, config) dataset = raw_dataset figure_path = os.path.join(path, config.figure_path) plot_heatmaps.pdf_book(config, dataset, save_figure_path=os.path.join(figure_path, 'heatmaps/') ) #plot_spagetti.main(config, dataset, save_figure_path=os.path.join(figure_path, 'spagetti/') ) #plot_activity_histograms.main(dataset, save_figure_path=os.path.join(figure_path, 'activity/') ) #plot_distance_histograms.plot_distance_histogram(config, dataset, save_figure_path='') plot_landing_histogram.plot_landing_histogram(config, dataset) sachead.main(config, dataset)
def main(path, config, options): h5 = options.h5 odor = options.odor try: generate_empty_data_directory.main(path, config) except: 'Could not make empty data directory -- probably exists already!' return h5_path = os.path.join(path, config.h5_path) shutil.move(h5, h5_path) if odor is not None: odor_path = os.path.join(path, config.odor_control_path) shutil.move(odor, odor_path) if config.h5_files is not None: save_h5_to_dataset.main(path, config) prep_dataset.main(path, config) make_plots.main(path, config)
def main(path, config, options): h5 = options.h5 # make file structure try: generate_empty_data_directory.main(path, config) except: 'Could not make empty data directory -- probably exists already!' return # move h5 file h5_path = os.path.join(path, config.h5_path) shutil.move(h5, h5_path) # save_h5_to_dataset.py: do raw dataset analysis if config.h5_files is not None: save_h5_to_dataset.main(path, config) # prep_dataset.py: load raw dataset, cull data, apply other functions prep_dataset.main(path, config) # make_plots.py: make all the plots you want make_plots.main(path, config)
def main(path, config): if 0: culled_dataset = prep_dataset.main(path, config) dataset = culled_dataset if 1: raw_dataset_name = os.path.join(path, config.raw_datasets_path, config.raw_dataset_name) raw_dataset = fad.load(raw_dataset_name) prep_dataset.prep_data(raw_dataset, path, config) dataset = raw_dataset figure_path = os.path.join(path, config.figure_path) plot_heatmaps.main(dataset, save_figure_path=os.path.join(figure_path, 'heatmaps/') ) plot_spagetti.main(dataset, save_figure_path=os.path.join(figure_path, 'spagetti/') ) plot_activity_histograms.main(dataset, save_figure_path=os.path.join(figure_path, 'activity/') )