-
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
Geo-SAM fails to load QGIS 3.36.2 #44
Comments
This is likely due to the path of the Python dependencies is incorrect. Please follow the tutorial and reinstall the python dependencies: https://geo-sam.readthedocs.io/en/latest/installation.html#for-windows-users. Since you have installed two versions of QGIS, there should be two |
I've:
Python Path: Suggestions please! |
Hi @Martin-Dawson , This seems to be a problem with the PyTorch installation. Make sure you have installed the PyTorch version that corresponds to your CUDA version, or directly install the CPU version of PyTorch. The following links are for reference : |
QGIS v3.36.2 has a load of updates: https://lists.osgeo.org/pipermail/qgis-user/2024-April/054334.html. I suspect this is the source of the issue I've raised rather than Pytorch-CUDA incompatibility. Note this update should solve the RTree issue. |
Hi @Martin-Dawson , I tested it in Windows, and the code prompted a permission issue. Try to launch the OSGeo4W Shell as administrator and run the following command. pip3 install torch --force-reinstall This worked for me. |
Many thanks. Forcing the reinstall running the Shell as an administrator resolved the problem. The earlier installs I did (not as Administrator) seem to have produced several invalid torch distributions (now removed to avoid warnings!)
…________________________________
From: Fanchengyan ***@***.***>
Sent: 07 May 2024 09:52
To: coolzhao/Geo-SAM ***@***.***>
Cc: Martin-Dawson ***@***.***>; Mention ***@***.***>
Subject: Re: [coolzhao/Geo-SAM] Geo-SAM fails to load QGIS 3.36.2 (Issue #44)
Hi @Martin-Dawson<https://github.com/Martin-Dawson> ,
I tested it in Windows, and the code prompted a permission issue.
Try to launch the OSGeo4W Shell as administrator and run the following command.
pip3 install torch --force-reinstall
This worked for me.
—
Reply to this email directly, view it on GitHub<#44 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/BC3PZPEDD23YFRR4SMXIA23ZBCI3JAVCNFSM6AAAAABHHCYW4CVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDAOJXG44DGMBZGQ>.
You are receiving this because you were mentioned.Message ID: ***@***.***>
|
I am getting the following error when trying to initial Geo-SAM in QGIS v3.36.2:
ModuleNotFoundError: No module named 'rasterio'
Traceback (most recent call last):
File "C:\PROGRA
1/QGIS332.2/apps/qgis/./python\qgis\utils.py", line 404, in loadPluginimport(packageName)
File "C:\PROGRA
1/QGIS332.2/apps/qgis/./python\qgis\utils.py", line 923, in _importmod = builtin_import(name, globals, locals, fromlist, level)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users/marti/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\Geo-SAM_init.py", line 7, in
from .geo_sam_tool import Geo_SAM
File "C:\PROGRA
1/QGIS332.2/apps/qgis/./python\qgis\utils.py", line 923, in _importmod = _builtin_import(name, globals, locals, fromlist, level)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users/marti/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\Geo-SAM\geo_sam_tool.py", line 10, in
from .tools.widgetTool import Selector, EncoderCopilot
File "C:\PROGRA
1/QGIS332.2/apps/qgis/./python\qgis\utils.py", line 923, in _importmod = _builtin_import(name, globals, locals, fromlist, level)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users/marti/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\Geo-SAM\tools\widgetTool.py", line 7, in
import rasterio
File "C:\PROGRA
1/QGIS332.2/apps/qgis/./python\qgis\utils.py", line 923, in _importmod = _builtin_import(name, globals, locals, fromlist, level)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
ModuleNotFoundError: No module named 'rasterio'
Python version: 3.12.3 (main, Apr 14 2024, 17:21:43) [MSC v.1938 64 bit (AMD64)]
QGIS version: 3.36.2-Maidenhead Maidenhead, 6d250527
Python Path:
C:\Users/marti/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\geometric_attributes
C:/PROGRA
1/QGIS332.2/apps/qgis/./pythonC:/Users/marti/AppData/Roaming/QGIS/QGIS3\profiles\default/python
C:/Users/marti/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins
C:/PROGRA
1/QGIS332.2/apps/qgis/./python/pluginsC:\PROGRA
1\QGIS332.2\apps\grass\grass83\etc\pythonC:\Users\marti\Documents
C:\Program Files\QGIS 3.36.2\bin\python312.zip
C:\PROGRA
1\QGIS332.2\apps\Python312\DLLsC:\PROGRA
1\QGIS332.2\apps\Python312\LibC:\Program Files\QGIS 3.36.2\bin
C:\PROGRA
1\QGIS332.2\apps\Python312C:\PROGRA
1\QGIS332.2\apps\Python312\Lib\site-packagesC:\PROGRA
1\QGIS332.2\apps\Python312\Lib\site-packages\win32C:\PROGRA
1\QGIS332.2\apps\Python312\Lib\site-packages\win32\libC:\PROGRA
1\QGIS332.2\apps\Python312\Lib\site-packages\PythonwinC:/Users/marti/AppData/Roaming/QGIS/QGIS3\profiles\default/python
C:\Users\marti\AppData\Roaming\QGIS\QGIS3\profiles\default\python\plugins\deepness\python3.12
C:\Users\marti\AppData\Roaming\QGIS\QGIS3\profiles\default\python\plugins\DigitizingTools\tools
C:\Users\marti\AppData\Roaming\QGIS\QGIS3\profiles\default\python\plugins\DigitizingTools
C:\Users\marti\AppData\Roaming\QGIS\QGIS3\profiles\default\python\plugins\HCMGIS/forms
C:\Users/marti/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\rvt-qgis
The problem does not occur in QGIS v3.36.1
There seem to have been a substantial number of Python version updates in 3.36.2: https://lists.osgeo.org/pipermail/qgis-user/2024-April/054334.html
The text was updated successfully, but these errors were encountered: