Function hard_sigmoid
pub fn hard_sigmoid<const D: usize, B>(
tensor: Tensor<B, D>,
alpha: f64,
beta: f64,
) -> Tensor<B, D>where
B: Backend,Expand description
Applies the hard sigmoid function element-wise.
hard_sigmoid(x) = max(0, min(1, alpha * x + beta))