improve analysis

This commit is contained in:
alexanderott
2021-02-13 11:36:17 +01:00
parent f7926e02f5
commit 00843beb05
8 changed files with 97 additions and 36 deletions

View File

@@ -79,6 +79,13 @@ class DatParser(AbstractParser):
def has_sam_recordings(self):
return exists(self.sam_file)
def get_measured_repros(self):
repros = []
for metadata, key, data in Dl.iload(self.stimuli_file):
repros.extend([d["repro"] for d in metadata if "repro" in d.keys()])
return sorted(np.unique(repros))
def get_baseline_length(self):
lengths = []
for metadata, key, data in Dl.iload(self.baseline_file):