code: def restore_model(self):
      if not os.path.isfile(self.model_path):
          return
  
      self.actor_critic = torch.load(self.model_path)
  
      if torch.cuda.is_available():
          self.actor_critic = self.actor_critic.cuda(device=self.device)
  
      file_path = self.model_path.replace(".pth", ".json")
  
      if os.path.isfile(file_path):
          with open(file_path, "r") as f:
              data = json.loads(f.read())
  
          self.current_episode = data["current_episode"]
          self.current_step = data["current_step"]
  
      self.emit_persisted_events()
  
file_path: SerpentAI/serpent/machine_learning/reinforcement_learning/agents/ppo_agent.py
imports: from serpent.machine_learning.reinforcement_learning.agent import Agent
  from serpent.game_frame import GameFrame
  from serpent.game_frame_buffer import GameFrameBuffer
  from serpent.enums import InputControlTypes
  from serpent.logger import Loggers
  from serpent.utilities import SerpentError
  import os
  import enum
  import copy
  import json
  import numpy
label_desc: Use image node_id 5 for calling the PPOAgent obj's underlying member method code with example usage: obj.restore_model() without return types