code: def test_dtype():
      data_32 = np.zeros((9, 9, 9), dtype=np.float32)
      data_64 = np.zeros((9, 9, 9), dtype=np.float64)
      data_32[2:-2, 2:-2, 2:-2] = 10
      data_64[2:-2, 2:-2, 2:-2] = 10
  
      affine_32 = np.eye(4, dtype=np.float32)
      affine_64 = np.eye(4, dtype=np.float64)
  
      img_32 = nibabel.Nifti1Image(data_32, affine_32)
      img_64 = nibabel.Nifti1Image(data_64, affine_64)
  
      masker_1 = NiftiMasker(dtype="auto")
      assert masker_1.fit_transform(img_32).dtype == np.float32
      assert masker_1.fit_transform(img_64).dtype == np.float32
  
      masker_2 = NiftiMasker(dtype="float64")
      assert masker_2.fit_transform(img_32).dtype == np.float64
      assert masker_2.fit_transform(img_64).dtype == np.float64
  
imports: import os
  import shutil
  import warnings
  from tempfile import mkdtemp
  import nibabel
  import numpy
  import pytest
  from numpy.testing import assert_array_equal
  from nilearn._utils import data_gen, exceptions, testing
  from nilearn._utils.class_inspect import get_params
  from nilearn.image import get_data, index_img
  from nilearn.maskers import NiftiMasker
  from nilearn.maskers.nifti_masker import _filter_and_mask
label_desc: Use image node_id 23 for calling a global function with example usage: test_dtype() without return types