add multiprocessing variant of ReinforcementLearningPPO

This commit is contained in:
robcaulk
2022-08-15 13:46:12 +02:00
parent cf0731095f
commit acf3484e88
2 changed files with 118 additions and 2 deletions

View File

@@ -35,10 +35,12 @@ class Base3ActionRLEnv(gym.Env):
metadata = {'render.modes': ['human']}
def __init__(self, df, prices, reward_kwargs, window_size=10, starting_point=True, ):
def __init__(self, df, prices, reward_kwargs, window_size=10, starting_point=True,
id: str = 'baseenv-1', seed: int = 1):
assert df.ndim == 2
self.seed()
self.id = id
self.seed(seed)
self.df = df
self.signal_features = self.df
self.prices = prices