Introduction to CellProfiler

Peter Sobolewski (he/him)

Systems Analyst, Imaging Applications

Research IT

CellProfiler logo https://cellprofiler.org/home

Plan for Day 1

  • Introduction to CellProfiler
  • Overview of basic CellProfiler concepts
    • projects, pipelines, modules
  • User Interface (UI) Walk-through
  • Hands-on tutorial

What is CellProfiler?

CellProfiler is an open-source image analysis program


Key feature:
CellProfiler has a graphical user interface (GUI) for assembling image processing and analysis workflows (called pipelines) using a sequence of modular analysis modules

A bit of background

Strengths of CellProfiler

  • It was designed for batch image analysis using reproducible workflows—without scripting

  • It includes advanced algorithms for image (pre)processing, segmentation, etc. as modular modules

  • It includes in-app documentation for module parameters plus extensive help menu

  • End-to-end workflows: images go in, data tables go out

Limitations

  • Limited viewing capabilities:
    • single planes, single channels only
  • No annotation tools
  • Limited out-of-memory performance
    • lacking support for multiscale (“pyramidal”) images
    • lacking built-in tiling/chunking
  • Limited OMERO support
  • Problematic OME.TIFF handling

The CellProfiler concept

  • Create a project that has an associated image file list of locations and an associated pipeline
  • Use the GUI to add a sequence of modules to implement your analysis—these form a pipeline
    • Start with input images and end with measurements in a spreadsheet (.csv) or a MySQL database
  • run in batches over large number of images
  • analyze measurement data in the downstream tool of your choice (Python, R, Excel, etc.)

CellProfiler projects & pipelines

  • projects contain a list of the locations of your image files plus an associated CellProfiler analysis pipeline
    • projects will also contain some cached computed results


  • pipelines can be exported, but do not contain image locations—this is ideal for sharing or reuseing workflows

Typical pipeline

  • start with setting up Input modules
  • Add Image Processing modules to facillitate segmentation
  • Add Object Processing modules to segment the image (identify objects) and manipulate objects
  • Add Measurement modules to get quantified information you’re interested in
  • Finish with Data Tools and File Processing to export data or images

CellProfiler UI

Screenshot of empty CellProfiler UI with menu bar
Screenshot of empty CellProfiler UI with menu bar. At the top right, the Notes box is emphasized with red text. Below, in the middle-right, the Image list drag-and-drop is emphasized with red text.
Screenshot of empty CellProfiler UI with menu bar. In the top left, the four Input modules are highlighted with a red box and red text.
Screenshot of empty CellProfiler UI with menu bar. On the middle-left, the area for adding pipeline modules is highlighted with red text. Below, the module buttons are highlighted with a red box.
Screenshot of CellProfiler UI with menu bar and a single module (ColorToGrey) open. At the top, the Test menu is open and the `Start Test Mode` option is highlighted with a red box. At the bottom left, the `Start Test Mode` button is highlighted with a red box.
Screenshot of CellProfiler UI with menu bar and a single module (ColorToGrey) open. Test mode is now active. At the top of the modules area, the Test mode buttons next to the ColorToGrey module are highlighted with a red box. At the bottom left, the Run and Step buttons are highlighted with a red box.
Screenshot of CellProfiler UI with menu bar and a single module (ColorToGrey) open. Test mode is now active. At the top, the Test menu is open and the Image set menu items are highlighted with a red box. At the bottom left, the `Next Image Set` button is highlighted with a red box.
Screenshot of CellProfiler UI with menu bar and a single module (ColorToGrey) open. In the middle right, the ColorToGrey module options are showing with the input image selection and output image naming highlighted with red boxes.

Keys to success

  • ensure image inputs are properly set up (NamesAndTypes) and that they and intermediate step outputs have meaningful names
  • use Test mode to see the outputs of individual modulues (pipeline steps) one-at-a-time
    • let’s you test parameters on a single image or any number of images (even a randomly selected one)
    • can run the whole pipeline or just individual modules

Getting more help