Documentation
¶
Overview ¶
Package data contains structs and methods common for listening test datasets.
Index ¶
- type AccuracyScore
- type AccuracyScores
- type CorrelationScore
- type CorrelationTable
- type Distortion
- type Measurement
- type Reference
- type Row
- type ScoreType
- type ScoreTypes
- type Study
- func (s *Study) Accuracy() (AccuracyScores, error)
- func (s *Study) Calculate(measurements map[ScoreType]Measurement, pool *worker.Pool[any]) error
- func (s *Study) Close() error
- func (s *Study) Correlate() (CorrelationTable, error)
- func (s *Study) Put(refs []*Reference) error
- func (s *Study) ViewEachReference(f func(*Reference) error) error
- type Table
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AccuracyScore ¶ added in v0.1.11
AccuracyScore contains the accuracy for a metric when used to predict audible differences, and the threshold when that accuracy was achieved.
type AccuracyScores ¶ added in v0.1.11
type AccuracyScores []AccuracyScore
AccuracyScores contains the accuracy scores for multiple score types.
func (AccuracyScores) String ¶ added in v0.1.11
func (a AccuracyScores) String() string
type CorrelationScore ¶
CorrelationScore contains the scorrelation score between two score types.
type CorrelationTable ¶
type CorrelationTable [][]CorrelationScore
CorrelationTable contains the pairwise correlations between a set of score types.
func (CorrelationTable) String ¶
func (c CorrelationTable) String() string
type Distortion ¶
Distortion contains data for a distortion of a reference.
type Measurement ¶
Measurement returns distance between sounds.
type Reference ¶
type Reference struct { Name string Path string Distortions []*Distortion }
Reference contains data for a reference.
type ScoreType ¶
type ScoreType string
ScoreType represents a type of score, such as MOS or Zimtohrli.
type ScoreTypes ¶
type ScoreTypes []ScoreType
ScoreTypes is a slice of ScoreType.
func (ScoreTypes) Len ¶
func (s ScoreTypes) Len() int
func (ScoreTypes) Less ¶
func (s ScoreTypes) Less(i, j int) bool
func (ScoreTypes) Swap ¶
func (s ScoreTypes) Swap(i, j int)
type Study ¶
type Study struct {
// contains filtered or unexported fields
}
Study contains data from a study.
func OpenStudy ¶
OpenStudy opens a study from a database directory. If the study doesn't exist, it will be created.
func (*Study) Accuracy ¶ added in v0.1.11
func (s *Study) Accuracy() (AccuracyScores, error)
Accuracy returns the accuracy of each score type when used to predict audible differences.
func (*Study) Calculate ¶
Calculate computes measurements and populates the scores of the distortions.
func (*Study) Correlate ¶
func (s *Study) Correlate() (CorrelationTable, error)
Correlate returns a table of all scores in the study Spearman correlated to each other.