Cell shape analysis using graph neural networks
Project description
Cellshape-cloud is an easy-to-use tool to analyse the shapes of cells using deep learning and, in particular, graph-neural networks. The tool provides the ability to train popular graph-based autoencoders on point cloud data of 2D and 3D single cell masks as well as providing pre-trained networks for inference.
To install
pip install cellshape-cloud
Usage
import torch
from cellshape_cloud import CloudAutoEncoder
model = CloudAutoEncoder(num_features=128,
k=20,
encoder_type='dgcnn',
decoder_type='foldingnet')
points = torch.randn(1, 2048, 3)
recon, features = model(points)
Parameters
num_features
: int.
The size of the latent space of the autoencoder. If you have rectangular images, make sure your image size is the maximum of the width and heightk
: int.
The number of neightbours to use in the k-nearest-neighbours graph construction.encoder_type
: int.
The type of encoder: 'foldingnet' or 'dgcnn'decoder_type
: int.
The type of decoder: 'foldingnet' or 'dgcnn'
For developers
- Fork the repository
- Clone your fork
git clone https://github.com/USERNAME/cellshape-cloud
- Install an editable version (
-e
) with the development requirements (dev
)
cd cellshape-cloud
pip install -e .[dev]
- To install pre-commit hooks to ensure formatting is correct:
pre-commit install
- To release a new version:
Firstly, update the version with bump2version (bump2version patch
,
bump2version minor
or bump2version major
). This will increment the
package version (to a release candidate - e.g. 0.0.1rc0
) and tag the
commit. Push this tag to GitHub to run the deployment workflow:
git push --follow-tags
Once the release candidate has been tested, the release version can be created with:
bump2version release
References
[1] An Tao, 'Unsupervised Point Cloud Reconstruction for Classific Feature Learning', GitHub Repo, 2020
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for cellshape_cloud-0.0.3rc0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8ecba879c2a2e4fac98ccb4ff52d518af8b9af74d38bdd674e035872863b1157 |
|
MD5 | fc16d9dd858183c2faef63a092c275cc |
|
BLAKE2b-256 | e8dd0210a8b4c1ed7b74aabffc4f8efd1f07250c61d7cc5a28911dbabe67386a |