backend better output
This commit is contained in:
parent
f4d669f1d6
commit
1832bae72c
@ -231,7 +231,7 @@ def populate_datasets(data_path, update=False):
|
|||||||
|
|
||||||
inserts = Datasets.get_template_tuple()
|
inserts = Datasets.get_template_tuple()
|
||||||
inserts["dataset_id"] = dset_name
|
inserts["dataset_id"] = dset_name
|
||||||
inserts["data_source"] = data_path
|
inserts["data_source"] = os.path.abspath(data_path)
|
||||||
inserts["data_host"] = socket.getfqdn()
|
inserts["data_host"] = socket.getfqdn()
|
||||||
inserts["experimenter"] = experimenter
|
inserts["experimenter"] = experimenter
|
||||||
inserts["recording_date"] = rec_date
|
inserts["recording_date"] = rec_date
|
||||||
@ -434,7 +434,6 @@ def scan_folder_for_repros(dataset):
|
|||||||
repro_settings, stim_indices = read_stimuli_file(dataset["data_source"])
|
repro_settings, stim_indices = read_stimuli_file(dataset["data_source"])
|
||||||
repro_counts = {}
|
repro_counts = {}
|
||||||
cell_id = (Cells * CellDatasetMap * (Datasets & "dataset_id = '%s'" % dataset["dataset_id"])).fetch("cell_id", limit=1)[0]
|
cell_id = (Cells * CellDatasetMap * (Datasets & "dataset_id = '%s'" % dataset["dataset_id"])).fetch("cell_id", limit=1)[0]
|
||||||
total = len(repro_settings)
|
|
||||||
for i, (rs, si) in enumerate(zip(repro_settings, stim_indices)):
|
for i, (rs, si) in enumerate(zip(repro_settings, stim_indices)):
|
||||||
rp = Repros.get_template_tuple()
|
rp = Repros.get_template_tuple()
|
||||||
path = []
|
path = []
|
||||||
@ -449,7 +448,6 @@ def scan_folder_for_repros(dataset):
|
|||||||
if not find_key_recursive(rs, "repro", path):
|
if not find_key_recursive(rs, "repro", path):
|
||||||
find_key_recursive(rs, "RePro", path)
|
find_key_recursive(rs, "RePro", path)
|
||||||
rp["repro_name"] = deep_get(rs, path, "None")
|
rp["repro_name"] = deep_get(rs, path, "None")
|
||||||
progress(i+1, total, "scanning repro %s" % rp["repro_name"])
|
|
||||||
|
|
||||||
path = []
|
path = []
|
||||||
if rp["repro_name"] in repro_counts.keys():
|
if rp["repro_name"] in repro_counts.keys():
|
||||||
@ -469,7 +467,10 @@ def scan_folder_for_repros(dataset):
|
|||||||
repro.pop("repro_name")
|
repro.pop("repro_name")
|
||||||
repro.pop("start")
|
repro.pop("start")
|
||||||
repro.pop("duration")
|
repro.pop("duration")
|
||||||
|
|
||||||
|
total = len(si.keys())
|
||||||
for j, k in enumerate(si.keys()):
|
for j, k in enumerate(si.keys()):
|
||||||
|
progress(j+1, total, "scanning repro %s" % rp["repro_name"])
|
||||||
s = int(si[k])
|
s = int(si[k])
|
||||||
stim_start = 0.
|
stim_start = 0.
|
||||||
path = []
|
path = []
|
||||||
@ -495,7 +496,9 @@ def scan_folder_for_repros(dataset):
|
|||||||
stim["stimulus_name"] = ""
|
stim["stimulus_name"] = ""
|
||||||
stim.update(repro)
|
stim.update(repro)
|
||||||
Stimuli.insert1(stim, skip_duplicates=True)
|
Stimuli.insert1(stim, skip_duplicates=True)
|
||||||
print("\n")
|
print(" " *120, end='\r')
|
||||||
|
#if i < len(repro_settings):
|
||||||
|
# print((" " * 150), end="\r")
|
||||||
|
|
||||||
|
|
||||||
def populate_repros(data_path):
|
def populate_repros(data_path):
|
||||||
|
Loading…
Reference in New Issue
Block a user