Skip to content

cytomining/pipeline-examples

Repository files navigation

Perform an example image-base profiling pipeline

We provide an example image-based profiling pipeline using pycytominer and cytominer-eval. We use publicly-available Cell Painting datasets to demonstrate how to use tools in the cytominer ecosystem.

Step 0: Setup

  • Step 0.0 - Install miniconda.
    • After installing miniconda, restart your terminal. You should now see the (base) prefix on your command line.
    • Optionally, also install mamba with conda install mamba -c conda-forge
  • Step 0.1 - Install aws cli
  • Step 0.2 - Clone this github repository (forking is optional):
# Make sure you are navigated to the directory of your choice
git clone [email protected]:cytomining/pipeline-examples.git
  • Step 0.3 - Create the conda environment, which includes pycytominer and cytominer-eval packages.
# Make sure you navigated into the repository folder after cloning
# cd pipeline-examples
conda env create --force --file environment.yml

# Or, if you installed mamba
mamba env create --force --file environment.yml
  • Step 0.4 - Activate the conda environment
conda activate pycytominer-example
  • [Optional] Step 0.5 - Alternatively, the two packages (pycytominer and cytominer-eval) can be installed via pip
pip install git+https://github.com/cytomining/pycytominer@8e3c28d3b81efd2c241d4c792edfefaa46698115
pip install git+https://github.com/cytomining/cytominer-eval@6f9d350badd0a18b6c1a76171813aaf9a52f8d9f

Step 1: Download one plate of single cell Cell Painting data (2GB .SQLite file)

Data are not included in this repository. You must run the code in 0.download.sh, which requires the AWS command line interface.

# Download one example plate from AWS
./0.download.sh

Step 2: Perform an image-based profiling pipeline

  • Step 2.0 - Run the command jupyter lab in your terminal, in the top level directory.
# Make sure the pycytominer-example environment is activated
jupyter lab
  • Step 2.1 - Navigate to 1.profile.ipynb and follow along!

Step 3: Evaluate profile quality

  • Step 3.0 - Navigate to 2.evaluate.ipynb and follow along!