why is my reward function outputting such a small number [closed]
I have this loop
while True:
current_time = time.time()
elapsed_time = current_time - start_time
z = r.give_force()
print("z is", z)
score += r.what_is_reward()
print("the score during game is", score)
time.sleep(1.0)
print(elapsed_time)
if elapsed_time > seconds:
break
And here is my reward function
def what_is_reward(self):
start_time = time.time()
if self.target1 - 3 < self.joint1 < self.target1 + 3:
self.reward = time.time() - start_time
It keeps outputting an extremely small number like to the 0.1e-5 even though the joint position in radians should be within the target zone. target zone is target-3 radians to target zone+3 radians