code: def test_tsne_knn_graph_used(test_datasets, type_knn_graph, method):
      X = test_datasets.data
  
      neigh = cuKNN(
          n_neighbors=DEFAULT_N_NEIGHBORS, metric="euclidean"
      ).fit(X)
      knn_graph = neigh.kneighbors_graph(X, mode="distance").astype(
          "float32"
      )
  
      if type_knn_graph == "cuml":
          knn_graph = cupyx.scipy.sparse.csr_matrix(knn_graph)
  
      tsne = TSNE(
          random_state=1,
          n_neighbors=DEFAULT_N_NEIGHBORS,
          method=method,
          perplexity=DEFAULT_PERPLEXITY,
          learning_rate_method="none",
          min_grad_norm=1e-12,
      )
  
      # Perform tsne with normal knn_graph
      Y = tsne.fit_transform(X, True, knn_graph)
  
      trust_normal = trustworthiness(
          X, Y, n_neighbors=DEFAULT_N_NEIGHBORS
      )
  
      X_garbage = np.ones(X.shape)
      knn_graph_garbage = neigh.kneighbors_graph(
          X_garbage, mode="distance"
      ).astype("float32")
  
      if type_knn_graph == "cuml":
          knn_graph_garbage = cupyx.scipy.sparse.csr_matrix(
              knn_graph_garbage
          )
  
      tsne = TSNE(
          random_state=1,
          n_neighbors=DEFAULT_N_NEIGHBORS,
          method=method,
          perplexity=DEFAULT_PERPLEXITY,
          learning_rate_method="none",
          min_grad_norm=1e-12,
      )
  
      # Perform tsne with garbage knn_graph
      Y = tsne.fit_transform(X, True, knn_graph_garbage)
  
      trust_garbage = trustworthiness(
          X, Y, n_neighbors=DEFAULT_N_NEIGHBORS
      )
      assert (trust_normal - trust_garbage) > 0.15
  
      Y = tsne.fit_transform(X, True, knn_graph_garbage)
      trust_garbage = trustworthiness(
          X, Y, n_neighbors=DEFAULT_N_NEIGHBORS
      )
      assert (trust_normal - trust_garbage) > 0.15
  
      Y = tsne.fit_transform(X, True, knn_graph_garbage)
      trust_garbage = trustworthiness(
          X, Y, n_neighbors=DEFAULT_N_NEIGHBORS
      )
      assert (trust_normal - trust_garbage) > 0.15
  
imports: import pytest
  from sklearn.manifold import TSNE
  from sklearn import datasets
  from sklearn.manifold import trustworthiness
  from sklearn.datasets import make_blobs
  from sklearn.neighbors import NearestNeighbors
  from cuml.manifold import TSNE
  from cuml.neighbors import NearestNeighbors
  from cuml.metrics import pairwise_distances
  from cuml.testing.utils import array_equal, stress_param
  from cuml.internals.safe_imports import cpu_only_import
  from cuml.internals.safe_imports import gpu_only_import
label_desc: Use image node_id 2 for calling a global function with example usage: test_tsne_knn_graph_used(test_datasets, type_knn_graph, method) without return types