diff --git a/README.rst b/README.rst index 12a1a2b8130444ac4dc0ccee5338045879b95d20..e0376fe7b201ff18ce88c3d69187c011df86debf 100644 --- a/README.rst +++ b/README.rst @@ -85,7 +85,7 @@ Basic usage of the RailEnv environment used by the Flatland Challenge min_dist=8, max_dist=99999, seed=0), - schedule_generator=complex_schedule_generator() + schedule_generator=complex_schedule_generator(), number_of_agents=NUMBER_OF_AGENTS) env_renderer = RenderTool(env) diff --git a/docs/intro_observationbuilder.rst b/docs/intro_observationbuilder.rst index 3cde8167838a6040db8513d5944421ce5e02460d..fd03e26424378448839c57faa14fe730e68698ff 100644 --- a/docs/intro_observationbuilder.rst +++ b/docs/intro_observationbuilder.rst @@ -350,8 +350,9 @@ All the agent in the initiated environment can be found in the :code:`env.agents Beyond the basic agent information we can also access more details about the agents type by looking at speed data: - Agent max speed :code:`agent.speed_data["speed"]` wich defines the traveling speed when the agent is moving. -- Agent position fraction :code:``agent.speed_data["position_fraction"]` which is a number between 0 and 1 and inidicates when the move to the next cell will occur. Each speed of an agent is 1 or a smaller fraction. At each :code:`env.step()` the agent moves at its fractional speed forwards any only changes to the next cell when the cumulated fractions are :code:`agent.speed_data["position_fraction"] >= 1.` - +- Agent position fraction :code:``agent.speed_data["position_fraction"]` which is a number between 0 and 1 and indicates when the move to the next cell will occur. Each speed of an agent is 1 or a smaller fraction. At each :code:`env.step()` the agent moves at its fractional speed forwards and only changes to the next cell when the cumulated fractions are :code:`agent.speed_data["position_fraction"] >= 1.` +- Agent can move at different speed which can be set up by modifying the agent.speed_data within the schedule_generator. For example refer this Link_ +.. _Link:https://gitlab.aicrowd.com/flatland/flatland/blob/master/flatland/envs/schedule_generators.py#L59 **Agent malfunction information** Similar to the speed data you can also access individual data about the malfunctions of an agent. All data is available through :code:`agent.malfunction_data` with: