Skip to main content

Automatic Cut Detector

Project description

Cut Detector

License BSD-3 PyPI Python Version tests codecov napari hub

Automatic micro-tubule cut detector.

https://github.com/user-attachments/assets/356efbf6-d78a-44a0-ad94-de3de83f01ed


This napari plugin was generated with Cookiecutter using @napari's cookiecutter-napari-plugin template.

Your browser does not support the video tag.

Installation

Conda environment

It is highly recommended to create a dedicated conda environment, by following these few steps:

  1. Install an Anaconda distribution of Python. Note you might need to use an anaconda prompt if you did not add anaconda to the path.

  2. Open an Anaconda prompt as admin to create a new environment using conda. We advice to use python 3.10 and conda 23.10.0, to get conda-libmamba-solver as default solver.

conda create --name cut_detector python=3.10 conda=23.10.0
conda activate cut_detector

Package installation

Once in a dedicated environment, our package can be installed via pip:

pip install cut_detector

Alternatively, you can clone the github repo to access to playground scripts.

git clone https://github.com/15bonte/cut-detector.git
cd cut-detector
pip install -e .

GPU

We highly recommend to use GPU to speed up segmentation. To use your NVIDIA GPU, the first step is to download the dedicated driver from NVIDIA.

Next we need to remove the CPU version of torch:

pip uninstall torch

The GPU version of torch to be installed can be found here. You may choose the CUDA version supported by your GPU, and install it with conda. This package has been developed with the version 11.6, installed with this command:

conda install pytorch==1.12.1 torchvision pytorch-cuda=11.6 -c pytorch -c nvidia

Update

To update cut-detector to the latest version, open an Anaconda prompt and use the following commands:

conda activate cut_detector
pip install cut-detector --upgrade

Definitions

Each detected cell division is labeled with one of the following categories:

  • NORMAL: Division happening as expected, where (at least) 1 micro-tubule cut is detected.
  • NO_MID_BODY_DETECTED: Along the cell division, no mid-body was detected on the MKLP1 channel. This category encompasses different cases: the detection may have failed, the mid-body may not express the fluorescence, or this may not actually be a division.
  • MORE_THAN_TWO_DAUGHTER_TRACKS: Tripolar division. This category encompasses both actual tripolar divisions and wrong identifications of daughter cells (mainly caused by segmentation issues).
  • NEAR_BORDER: Division close to the border of the image, hence ignored as it is likely to be difficult to detect micro-tubule cuts. A division is classified as NEAR_BORDER as soon as the distance between 1 detected mid-body and the border of the image is less than 20px.
  • NO_CUT_DETECTED: Division whose mid-body was detected, but with all micro-tubule bridges classified as "No cut". Likely to be at the end of the video, cells dying before the end of division, or cells going out of frame.
  • TOO_SHORT_CUT: First micro-tubule cut detected before or at 50 minutes. Ignored as this is very unlikely, so it is probably caused by a wrong division detection.

Contributing

Contributions are very welcome. Tests can be run with tox, please ensure the coverage at least stays the same before you submit a pull request.

License

Distributed under the terms of the BSD-3 license, "cut-detector" is free and open source software

Issues

If you encounter any problems, please file an issue along with a detailed description.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cut_detector-1.4.0.tar.gz (324.2 kB view details)

Uploaded Source

Built Distribution

cut_detector-1.4.0-py3-none-any.whl (83.1 kB view details)

Uploaded Python 3

File details

Details for the file cut_detector-1.4.0.tar.gz.

File metadata

  • Download URL: cut_detector-1.4.0.tar.gz
  • Upload date:
  • Size: 324.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for cut_detector-1.4.0.tar.gz
Algorithm Hash digest
SHA256 d56976d34141d44bbccc715ca3e992cefa2eea0cf2e394dd180b66b9454420bf
MD5 e7327aab643d3f6a7c806e167442f38b
BLAKE2b-256 04205e1bad6efb9d854f4c38e6dbdb825823a33fd705783fb7381a80bde7d316

See more details on using hashes here.

File details

Details for the file cut_detector-1.4.0-py3-none-any.whl.

File metadata

  • Download URL: cut_detector-1.4.0-py3-none-any.whl
  • Upload date:
  • Size: 83.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for cut_detector-1.4.0-py3-none-any.whl
Algorithm Hash digest
SHA256 ae263b484aaca383badd576ac311a166f9d3aea708ae72e03bfbe7fdd0567ff5
MD5 22bcedf144d5516a7644a3d5b33c0167
BLAKE2b-256 0a2d10b70d8008c681dba4dbaa6b09b57ea03d410deb46933bcd739c0f7d717a

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page