ConvertToFloatArray

class ConvertToFloatArray(layout: TensorLayout) : Operation<Bitmap, Pair<FloatArray, TensorShape>>

Converts Bitmap to float array representation. Only Bitmap.Config.ARGB_8888 is supported.

Parameters

layout

TensorLayout of the resulting array.

Constructors

ConvertToFloatArray
Link copied to clipboard
fun ConvertToFloatArray(layout: TensorLayout = NCHW)

Functions

apply
Link copied to clipboard
open override fun apply(input: Bitmap): Pair<FloatArray, TensorShape>
getOutputShape
Link copied to clipboard
open override fun getOutputShape(inputShape: TensorShape): TensorShape

Properties

layout
Link copied to clipboard
var layout: TensorLayout