|
5 | 5 |
|
6 | 6 | ## Choosing a task
|
7 | 7 | * Check out our [Kanban board](https://github.com/OML-Team/open-metric-learning/projects/1).
|
8 |
| - You can work on one of the existing issues or create the new one. |
9 |
| - Especially pay attention to the issues marked with the `good_first_issue` flag. |
10 |
| -* Start the conversation under the issue that you picked. We will discuss the design and content of the pull request, and |
| 8 | + You can work on one of the existing issues or create a new one. |
| 9 | +* Start the conversation under the issue you picked. We will discuss the design and content of the pull request, and |
11 | 10 | then you can start working on it.
|
12 | 11 |
|
13 |
| -## Contributing |
| 12 | +## Contributing in general |
14 | 13 | * Fork the repository.
|
15 | 14 | * Clone it locally.
|
16 | 15 | * Create a branch with a name that speaks for itself.
|
17 | 16 | * Set up the environment. You can install the library in dev mode via `pip install -e .`
|
18 | 17 | or build / pull [docker image](https://github.com/OML-Team/open-metric-learning#installation).
|
19 | 18 | * Implement the discussed functionality, **docstrings**, and **tests** for it.
|
20 |
| -* Run tests locally via `make run_tests` or `make docker_tests` (preferable option). |
| 19 | +* Run tests locally using commands from `Makefile`. |
21 | 20 | * Push the code to your forked repository.
|
22 | 21 | * Create a pull request to OpenMetricLearning.
|
23 | 22 |
|
24 |
| -## Good to know |
| 23 | +## Contributing to documentation |
25 | 24 | * If you want to change `README.md` you should go to `docs/readme`, change the desired section and then build
|
26 | 25 | readme via `make build_readme`. *So, don't change the main readme file directly, otherwise tests will fail.*
|
27 | 26 | * Don't forget to update the documentation if needed. Its source is located in `docs/source`. To inspect
|
28 | 27 | it locally, you should run `make html` (from `docs` folder) and then open `docs/build/html/index.html` in your
|
29 | 28 | browser.
|
30 |
| -* If you want to add some new criterion, miner, model, optimizer, sampler, lr scheduler or transforms, don't forget to |
31 |
| - add it to the corresponding registry (see `oml.registry`) and also add a config file (see `oml.configs`). |
32 | 29 |
|
33 |
| -## How to add new functionality in Pipelines (Config-API)? |
34 |
| -* Implement your changes in `extractor_training_pipeline` and/or in `extractor_validation_pipeline` |
35 |
| -* Add a new test run or modify one of the existing tests. If adding a new test: |
| 30 | +## Contributing to models ZOO |
| 31 | +* Add the model's implementation under `oml/models`. |
| 32 | +* Implement `from_pretrained()` and add the corresponding [transforms](https://github.com/OML-Team/open-metric-learning/blob/f0d151ace24aaa527d0605d055529f31ad027f49/oml/registry/transforms.py#L53). |
| 33 | +* Add the model to `oml/registry` and `oml/configs`. |
| 34 | +* Evaluate model on 4 benchmarks and add the results into ZOO table in the main Readme. |
| 35 | + |
| 36 | +## Contributing to pipelines |
| 37 | +* Implement your changes in one of the pipelines (`extractor_training_pipeline`, `extractor_validation_pipeline` or others). |
| 38 | +* Add a new test or modify an existing one under `tests/test_runs/test_pipelines`. |
| 39 | +* If adding a new test: |
36 | 40 | * Add config file: `tests/test_runs/test_pipelines/configs/train_or_validate_new_feature.yaml`
|
37 | 41 | * Add python script: `tests/test_runs/test_pipelines/train_or_validate_new_feature.py`
|
38 |
| - * Add entry point to your test to: `tests/test_runs/test_pipelines/test_pipelines.py` |
| 42 | + * Add test: `tests/test_runs/test_pipelines/test_pipelines.py` |
| 43 | + |
| 44 | +## Don't forget to update Registry |
| 45 | +* If you want to add some new criterion, miner, model, optimizer, sampler, lr scheduler or transforms, don't forget to |
| 46 | + add it to the corresponding registry (see `oml.registry`) and also add a config file (see `oml.configs`). |
0 commit comments