docstr: Save the best model.
  
  Please note that if you only want the pytorch model or onnx model
  file, you can call .get_model() or .export_onnx_file(). The checkpoint
  file generated by .save() method can only be used by .load() in automodel.
  If you specify "keras" as backend, file name will be best_keras_config.json
  and best_keras_model.ckpt.
  
  :param checkpoint_path: The location you want to save the best model.
docstr_tok: ["Save","the","best","model",".","Please","note","that","if","you","only","want","the","pytorch","model","or","onnx","model","file",",","you","can","call",".get_model","(",")","or",".export_onnx_file","(",")",".","The","checkpoint","file","generated","by",".save","(",")","method","can","only","be","used","by",".load","(",")","in","automodel",".","If","you","specify","``","keras","''","as","backend",",","file","name","will","be","best_keras_config.json","and","best_keras_model.ckpt",".",":","param","checkpoint_path",":","The","location","you","want","to","save","the","best","model","."]
code: def save(self, checkpoint_path):
      """
      Save the best model.
  
      Please note that if you only want the pytorch model or onnx model
      file, you can call .get_model() or .export_onnx_file(). The checkpoint
      file generated by .save() method can only be used by .load() in automodel.
      If you specify "keras" as backend, file name will be best_keras_config.json
      and best_keras_model.ckpt.
  
      :param checkpoint_path: The location you want to save the best model.
      """
      from bigdl.nano.utils.common import invalidInputError
  
      if self.best_model is None:
          invalidInputError(
              False,
              "You must call fit or load first before calling predict!",
          )
      if not os.path.isdir(checkpoint_path):
          os.mkdir(checkpoint_path)
      model_path = os.path.join(
          checkpoint_path, self._DEFAULT_BEST_MODEL_DIR
      )
      best_config_path = os.path.join(
          checkpoint_path, self._DEFAULT_BEST_CONFIG_DIR
      )
      self.best_model.save(model_path)
      with open(best_config_path, "w") as f:
          json.dump(self.best_config, f)
  
file_path: BigDL/python/chronos/src/bigdl/chronos/autots/model/base_automodel.py
imports: import os
  import json
  from bigdl.chronos.autots.utils import recalculate_n_sampling
  import warnings
label_desc: Use image node_id 7 for calling the BaseAutomodel obj's underlying member method code with example usage: obj.save(checkpoint_path) without return types