sgoldenlab / simba

SimBA (Simple Behavioral Analysis), a pipeline and GUI for developing supervised behavioral classifiers
https://simba-uw-tf-dev.readthedocs.io/
GNU General Public License v3.0
287 stars 140 forks source link

ROI data analysis #92

Closed Wutaijing9 closed 3 years ago

Wutaijing9 commented 3 years ago

**This was amazing to replace manual behavior annotation. When analyzing ROI data, I got cumulative entry times and cumulative spending time. But this was not enough for further analysis. I need to know the exact time and frame mouse entry and exit from the ROI area, like from frame 675 mouse begin to entry in the ROI area and frame #700 mouse exit from it OR the exact time. Could you add this feature in ROI analysis? Thanks a lot!

sgoldenlab commented 3 years ago

Hello @Wutaijing9 !

Yes, what we can do is generate a sub-folder in the project logs folder, containing one CSV output file per video analyzed, the file lists the animal ID together with the shape and entry and exit frame.. the individual CSV files would look like this. Do you think that would work?

If the animal does not exit the ROI before the end of the video, the Exit_frame would be read as -1.

Screen Shot 2021-02-26 at 6 13 27 AM

sgoldenlab commented 3 years ago

If you update to the latest simba-uw-tf-dev version, you should have access to it. It is documented at the end of Part II of this tutorial : https://github.com/sgoldenlab/simba/blob/master/docs/ROI_tutorial.md#part-2-analyzing-roi-data

Lat me know if it works!