ConservationInternational / trends.earth

trends.earth - measure land change
http://trends.earth
GNU General Public License v2.0
111 stars 45 forks source link

IMPORTING LAND COVER RASTER #780

Open sabepaco opened 1 year ago

sabepaco commented 1 year ago

I HAVE AN ISSUE WHEN IM TRYING TO IMPORT A .TIF CUSTOM DATASET LAND COVER 2023-05-19T19:56:54 WARNING Traceback (most recent call last): File "C:\Users/paco0/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\LDMP\lc_setup.py", line 969, in done self.validate_input(value) File "C:\Users/paco0/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\LDMP\lc_setup.py", line 1002, in validate_input self.ok_clicked() File "C:\Users/paco0/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\LDMP\lc_setup.py", line 1140, in ok_clicked remap_ret = self.remap_raster(out_file, self.dlg_agg.nesting.get_list()) File "C:\Users/paco0/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\LDMP\data_io.py", line 1250, in remap_raster warp_ret = self.warp_raster(temp_tif) File "C:\Users/paco0/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\LDMP\data_io.py", line 1317, in warp_raster raster_import_worker = worker.StartWorker( File "C:\Users/paco0/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\LDMP\worker.py", line 174, in init raise self.exception File "C:\Users/paco0/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\LDMP\worker.py", line 42, in run result = self.work() File "C:\Users/paco0/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\LDMP\data_io.py", line 364, in work res = gdal.Warp( File "C:\PROGRA~1\QGIS32~1.3\apps\Python39\lib\site-packages\GDAL-3.4.1-py3.9-win-amd64.egg\osgeo\gdal.py", line 673, in Warp return wrapper_GDALWarpDestName(destNameOrDestDS, srcDSTab, opts, callback, callback_data) File "C:\PROGRA~1\QGIS32~1.3\apps\Python39\lib\site-packages\GDAL-3.4.1-py3.9-win-amd64.egg\osgeo\gdal.py", line 4211, in wrapper_GDALWarpDestName return _gdal.wrapper_GDALWarpDestName(*args) TypeError: object of wrong GDALDatasetShadow

2023-05-19T20:07:25 WARNING Traceback (most recent call last): File "C:\Users/paco0/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\LDMP\lc_setup.py", line 969, in done self.validate_input(value) File "C:\Users/paco0/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\LDMP\lc_setup.py", line 1002, in validate_input self.ok_clicked() File "C:\Users/paco0/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\LDMP\lc_setup.py", line 1140, in ok_clicked remap_ret = self.remap_raster(out_file, self.dlg_agg.nesting.get_list()) File "C:\Users/paco0/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\LDMP\data_io.py", line 1250, in remap_raster File "C:\Users/paco0/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\LDMP\data_io.py", line 1317, in warp_raster RasterImportWorker, File "C:\Users/paco0/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\LDMP\worker.py", line 174, in init raise self.exception File "C:\Users/paco0/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\LDMP\worker.py", line 42, in run result = self.work() File "C:\Users/paco0/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\LDMP\data_io.py", line 364, in work self.out_file, File "C:\PROGRA~1\QGIS32~1.3\apps\Python39\lib\site-packages\GDAL-3.4.1-py3.9-win-amd64.egg\osgeo\gdal.py", line 673, in Warp return wrapper_GDALWarpDestName(destNameOrDestDS, srcDSTab, opts, callback, callback_data) File "C:\PROGRA~1\QGIS32~1.3\apps\Python39\lib\site-packages\GDAL-3.4.1-py3.9-win-amd64.egg\osgeo\gdal.py", line 4211, in wrapper_GDALWarpDestName return _gdal.wrapper_GDALWarpDestName(*args) TypeError: object of wrong GDALDatasetShadow

azvoleff commented 1 year ago

@sabepaco sorry for the slow follow-up. If you are still seeing this issue, can you tell us what platform you are using, the plugin version, and also share a sample dataset so we can test this?

d-consoli commented 1 month ago

I get a similar error. I am using Trends.Earth 2.1.16 on: Qt version | 5.15.3 Python version | 3.10.12 GDAL/OGR version | 3.8.4 PROJ version | 9.3.1 EPSG Registry database version | v10.098 (2023-11-24) GEOS version | 3.12.1-CAPI-1.18.1 SQLite version | 3.37.2 PostgreSQL client version | 14.12 (Ubuntu 14.12-0ubuntu0.22.04.1) SpatiaLite version | 5.1.0 QWT version | 6.1.4 QScintilla2 version | 2.11.6 OS version | Ubuntu 22.04.5 LTS

How can I solve this?