Show / Hide Table of Contents

    Property NElems

    property NElems: int64

    Total number of elements within this tensor.

    Declaration
    property NElems: int64 with get
    Property Value
    Type Description
    int64

    Number of elements.

    Remarks

    Counts the total number of elements of this tensor.

    A zero-dimensional tensor contains one element, i.e. it is a scalar.

    Examples
     let a = HostTensor.ofList [[1.0; 2.0; 5.0]
                                [3.0; 4.0; 6.0]]
     let c = a.NElems // 6L
    See Also
    member Shape: unit -> int64 list
    Back to top Generated by DocFX