2020-03-23 10:40:39 +08:00

6 lines
149 B
Python

from ...core import numeric as np
def in_bounds(x, lb, ub):
"""Check if a point lies within bounds."""
return np.all((x >= lb) & (x <= ub))