class_docstr: run insert
class_docstr_tok: ["run","insert"]
code: def prepare(self, **case_param):
      collection_name = case_param["collection_name"]
      dimension = case_param["dimension"]
      vector_type = case_param["vector_type"]
      other_fields = case_param["other_fields"]
      index_field_name = case_param["index_field_name"]
      build_index = case_param["build_index"]
  
      self.milvus.set_collection(collection_name)
      if self.milvus.exists_collection():
          logger.debug("Start drop collection")
          self.milvus.drop()
          time.sleep(runner_utils.DELETE_INTERVAL_TIME)
      self.milvus.create_collection(
          dimension, data_type=vector_type, other_fields=other_fields
      )
      # TODO: update fields in collection_info
      # fields = self.get_fields(self.milvus, collection_name)
      # collection_info = {
      #     "dimension": dimension,
      #     "metric_type": metric_type,
      #     "dataset_name": collection_name,
      #     "fields": fields
      # }
      if build_index is True:
          if case_param["index_type"]:
              self.milvus.create_index(
                  index_field_name,
                  case_param["index_type"],
                  case_param["metric_type"],
                  index_param=case_param["index_param"],
              )
              logger.debug(self.milvus.describe_index(index_field_name))
          else:
              build_index = False
              logger.warning("Please specify the index_type")
  
imports: import time
  import copy
  import logging
  from .None import locust_user
  from .base import BaseRunner
  from milvus_benchmark import parser
  from milvus_benchmark import utils
  from milvus_benchmark.runners import utils
label_desc: Use image node_id 3 for calling the LocustInsertRunner obj's underlying member method code with example usage: obj.prepare() without return types