TensorPrimitives.IsInteger<T> 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
計算指定張量中每個值是否為整數。
public:
generic <typename T>
where T : System::Numerics::INumberBase<T> static void IsInteger(ReadOnlySpan<T> x, Span<bool> destination);
public static void IsInteger<T>(ReadOnlySpan<T> x, Span<bool> destination) where T : System.Numerics.INumberBase<T>;
static member IsInteger : ReadOnlySpan<'T (requires 'T :> System.Numerics.INumberBase<'T>)> * Span<bool> -> unit (requires 'T :> System.Numerics.INumberBase<'T>)
Public Shared Sub IsInteger(Of T As INumberBase(Of T)) (x As ReadOnlySpan(Of T), destination As Span(Of Boolean))
類型參數
- T
參數
張量以跨度表示。
例外狀況
x 並 destination 參考重疊的記憶體位置,且不從相同位置開始。
備註
此方法有效計算 。destination[i] = T.IsInteger(x[i])