dfuncs

package
v0.0.0-...-98db5b7 Latest Latest
Warning

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

Go to latest
Published: May 7, 2020 License: CC-BY-4.0 Imports: 9 Imported by: 2

Documentation

Index

Constants

View Source
const (
	Width  = 28
	Height = 28
)

Variables

This section is empty.

Functions

func FindAverage

func FindAverage(input []LabeledData) float32

Types

type LabeledData

type LabeledData struct {
	Data   []float32
	Number int
	Label  []float32
}

func LoadMNIST

func LoadMNIST(filedirectory string, filenameLabel string, filenameData string) ([]LabeledData, error)

func LoadMNIST11gan

func LoadMNIST11gan(filedirectory string, filenameLabel string, filenameData string) ([]LabeledData, error)

LoadMNIST11gan will add an extra zero at the end so that it has a fake class

func MakeEncodeeSoftmaxPerPixelCopy

func MakeEncodeeSoftmaxPerPixelCopy(data []LabeledData) (copydata []LabeledData)

MakeEncodeeSoftmaxPerPixelCopy this is for NCHW

func NormalizeData

func NormalizeData(data []LabeledData, average float32) []LabeledData

func (LabeledData) MakeJPG

func (data LabeledData) MakeJPG(folder, name string, index int) error

func (LabeledData) MakeJPGsimple

func (data LabeledData) MakeJPGsimple(index int) error

Jump to

Keyboard shortcuts

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