code: def play_multi_episode(agent, episode_num=2, vis=False, seed=0):
      np.random.seed(seed)
      env = ProstheticsEnv(visualize=vis)
      env.change_model(
          model="3D", difficulty=1, prosthetic=True, seed=seed
      )
      env = TestReward(env)
      env = FrameSkip(env, 4)
      env = ActionScale(env)
      env = PelvisBasedObs(env)
  
      all_reward = []
  
      for e in range(episode_num):
          t = time.time()
          episode_reward = 0.0
          obs = env.reset(project=False)
          step = 0
          while True:
              step += 1
  
              batch_obs = np.expand_dims(obs, axis=0)
  
              action = agent.ensemble_predict(batch_obs)
              action = np.squeeze(action, axis=0)
              obs, reward, done, info = env.step(action, project=False)
              episode_reward += reward
              logger.info("[step/{}]reward:{}".format(step, reward))
              if done:
                  break
          all_reward.append(episode_reward)
          t = time.time() - t
          logger.info(
              "[episode/{}] time: {} episode_reward:{} mean_reward:{}".format(
                  e, t, episode_reward, np.mean(all_reward)
              )
          )
      logger.info("Mean reward:{}".format(np.mean(all_reward)))
  
file_path: PARL/examples/NeurIPS2018-AI-for-Prosthetics-Challenge/test.py
imports: import argparse
  import numpy
  import time
  from env_wrapper import FrameSkip, ActionScale, PelvisBasedObs, TestReward
  from multi_head_ddpg import MultiHeadDDPG
  from opensim_agent import OpenSimAgent
  from opensim_model import OpenSimModel
  from osim.env import ProstheticsEnv
  from parl.utils import logger
label_desc: Use image node_id 1 for calling a global function with example usage: play_multi_episode(agent, episode_num, vis, seed) without return types