Skip to content

Commit 111d947

Browse files
committed
make figures have original widths
1 parent 58c63e4 commit 111d947

File tree

2 files changed

+17
-1
lines changed

2 files changed

+17
-1
lines changed

ibllib/pipes/tasks.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ def register_images(self, **kwargs):
165165
if self.one and len(self.plot_tasks) > 0:
166166
for plot_task in self.plot_tasks:
167167
try:
168-
_ = plot_task.register_images()
168+
_ = plot_task.register_images(widths=['orig'])
169169
except Exception:
170170
_logger.error(traceback.format_exc())
171171
continue

ibllib/plots/figures.py

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -350,6 +350,22 @@ def get_probe_signature(self):
350350
output_signature = [('spike_sorting_raster*.png', f'snapshot/{self.pname}', True)]
351351
self.signature = {'input_files': input_signature, 'output_files': output_signature}
352352

353+
def get_signatures(self, **kwargs):
354+
files_spikes = Path(self.session_path).joinpath('alf').rglob('spikes.times.npy')
355+
folder_probes = [f.parent for f in files_spikes]
356+
357+
full_input_files = []
358+
for sig in self.signature['input_files']:
359+
for folder in folder_probes:
360+
full_input_files.append((sig[0], str(folder.relative_to(self.session_path)), sig[2]))
361+
if len(full_input_files) != 0:
362+
self.input_files = full_input_files
363+
else:
364+
self.input_files = self.signature['input_files']
365+
366+
self.output_files = self.signature['output_files']
367+
368+
353369

354370
class BadChannelsAp(ReportSnapshotProbe):
355371
"""

0 commit comments

Comments
 (0)