ImageShape

data class ImageShape(width: Long?, height: Long?, channels: Long)

Helper class to keep widely used shape of image object presented as a 4D tensor (batchSize = 1, width, height, channels).

Constructors

ImageShape
Link copied to clipboard
fun ImageShape(width: Long? = null, height: Long? = null, channels: Long = 3)

Properties

channels
Link copied to clipboard
val channels: Long = 3
height
Link copied to clipboard
val height: Long? = null
numberOfElements
Link copied to clipboard
val numberOfElements: Long

Returns number of elements in tensor with the given shape.

width
Link copied to clipboard
val width: Long? = null