Share via


MLImage.CreateFromPixels メソッド

定義

ピクセル データスパンから MLImage オブジェクトを作成します。

public static Microsoft.ML.Data.MLImage CreateFromPixels (int width, int height, Microsoft.ML.Data.MLPixelFormat pixelFormat, ReadOnlySpan<byte> imagePixelData);
static member CreateFromPixels : int * int * Microsoft.ML.Data.MLPixelFormat * ReadOnlySpan<byte> -> Microsoft.ML.Data.MLImage
Public Shared Function CreateFromPixels (width As Integer, height As Integer, pixelFormat As MLPixelFormat, imagePixelData As ReadOnlySpan(Of Byte)) As MLImage

パラメーター

width
Int32

画像の幅 (ピクセル単位)。

height
Int32

画像の高さ (ピクセル単位)。

pixelFormat
MLPixelFormat

イメージを作成するピクセル形式。

imagePixelData
ReadOnlySpan<Byte>

イメージを作成するピクセル データ。

戻り値

MLImage オブジェクト。

適用対象