Utils

benchmark_ea.python.utils.check_ap_at_zero(stim_ind, volts, opt_stim_name_list, stim_file)[source]

Kyung function to check if a volt should be penalized for having an AP before there should be one. Modified to take in “volts” as a list of individuals instead of “volt”

benchmark_ea.python.utils.convert_allen_data(opt_stim_name_list, stim_file, dts)[source]

Function that sets up our new allen data every run. It reads and writes every stimi and timesi and removes previous ones. Using csv writer to write timesi so it reads well.

benchmark_ea.python.utils.getVolts(vs_fn, idx)[source]

Helper function that gets volts from data and shapes them for a given stim index

benchmark_ea.python.utils.get_first_zero(stim)[source]

Kyung helper function to penalize AP where there should not be one

benchmark_ea.python.utils.stim_swap(idx, i)[source]

Stim swap takes ‘idx’ which is the stim index % 8 and ‘i’ which is the actual stim idx and then deletes the one at ‘idx’ and replaces it with the stim at i so that neuroGPU reads stims like 13 as stim_raw5 (13 % 8)

benchmark_ea.python.utils.top_SFs(n_stims, opt_stim_list, weights, run_num=None, max_sfs=0)[source]

finds scoring functions w/ weight over 50 and pairs them with that stim and sends them to mapping function so that we will run so many processes Arguments ————————————————————– run_num: the number of times neuroGPU has ran for 8 stims, keep track of what stims we are picking out score functions for