We welcome community contributions to the Lightning Pose repo! If you have found a bug or would like to request a minor change, please open an issue.
In order to contribute code to the repo, please follow the steps below.
We strive to maintain a fun and inclusive environment for our users and contributors. See our code of conduct for more information.
In order to make changes to Lightning Pose, you will need to fork the repo.
If you are not familiar with git, check out this guide.
Whenever you initially install the lightning pose repo, instead of
pip install -e .run
pip install -e .[dev]to install additional development tools.
After making changes in your fork, open a pull request from your fork. Please read through the rest of this document before submitting the request.
We use ruff for formatting, import sorting, and linting. Run both commands before submitting a pull request:
ruff check --fix lightning_pose testsTo check without modifying files:
ruff check lightning_pose testsIf you set up the pre-commit hook (see below), ruff runs automatically on every commit.
Install the pre-commit hook so ruff runs automatically before each commit:
pre-commit installTo run it manually against all files:
pre-commit run --all-filesTo run the tests locally, you must have access to a GPU. Navigate to the Lightning Pose directory and simply run
pytestDocumentation is built automatically when a pull request is opened, so this step is not
required. If you have changed the docs and want to preview the result locally before pushing,
from the lightning-pose directory run:
cd docs
make htmlThen open docs/_build/html/index.html in your browser.