fitness

package
v2.1.0 Latest Latest
Warning

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

Go to latest
Published: Apr 18, 2020 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Overview

Package fitness provides common fitness functions.

Index

Constants

This section is empty.

Variables

View Source
var ErrLength = errors.New("length error")

ErrLength is returned when the predicted and target slices are empty or not the same length.

Functions

This section is empty.

Types

type BoolFunc

type BoolFunc func(predicted, target []bool) (float64, error)

BoolFunc ...

func NumHits

func NumHits(scaleFactor float64) (BoolFunc, error)

NumHits returns a fitness function that counts the number of correct values. The maximum fitness possible is N*scaleFactor, where N=len(target).

Jump to

Keyboard shortcuts

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