Is it possible to set the data type (Byte, Float32) when using gdal.Rasterize in gdal 2.1? Currently, I use gdal.Translate to convert to Byte, but this is inefficient.
If you are in gdal 2.1.2, use gdal.RasterizeOptions() as if you were using it on the command line:
opts_str = '-ot Byte' rast_opts = gdal.RasterizeOptions(options=opts_str)