keras/src/constraints/constraints.py/NonNeg/__call__
class NonNeg:    def __call__(self, w):
        w = backend.convert_to_tensor(w)
        return w * ops.cast(ops.greater_equal(w, 0.0), dtype=w.dtype)