Skip to content

Commit

Permalink
Merge branch 'rcp' of https://github.com/CBroz1/spyglass into rcp
Browse files Browse the repository at this point in the history
  • Loading branch information
CBroz1 committed Nov 13, 2024
2 parents 1ed831e + 1587997 commit 7547fe2
Showing 1 changed file with 1 addition and 9 deletions.
10 changes: 1 addition & 9 deletions src/spyglass/utils/nwb_hash.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,12 +82,7 @@ def collect_names(self, file):
"""Collects all object names in the file."""

def collect_items(name, obj):
if isinstance(file.get(name, getclass=True), h5py.SoftLink):
print("SoftLink:", name)
items_to_process.append((name, file.get(name, getclass=True)))
__import__("pdb").set_trace()
else:
items_to_process.append((name, obj))
items_to_process.append((name, obj))

items_to_process = []
file.visititems(collect_items)
Expand Down Expand Up @@ -144,8 +139,6 @@ def compute_hash(self) -> str:
desc=self.file.filename.split("/")[-1].split(".")[0],
disable=not self.verbose,
):
if "basic" in name:
__import__("pdb").set_trace()
self.hashed.update(name.encode())
for attr_key in sorted(obj.attrs):
attr_value = obj.attrs[attr_key]
Expand All @@ -158,7 +151,6 @@ def compute_hash(self) -> str:
elif isinstance(obj, h5py.SoftLink):
# TODO: Check that this works
self.hashed.update(obj.path.encode())
print("SoftLink:", obj.path)
elif isinstance(obj, h5py.Group):
for k, v in obj.items():
self.hashed.update(k.encode())
Expand Down

0 comments on commit 7547fe2

Please sign in to comment.