Problem with imageutils for reprojection/resampling

42 views
Skip to first unread message

Johannes Heisig

unread,
Nov 20, 2018, 3:59:30 AM11/20/18
to RSGISLib Support
Dear All,
while working through the RSGISLib tutorial I came across an error ending in the following statement: "RuntimeError: Object given is not a Python function"
Up until chapter 4.2 (reprojecting and resampling) all code samples worked fine, including the mosaicing, where imageutils is already required. GDAL further works fine when used seperately.
Any Ideas? Thanks for your help!
Johannes
screenshot_rsgislib_error.PNG

Daniel Clewley

unread,
Nov 20, 2018, 5:23:05 AM11/20/18
to johanne...@googlemail.com, rsgislib...@googlegroups.com
Hi Johannes,

I think this is a problem with the progress function we are passing to GDAL, it works fine on macOS / Linux but not Windows. Can you try the attached script, which has an edited copy of one of the RSGISLib functions, and let me know if this fixes the problem.

Thanks,

Dan

--
You received this message because you are subscribed to the Google Groups "RSGISLib Support" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rsgislib-suppo...@googlegroups.com.
To post to this group, send email to rsgislib...@googlegroups.com.
Visit this group at https://groups.google.com/group/rsgislib-support.
For more options, visit https://groups.google.com/d/optout.
04_Resample2Landsat.py

Johannes Heisig

unread,
Nov 20, 2018, 6:07:56 AM11/20/18
to dac...@gmail.com, rsgislib...@googlegroups.com
Thanks Dan, for this instant reaction and your great work in general,

your solution does fix the problem, at least temporarily. I already stumbled again in the next step (05_ValidImageryMask.py), but could solve the issue by replacing format='KEA' with gdalformat='KEA' in line 13. In step 6 (06A_RasterToVector.py) however, presumably the same issue as before occurs again. I understand that this is an OS-related problem and might just get rid of my Windows some day ;)

Best,
Johannes
screenshot_rsgislib_error2.PNG
Reply all
Reply to author
Forward
0 new messages