mirror of
https://github.com/rasterio/rasterio.git
synced 2026-02-01 14:34:43 +00:00
* Add rotated.tif to test data
import numpy as np
import rasterio
from affine import Affine
a = Affine.translation(100, 200) * Affine.rotation(30) * Affine.scale(20, -10)
with rasterio.open('rotated.tif', 'w', 'GTiff', width=10, height=15, count=1,
crs=None, transform=a, dtype='uint8',
compress='packbits') as ds:
ds.write(np.arange(15 * 10).reshape((1, 15, 10)).astype('B'))
* correctly calculate bounds on a rotated raster
563 B
563 B