Google Earth Engine – How to Export Classified Image as GeoTIFF

exportgeotiff-tiffgoogle-earth-engine

Is it possible to export this classified image from Google Earth Engine (GEE)? I have seen similar questions but the difference is that I didn't produce that image. I tried to export it using this code:

Export.image.toDrive({
      image: img_2019,
      description: 'imageToDriveExample',
      scale: 30,
      maxPixels: 1000000000000,
      region: img_2019
    });

but I am getting a black raster. In their band description there exists 3 bands, named:

Band Description   
* lulc:  urban land use category   
* counts: the number of observations with the predicted lulc category   
* observations: the total number of observations

What I want is the first image of this link (lulc: urban land use category).

Best Answer

It seems that you are supplying the image i.e. img_2019 to the region parameter. In this, you should provide the extent polygon or the bounding coordinates of the area for which you want the data.

The documentation can be found here.

Related Question