Closed MichaelCoulter closed 1 month ago
Hi @MichaelCoulter - Please share your pose_estimation_key
value.
The position pipeline expects epochs of the format pos # valid times
. My guess is that convert_epoch_interval_name_to_position_interval
is failing on a digit it can't substring.
@CBroz1, there won't be a matchingpos # valid time
interval for epochs without existing position tracking
It looks like the master branch has lost the changes from #973 that enabled the pipeline to run without existing position tracking. Looks like it happened in #870
ex)
thanks for figuring this out! here is the post estimation key if you need it: {'nwb_filename': 'RS1220240809.nwb', 'epoch': 2, 'video_file_num': 1, 'project_name': 'RS1220240809_run', 'dlc_model_name': 'RS1220240809_run_tutorial_01', 'dlc_model_params_name': 'default', 'task_mode': 'trigger'}
I'm getting this same error even though my spyglass is up to date
You may just need to run this prior to populating:
convert_epoch_interval_name_to_position_interval_name(
{
"nwb_file_name": key["nwb_file_name"],
"epoch": key["epoch"],
},
populate_missing=True, )
Checking the code, @CBroz1 is there a reason that this needs populate_missing=False
here?
Theres a no transaction make in convert_epoch_interval_name_to_position_interval_name
available which should let it be populated even in the DLCPoseEstimation.make()
I still get the same error when running the function on its own:
from spyglass.common.common_behav import convert_epoch_interval_name_to_position_interval_name
for epoch in [2,4,6,8]:
convert_epoch_interval_name_to_position_interval_name(
{
"nwb_file_name": "RS1220240810",
"epoch": epoch,
},
populate_missing=True, )
output:
[16:33:23][INFO] Spyglass: Found 0 interval list names found for RS1220240810 epoch 2
INFO:spyglass:Found 0 interval list names found for RS1220240810 epoch 2
---------------------------------------------------------------------------
IndexError Traceback (most recent call last)
Cell In[21], line 3
1 from spyglass.common.common_behav import convert_epoch_interval_name_to_position_interval_name
2 for epoch in [2,4,6,8]:
----> 3 convert_epoch_interval_name_to_position_interval_name(
4 {
5 "nwb_file_name": "RS1220240810",
6 "epoch": epoch,
7 },
8 populate_missing=True, )
File ~/spyglass/src/spyglass/common/common_behav.py:647, in convert_epoch_interval_name_to_position_interval_name(key, populate_missing)
644 PositionIntervalMap()._no_transaction_make(key)
645 pos_query = PositionIntervalMap & key
--> 647 if pos_query.fetch(pos_str)[0] == "":
648 logger.info(f"No position intervals found for {key}")
649 return []
IndexError: index 0 is out of bounds for axis 0 with size 0
wait disregard I forgot to put the .nwb it works fine
I'm trying to run the DLC pipeline with this command and i get the following error. I don't have trodes position for this session, so there is no entry in RawPosition, but I thought we found a way to run the code in this situation. Thanks. Command:
Error: