This repo contains a sample code to show how to create a Flask API server by deploying our remote sensing imagery cloud removal PyTorch model that is trained on RICE dataset.
pip install -r requirements.txt
- Download the pretrained model.
- For RCIE1 (thin cloud dataset): model_thin.pth
- For RCIE2 (thick cloud dateset): model_thick.path
- Place the model on root dir.
- Run
app.py
.
Go to https://ngrok.com/, register an account and then you can get an authtoken.
wget https://bin.equinox.io/c/4VmDzA7iaHb/ngrok-stable-linux-amd64.zip
unzip ngrok-stable-linux-amd64.zip
./ngrok authtoken ***
./ngrok http 9000
There are many images used for test in test_thin
and test_thick
folder.
- Lin D, Xu G, Wang X, et al. A remote sensing image dataset for cloud removal[J]. arXiv preprint arXiv:1901.00600, 2019.
- Isola P, Zhu J Y, Zhou T, et al. Image-to-image translation with conditional adversarial networks[C]//Proceedings of the IEEE conference on computer vision and pattern recognition. 2017: 1125-1134.