code: def test_dtype_rescaling_float64(tmpdir, runner):
      """Rescale uint8 [0, 255] to float64 [-1, 1]"""
      outputname = str(tmpdir.join("test.tif"))
      result = runner.invoke(
          main_group,
          [
              "convert",
              "tests/data/RGB.byte.tif",
              outputname,
              "--dtype",
              "float64",
              "--scale-ratio",
              str(2.0 / 255),
              "--scale-offset",
              "-1.0",
          ],
      )
      assert result.exit_code == 0
      with rasterio.open(outputname) as src:
          for band in src.read():
              assert round(band.min() + 1.0, 6) == 0.0
              assert round(band.max() - 1.0, 6) == 0.0
  
file_path: rasterio/tests/test_rio_convert.py
imports: import pytest
  import rasterio
  from rasterio.rio.main import main_group
label_desc: Use image node_id 10 for calling a global function with example usage: test_dtype_rescaling_float64(tmpdir, runner) without return types