code: def test_inverse_transform(
      whiten,
      n_components,
      expected_mixing_shape,
      global_random_seed,
      global_dtype,
  ):
      # Test FastICA.inverse_transform
      n_samples = 100
      rng = np.random.RandomState(global_random_seed)
      X = rng.random_sample((n_samples, 10)).astype(global_dtype)
  
      ica = FastICA(
          n_components=n_components, random_state=rng, whiten=whiten
      )
      with warnings.catch_warnings():
          # For some dataset (depending on the value of global_dtype) the model
          # can fail to converge but this should not impact the definition of
          # a valid inverse transform.
          warnings.simplefilter("ignore", ConvergenceWarning)
          Xt = ica.fit_transform(X)
      assert ica.mixing_.shape == expected_mixing_shape
      X2 = ica.inverse_transform(Xt)
      assert X.shape == X2.shape
  
      # reversibility test in non-reduction case
      if n_components == X.shape[1]:
          # XXX: we have to set atol for this test to pass for all seeds when
          # fitting with float32 data. Is this revealing a bug?
          if global_dtype:
              # XXX: dividing by a smaller number makes
              # tests fail for some seeds.
              atol = np.abs(X2).mean() / 1e5
          else:
              atol = 0.0  # the default rtol is enough for float64 data
          assert_allclose(X, X2, atol=atol)
  
imports: import itertools
  import os
  import warnings
  import numpy
  import pytest
  from scipy import stats
  from sklearn.decomposition import PCA, FastICA, fastica
  from sklearn.decomposition._fastica import _gs_decorrelation
  from sklearn.exceptions import ConvergenceWarning
  from sklearn.utils._testing import assert_allclose
label_desc: Use image node_id 10 for calling a global function with example usage: test_inverse_transform(whiten, n_components, expected_mixing_shape, global_random_seed, global_dtype) without return types