mnist

package
v0.1.8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 29, 2025 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Overview

Package MNIST is the 60000 + 10000 handwritten digits dataset

Index

Constants

View Source
const ImgSize = 28

original

View Source
const SmallImgSize = 13

downscaled

Variables

This section is empty.

Functions

func New added in v0.1.0

func New() (TrainSet []Input, InferSet []Input, SmallTrainSet []SmallInput, SmallInferSet []SmallInput, err error)

Types

type Input

type Input struct {
	Image [ImgSize * ImgSize]byte
	Label byte
}

Input is the type of input image

func (*Input) Feature

func (i *Input) Feature(n int) uint32

Feature extracts the n-th feature from input

func (*Input) Output added in v0.1.0

func (i *Input) Output() uint16

func (*Input) Parity added in v0.0.11

func (i *Input) Parity() uint16

type SmallInput

type SmallInput struct {
	Image [SmallImgSize * SmallImgSize]byte
	Label byte
}

SmallInput is the type of small input image

func (*SmallInput) Feature

func (i *SmallInput) Feature(n int) uint32

Feature extracts the n-th feature from small input

func (*SmallInput) Output added in v0.1.0

func (i *SmallInput) Output() uint16

func (*SmallInput) Parity added in v0.0.11

func (i *SmallInput) Parity() uint16

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL