Help us shape the future of Go! Take the 2026 Go Developer Survey

word2vec

package module
v0.0.0-...-99eb4af Latest Latest
Warning

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

Go to latest
Published: Oct 27, 2013 License: Apache-2.0 Imports: 5 Imported by: 0

README

word2vec

word2vec in go lang

Thanks to these guys - https://code.google.com/p/word2vec/

Main motivations are that I used gensim with the freebase vectors skipgram file and it ended up using 27Gb of ram. I'm not particularly intestested in writting c++ so to golang. Right now the distance part uses ~11Gb of memory for the same file.

Documentation

Index

Constants

View Source
const N int = 40

Variables

This section is empty.

Functions

This section is empty.

Types

type Model

type Model struct {
	M []float32
	// contains filtered or unexported fields
}

func (*Model) Load

func (m *Model) Load(fn string)

func (*Model) MostSimilar

func (m *Model) MostSimilar(seedWords []string) []WordData

type WordData

type WordData struct {
	Distance float64
	Word     string
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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