docstr: Loads the PyTorch model and returns the NN model object.
  
  Args:
      model_pt_path (str): denotes the path of the model file.
  
  Returns:
      (NN Model Object) : Loads the model object.
docstr_tok: ["Loads","the","PyTorch","model","and","returns","the","NN","model","object",".","Args",":","model_pt_path","(","str",")",":","denotes","the","path","of","the","model","file",".","Returns",":","(","NN","Model","Object",")",":","Loads","the","model","object","."]
code: def _load_torchscript_model(self, model_pt_path):
      """Loads the PyTorch model and returns the NN model object.
  
      Args:
          model_pt_path (str): denotes the path of the model file.
  
      Returns:
          (NN Model Object) : Loads the model object.
      """
      # TODO: remove this method if https://github.com/pytorch/text/issues/1793 gets resolved
  
      model = YOLO(model_pt_path)
      model.to(self.device)
      return model
  
file_path: serve/examples/object_detector/yolo/yolov8/custom_handler.py
imports: import logging
  import os
  from collections import Counter
  import torch
  from torchvision import transforms
  from ultralytics import YOLO
  from ts.torch_handler.object_detector import ObjectDetector
label_desc: Use image node_id 3 for calling the Yolov8Handler obj's underlying member method code with example usage: obj._load_torchscript_model(model_pt_path) and returns: model