Skip to content

Instantly share code, notes, and snippets.

@MTDzi
Created November 25, 2018 15:08
Show Gist options
  • Select an option

  • Save MTDzi/62aaca107e116187cfbe7be654720515 to your computer and use it in GitHub Desktop.

Select an option

Save MTDzi/62aaca107e116187cfbe7be654720515 to your computer and use it in GitHub Desktop.
Throttle clipping function
def clip_throttle(throttle, curr_speed, target_speed):
return np.clip(
throttle - 0.1 * (curr_speed-target_speed),
0.25,
1.0
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment