ai

package
v0.0.0-...-0117f21 Latest Latest
Warning

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

Go to latest
Published: Jan 25, 2016 License: Apache-2.0 Imports: 1 Imported by: 4

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CosineSimilarity

func CosineSimilarity(vector_1 []int, vector_2 []int) float64

func NormalizeTwoVectors

func NormalizeTwoVectors(vector_1 []Vector_element, vector_2 []Vector_element) ([]int, []int)

We want to return two int-vectors which we can compare Therefor we need to construct the vectors out of the given ones

Types

type Vector_element

type Vector_element struct {
	Count int
	Ngram string
}

Jump to

Keyboard shortcuts

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