docstr: Compile the input model using Apache TVM compiler.
  
  Args:
      model (Union[Module, str]: The input model. Can be a torch model
          or a path to an onnx model.
      input_tfms (MultiStageTransformation, optional): Transformations
          to be performed to the model's input tensors in order to
          get the prediction. Default: None.
      model_params (ModelParams): Model parameters.
      metric_drop_ths (float, optional): Threshold for the accepted drop
          in terms of precision. Any optimized model with a higher drop
          will be ignored. Default: None.
      quantization_type (QuantizationType, optional): The desired
          quantization algorithm to be used. Default: None.
      input_data (DataManager): User defined data. Default: None
docstr_tok: ["Compile","the","input","model","using","Apache","TVM","compiler",".","Args",":","model","(","Union","[","Module",",","str","]",":","The","input","model",".","Can","be","a","torch","model","or","a","path","to","an","onnx","model",".","input_tfms","(","MultiStageTransformation",",","optional",")",":","Transformations","to","be","performed","to","the","model","'s","input","tensors","in","order","to","get","the","prediction",".","Default",":","None",".","model_params","(","ModelParams",")",":","Model","parameters",".","metric_drop_ths","(","float",",","optional",")",":","Threshold","for","the","accepted","drop","in","terms","of","precision",".","Any","optimized","model","with","a","higher","drop","will","be","ignored",".","Default",":","None",".","quantization_type","(","QuantizationType",",","optional",")",":","The","desired","quantization","algorithm","to","be","used",".","Default",":","None",".","input_data","(","DataManager",")",":","User","defined","data",".","Default",":","None"]
code: def execute(
      self,
      model: Union[Module, str],
      input_tfms: MultiStageTransformation,
      model_params: ModelParams,
      metric_drop_ths: float = None,
      quantization_type: QuantizationType = None,
      input_data: DataManager = None,
      **kwargs,
  ):
      """Compile the input model using Apache TVM compiler.
  
      Args:
          model (Union[Module, str]: The input model. Can be a torch model
              or a path to an onnx model.
          input_tfms (MultiStageTransformation, optional): Transformations
              to be performed to the model's input tensors in order to
              get the prediction. Default: None.
          model_params (ModelParams): Model parameters.
          metric_drop_ths (float, optional): Threshold for the accepted drop
              in terms of precision. Any optimized model with a higher drop
              will be ignored. Default: None.
          quantization_type (QuantizationType, optional): The desired
              quantization algorithm to be used. Default: None.
          input_data (DataManager): User defined data. Default: None
      """
  
      if (
          quantization_type
          not in self.supported_ops[self.device.type.value]
      ):
          self.compiled_model = None
          return
  
      if (
          quantization_type is QuantizationType.STATIC
          and input_data is None
      ):
          raise ValueError(
              "Input data is required for static quantization."
          )
  
      self.logger.info(
          f"Optimizing with {self.__class__.__name__} and "
          f"q_type: {quantization_type}."
      )
  
      check_quantization(quantization_type, metric_drop_ths)
  
      mod, params = self._build_tvm_model(model, model_params)
  
      if quantization_type is not None:
          mod = self._quantize_model(
              mod, quantization_type, input_tfms, input_data, params
          )
  
      self.compiled_model = self._compile_model(mod, params)
  
imports: import abc
  import os
  import uuid
  from abc import ABC
  from typing import Any, Tuple, Dict, Union
  from nebullvm.config import AUTO_TVM_PARAMS, AUTO_TVM_TUNING_OPTION
  from nebullvm.core.models import QuantizationType, ModelParams, DeviceType, Device
  from nebullvm.operations.optimizations.compilers.base import Compiler
  from nebullvm.operations.optimizations.compilers.quantizations.tvm import TVMCalibrator, quantize_apache_tvm
  from nebullvm.operations.optimizations.compilers.quantizations.utils import check_quantization
  from nebullvm.optional_modules.onnx import onnx
  from nebullvm.optional_modules.torch import Module, torch
  from nebullvm.optional_modules.tvm import tvm, IRModule, NDArray, XGBTuner, autotvm, relay, ExecutorFactoryModule
  from nebullvm.tools.data import DataManager
  from nebullvm.tools.onnx import get_input_names
  from nebullvm.tools.pytorch import create_model_inputs_torch
  from nebullvm.tools.transformations import MultiStageTransformation
label_desc: Use image node_id 2 for calling the ApacheTVMCompiler obj's underlying member method code with example usage: obj.execute(model, input_tfms, model_params, metric_drop_ths, quantization_type, input_data) without return types