License | BSD-3-Clause |
---|---|
Stability | experimental |
Portability | non-portable |
Safe Haskell | None |
Language | Haskell2010 |
Numeric.Datasets.CIFAR10
Description
The binary version contains the files data_batch_1.bin, data_batch_2.bin, ..., data_batch_5.bin, as well as test_batch.bin. Each of these files is formatted as follows:
x labelx pixel ... x labelx pixel
In other words, the first byte is the label of the first image, which is a number in the range 0-9. The next 3072 bytes are the values of the pixels of the image. The first 1024 bytes are the red channel values, the next 1024 the green, and the final 1024 the blue. The values are stored in row-major order, so the first 32 bytes are the red channel values of the first row of the image.
Synopsis
- data Label
- newtype CIFARImage = CIFARImage {}
- height :: Int
- width :: Int
- image :: CIFARImage -> Image PixelRGB8
- label :: CIFARImage -> Label
- cifarURL :: Url Https
- cifar10 :: Dataset CIFARImage
- parseCifar :: Parser CIFARImage
Documentation
labels of CIFAR-10 dataset. Enum corresponds to binary-based uint8 label.
Instances
newtype CIFARImage Source #
Data representation of a CIFAR image is a 32x32 RGB image
Constructors
CIFARImage | |
Instances
Eq CIFARImage Source # | |
Defined in Numeric.Datasets.CIFAR10 | |
Show CIFARImage Source # | |
Defined in Numeric.Datasets.CIFAR10 Methods showsPrec :: Int -> CIFARImage -> ShowS # show :: CIFARImage -> String # showList :: [CIFARImage] -> ShowS # | |
NFData CIFARImage Source # | |
Defined in Numeric.Datasets.CIFAR10 Methods rnf :: CIFARImage -> () # |
height of CIFARImage
width of CIFARImage
image :: CIFARImage -> Image PixelRGB8 Source #
extract the JuicyPixel representation from a CIFAR datapoint
label :: CIFARImage -> Label Source #
extract the label from a CIFAR datapoint
cifar10 :: Dataset CIFARImage Source #
Define a dataset from a source for a CSV file
parseCifar :: Parser CIFARImage Source #
parser for a cifar binary