This repository demonstrates a simplified example of training and running inference on a toy model using the Retrogressive Thaw Slumps (RTS) dataset. It is adapted from the official PyTorch Vision Tutorial.
The copyright for the tutorial content belongs to PyTorch. © Copyright 2024, PyTorch.
To set up the environment, I recommend using Conda. You can create the environment using the provided requirements_conda.txt file:
conda create --name <env_name> --file requirements_conda.txtA requirements.txt file is also provided for pip installation, though it has not been fully tested:
To train the model, run the following command in your terminal:
python train.pyThis command trains a Mask R-CNN model with a ResNet-50 backbone using the RTS dataset.
To perform inference using the trained model, run:
python inference.py --image-path <path_to_image>Replace <path_to_image> with the path to your image file.
If training cannot be completed due to time constraints, a pre-trained model is available. You can download the model weights from this link and place the rts_model.pth file in the root directory of the repository.
- This model is for demonstration purposes and has not been optimized for performance.