class_docstr: Categorical LSTM Policy.
  
  A policy represented by a Categorical distribution
  which is parameterized by a Long short-term memory (LSTM).
  
  It only works with akro.Discrete action space.
  
  Args:
      env_spec (garage.envs.env_spec.EnvSpec): Environment specification.
      name (str): Policy name, also the variable scope.
      hidden_dim (int): Hidden dimension for LSTM cell.
      hidden_nonlinearity (callable): Activation function for intermediate
          dense layer(s). It should return a tf.Tensor. Set it to
          None to maintain a linear activation.
      hidden_w_init (callable): Initializer function for the weight
          of intermediate dense layer(s). The function should return a
          tf.Tensor.
      hidden_b_init (callable): Initializer function for the bias
          of intermediate dense layer(s). The function should return a
          tf.Tensor.
      recurrent_nonlinearity (callable): Activation function for recurrent
          layers. It should return a tf.Tensor. Set it to None to
          maintain a linear activation.
      recurrent_w_init (callable): Initializer function for the weight
          of recurrent layer(s). The function should return a
          tf.Tensor.
      output_nonlinearity (callable): Activation function for output dense
          layer. It should return a tf.Tensor. Set it to None to
          maintain a linear activation.
      output_w_init (callable): Initializer function for the weight
          of output dense layer(s). The function should return a
          tf.Tensor.
      output_b_init (callable): Initializer function for the bias
          of output dense layer(s). The function should return a
          tf.Tensor.
      hidden_state_init (callable): Initializer function for the
          initial hidden state. The functino should return a tf.Tensor.
      hidden_state_init_trainable (bool): Bool for whether the initial
          hidden state is trainable.
      cell_state_init (callable): Initializer function for the
          initial cell state. The functino should return a tf.Tensor.
      cell_state_init_trainable (bool): Bool for whether the initial
          cell state is trainable.
      state_include_action (bool): Whether the state includes action.
          If True, input dimension will be
          (observation dimension + action dimension).
      forget_bias (bool): If True, add 1 to the bias of the forget gate
          at initialization. It's used to reduce the scale of forgetting at
          the beginning of the training.
      layer_normalization (bool): Bool for using layer normalization or not.
class_docstr_tok: ["Categorical","LSTM","Policy",".","A","policy","represented","by","a","Categorical","distribution","which","is","parameterized","by","a","Long","short-term","memory","(","LSTM",")",".","It","only","works","with","akro.Discrete","action","space",".","Args",":","env_spec","(","garage.envs.env_spec.EnvSpec",")",":","Environment","specification",".","name","(","str",")",":","Policy","name",",","also","the","variable","scope",".","hidden_dim","(","int",")",":","Hidden","dimension","for","LSTM","cell",".","hidden_nonlinearity","(","callable",")",":","Activation","function","for","intermediate","dense","layer","(","s",")",".","It","should","return","a","tf.Tensor",".","Set","it","to","None","to","maintain","a","linear","activation",".","hidden_w_init","(","callable",")",":","Initializer","function","for","the","weight","of","intermediate","dense","layer","(","s",")",".","The","function","should","return","a","tf.Tensor",".","hidden_b_init","(","callable",")",":","Initializer","function","for","the","bias","of","intermediate","dense","layer","(","s",")",".","The","function","should","return","a","tf.Tensor",".","recurrent_nonlinearity","(","callable",")",":","Activation","function","for","recurrent","layers",".","It","should","return","a","tf.Tensor",".","Set","it","to","None","to","maintain","a","linear","activation",".","recurrent_w_init","(","callable",")",":","Initializer","function","for","the","weight","of","recurrent","layer","(","s",")",".","The","function","should","return","a","tf.Tensor",".","output_nonlinearity","(","callable",")",":","Activation","function","for","output","dense","layer",".","It","should","return","a","tf.Tensor",".","Set","it","to","None","to","maintain","a","linear","activation",".","output_w_init","(","callable",")",":","Initializer","function","for","the","weight","of","output","dense","layer","(","s",")",".","The","function","should","return","a","tf.Tensor",".","output_b_init","(","callable",")",":","Initializer","function","for","the","bias","of","output","dense","layer","(","s",")",".","The","function","should","return","a","tf.Tensor",".","hidden_state_init","(","callable",")",":","Initializer","function","for","the","initial","hidden","state",".","The","functino","should","return","a","tf.Tensor",".","hidden_state_init_trainable","(","bool",")",":","Bool","for","whether","the","initial","hidden","state","is","trainable",".","cell_state_init","(","callable",")",":","Initializer","function","for","the","initial","cell","state",".","The","functino","should","return","a","tf.Tensor",".","cell_state_init_trainable","(","bool",")",":","Bool","for","whether","the","initial","cell","state","is","trainable",".","state_include_action","(","bool",")",":","Whether","the","state","includes","action",".","If","True",",","input","dimension","will","be","(","observation","dimension","+","action","dimension",")",".","forget_bias","(","bool",")",":","If","True",",","add","1","to","the","bias","of","the","forget","gate","at","initialization",".","It","'s","used","to","reduce","the","scale","of","forgetting","at","the","beginning","of","the","training",".","layer_normalization","(","bool",")",":","Bool","for","using","layer","normalization","or","not","."]
docstr: Return a clone of the policy.
  
  It copies the configuration of the primitive and also the parameters.
  
  Args:
      name (str): Name of the newly created policy. It has to be
          different from source policy if cloned under the same
          computational graph.
  
  Returns:
      garage.tf.policies.CategoricalLSTMPolicy: Newly cloned policy.
docstr_tok: ["Return","a","clone","of","the","policy",".","It","copies","the","configuration","of","the","primitive","and","also","the","parameters",".","Args",":","name","(","str",")",":","Name","of","the","newly","created","policy",".","It","has","to","be","different","from","source","policy","if","cloned","under","the","same","computational","graph",".","Returns",":","garage.tf.policies.CategoricalLSTMPolicy",":","Newly","cloned","policy","."]
code: def clone(self, name):
      """Return a clone of the policy.
  
      It copies the configuration of the primitive and also the parameters.
  
      Args:
          name (str): Name of the newly created policy. It has to be
              different from source policy if cloned under the same
              computational graph.
  
      Returns:
          garage.tf.policies.CategoricalLSTMPolicy: Newly cloned policy.
  
      """
      new_policy = self.__class__(
          name=name,
          env_spec=self._env_spec,
          hidden_dim=self._hidden_dim,
          hidden_nonlinearity=self._hidden_nonlinearity,
          hidden_w_init=self._hidden_w_init,
          hidden_b_init=self._hidden_b_init,
          recurrent_nonlinearity=self._recurrent_nonlinearity,
          recurrent_w_init=self._recurrent_w_init,
          output_nonlinearity=self._output_nonlinearity,
          output_w_init=self._output_w_init,
          output_b_init=self._output_b_init,
          hidden_state_init=self._hidden_state_init,
          hidden_state_init_trainable=self._hidden_state_init_trainable,
          cell_state_init=self._cell_state_init,
          cell_state_init_trainable=self._cell_state_init_trainable,
          state_include_action=self._state_include_action,
          forget_bias=self._forget_bias,
          layer_normalization=self._layer_normalization,
      )
      new_policy.parameters = self.parameters
      return new_policy
  
imports: import akro
  import numpy
  import tensorflow
  from garage.experiment import deterministic
  from garage.tf.models import CategoricalLSTMModel
  from garage.tf.policies.policy import Policy
label_desc: Use image node_id 10 for calling the CategoricalLSTMPolicy obj's underlying member method code with example usage: obj.clone(name) and returns: new_policy