I am running QGIS 3.4.14 (current stable version) on OSX Mojave 10.14.5.
I have a vector mask that I want to use to clip out a region of an image. Image was a jpeg originally but I translated it to a tiff in Q.
Now I'm getting the error "ERROR 1: The transformation is already "north up" or a transformation between pixel/line and georeferenced coordinates cannot be computed for /path/to/file/boston.tif. There is no affine transformation and no GCPs. Specify transformation option SRC_METHOD=NO_GEOTRANSFORM to bypass this check."
I can't change the GDAL console call directly in this version of Q, as far as I'm aware, but based on a previous question I can edit it within the python console using the following answer from a similar problem:
import subprocess cmd = "gdalwarp -of GTiff -cutline /path/to/mask/mask_poly.shp -cl mask_poly -crop_to_cutline /path/to/raster/boston.tif /path/to/output/_boston_clip.tif SRC_METHOD=NO_GEOTRANSFORM" subprocess.run ([x for x in cmd.split(" ") if x != ""])
I don't get any errors but no file seems to be created. Does anyone know a way to resolve this error?
The above solution was posted at How to edit the GDAL/OGR console call in QGIS 3.0?