code: def test_exceptions():
      with pytest.raises(NotFittedError):
          X = cp.random.random((10, 10))
          cuPCA().transform(X)
  
      with pytest.raises(NotFittedError):
          X = cp.random.random((10, 10))
          cuPCA().inverse_transform(X)
  
file_path: cuml/python/cuml/tests/test_pca.py
imports: from cuml.common.exceptions import NotFittedError
  from sklearn.datasets import make_blobs
  from sklearn.decomposition import PCA
  from sklearn.datasets import make_multilabel_classification
  from sklearn import datasets
  from cuml.testing.utils import get_handle, array_equal, unit_param, quality_param, stress_param
  from cuml import PCA
  import pytest
  from cuml.internals.safe_imports import gpu_only_import
  from cuml.internals.safe_imports import cpu_only_import
label_desc: Use image node_id 7 for calling a global function with example usage: test_exceptions() without return types