docstr: Save model to a pickle located at `path`
docstr_tok: ["Save","model","to","a","pickle","located","at","`","path","`"]
code: def save_act(self, path=None):
      """Save model to a pickle located at `path`"""
      if path is None:
          path = os.path.join(logger.get_dir(), "model.pkl")
  
      with tempfile.TemporaryDirectory() as td:
          save_variables(os.path.join(td, "model"))
          arc_name = os.path.join(td, "packed.zip")
          with zipfile.ZipFile(arc_name, "w") as zipf:
              for root, dirs, files in os.walk(td):
                  for fname in files:
                      file_path = os.path.join(root, fname)
                      if file_path != arc_name:
                          zipf.write(
                              file_path, os.path.relpath(file_path, td)
                          )
          with open(arc_name, "rb") as f:
              model_data = f.read()
      with open(path, "wb") as f:
          cloudpickle.dump((model_data, self._act_params), f)
  
imports: import os
  import tempfile
  import tensorflow
  import zipfile
  import cloudpickle
  import numpy
  import baselines.common.tf_util
  from baselines.common.tf_util import load_variables, save_variables
  from baselines import logger
  from baselines.common.schedules import LinearSchedule
  from baselines.common import set_global_seeds
  from baselines import deepq
  from baselines.deepq.replay_buffer import ReplayBuffer, PrioritizedReplayBuffer
  from baselines.deepq.utils import ObservationInput
  from baselines.common.tf_util import get_session
  from baselines.deepq.models import build_q_func
label_desc: Use image node_id 5 for calling the ActWrapper obj's underlying member method code with example usage: obj.save_act(path) without return types