class_docstr: Tensorforce agent interface.
class_docstr_tok: ["Tensorforce","agent","interface","."]
docstr: Returns action(s) for the given state(s), needs to be followed by `observe()` unless
  independent mode.
  
  See the [act-observe script](https://github.com/tensorforce/tensorforce/blob/master/examples/act_observe_interface.py)
  for an example application as part of the act-observe interface.
  
  Args:
      states (dict[state] | iter[dict[state]]): Dictionary containing state(s) to be acted on
          (<span style="color:#C00000"><b>required</b></span>).
      internals (dict[internal] | iter[dict[internal]]): Dictionary containing current
          internal agent state(s), either given by `initial_internals()` at the beginning of
          an episode or as return value of the preceding `act()` call
          (<span style="color:#C00000"><b>required</b></span> if independent mode and agent
          has internal states).
      parallel (int | iter[int]): Parallel execution index
          (<span style="color:#00C000"><b>default</b></span>: 0).
      independent (bool): Whether this act() call is not part of the training
          agent-environment interaction and thus not followed by observe(), meaning its
          inputs/outputs/internals are not stored in memory and not used in updates, e.g. for
          independent evaluation episodes which should not be learned from
          (<span style="color:#00C000"><b>default</b></span>: false).
      deterministic (bool): Whether action should be chosen deterministically, so no
          action distribution sampling and no exploration, only valid in independent mode
          (<span style="color:#00C000"><b>default</b></span>: true).
  
  Returns:
      dict[action] | iter[dict[action]], dict[internal] | iter[dict[internal]] if `internals`
      argument given: Dictionary containing action(s), dictionary containing next internal
      agent state(s) if independent mode.
docstr_tok: ["Returns","action","(","s",")","for","the","given","state","(","s",")",",","needs","to","be","followed","by","`","observe","(",")","`","unless","independent","mode",".","See","the","[","act-observe","script","]","(","https",":","\/\/github.com\/tensorforce\/tensorforce\/blob\/master\/examples\/act_observe_interface.py",")","for","an","example","application","as","part","of","the","act-observe","interface",".","Args",":","states","(","dict","[","state","]","|","iter","[","dict","[","state","]","]",")",":","Dictionary","containing","state","(","s",")","to","be","acted","on","(","<","span","style=","''","color",":","#","C00000","''",">","<","b",">","required","<","\/b",">","<","\/span",">",")",".","internals","(","dict","[","internal","]","|","iter","[","dict","[","internal","]","]",")",":","Dictionary","containing","current","internal","agent","state","(","s",")",",","either","given","by","`","initial_internals","(",")","`","at","the","beginning","of","an","episode","or","as","return","value","of","the","preceding","`","act","(",")","`","call","(","<","span","style=","''","color",":","#","C00000","''",">","<","b",">","required","<","\/b",">","<","\/span",">","if","independent","mode","and","agent","has","internal","states",")",".","parallel","(","int","|","iter","[","int","]",")",":","Parallel","execution","index","(","<","span","style=","''","color",":","#","00C000","''",">","<","b",">","default","<","\/b",">","<","\/span",">",":","0",")",".","independent","(","bool",")",":","Whether","this","act","(",")","call","is","not","part","of","the","training","agent-environment","interaction","and","thus","not","followed","by","observe","(",")",",","meaning","its","inputs\/outputs\/internals","are","not","stored","in","memory","and","not","used","in","updates",",","e.g",".","for","independent","evaluation","episodes","which","should","not","be","learned","from","(","<","span","style=","''","color",":","#","00C000","''",">","<","b",">","default","<","\/b",">","<","\/span",">",":","false",")",".","deterministic","(","bool",")",":","Whether","action","should","be","chosen","deterministically",",","so","no","action","distribution","sampling","and","no","exploration",",","only","valid","in","independent","mode","(","<","span","style=","''","color",":","#","00C000","''",">","<","b",">","default","<","\/b",">","<","\/span",">",":","true",")",".","Returns",":","dict","[","action","]","|","iter","[","dict","[","action","]","]",",","dict","[","internal","]","|","iter","[","dict","[","internal","]","]","if","`","internals","`","argument","given",":","Dictionary","containing","action","(","s",")",",","dictionary","containing","next","internal","agent","state","(","s",")","if","independent","mode","."]
code: def act(
      self,
      states,
      internals=None,
      parallel=0,
      independent=False,
      deterministic=True,
      # Deprecated
      evaluation=None,
  ):
      """
      Returns action(s) for the given state(s), needs to be followed by `observe()` unless
      independent mode.
  
      See the [act-observe script](https://github.com/tensorforce/tensorforce/blob/master/examples/act_observe_interface.py)
      for an example application as part of the act-observe interface.
  
      Args:
          states (dict[state] | iter[dict[state]]): Dictionary containing state(s) to be acted on
              (<span style="color:#C00000"><b>required</b></span>).
          internals (dict[internal] | iter[dict[internal]]): Dictionary containing current
              internal agent state(s), either given by `initial_internals()` at the beginning of
              an episode or as return value of the preceding `act()` call
              (<span style="color:#C00000"><b>required</b></span> if independent mode and agent
              has internal states).
          parallel (int | iter[int]): Parallel execution index
              (<span style="color:#00C000"><b>default</b></span>: 0).
          independent (bool): Whether this act() call is not part of the training
              agent-environment interaction and thus not followed by observe(), meaning its
              inputs/outputs/internals are not stored in memory and not used in updates, e.g. for
              independent evaluation episodes which should not be learned from
              (<span style="color:#00C000"><b>default</b></span>: false).
          deterministic (bool): Whether action should be chosen deterministically, so no
              action distribution sampling and no exploration, only valid in independent mode
              (<span style="color:#00C000"><b>default</b></span>: true).
  
      Returns:
          dict[action] | iter[dict[action]], dict[internal] | iter[dict[internal]] if `internals`
          argument given: Dictionary containing action(s), dictionary containing next internal
          agent state(s) if independent mode.
      """
      if evaluation is not None:
          raise TensorforceError.deprecated(
              name="Agent.act",
              argument="evaluation",
              replacement="independent",
          )
  
      return super().act(
          states=states,
          internals=internals,
          parallel=parallel,
          independent=independent,
          deterministic=deterministic,
      )
  
imports: from collections import OrderedDict
  import json
  import logging
  import os
  import random
  import numpy
  import tensorflow
  from tensorforce import util, TensorforceError
  from tensorforce.agents import Recorder
  import tensorforce.agents
  from tensorforce.core import ArrayDict, TensorSpec, TensorforceConfig
label_desc: Use image node_id 12 for calling the Agent obj's underlying member method code with example usage: obj.act(states, internals, parallel, independent, deterministic, evaluation) and returns: super