Skip to content
Snippets Groups Projects
Commit c09d209d authored by Andi Gerken's avatar Andi Gerken
Browse files

Fixed bug

parent 9f2ae981
Branches
No related tags found
No related merge requests found
Pipeline #48641 failed
......@@ -94,8 +94,8 @@ def validate(args=None):
error_code = 0
for file, sf in sf_dict.items():
filled_file = (str)(file).ljust(max_filename_width + 3)
file.close()
validity, validity_message = sf.validate(strict_validate=False)
sf.close()
if not validity:
error_code = 1
print(f"{filled_file}:{validity}\t{validity_message}")
......
......@@ -752,8 +752,11 @@ class File(h5py.File):
elif isinstance(c, list):
this_c = c[fish_id]
if max_timesteps is None:
max_timesteps = poses.shape[1] - 1
max_timesteps = (
min(max_timesteps, poses.shape[1] - 1)
if max_timesteps is not None
else poses.shape[1] - 1
)
timesteps = min(max_timesteps + skip_timesteps, poses.shape[1] - 1)
for t in range(skip_timesteps, timesteps, step_size):
if lw_distances:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment