code: def test_compute_variance_from_index(
      self, weighted_distances, expected_var, atol
  ):
      var = self.model.compute_variance_from_index(weighted_distances)
      self.assertAllClose(var, expected_var, atol=atol)
  
file_path: geomstats/geomstats/test_cases/learning/expectation_maximization.py
imports: import pytest
  import geomstats.backend
  from geomstats.test.test_case import TestCase
  from geomstats.test_cases.learning._base import BaseEstimatorTestCase
label_desc: Use image node_id 5 for calling the GaussianMixtureModelTestCase obj's underlying member method code with example usage: obj.test_compute_variance_from_index(weighted_distances, expected_var, atol) without return types