Skip to content
Creating an optimized Q-Learning driving agent that will navigate a Smartcab through its environment towards a goal. Completed as a part of Udacity's MLND.
Branch: master
Clone or download
Latest commit b4e6151 Mar 4, 2017
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.ipynb_checkpoints Initial commit Mar 4, 2017
images init commit Feb 9, 2017
logs init commit Feb 9, 2017
smartcab Initial commit Mar 4, 2017
README.md readme tweak Mar 4, 2017
project_description.md init commit Feb 9, 2017
smartcab.ipynb Initial commit Mar 4, 2017
visuals.py init commit Feb 9, 2017
visuals.pyc init commit Feb 9, 2017

README.md

Reinforcement Learning

Project: Train a Smartcab How to Drive

This project was completed as a part of Udacity's Machine Learning Nanodegree.

Introduction

In this project, we work towards constructing an optimized Q-Learning driving agent that will navigate a Smartcab through its environment towards a goal. Since the Smartcab is expected to drive passengers from one location to another, the driving agent will be evaluated on two very important metrics: Safety and Reliability. A driving agent that gets the Smartcab to its destination while running red lights or narrowly avoiding accidents would be considered unsafe. Similarly, a driving agent that frequently fails to reach the destination in time would be considered unreliable. Maximizing the driving agent's safety and reliability would ensure that Smartcabs have a permanent place in the transportation industry.

Note that, template code for the Smartcab's environment and other agents (cars) in the environment was already provided. Our job is to implement a learning algorithm so that the Smartcab behaves properly, following the rules and regulations, while moving towards its destination.

Analysis Notebook

Please visit the notebook linked above to check out a step-by-step analysis of the project at various stages, and to understand the project better.

Install

This project requires Python 2.7 with the pygame library installed.

Run

In a terminal or command window, navigate to the top-level project directory smartcab/ (that contains this README) and run one of the following commands:

python smartcab/agent.py
python -m smartcab.agent

This will run the agent.py file and execute your agent code.

You might want to change the speed of the simulation in agent.py (simulation update delay) to make it go faster or slower, as per your need.

You can’t perform that action at this time.