This repository accompanies the pub "Rescuing Chlamydomonas motility in mutants modeling spermatogenic failure." It contains the code, scripts, and notebooks developed for the acquisition, processing, and analysis involved in the pub as well as the motility data on which the analysis was based.
This repository uses conda to manage software environments and installations. If you do not already have conda installed, you can find operating system-specific instructions for installing miniconda here. After installing conda, navigate to a directory where you would like to clone the repository, and run the following commands to create the pipeline run environment.
Start by cloning the repository and installing the required dependencies into a fresh conda environment:
git clone https://github.com/Arcadia-Science/2024-chlamy-mutant-motility-pub.git
cd 2024-chlamy-mutant-motility-pub
conda env create -n chlamy-mutant-motility --file envs/dev.yml
conda activate chlamy-mutant-motility
In order to enable cell tracking capabilities to process the raw image data or run the script compute_motility_metrics.py
, you must also install the Python package within the repo 2024-unicellular-tracking
. This can be done by running the following commands:
cd ..
git clone https://github.com/Arcadia-Science/2024-unicellular-tracking.git
cd 2024-unicellular-tracking
conda env update --file envs/dev.yml
pip install -e .
The data accompanying this pub is divided into two main folders, each corresponding to one of the assays described in the pub.
-
Assay 1:
vbottom_motility_assay
:
Raw images from the v-bottom motility assay are stored as ZIP files within this directory. The ZIP files contain single frame AVI files of either 96- or 384-well v-bottom plates containing C. reinhardtii cultures. Additionally, the final frame from each of these data acquisitions was cropped in FIJI and are available incropped_final_frames
. -
Assay 2:
single-cell-motility-assay
:
As described in the pub, the motility data was derived from processing brightfield time-lapse microscopy data of C. reinhardtii cells swimming in a 384-well plate. The image dataset underlying the pub is 108 GB and has been uploaded to the BioImage Archive: S-BIAD1470.
While the image data is too large to be included in this repository, CSV files of the detected cell trajectories can be found incell_trajectories
. The CSV files contain time series of x, y coordinates of tracked cells, from which summary motility statistics are calculated and output to a single CSV file as described in Methods.
This repository is organized into the following top-level directories.
- data: See Data.
- envs: Contains a conda environment YML file that lists the packages and dependencies used for creating the conda environment.
- notebooks: A collection of Jupyter notebooks for analyzing motility data.
- resources: Static files rendered within the repository.
- src: Python modules that support the analyses composed in the notebooks such as for extracting intensity profiles for the v-bottom motility assay and calculating statistics.
- src/scripts:
bioimage_archive_file_list.py
: A Python script for generating the list of files needed for the BioImage Archive upload. (No longer intended to be run.)compute_motility_metrics.py
: A Python script for computing summary motility statistics from cell trajectories.create_vbottom_gifs.py
: A Python script for creating GIFs from the zipped AVI files from the v-bottom motility assay data.
Cell tracking was performed using the track_cells.py
script included in 2024-unicellular-tracking
. To extract cell trajectories from image data, the image data must first be downloaded from [TODO: insert link to dataset on BioImage Archive]. The following command was used to perform cell tracking:
python src/chlamytracker/scripts/track_cells.py 20240425_174057_487 --use-dask
The same command was repeated for the dataset of cells after 18 hours by substituting in 20240426_095610_676
for the first argument.
See the README for more extensive documentation on how the track_cells.py
script can be configured.
To generate the summary motility statistics for each dataset of cell trajectories, the script compute_motility_metrics.py
was run using the commands:
python src/scripts/compute_motility_metrics.py data/cell_trajectories/20240425_174057_487/
python src/scripts/compute_motility_metrics.py data/cell_trajectories/20240426_095610_676/
The statistical analysis was done through a series of Jupyter notebooks in which several figures in the pub were also created. The list below maps each figure to the corresponding analysis notebook.
- Figure 3: 1_vbottom-motility-linescan.ipynb
- Figure 4: 2_mutant-motility-pca.ipynb
- Figure 5: 1_vbottom-motility-linescan.ipynb
- Figure 6: 2_mutant-motility-pca.ipynb
- Figure S1: 3_supplemental-analysis.ipynb
- Figure S2: 3_supplemental-analysis.ipynb
Cell tracking was done on a Supermicro X12SPA-TF 64L running Ubuntu 22.04.1 with 512 GB RAM, 64 cores, and a 2 TB SSD.
The notebooks for statistical analysis were run on an Apple MacBook Pro with an Apple M3 Max chip running macOS Sonoma version 14.5 with 36 GB RAM, 14 cores, and 1 TB SSD.
See how we recognize feedback and contributions to our code.