From a14476a26576f7125343f7b70d5c6716c23d1918 Mon Sep 17 00:00:00 2001 From: PierreCounathe Date: Wed, 30 Aug 2023 10:24:50 +0200 Subject: [PATCH] Correct FrozenLake's observation space --- notebooks/unit2/unit2.ipynb | 2 +- units/en/unit2/hands-on.mdx | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/notebooks/unit2/unit2.ipynb b/notebooks/unit2/unit2.ipynb index c9fa7ca..7a8881b 100644 --- a/notebooks/unit2/unit2.ipynb +++ b/notebooks/unit2/unit2.ipynb @@ -429,7 +429,7 @@ "id": "2MXc15qFE0M9" }, "source": [ - "We see with `Observation Space Shape Discrete(16)` that the observation is an integer representing the **agent’s current position as current_row * nrows + current_col (where both the row and col start at 0)**.\n", + "We see with `Observation Space Shape Discrete(16)` that the observation is an integer representing the **agent’s current position as current_row * ncols + current_col (where both the row and col start at 0)**.\n", "\n", "For example, the goal position in the 4x4 map can be calculated as follows: 3 * 4 + 3 = 15. The number of possible observations is dependent on the size of the map. **For example, the 4x4 map has 16 possible observations.**\n", "\n", diff --git a/units/en/unit2/hands-on.mdx b/units/en/unit2/hands-on.mdx index 6661341..6940aca 100644 --- a/units/en/unit2/hands-on.mdx +++ b/units/en/unit2/hands-on.mdx @@ -247,7 +247,7 @@ print("Observation Space", env.observation_space) print("Sample observation", env.observation_space.sample()) # Get a random observation ``` -We see with `Observation Space Shape Discrete(16)` that the observation is an integer representing the **agent’s current position as current_row * nrows + current_col (where both the row and col start at 0)**. +We see with `Observation Space Shape Discrete(16)` that the observation is an integer representing the **agent’s current position as current_row * ncols + current_col (where both the row and col start at 0)**. For example, the goal position in the 4x4 map can be calculated as follows: 3 * 4 + 3 = 15. The number of possible observations is dependent on the size of the map. **For example, the 4x4 map has 16 possible observations.**