code: def templateDynamicLength(
      path,
      number_clusters,
      expected_length,
      initial_neighbors,
      increase_persent,
      collect_dynamic_flag,
      ccore_flag,
  ):
      sample = read_sample(path)
      network = hsyncnet(
          sample,
          number_clusters,
          initial_type.EQUIPARTITION,
          initial_neighbors,
          increase_persent,
          ccore=ccore_flag,
      )
  
      analyser = network.process(
          order=0.995,
          solution=solve_type.FAST,
          collect_dynamic=collect_dynamic_flag,
      )
  
      assert len(analyser) != 0
  
      if collect_dynamic_flag is True:
          assert len(analyser) >= 1
          if expected_length is None:
              assert len(analyser) > 1
          else:
              assert len(analyser) == expected_length
  
      else:
          assert len(analyser) == 1
  
imports: from pyclustering.nnet import initial_type, solve_type
  from pyclustering.utils import read_sample
  from pyclustering.cluster.hsyncnet import hsyncnet
label_desc: Use image node_id 2 for calling the HsyncnetTestTemplates obj's underlying member method code with example usage: obj.templateDynamicLength(path, number_clusters, expected_length, initial_neighbors, increase_persent, collect_dynamic_flag, ccore_flag) without return types