This is a minimal template repository for ChRIS plugin applications in Python.
A ChRIS plugin is a scientific data-processing software which can run anywhere all-the-same:
in the cloud via a web app, or on your own laptop
from the terminal. They are easy to build and easy to understand: most simply, a
ChRIS plugin is a command-line program which processes data from an input directory
and creates data to an output directory with the usage
commandname [options...] inputdir/ outputdir/
.
For more information, visit our website https://chrisproject.org
Go to https://github.com/FNNDSC/python-chrisapp-template and click "Use this template". The newly created repository is ready to use right away.
A script bootstrap.sh
is provided to help fill in and rename values for your new project.
It is optional to use.
- Edit the variables in
bootstrap.sh
- Run
./bootstrap.sh
- Follow the instructions it will print out
Here are some good, complete examples of ChRIS plugins created from this template.
- https://github.com/FNNDSC/pl-dcm2niix (basic command wrapper example)
- https://github.com/FNNDSC/pl-adapt_object_mesh (parallelizes a command)
- https://github.com/FNNDSC/pl-mri-preview (uses NiBabel)
- https://github.com/FNNDSC/pl-pyvista-volume (example using Python package project structure and pytest)
- https://github.com/FNNDSC/pl-fetal-cp-surface-extract (has a good README.md)
Path | Purpose |
---|---|
app.py |
Main script: start editing here! |
tests/ |
Unit tests |
setup.py |
Python project metadata and installation script |
requirements.txt |
List of Python dependencies |
Dockerfile |
Container image build recipe |
.github/workflows/ci.yml |
"continuous integration" using Github Actions: automatic testing, building, and uploads to https://chrisstore.co |
The source code for the main
branch of this repository is on the
src
branch, which has an additional file
.github/workflows/src.yml
When tests pass, changes are automatically merged into main
.
Developers should commit to or make pull requests targeting src
.
Do not push directly to main
.
This is a workaround in order to do automatic testing of this template
without including the .github/workflows/src.yml
file in the template itself.