MCPcopy Create free account
hub / github.com/cogentcore/core / TestSimMat

Function TestSimMat

tensor/stats/simat/simat_test.go:31–43  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

29`
30
31func TestSimMat(t *testing.T) {
32 dt := &table.Table{}
33 err := dt.OpenCSV("../clust/testdata/faces.dat", table.Tab)
34 if err != nil {
35 t.Error(err)
36 }
37 ix := table.NewIndexView(dt)
38 smat := &SimMat{}
39 smat.TableCol(ix, "Input", "Name", false, metric.Euclidean64)
40
41 // fmt.Println(smat.Mat)
42 assert.Equal(t, simres, smat.Mat.String())
43}

Callers

nothing calls this directly

Calls 6

OpenCSVMethod · 0.95
TableColMethod · 0.95
NewIndexViewFunction · 0.92
EqualMethod · 0.80
ErrorMethod · 0.65
StringMethod · 0.65

Tested by

no test coverage detected