b2aad723220e31bc8e950c112b557732b608b97a,PyPi/environments/car_on_hill.py,CarOnHill,__init__,#CarOnHill#,14

Before Change


        self._dt = .1

        // MDP initialization
        self._seed()
        self.reset()

    def _seed(self, seed=None):
        self.np_random, seed = seeding.np_random(seed)
        return [seed]

After Change


    The Car On Hill environment as presented in:
    "Tree-Based Batch Mode Reinforcement Learning, D. Ernst et. al."
    
    def __init__(self):
        self.__name__ = "CarOnHill"

        // MDP spaces
        self.max_pos = 1.
        self.max_velocity = 3.
        high = np.array([self.max_pos, self.max_velocity])
        self.observation_space = spaces.Box(low=-high, high=high)
        self.action_space = spaces.Discrete(values=(-4., 4.))

        // MDP parameters
        self.horizon = 100
        self.gamma = 0.95

        // MDP properties
        self._g = 9.81
        self._m = 1
        self._dt = .1

        super(CarOnHill, self).__init__()

    def reset(self, state=None):
        if state is None:
            self._state = np.array([-0.5, 0])
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 3

Instances


Project Name: AIRLab-POLIMI/mushroom
Commit Name: b2aad723220e31bc8e950c112b557732b608b97a
Time: 2017-06-04
Author: carlo.deramo@gmail.com
File Name: PyPi/environments/car_on_hill.py
Class Name: CarOnHill
Method Name: __init__


Project Name: AIRLab-POLIMI/mushroom
Commit Name: b2aad723220e31bc8e950c112b557732b608b97a
Time: 2017-06-04
Author: carlo.deramo@gmail.com
File Name: PyPi/environments/grid_world.py
Class Name: GridWorldVanHasselt
Method Name: __init__


Project Name: AIRLab-POLIMI/mushroom
Commit Name: b2aad723220e31bc8e950c112b557732b608b97a
Time: 2017-06-04
Author: carlo.deramo@gmail.com
File Name: PyPi/environments/grid_world.py
Class Name: GridWorld
Method Name: __init__