I have written a deep q-learning algorithm with this website (without terminal state)for a car racing game where you get reseted when get of the track. I got input of speed, some distance sensors and the progress of the track in percent. Output is the acceleration of the car and the steering angle.

My question is how should is set the reward and the function to get target Q-Value.

The neural net accepts values in range $(0,1]$ as input and target, so my idea was to set the reward to progressInPercent/2 + 0.5 (or + 0.01) when the car was reset.

My problem is since the neural net(Q-Function) can only take $(0,1]$ as target, how do I make sure these values don't grow over 1? Using tt = rr + γmaxa’Q(ss’, aa’) as training target doesnt work.

Or should I take something else as reward?


What about clipping the reward, after scaling it? By clipping around (0,1] all outliers are projected back to the extreme values.

| cite | improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.