Skip to content

Commit

Permalink
update benchmark names
Browse files Browse the repository at this point in the history
  • Loading branch information
vincentsarago committed Oct 4, 2024
1 parent 05c3a84 commit 7e9dedb
Showing 1 changed file with 5 additions and 11 deletions.
16 changes: 5 additions & 11 deletions tests/benchmarks/benchmarks.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,22 +75,16 @@ def read_tile(dst, tile):
return src.tile(*tile)


data_types = list(dtype_ranges.keys())
nodata_type = ["nodata", "alpha", "mask", "none"]


@pytest.mark.parametrize("tile_name", ["full"])
@pytest.mark.parametrize("dataset_name", ["equator", "dateline"])
@pytest.mark.parametrize("data_type", list(dtype_ranges.keys()))
@pytest.mark.parametrize("nodata_type", ["nodata", "alpha", "mask", "none"])
def test_tile(
nodata_type, data_type, dataset_name, tile_name, dataset_fixture, benchmark
):
def test_tile(nodata_type, data_type, dataset_name, dataset_fixture, benchmark):
"""Test tile read for multiple combination of datatype/mask/tile extent."""
benchmark.name = f"{data_type}-{nodata_type}"
benchmark.group = f"{dataset_name} - {tile_name} tile "
tile = benchmark_tiles[dataset_name][tile_name]
benchmark.name = f"{dataset_name}-{data_type}-{nodata_type}"
benchmark.fullname = f"{dataset_name}-{data_type}-{nodata_type}"
benchmark.group = dataset_name

tile = benchmark_tiles[dataset_name]["full"]
dst_info = datasets[dataset_name]
with rasterio.Env(GDAL_DISABLE_READDIR_ON_OPEN="EMPTY_DIR", NUM_THREADS="all"):
with MemoryFile(
Expand Down

0 comments on commit 7e9dedb

Please sign in to comment.