def limit_step(self, step):
if self.qmax is None:<EOL><INDENT>return step<EOL><DEDENT>else:<EOL><INDENT>return np.clip(step, -self.qmax, self.qmax)<EOL><DEDENT>
Clip the a step within the maximum allowed range