[−][src]Function arrayfire::constant
pub fn constant<T>(cnst: T, dims: Dim4) -> Array<T> where
T: ConstGenerator<OutType = T>,
Create an Array with constant value
The trait ConstGenerator has been defined internally for the following types:
- i64
- u64
- num::Complex<f32> a.k.a c32
- num::Complex<f64> a.k.a c64
- f32
- f64
- i32
- u32
- u8
- i16
- u16
Parameters
cnst
is the constant value to be filled in the Arraydims
is the size of the constant Array
Return Values
An Array of given dimensions with constant value