YttriLab / B-SOID

Behavioral segmentation of open field in DeepLabCut, or B-SOID ("B-side"), is a pipeline that pairs unsupervised pattern recognition with supervised classification to achieve fast predictions of behaviors that are not predefined by users.
GNU General Public License v3.0
190 stars 54 forks source link

Error while 'generating video snippets for interpretation' (KeyError: 'bit_rate') #39

Open njb615 opened 3 years ago

njb615 commented 3 years ago

Hello!

I've encountered an error while using B-SOiD v2.0 on Windows. While trying to 'generate video snippets for interpretation' I'm presented with an error that says the following:

KeyError: 'bit_rate' Traceback:

File "c:\users\nick\anaconda3\envs\bsoid_v2\lib\site-packages\streamlit\script_runner.py", line 332, in _run_script exec(code, module.dict) File "C:\Users\Nick\OneDrive - The University Of Newcastle\Desktop\B-SOID\B-SOID-master\B-SOID-master\bsoid_app.py", line 69, in creator.main() File "C:\Users\Nick\OneDrive - The University Of Newcastle\Desktop\B-SOID\B-SOID-master\B-SOID-master\bsoid_app\video_creator.py", line 268, in main self.setup() File "C:\Users\Nick\OneDrive - The University Of Newcastle\Desktop\B-SOID\B-SOID-master\B-SOID-master\bsoid_app\video_creator.py", line 120, in setup self.bit_rate = int(video_info['bit_rate'])

This appears after I've selected the corresponding video which matches the h5 file. Do you think it could be related to the fact I don't have any audio throughout my videos?

Thank you!

runninghsus commented 3 years ago

Hi @njb615

The video seemed to have been perturbed that it does not contain the bitrate information. Can you take a screenshot of the "properties -> details" tab of the video?

pozel commented 2 years ago

Hi @njb615, I had this error using an avi file (which must have been corrupted, although I am not sure how this may have happened. I recorded this video through SpinView using the Mjpg video recording type at a 90% compression quality. I think the compression may resulted in a faulty bitrate encoding), but was solved when using the mp4 converted version of the video.