Skip to content

Commit

Permalink
Fix missing pos interval map entry in pose estimation (#1208)
Browse files Browse the repository at this point in the history
* fix missing pos interval map entry in pose estimation

* update changelog

* strip extra key values in no_transaction_make
  • Loading branch information
samuelbray32 authored Jan 16, 2025
1 parent 2a37bff commit dbae127
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 1 deletion.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,11 @@
- Ensure merge tables are declared during file insertion #1205
- Update URL for DANDI Docs #1210

### Pipelines

- Position
- Allow population of missing `PositionIntervalMap` entries during population of `DLCPoseEstimation` #1208

## [0.5.4] (December 20, 2024)

### Infrastructure
Expand Down
3 changes: 3 additions & 0 deletions src/spyglass/common/common_behav.py
Original file line number Diff line number Diff line change
Expand Up @@ -536,6 +536,9 @@ def _no_transaction_make(self, key):
EPSILON = 0.51 # tolerated time diff in bounds across epoch/pos
no_pop_msg = "CANNOT POPULATE PositionIntervalMap"

# Strip extra info from key if not passed via populate call
key = {k: v for k, v in key.items() if k in self.primary_key}

nwb_file_name = key["nwb_file_name"]
pos_intervals = get_pos_interval_list_names(nwb_file_name)
null_key = dict(key, position_interval_name="")
Expand Down
1 change: 0 additions & 1 deletion src/spyglass/position/v1/position_dlc_pose_estimation.py
Original file line number Diff line number Diff line change
Expand Up @@ -254,7 +254,6 @@ def _logged_make(self, key):
"nwb_file_name": key["nwb_file_name"],
"epoch": key["epoch"],
},
populate_missing=False,
)
)
if interval_list_name:
Expand Down

0 comments on commit dbae127

Please sign in to comment.