|
| 1 | +# Contributing to Neural-LAM |
| 2 | + |
| 3 | +Thank you for your interest in contributing to Neural-LAM! |
| 4 | +We welcome bug reports, bug fixes, documentation improvements, and new features. |
| 5 | + |
| 6 | +## Getting started |
| 7 | + |
| 8 | +1. **Open or find an issue.** Before writing code, open a |
| 9 | + [GitHub issue](https://github.com/mllam/neural-lam/issues) describing what |
| 10 | + you plan to do. If an issue already exists, comment so others know you are |
| 11 | + working on it. |
| 12 | + |
| 13 | +2. **Read the existing discussion.** Review the full issue thread and any |
| 14 | + linked PRs — someone may have already proposed a solution or identified a |
| 15 | + blocker. |
| 16 | + |
| 17 | +3. **Set up your environment.** Fork the repo via the GitHub UI, then follow |
| 18 | + the [Installing Neural-LAM section of the README](README.md#installing-neural-lam) |
| 19 | + using the `--group dev` flag. Then activate the hooks: |
| 20 | + |
| 21 | + ```bash |
| 22 | + pre-commit install |
| 23 | + ``` |
| 24 | + |
| 25 | +## Code standards |
| 26 | + |
| 27 | +Code quality is enforced automatically by |
| 28 | +[pre-commit hooks](.pre-commit-config.yaml) (Black, isort, Flake8, mypy, |
| 29 | +Codespell and others). In addition: |
| 30 | + |
| 31 | +- Add **NumPy-style docstrings** and **type annotations** to every public |
| 32 | + function and class. |
| 33 | +- Keep new code consistent with the patterns already in the codebase. |
| 34 | + |
| 35 | +## Before you push |
| 36 | + |
| 37 | +Run **both** checks locally — they are the same ones CI will run: |
| 38 | + |
| 39 | +```bash |
| 40 | +pre-commit run --all-files |
| 41 | +pytest -vv -s --doctest-modules |
| 42 | +``` |
| 43 | + |
| 44 | +> **Note:** The first test run downloads ~50 MB of example data via |
| 45 | +> [pooch](https://www.fatiando.org/pooch/). |
| 46 | +
|
| 47 | +## Pull requests |
| 48 | + |
| 49 | +1. Push your branch and open a PR against `main`. |
| 50 | +2. Fill in the |
| 51 | + [pull request template](.github/pull_request_template.md) — it contains the |
| 52 | + full checklists for authors, reviewers, and assignees, including the |
| 53 | + CHANGELOG entry format. |
| 54 | +3. A maintainer will review your PR. Small, focused PRs are reviewed faster. |
| 55 | + |
| 56 | +## Getting help |
| 57 | + |
| 58 | +- Join the [mllam Slack workspace](https://join.slack.com/t/ml-lam/shared_invite/zt-2t112zvm8-Vt6aBvhX7nYa6Kbj_LkCBQ) |
| 59 | +- [Open a GitHub issue](https://github.com/mllam/neural-lam/issues) |
0 commit comments