docstr: Helper method to apply a clamp to a velocity vector
docstr_tok: ["Helper","method","to","apply","a","clamp","to","a","velocity","vector"]
code: def __apply_clamp(self, velocity, clamp):
      """Helper method to apply a clamp to a velocity vector"""
      clamped_vel = velocity
      min_velocity, max_velocity = clamp
      lower_than_clamp = clamped_vel <= min_velocity
      greater_than_clamp = clamped_vel >= max_velocity
      clamped_vel = np.where(
          lower_than_clamp, min_velocity, clamped_vel
      )
      clamped_vel = np.where(
          greater_than_clamp, max_velocity, clamped_vel
      )
      return clamped_vel
  
imports: import inspect
  import logging
  import numpy
  import math
  from copy import copy
  from ..utils.reporter import Reporter
label_desc: Use image node_id 3 for calling the VelocityHandler obj's underlying member method code with example usage: obj.__apply_clamp(velocity, clamp) and returns: clamped_vel