class_docstr: Provides implementations for DRL algorithms
  
  Attributes
  ----------
      env: gym environment class
          user-defined class
  
  Methods
  -------
      get_model()
          setup DRL algorithms
      train_model()
          train DRL algorithms in a train dataset
          and output the trained model
      DRL_prediction()
          make a prediction in a test dataset and get results
class_docstr_tok: ["Provides","implementations","for","DRL","algorithms","Attributes","--","--","--","--","--","env",":","gym","environment","class","user-defined","class","Methods","--","--","--","-","get_model","(",")","setup","DRL","algorithms","train_model","(",")","train","DRL","algorithms","in","a","train","dataset","and","output","the","trained","model","DRL_prediction","(",")","make","a","prediction","in","a","test","dataset","and","get","results"]
code: def DRL_prediction_load_from_file(
      model_name, environment, cwd, deterministic=True
  ):
      if model_name not in MODELS:
          raise ValueError(
              f"Model '{model_name}' not found in MODELS."
          )  # this is more informative than NotImplementedError("NotImplementedError")
      try:
          # load agent
          model = MODELS[model_name].load(cwd)
          print("Successfully load model", cwd)
      except BaseException as error:
          raise ValueError(
              f"Failed to load agent. Error: {str(error)}"
          ) from error
  
      # test on the testing env
      state = environment.reset()
      episode_returns = []  # the cumulative_return / initial_account
      episode_total_assets = [environment.initial_total_asset]
      done = False
      while not done:
          action = model.predict(state, deterministic=deterministic)[0]
          state, reward, done, _ = environment.step(action)
  
          total_asset = (
              environment.amount
              + (
                  environment.price_ary[environment.day]
                  * environment.stocks
              ).sum()
          )
          episode_total_assets.append(total_asset)
          episode_return = total_asset / environment.initial_total_asset
          episode_returns.append(episode_return)
  
      print("episode_return", episode_return)
      print("Test Finished!")
      return episode_total_assets
  
imports: from __future__ import annotations
  import time
  import numpy
  import pandas
  from stable_baselines3 import A2C
  from stable_baselines3 import DDPG
  from stable_baselines3 import PPO
  from stable_baselines3 import SAC
  from stable_baselines3 import TD3
  from stable_baselines3.common.callbacks import BaseCallback
  from stable_baselines3.common.noise import NormalActionNoise
  from stable_baselines3.common.noise import OrnsteinUhlenbeckActionNoise
  from stable_baselines3.common.vec_env import DummyVecEnv
  from finrl import config
  from finrl.meta.env_stock_trading.env_stocktrading import StockTradingEnv
  from finrl.meta.preprocessor.preprocessors import data_split
label_desc: Use image node_id 5 for calling the DRLAgent obj's underlying member method code with example usage: obj.DRL_prediction_load_from_file(model_name, environment, cwd, deterministic) and returns: episode_total_assets