2022-09-12 10:19:19 +00:00
|
|
|
|
# sphereDetect
|
|
|
|
|
|
|
|
|
|
sphereDetect is a simple neural network, based on a Mask R-CNN, to detect spherical landmarks for image calibration.
|
|
|
|
|
|
|
|
|
|
## Built with
|
|
|
|
|
|
|
|
|
|
- [Python](https://www.python.org/)
|
|
|
|
|
|
|
|
|
|
### Frameworks
|
|
|
|
|
|
|
|
|
|
- [PyTorch](https://pytorch.org/)
|
|
|
|
|
- [TorchVision](https://pytorch.org/vision/stable/index.html)
|
|
|
|
|
- [PyTorch Lightning](https://www.pytorchlightning.ai/)
|
|
|
|
|
- [PyTorch Lightning Bolts](https://www.pytorchlightning.ai/bolts)
|
2022-09-12 12:52:28 +00:00
|
|
|
|
- [PyTorch Metrics](https://torchmetrics.readthedocs.io/en/stable/)
|
2022-09-12 10:19:19 +00:00
|
|
|
|
- [ONNXRuntime](https://onnxruntime.ai/)
|
|
|
|
|
|
|
|
|
|
### Tools
|
|
|
|
|
|
|
|
|
|
- [Poetry](https://python-poetry.org/)
|
|
|
|
|
- [Docker](https://www.docker.com/)
|
|
|
|
|
- [VSCode](https://code.visualstudio.com/)
|
|
|
|
|
- [ms-python](https://marketplace.visualstudio.com/items?itemName=ms-python.python)
|
|
|
|
|
- [Python Docstring Generator](https://marketplace.visualstudio.com/items?itemName=njpwerner.autodocstring)
|
|
|
|
|
- [Conventional Commits](https://marketplace.visualstudio.com/items?itemName=vivaxy.vscode-conventional-commits)
|
|
|
|
|
- [Remote container](https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.remote-containers)
|
|
|
|
|
- [EditorConfig](https://marketplace.visualstudio.com/items?itemName=EditorConfig.EditorConfig)
|
|
|
|
|
- [Docker](https://marketplace.visualstudio.com/items?itemName=ms-azuretools.vscode-docker)
|
2022-09-12 12:52:28 +00:00
|
|
|
|
- [Jupyter](https://marketplace.visualstudio.com/items?itemName=ms-toolsai.jupyter)
|
2022-09-12 10:19:19 +00:00
|
|
|
|
|
2022-09-12 12:52:28 +00:00
|
|
|
|
## Getting started (with docker and vscode)
|
2022-09-12 10:19:19 +00:00
|
|
|
|
|
2022-09-12 12:52:28 +00:00
|
|
|
|
### Requirements
|
|
|
|
|
|
|
|
|
|
- [Git](https://git-scm.com/)
|
|
|
|
|
- [Docker](https://www.docker.com/)
|
|
|
|
|
- [NVIDIA-Docker](https://github.com/NVIDIA/nvidia-docker)
|
|
|
|
|
|
|
|
|
|
### Installation
|
|
|
|
|
|
|
|
|
|
Clone the repository:
|
|
|
|
|
```bash
|
|
|
|
|
git clone git@git.inpt.fr:fainsil/pytorch-reva.git
|
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
Start VS Code:
|
|
|
|
|
```bash
|
|
|
|
|
vscode pytorch-reva
|
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
Install the [Remote Development extension pack](https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.vscode-remote-extensionpack). \
|
|
|
|
|
Reopen the workspace in [devcontainer mode](https://code.visualstudio.com/docs/remote/containers).
|
|
|
|
|
|
|
|
|
|
### Usage
|
|
|
|
|
|
|
|
|
|
Configure [Weights & Biases (local) server](https://docs.wandb.ai/guides/self-hosted/local) at <http://localhost:8080>, and login:
|
|
|
|
|
```bash
|
|
|
|
|
wandb login --host http://localhost:8080
|
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
Press `F5` to launch `src/train.py` in debug mode (with breakpoints, slower) \
|
|
|
|
|
or press `Ctrl+F5` to launch `src/train.py` in release mode.
|
2022-09-12 10:19:19 +00:00
|
|
|
|
|
|
|
|
|
## Getting started (without docker)
|
|
|
|
|
|
2022-09-12 12:52:28 +00:00
|
|
|
|
### Requirements
|
|
|
|
|
|
|
|
|
|
- [Git](https://git-scm.com/)
|
|
|
|
|
- [Poetry](https://python-poetry.org/)
|
|
|
|
|
- [Python](https://www.python.org/)
|
|
|
|
|
- [Docker](https://www.docker.com/) (if local wandb server used)
|
|
|
|
|
|
2022-09-12 10:19:19 +00:00
|
|
|
|
### Installation
|
|
|
|
|
|
|
|
|
|
Clone the repository:
|
|
|
|
|
```bash
|
|
|
|
|
git clone git@git.inpt.fr:fainsil/pytorch-reva.git
|
|
|
|
|
cd pytorch-reva
|
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
Install the dependencies:
|
|
|
|
|
```bash
|
|
|
|
|
poetry install --with all
|
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
### Usage
|
|
|
|
|
|
|
|
|
|
Activate python environment:
|
|
|
|
|
```bash
|
|
|
|
|
poetry shell
|
|
|
|
|
```
|
|
|
|
|
|
2022-09-12 12:52:28 +00:00
|
|
|
|
Configure [Weights & Biases (local) server](https://docs.wandb.ai/guides/self-hosted/local), and login:
|
2022-09-12 10:19:19 +00:00
|
|
|
|
```bash
|
|
|
|
|
wandb server start
|
2022-09-12 12:52:28 +00:00
|
|
|
|
wandb login --host http://localhost:8080
|
2022-09-12 10:19:19 +00:00
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
Start a training:
|
|
|
|
|
```bash
|
|
|
|
|
python src/train.py
|
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
## License
|
|
|
|
|
|
|
|
|
|
Distributed under the [MIT](https://choosealicense.com/licenses/mit/) license. \
|
|
|
|
|
See [`LICENSE`](https://git.inpt.fr/fainsil/pytorch-reva/-/blob/master/LICENSE) for more information.
|
|
|
|
|
|
|
|
|
|
## Contact
|
|
|
|
|
|
2022-09-12 12:52:28 +00:00
|
|
|
|
Laurent Fainsin _[loʁɑ̃ fɛ̃zɛ̃]_ \
|
2022-09-12 10:19:19 +00:00
|
|
|
|
\<[laurent@fainsin.bzh](mailto:laurent@fainsin.bzh)\>
|