Skip to content

Commit

Permalink
Update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
zuoxingdong committed Sep 4, 2018
1 parent 10c9e61 commit cc8a34a
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions lagom/runner/transition.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,12 @@ def add_info(self, name, value):
.. note::
For certain information, the specific key is required. It shows as following
* ``'V_s'``: state value for current state (i.e. :attr:`s`)
* ``'V_s_next'``: state value for next state (i.e. :attr:`s_next`). Note that
it should only be added for the last transition in either :class:`Trajectory`
or :class:`Segment`
or :class:`Segment` to save memory.
Args:
name (str): name of the information
Expand All @@ -44,13 +45,12 @@ def add_info(self, name, value):

@property
def V_s(self):
r"""Return the state value for the given state, self.s"""
r"""Return the state value for the current state, i.e. :attr:`s`"""
return self.info['V_s']

@property
def V_s_next(self):
"""
Return the state value for the next state, self.s_next.
r"""Return the state value for the next state, i.e. :attr:`s_next`
Note that we do not set zero value for terminal state, because this function
often returns the Tensor dtype, used for backprop.
Expand Down

0 comments on commit cc8a34a

Please sign in to comment.