code: def test_distance_transform_edt_additional_shapes(
      self, xp, scp, shape, density, float64_distances
  ):
      kwargs = dict(return_distances=True, return_indices=False)
      if xp == cupy:
          # test CuPy-specific behavior allowing float32 distances
          kwargs["float64_distances"] = float64_distances
      img = self._binary_image(shape, xp=xp, pct_true=density)
      distances = scp.ndimage.distance_transform_edt(img, **kwargs)
      if not float64_distances and xp == cupy:
          assert distances.dtype == cupy.float32
          # cast to same dtype as numpy for numpy_cupy_allclose comparison
          distances = distances.astype(cupy.float64)
      return distances
  
imports: import copy
  import numpy
  import pytest
  import cupy
  from cupy import testing
  import cupyx.scipy.ndimage
label_desc: Use image node_id 4 for calling the TestDistanceTransform obj's underlying member method code with example usage: obj.test_distance_transform_edt_additional_shapes(xp, scp, shape, density, float64_distances) and returns: distances