Skip to main content

cyclops Logo


PyPI PyPI - Python Version code checks integration tests docs codecov docker

cyclops is a toolkit for facilitating research and deployment of ML models for healthcare. It provides a few high-level APIs namely:

  • data - Create datasets for training, inference and evaluation. We use the popular 🤗 datasets to efficiently load and slice different modalities of data
  • models - Use common model implementations using scikit-learn and PyTorch
  • tasks - Use common ML task formulations such as binary classification or multi-label classification on tabular, time-series and image data
  • evaluate - Evaluate models on clinical prediction tasks
  • monitor - Detect dataset shift relevant for clinical use cases
  • report - Create model report cards for clinical ML models

cyclops also provides example end-to-end use case implementations on clinical datasets such as

🐣 Getting Started

Installing cyclops using pip

python3 -m pip install pycyclops

cyclops has many optional dependencies that are used for specific functionality. For example, the monai library is used for loading DICOM images to create datasets. Hence, monai can be installed using python3 -m pip install pycyclops[monai]. Specific sets of dependencies are listed below.

Dependency pip extra Notes
xgboost xgboost Allows use of XGBoost model
torch torch Allows use of PyTorch models
torchvision torchvision Allows use of Torchvision library
torchxrayvision torchxrayvision Uses TorchXRayVision library
monai monai Uses MONAI to load and transform images
alibi alibi Uses Alibi for additional explainability functionality
alibi-detect alibi-detect Uses Alibi Detect for dataset shift detection

🧑🏿‍💻 Developing

Using poetry

The development environment can be set up using poetry. Hence, make sure it is installed and then run:

python3 -m poetry install
source $(poetry env info --path)/bin/activate

In order to install dependencies for testing (codestyle, unit tests, integration tests), run:

python3 -m poetry install --with test

API documentation is built using Sphinx and can be locally built by:

python3 -m poetry install --with docs
cd docs
make html SPHINXOPTS="-D nbsphinx_allow_errors=True"

Contributing

Contributing to cyclops is welcomed. See Contributing for guidelines.

📚 Documentation

If you need to build the documentations locally, make sure to install Pandoc in addition to docs poetry group.

📓 Notebooks

To use jupyter notebooks, the python virtual environment can be installed and used inside an IPython kernel. After activating the virtual environment, run:

python3 -m ipykernel install --user --name <name_of_kernel>

Now, you can navigate to the notebook's Kernel tab and set it as <name_of_kernel>.

🎓 Citation

Reference to cite when you use cyclops in a project or a research paper:

@article {Krishnan2022.12.02.22283021,
	author = {Krishnan, Amrit and Subasri, Vallijah and McKeen, Kaden and Kore, Ali and Ogidi, Franklin and Alinoori, Mahshid and Lalani, Nadim and Dhalla, Azra and Verma, Amol and Razak, Fahad and Pandya, Deval and Dolatabadi, Elham},
	title = {CyclOps: Cyclical development towards operationalizing ML models for health},
	elocation-id = {2022.12.02.22283021},
	year = {2022},
	doi = {10.1101/2022.12.02.22283021},
	publisher = {Cold Spring Harbor Laboratory Press},
	URL = {https://www.medrxiv.org/content/early/2022/12/08/2022.12.02.22283021},
	journal = {medRxiv}
}

Metadata

Release files for pycyclops 0.2.12

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pycyclops 0.2.12
File Size Uploaded
pycyclops-0.2.12.tar.gz 303.5 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for pycyclops 0.2.12
File Interpreter ABI Platform
pycyclops-0.2.12-py3-none-any.whl Python 3 none any Details

Total release size: 713.8 kB

Release files / pycyclops-0.2.12.tar.gz

Download URL pycyclops-0.2.12.tar.gz
Size 303.5 kB
Tags Source
SHA-256 checksum
How to use checksums
601d8bc4a9e01ec15b9f7824d4cbb32fbe9c84b08fd18e55a2605cad4e3a1d9c
BLAKE2b-256 checksum
How to use checksums
3aceacbeef79f57f7ed1762b2a38f59b01ec719ff45cc3e5da725166b61a6289
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.0.1 CPython/3.12.8

Release files / pycyclops-0.2.12-py3-none-any.whl

Download URL pycyclops-0.2.12-py3-none-any.whl
Size 410.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
09405fce6ff125d8864aa51c6b70d1b873a8955e287decbd5b6587b3570bcb8b
BLAKE2b-256 checksum
How to use checksums
8192db0e437acfb9a57612f9db734f86f81413064f9f6af15b8f7b219a9ba4e2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.0.1 CPython/3.12.8

Release history Release notifications | RSS feed

This release

0.2.12 This release

2 release files

0.2.10

2 release files

0.2.9

2 release files

0.2.8

2 release files

0.2.7

2 release files

0.2.6

2 release files

0.2.5

2 release files

0.2.4

2 release files

0.2.3

2 release files

0.2.2

2 release files

0.2.1

2 release files

0.2.0

2 release files

0.1.40

2 release files

0.1.39

2 release files

0.1.37

2 release files

0.1.36

2 release files

0.1.35

2 release files

0.1.34

2 release files

0.1.33

2 release files

0.1.30

2 release files

0.1.29

2 release files

0.1.24

2 release files

0.1.23

2 release files

0.1.22

2 release files

0.1.20

2 release files

0.1.19

2 release files

0.1.13

2 release files

0.1.12

2 release files

0.1.11

2 release files

0.1.9

2 release files

0.1.8

2 release files

0.1.7

2 release files

0.1.6

2 release files

0.1.5

2 release files

0.1.4

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page