Testing the TurtleBot-2 environment

Now, we're all ready to see the training visually. We can start the example by running the following commands:

$ cd gym-gazebo/gym_gazebo/envs/installation/
$ bash turtlebot_setup.bash
$ cd gym-gazebo/examples/turtlebot
$ python circuit_turtlebot_lidar_qlearn.py

You should see a Terminal window as shown in the following screenshot, that starts the training. If you want to see the TurtleBot training itself visually, open gzclient in another Terminal:

$ cd gym-gazebo/gym_gazebo/envs/installation/
$ bash turtlebot_setup.bash
$ export GAZEBO_MASTER_URI=http://localhost:13853
$ gzclient

You should see the TurtleBot trying to learn how to navigate in that environment, as shown in the following screenshot, through a series of episodes and respective rewards:

TurtleBot-2 training in the given environment

After, say, 500 episodes, you should see that the TurtleBot can move almost halfway through the environment without colliding. After, say, 2,000 episodes, you should see that the TurtleBot is able to complete one lap inside the environment without colliding with the environment.

A Terminal with rewards over specific episodes is as follows:

Terminal with rewards over specific episodes

A graph of rewards over specific episodes is as follows:

TurtleBot rewards graph

It is evident that the rewards are gradually increasing over time (episodes). Have a look at the whitepaper for more benchmark results and comparison with the SARSA algorithm.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.18.220.243