speak

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Jul 22, 2025 License: Apache-2.0 Imports: 5 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Sample

type Sample struct {
	Candidate uint32
	Source    []rune
	Target    []uint32
	Dim       int
	Incorrect *map[uint32]struct{}
}

func NewDataset

func NewDataset(file string, dimension int) (ret []Sample)

func (*Sample) Alls

func (s *Sample) Alls() (ret []uint32)

func (*Sample) Feature

func (s *Sample) Feature(n int) (ret uint32)

Feature: calculates query, keyvalue input for attention matrix

func (*Sample) Len

func (s *Sample) Len() int

func (*Sample) Output

func (s *Sample) Output() (ret uint16)

func (*Sample) Parity

func (s *Sample) Parity() (ret uint16)

func (*Sample) SetOutput

func (s *Sample) SetOutput(n uint32)

type Sample2

type Sample2 struct {
	Sample
}

func NewDataset2

func NewDataset2(file string, dimension int) (ret []Sample2)

func (*Sample2) Alls

func (s *Sample2) Alls() (ret []uint32)

func (*Sample2) Feature

func (s *Sample2) Feature(n int) (ret uint32)

func (*Sample2) Len

func (s *Sample2) Len() int

func (*Sample2) Output

func (s *Sample2) Output() uint16

func (*Sample2) Parity

func (s *Sample2) Parity() uint16

func (*Sample2) SetOutput

func (s *Sample2) SetOutput(n uint32)

Jump to

Keyboard shortcuts

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