Skip to content

Latest commit

 

History

History
22 lines (17 loc) · 1.02 KB

README.md

File metadata and controls

22 lines (17 loc) · 1.02 KB

Small Implementation of A very Famous Re-Inforcement Learning Algorithm i.e q-learning

I choose EV-3 Robot Kit to implemet it on.

What I wanted to accomplish:

when the bot is put in the arena with black lines in it. The Bot should automatically start following the black line.

Hardware Specification:
1. Color Sensor
2. Motors So that bot can move
How This works:
1. the color sensor detects where it is standing right now and classify the place as either BLACK or WHITE
2. Get appropriate action from the Q-Matrix (First time It would be just random)
2.1 Possible actions in my case are move_forward, move_left, move_right
3. Execute that action and now the bot is slightly at different place
4. Get the value of new state as in first step
5. Then it calculates the reward using Reward Function for that state (plus points for being on black spot otherwise panelity Minus Points)
5.1. It updates the Q-Matix with the values.
6. Loops back to step 1

@shahraiz ali