code: def test_find_probabilistic_atlas_cut_coords(affine_eye):
      # make data
      arr1 = np.zeros((100, 100, 100))
      x_map_a, y_map_a, z_map_a = 30, 40, 50
      arr1[
          x_map_a - 10 : x_map_a + 10,
          y_map_a - 20 : y_map_a + 20,
          z_map_a - 30 : z_map_a + 30,
      ] = 1
  
      arr2 = np.zeros((100, 100, 100))
      x_map_b, y_map_b, z_map_b = 40, 50, 60
      arr2[
          x_map_b - 10 : x_map_b + 10,
          y_map_b - 20 : y_map_b + 20,
          z_map_b - 30 : z_map_b + 30,
      ] = 1
  
      # make data with empty in between non-empty maps to make sure that
      # code does not crash
      arr3 = np.zeros((100, 100, 100))
  
      data = np.concatenate(
          (
              arr1[..., np.newaxis],
              arr3[..., np.newaxis],
              arr2[..., np.newaxis],
          ),
          axis=3,
      )
  
      # Number of maps in time dimension
      n_maps = data.shape[-1]
  
      # run test on img with identity affine
      img = nibabel.Nifti1Image(data, affine_eye)
      coords = find_probabilistic_atlas_cut_coords(img)
  
      # Check outputs
      assert (n_maps, 3) == coords.shape
  
      np.testing.assert_allclose(
          (coords[0][0], coords[0][1], coords[0][2]),
          (x_map_a, y_map_a, z_map_a),
          rtol=6e-2,
      )
      np.testing.assert_allclose(
          (coords[2][0], coords[2][1], coords[2][2]),
          (x_map_b - 0.5, y_map_b - 0.5, z_map_b - 0.5),
          rtol=6e-2,
      )
  
      # non-trivial affine
      affine = np.diag([1 / 2.0, 1 / 3.0, 1 / 4.0, 1.0])
      img = nibabel.Nifti1Image(data, affine)
      coords = find_probabilistic_atlas_cut_coords(img)
      # Check outputs
      assert (n_maps, 3) == coords.shape
      np.testing.assert_allclose(
          (coords[0][0], coords[0][1], coords[0][2]),
          (x_map_a / 2.0, y_map_a / 3.0, z_map_a / 4.0),
          rtol=6e-2,
      )
      np.testing.assert_allclose(
          (coords[2][0], coords[2][1], coords[2][2]),
          (x_map_b / 2.0, y_map_b / 3.0, z_map_b / 4.0),
          rtol=6e-2,
      )
  
file_path: nilearn/nilearn/plotting/tests/test_find_cuts.py
imports: import nibabel
  import numpy
  import pytest
  from nilearn.masking import compute_epi_mask
  from nilearn.plotting.find_cuts import _transform_cut_coords, find_cut_slices, find_parcellation_cut_coords, find_probabilistic_atlas_cut_coords, find_xyz_cut_coords
label_desc: Use image node_id 11 for calling a global function with example usage: test_find_probabilistic_atlas_cut_coords(affine_eye) without return types