-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changing the resolution results in a high batch/sample size - dev #13
Comments
Hi @4del-Yousefi . Can you please share all the logs with us? We are unable to pinpoint the cause of the error based on the description you provided. Additionally, we have released a Python package called GeoSAM-Image-Encoder that does not rely on QGIS. If you're interested, you can also try it out in Colab. https://github.com/coolzhao/Geo-SAM/blob/dev/GeoSAM-Image-Encoder/examples/geosam-image-encoder.ipynb |
Hey @Fanchengyan, I have the logs for that run, I also I will try and use the package, thank you!: QGIS version: 3.30.0-'s-Hertogenbosch Input data value range to be rescaled: [0.0, 255.0] (set by user) RasterDataset info: SAM model initialized.
|
Hi @4del-Yousefi . We have found the reason. The resolution exported by Encoder Copilot is in the units of the image projection (in degrees, as in your example). However, Image Encoder currently only supports resolution in meters. We suggest that you estimate the resolution of the image in meters yourself and multiply it by the resolution scale provided in Encoder Copilot. Then manually enter the calculated resolution into Image Encoder. In the future, we will consider how to address this issue. |
Hi @4del-Yousefi, thanks for your feedback. Based on your circumstances, I suggest reprojecting your image into UTM CRS (in meter units). We will continue to improve our tool to handle images with the degree units better. BTW, by using the default settings of the Encoding Tool, you can find the native resolution of your image in meters from the log information. This can help you decide the target resolution. |
Hi @4del-Yousefi ,If you are unsure about the resolution of your image in meters, you can first reproject the image into a coordinate system with units in meters, such as UTM. After the reprojection, Encoder Copilot will provide the resolution in meters. |
Hi @4del-Yousefi, it is just due to the bugs for not clearing the canvas properly in the dev version. This will disappear when you restart QGIS. We will fix this in the stable version. Thanks for your feedback. |
Hello, Thanks for keeping us updated and fixing the issues, I'm using the Copilot tool with the following settings – I copied and pasted them into the encoder.
It resulted in a very high batch/sample size:
SAM model initialized.
SAM model type: vit_b
Device type: cuda:0 on NVIDIA GeForce GTX 1070 Ti
Patch size: (1024, 1024)
Batch size: 1
-> Patch sample num: 27559879364
-> Total batch num: 27559879364
The selected area is this:
![image](https://private-user-images.githubusercontent.com/82387511/258787180-938890d4-15c2-4bda-92ec-19a323da6c3b.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjQ4NTk5NDksIm5iZiI6MTcyNDg1OTY0OSwicGF0aCI6Ii84MjM4NzUxMS8yNTg3ODcxODAtOTM4ODkwZDQtMTVjMi00YmRhLTkyZWMtMTlhMzIzZGE2YzNiLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA4MjglMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwODI4VDE1NDA0OVomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTcxZDY1M2M0MzZlNzEzNDkyMGFhZmEyYTNkZWI2ZWJiZjYyYzhjNzk2YzcxMGI4OWNhZGM1OWEyNTY3YmVhMjAmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.vX-vfeykz6YmKzhlOGYTuILTQWnT0I53uXwHKPpDGdg)
The text was updated successfully, but these errors were encountered: