pub fn constant<B>( shape: impl Into<Shape>, val: f64, dtype: DType, device: &<B as Backend>::Device, ) -> Result<Tensor<B>, Error>where B: Backend,
Initialize a tensor with a constant value.