Skip to content

vjesticalab/VLabApp

Repository files navigation

VLabApplication

Automating cellular image analysis

About The Project

The VLabApp is created with the aim of automating the cellular image analysis process.

The application is divided into several modules that can be used consecutively and/or independently:

  • Registration - to register and align images.
  • Z-Projection - to make a projection of the z stack. Max, min, std, average and median projections possible.
  • Segmentation - to segment the images and generate the corresponding masks.
  • Cell tracking - to track segmented cells over time and create the cell tracking graph.
  • Graph filtering - to filter and clean the graph and the corresponding mask.
  • Events selection - to extract fusion or division events from the graph and the corresponding mask.
  • Pipeline - to create a pipeline by combining individual modules.
  • Viewers - to easily view the generated images, masks, graphs, registration matrix in Napari.
  • File organization - to export or clean generated output.
  • File conversion - to export masks and graphs to various file formats and to convert image and masks to small file-size preview movies or images.
  • Image cropping - to crop images and masks.
  • Ground truth generator - to quickly and easily generate the ground truth masks useful for a possible retraining of the network to be used in the Segmentation module.

Getting Started

Installation

  1. Install Conda

    If Conda is not already installed, download and install Miniconda or Anaconda from https://www.anaconda.com/download/.

  2. Download VLabApp

    Go to the latest release page and download the Source code archive (.zip or .tar.gz). Extract the archive, then open a terminal or anaconda powershell prompt (Windows) and navigate to the extracted folder.

  3. Create a new conda environment

    If an older venv_VLabApp environment exists, remove it with conda env remove --name venv_VLabApp.

    Run the following command to create a new environment

    conda create --name venv_VLabApp python=3.11.11
    
  4. Activate the environment

    After the environment is created, activate it

    conda activate venv_VLabApp
    
  5. Install dependencies

    Use pip to install dependencies listed in the requirements.txt file

    pip install -r requirements.txt
    

    Windows: CUDA support

    To enable GPU acceleration on Windows with an NVIDIA GPU, a CUDA-enabled build of PyTorch must be installed. Use one of the following commands instead, selecting the CUDA version suited to your system:

    • For CUDA 12.9:

      pip install -r requirements.txt --extra-index-url https://download.pytorch.org/whl/cu129
      
    • For CUDA 12.8:

      pip install -r requirements.txt --extra-index-url https://download.pytorch.org/whl/cu128
      
    • For CUDA 12.6:

      pip install -r requirements.txt --extra-index-url https://download.pytorch.org/whl/cu126
      

    More information is available in the official PyTorch documentation https://pytorch.org/get-started/locally/

  6. Start the application

    In the venv_VLabApp environment, start the application with

    python master.py
    

Open doc/site/index.html from the downloaded VLabApp folder with a web browser to access documentation.

Citation

If you use VLabApp in your research, please cite the VLabApp paper:

J. Dorier, A. Ravera and A. Vjestica. In preparation

If you use the registration module with stackreg, please cite the following publication:

P. Thevenaz, U. E. Ruttimann and M. Unser (1998). A pyramid approach to subpixel registration based on intensity. IEEE Transactions on Image Processing, 7(1), 27–41.

If you use the segmentation module with Cellpose, please cite the Cellpose 1.0 publication:

C. Stringer, T. Wang, M. Michaelos and M. Pachitariu (2021). Cellpose: a generalist algorithm for cellular segmentation. Nature Methods 18, 100–106.

If you fine-tune a Cellpose model, please cite the Cellpose 2.0 publication:

M. Pachitariu and C. Stringer (2022). Cellpose 2.0: how to train your own model. Nature Methods 19, 1634–1641.

If you use the segmentation module with the cyto3 Cellpose model, please cite the Cellpose 3.0 publication:

C. Stringer and M. Pachitariu (2025). Cellpose3: one-click image restoration for improved cellular segmentation. Nature Methods 22, 592-599.

Other tools and libraries used in this project

  • igraph

    G. Csardi and T. Nepusz (2006). The igraph software package for complex network research. InterJournal, Complex Systems, 1695.

  • napari

    napari contributors (2019). napari: a multi-dimensional image viewer for python. doi:10.5281/zenodo.3555620

  • NumPy

    C.R. Harris, K.J. Millman, S.J. van der Walt et al. (2020). Array programming with NumPy. Nature 585, 357–362.

  • OpenCV

    G. Bradski (2000). The OpenCV Library. Dr. Dobb's Journal of Software Tools.

  • Python

  • Qt

  • scikit-image

    S. van der Walt, J. L. Schönberger, J. Nunez-Iglesias et al. (2014). scikit-image: Image processing in Python. PeerJ 2, e453.

  • scipy

    P. Virtanen, R. Gommers, T.E. Oliphant et al. (2020). SciPy 1.0: Fundamental Algorithms for Scientific Computing in Python. Nature Methods, 17, 261–272.

Credits

Julien Dorier - Bioinformatics Competence Center, University of Lausanne.

Arianna Ravera - Scientific Computing and Research Support Unit, University of Lausanne.

Aleksandar Vjestica - Center for Integrative Genomics, University of Lausanne.

Project Link: VLabApp

About

Application created with the aim of automating the cellular image analysis process, from the recording of the movies that come out of the microscope, to the tracking of the events within each time frame.

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages