示例#1
0
def test_from_assets_two_rasters():
    assets = GeoMultiRaster([raster_for_test(), raster_for_test()]).to_assets()
    assert GeoMultiRaster.from_assets(assets) == GeoRaster2.from_assets(assets)
    assert isinstance(GeoMultiRaster.from_assets(assets), GeoMultiRaster)
    assert isinstance(GeoRaster2.from_assets(assets), GeoMultiRaster)
示例#2
0
def test_from_assets_to_assets():
    raster = GeoRaster2.open("tests/data/raster/rgb.tif")
    assert raster == GeoRaster2.from_assets(raster.to_assets())
示例#3
0
def test_from_assets_single_raster():
    assets = raster_for_test().to_assets()
    assert GeoMultiRaster.from_assets(assets) == GeoRaster2.from_assets(assets)
    assert isinstance(GeoMultiRaster.from_assets(assets), GeoRaster2)
    assert isinstance(GeoRaster2.from_assets(assets), GeoRaster2)