Code for running code through the wake-tracking project, which tests whether some fish species can follow the wake of neighboring fish in the dark. Here we have developed python code for controlling devices during the running of experiments and the acquisition of kinematic data from the video recordings.
Read the following pages for tips on setting up the software and hardware for running experiments.
Running experiments entails video-recording the swimming of fish under controlled lighting conditions.
schooling_experiments.ipynb: Jupyter notebook that steps through the running of experiments.
def_runexperiments.py: Python functions called by schooling_experiments.ipynb to run experiments.
The execution of code is controlled by the "experiment_log" spreadsheet, which you will need to export from Google Sheets as a .csv file and save in the root directory for the project.
The code assumes the following directory structure. This will be self-generated when running code in schooling_experiments.ipynb.
Includes the following files:
acquire_kinematics.ipynb: Jupyter notebook that explains how to run the acquisition and includes the necessary code.
def_paths.py: Defines the data and video paths for the project. You need to add root paths for each new user or machine included in the project (and push the addition).
def_acquisition.py: Functions for running data acquisition.
acqfunctions.py: Copied from kineKit, these functions are used to prep video for TRex.
videotools.py: Copied from kineKit, series of functions for manipulating and interacting with video. Requires installing ffmpeg and opencv.
//: # ()
//: # ()
//: # ()