Skip to content

Utility functions to manipulate and analyze behavior videos and associated data (tracking...) acquired in various setups and settings.

License

Notifications You must be signed in to change notification settings

NeLy-EPFL/utils_behavior

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

utils_behavior

Utility functions to manipulate and analyze behavior videos and associated data (tracking...) acquired in various setups and settings.

This directory contains a few useful scripts that can be used in many projects. It includes images and video manipulation tools, as well as some processing (filtering etc.) and analysis (Bootstrap, etc.) scripts.

Tools

Combine.sh

This script is used to combine videos and associated processing data. It was used in the Maze Recorder project to rearrange the data folder in a more efficient way, storing each video, metadata and associated data together in dediacted folders.

framecapture.py

This script is used to extract and save frames from a video.

GrabImage.py

This script is used to grab one frame from a video and save it as an image.

Make_TrackedVideo.py

This script loads predicted positions from a .h5 datafile generated by SLEAP tracking of a video, and creates a video with the tracked positions overlaid on the original video.

OrderVideos.py

This script is used to rearrange videos in a data folder by moving them all to dedicated folders. It was used in the Maze Recorder project to rearrange early data folders that contained all videos in the same folder.

OutputTest.ipynb

This script generates a random output to test git related scripts that manipulate jupyter notebooks outputs before commiting them to the repository.

Processing.py

This script is a library of processing and analysis functions that are used in many other scripts in this repository.

Functions

  • Savgol-Golay lowpass filter : lowpass filter with a moving window. Compared to the butterworth filter, it better captures the shape of the signal, but it is slightly less efficient at removing noise. It is used to smooth the position of the ball in the Ball Pushing project.

  • butter_lowpass_filter : lowpass filter with a butterworth filter. Compared to the savgol-golay filter, it is more efficient at removing noise, but it can distort the shape of the signal and is not as good to capture sharp meaningful changes in the signal.

  • draw_bs_ci : draw bootstrap confidence intervals.

About

Utility functions to manipulate and analyze behavior videos and associated data (tracking...) acquired in various setups and settings.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published