classifier

package
v0.0.0-...-7ce53e0 Latest Latest
Warning

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

Go to latest
Published: May 31, 2022 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Train

func Train(weights string, dataset dataset.Dataset) error

Train will train a mnist network for given dataset object.

Types

type Inference

type Inference struct {
	// contains filtered or unexported fields
}

Inference is the internal representation of the inference object.

func NewInference

func NewInference(weights string) (*Inference, error)

NewInference will return a new inference object with the given trained weights file to handle predictions.

func (*Inference) Predict

func (in *Inference) Predict(image []byte) (int, float64, error)

Predict will take a 28x28 image and return the integer it thinks best matches the image. If no match is found, it will return -1.

Jump to

Keyboard shortcuts

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