edelwace-0.1.0.0: HaskTorch Reinforcement Learning Agents for GACE
Safe HaskellNone
LanguageHaskell2010

RPB.MEM

Description

PPO Style Replay Memory and Memory Loaders

Synopsis

Documentation

data Buffer a Source #

Replay Memory

Constructors

Buffer 

Fields

Instances

Instances details
Functor Buffer Source # 
Instance details

Defined in RPB.MEM

Methods

fmap :: (a -> b) -> Buffer a -> Buffer b #

(<$) :: a -> Buffer b -> Buffer a #

Eq a => Eq (Buffer a) Source # 
Instance details

Defined in RPB.MEM

Methods

(==) :: Buffer a -> Buffer a -> Bool #

(/=) :: Buffer a -> Buffer a -> Bool #

Show a => Show (Buffer a) Source # 
Instance details

Defined in RPB.MEM

Methods

showsPrec :: Int -> Buffer a -> ShowS #

show :: Buffer a -> String #

showList :: [Buffer a] -> ShowS #

mkBuffer :: Buffer Tensor Source #

Create a new, empty Buffer on the GPU

empty :: Buffer Tensor Source #

Create Empty Buffer

size :: Buffer Tensor -> Int Source #

How many Trajectories are currently stored in memory

push :: Buffer Tensor -> Tensor -> Tensor -> Tensor -> Tensor -> Tensor -> Tensor -> Buffer Tensor Source #

Push new memories into Buffer

push' :: Buffer Tensor -> Buffer Tensor -> Buffer Tensor Source #

Pushing one buffer into another one

gae :: Tensor -> Tensor -> Tensor -> Tensor -> Tensor -> Tensor -> Tensor Source #

Generalized Advantage Estimate

data Loader a Source #

Memory Data Loader

Constructors

Loader 

Fields

Instances

Instances details
Functor Loader Source # 
Instance details

Defined in RPB.MEM

Methods

fmap :: (a -> b) -> Loader a -> Loader b #

(<$) :: a -> Loader b -> Loader a #

Eq a => Eq (Loader a) Source # 
Instance details

Defined in RPB.MEM

Methods

(==) :: Loader a -> Loader a -> Bool #

(/=) :: Loader a -> Loader a -> Bool #

Show a => Show (Loader a) Source # 
Instance details

Defined in RPB.MEM

Methods

showsPrec :: Int -> Loader a -> ShowS #

show :: Loader a -> String #

showList :: [Loader a] -> ShowS #

mkLoader :: Buffer Tensor -> Int -> Tensor -> Tensor -> Loader [Tensor] Source #

Turn Replay memory into chunked data loader

size' :: Loader [Tensor] -> Int Source #

How many Trajectories are currently stored in memory