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
299 stars 145 forks source link

Include Timestamp for Each Behavioral Bout #293

Open mrnels19 opened 1 year ago

mrnels19 commented 1 year ago

Would it be possible for SimBA to include the timestamp for each behavioral bout in a video? I know that the time of first occurrence for each behavior is reported in the .csv files under "Analyze Machine Predictions" and in each time bin in "Time Bins: Machine Predictions." However, the timestamp for every behavioral bout in the video is not listed. By including the timestamp for each behavioral bout, patterns of behavior can be identified in a video.

sronilsson commented 1 year ago

Hi @mrnels19, that's a good point. To be honest, I'm losing track on all the functionalities and it feels like this should already be available through some menu somewhere but I don't know lol. It is calculated by THIS function and SimBA uses it as base for many of other calculations.

How about I insert another checkbox in this pop-up menu in the screengrab below, that when checked outputs a CSV that list the start times, end times, start frames and end-frames of all selected behaviors in all videos, does that work?

image
mrnels19 commented 1 year ago

Thank you! This update sounds great.

mrnels19 commented 1 year ago

By the way, do you know the name of the most updated version of SimBA that will have this feature?

sronilsson commented 1 year ago

@mrnels19 It will be in 1.74.4 - if you update with pip install simba-uw-tf-dev --upgrade you should see it:

image

If you check this button, you can expect a file in the logs folder named and looking like this:

detailed_bout_data_summary_20231011091832.csv

Let me know if that is what your looking for or if anything is missing!

Simon