pub struct Reward(pub f64);
Expand description
A reward-signal environment feedback
Tuple Fields
0: f64
Implementations
Trait Implementations
sourceimpl AddAssign<Reward> for Reward
impl AddAssign<Reward> for Reward
sourcefn add_assign(&mut self, rhs: Reward)
fn add_assign(&mut self, rhs: Reward)
Performs the +=
operation. Read more
sourceimpl<'de> Deserialize<'de> for Reward
impl<'de> Deserialize<'de> for Reward
sourcefn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
sourceimpl Feedback for Reward
impl Feedback for Reward
type EpisodeFeedback = Reward
type EpisodeFeedback = Reward
Overall feedback for an episode.
type StepSummary = RewardSummary
type StepSummary = RewardSummary
Per-step feedback summary.
type EpisodeSummary = RewardSummary
type EpisodeSummary = RewardSummary
Per-episode feedback summary.
fn add_to_episode_feedback(&self, episode_feedback: &mut Self::EpisodeFeedback)
sourceimpl MetaFeedback for Reward
impl MetaFeedback for Reward
Reward feedback is always replicated in both the inner and outer environments.
This is the structure of RL-Squared meta reinforcement learning.
type Inner = Reward
type Outer = Reward
sourcefn neutral_outer() -> Self
fn neutral_outer() -> Self
Neutral outer feedback that does not indicate good or bad behaviour.
sourcefn into_inner_outer(self) -> (Self, Self)
fn into_inner_outer(self) -> (Self, Self)
Split the feedback into inner and outer environment feedback
sourceimpl PartialOrd<Reward> for Reward
impl PartialOrd<Reward> for Reward
sourcefn partial_cmp(&self, other: &Reward) -> Option<Ordering>
fn partial_cmp(&self, other: &Reward) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
1.0.0 · sourcefn lt(&self, other: &Rhs) -> bool
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
1.0.0 · sourcefn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
sourceimpl SubAssign<Reward> for Reward
impl SubAssign<Reward> for Reward
sourcefn sub_assign(&mut self, rhs: Reward)
fn sub_assign(&mut self, rhs: Reward)
Performs the -=
operation. Read more
sourceimpl ToPrimitive for Reward
impl ToPrimitive for Reward
sourcefn to_i64(&self) -> Option<i64>
fn to_i64(&self) -> Option<i64>
Converts the value of self
to an i64
. If the value cannot be
represented by an i64
, then None
is returned. Read more
sourcefn to_u64(&self) -> Option<u64>
fn to_u64(&self) -> Option<u64>
Converts the value of self
to a u64
. If the value cannot be
represented by a u64
, then None
is returned. Read more
sourcefn to_f32(&self) -> Option<f32>
fn to_f32(&self) -> Option<f32>
Converts the value of self
to an f32
. Overflows may map to positive
or negative inifinity, otherwise None
is returned if the value cannot
be represented by an f32
. Read more
sourcefn to_f64(&self) -> Option<f64>
fn to_f64(&self) -> Option<f64>
Converts the value of self
to an f64
. Overflows may map to positive
or negative inifinity, otherwise None
is returned if the value cannot
be represented by an f64
. Read more
sourcefn to_isize(&self) -> Option<isize>
fn to_isize(&self) -> Option<isize>
Converts the value of self
to an isize
. If the value cannot be
represented by an isize
, then None
is returned. Read more
sourcefn to_i8(&self) -> Option<i8>
fn to_i8(&self) -> Option<i8>
Converts the value of self
to an i8
. If the value cannot be
represented by an i8
, then None
is returned. Read more
sourcefn to_i16(&self) -> Option<i16>
fn to_i16(&self) -> Option<i16>
Converts the value of self
to an i16
. If the value cannot be
represented by an i16
, then None
is returned. Read more
sourcefn to_i32(&self) -> Option<i32>
fn to_i32(&self) -> Option<i32>
Converts the value of self
to an i32
. If the value cannot be
represented by an i32
, then None
is returned. Read more
sourcefn to_i128(&self) -> Option<i128>
fn to_i128(&self) -> Option<i128>
Converts the value of self
to an i128
. If the value cannot be
represented by an i128
(i64
under the default implementation), then
None
is returned. Read more
sourcefn to_usize(&self) -> Option<usize>
fn to_usize(&self) -> Option<usize>
Converts the value of self
to a usize
. If the value cannot be
represented by a usize
, then None
is returned. Read more
sourcefn to_u8(&self) -> Option<u8>
fn to_u8(&self) -> Option<u8>
Converts the value of self
to a u8
. If the value cannot be
represented by a u8
, then None
is returned. Read more
sourcefn to_u16(&self) -> Option<u16>
fn to_u16(&self) -> Option<u16>
Converts the value of self
to a u16
. If the value cannot be
represented by a u16
, then None
is returned. Read more
impl Copy for Reward
impl StructuralPartialEq for Reward
Auto Trait Implementations
impl RefUnwindSafe for Reward
impl Send for Reward
impl Sync for Reward
impl Unpin for Reward
impl UnwindSafe for Reward
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more