code: def test_constrained_voronoi_2(nbseeds=3):
      # Test the geodisc k-means algorithm
      xyz, x = np.zeros((30, 3)), np.arange(30)
      xyz[:, 0] = x
      y = np.array((x // 10), np.float64)
      myfield = field_from_graph_and_data(
          wgraph_from_3d_grid(xyz, 6), y
      )
      seeds = np.array([1, 18, 25])
      label = myfield.constrained_voronoi(seeds)
      assert_array_equal(label, x // 10)
  
imports: import numpy
  import numpy.random
  from numpy.testing import assert_array_equal
  from ..field import field_from_coo_matrix_and_data, field_from_graph_and_data
  from ..graph import wgraph_from_3d_grid
label_desc: Use image node_id 26 for calling a global function with example usage: test_constrained_voronoi_2(nbseeds) without return types