import pandas as pd
from fastrl.pipes.core import *
from fastrl.pipes.map.transforms import *
from fastrl.envs.gym import GymTypeTransform,GymStepper,GymTransformBlock
Visualizers
Iterable pipes for displaying environments as they run using
typing.NamedTuples
with image
fields
SimpleJupyterVideoPlayer
SimpleJupyterVideoPlayer (*args, **kwds)
Displays video from a source_datapipe
that produces typing.NamedTuples
that contain an image
field. This only can handle 1 env input.
ImageCollector
ImageCollector (*args, **kwds)
LogCollector
specifically manages finding and attaching itself to LoggerBase
s found earlier in the pipeline.
= SimpleJupyterVideoPlayer()
video_logger = GymTransformBlock(None,n=100,seed=0,include_images=True)(['CartPole-v1'])
pipe = LoggerBasePassThrough(pipe,[video_logger])
pipe = ImageCollector(pipe)
pipe
= video_logger.connect_source_datapipe(pipe)
pipe
; L(pipe)