code: def testCentroid(self):
      layout = Layout([(0, 0, 1), (0, 1, 0), (1, 0, 0), (2, 1, 3)])
      centroid = layout.centroid()
      self.assertEqual(len(centroid), 3)
      self.assertAlmostEqual(centroid[0], 0.75)
      self.assertAlmostEqual(centroid[1], 0.5)
      self.assertAlmostEqual(centroid[2], 1.0)
  
imports: import unittest
  from math import hypot
  from igraph import Graph, Layout, BoundingBox, InternalError
  from igraph import umap_compute_weights
label_desc: Use image node_id 5 for calling the LayoutTests obj's underlying member method code with example usage: obj.testCentroid() without return types