code: def test_sparse(csr_container):
      """Test Bisecting K-Means with sparse data.
  
      Checks if labels and centers are the same between dense and sparse.
      """
  
      rng = np.random.RandomState(0)
  
      X = rng.rand(20, 2)
      X[X < 0.8] = 0
      X_csr = csr_container(X)
  
      bisect_means = BisectingKMeans(n_clusters=3, random_state=0)
  
      bisect_means.fit(X_csr)
      sparse_centers = bisect_means.cluster_centers_
  
      bisect_means.fit(X)
      normal_centers = bisect_means.cluster_centers_
  
      # Check if results is the same for dense and sparse data
      assert_allclose(normal_centers, sparse_centers, atol=1e-8)
  
file_path: scikit-learn/sklearn/cluster/tests/test_bisect_k_means.py
imports: import numpy
  import pytest
  from sklearn.cluster import BisectingKMeans
  from sklearn.metrics import v_measure_score
  from sklearn.utils._testing import assert_allclose, assert_array_equal
  from sklearn.utils.fixes import CSR_CONTAINERS
label_desc: Use image node_id 2 for calling a global function with example usage: test_sparse(csr_container) without return types