CIFAR10Dataset

@Serializable
data class CIFAR10Dataset(val images: List<CIFAR10Image>, executionContext: ExecutionContext = DefaultDataExecutionContext()) : Dataset<CIFAR10Image, Float> (source)

CIFAR-10 dataset implementation using Dataset/DataBatch API.

  • Provides batching as tensors Int8 with shapes: x: batch, 3, 32, 32 (channel-first RGB) y: batch (labels as bytes)

Constructors

Link copied to clipboard
constructor(images: List<CIFAR10Image>, executionContext: ExecutionContext = DefaultDataExecutionContext())

Properties

Link copied to clipboard
Link copied to clipboard
open override val xSize: Int

Functions

Link copied to clipboard
open override fun getX(idx: Int): CIFAR10Image
Link copied to clipboard
open override fun getY(idx: Int): Float
Link copied to clipboard
open override fun shuffle(): Dataset<CIFAR10Image, Float>
Link copied to clipboard
open override fun split(splitRatio: Double): Pair<Dataset<CIFAR10Image, Float>, Dataset<CIFAR10Image, Float>>
Link copied to clipboard
fun subset(fromIndex: Int, toIndex: Int): CIFAR10Dataset

Returns a subset of the dataset.