code: def test_transform_inverse_transform_round_trip(SPCA):
      """Check the `transform` and `inverse_transform` round trip with no loss of
      information.
      """
      rng = np.random.RandomState(0)
      n_samples, n_features = 10, 5
      X = rng.randn(n_samples, n_features)
  
      n_components = n_features
      spca = SPCA(
          n_components=n_components,
          alpha=1e-12,
          ridge_alpha=1e-12,
          random_state=0,
      )
      X_trans_spca = spca.fit_transform(X)
      assert_allclose(spca.inverse_transform(X_trans_spca), X)
  
imports: import sys
  import numpy
  import pytest
  from numpy.testing import assert_array_equal
  from sklearn.decomposition import PCA, MiniBatchSparsePCA, SparsePCA
  from sklearn.utils import check_random_state
  from sklearn.utils._testing import assert_allclose, assert_array_almost_equal, if_safe_multiprocessing_with_blas
label_desc: Use image node_id 20 for calling a global function with example usage: test_transform_inverse_transform_round_trip(SPCA) without return types