mirror of
https://github.com/metabarcoding/obitools4.git
synced 2025-06-29 16:20:46 +00:00
A first prototype for the space of sequences
Former-commit-id: 07dc6ef044b5b6a6fb45dc2acb01dffe71a96195
This commit is contained in:
@ -74,8 +74,7 @@ func AssignToClass(data, centers *obiutils.Matrix[float64]) []int {
|
||||
// Returns:
|
||||
// - centers: a pointer to a matrix of float64 values representing the centers of the clusters.
|
||||
func ComputeCenters(data *obiutils.Matrix[float64], k int, classes []int) *obiutils.Matrix[float64] {
|
||||
centers := obiutils.Make2DArray[float64](k, len((*data)[0]))
|
||||
centers.Init(0.0)
|
||||
centers := obiutils.Make2DNumericArray[float64](k, len((*data)[0]), true)
|
||||
ns := make([]int, k)
|
||||
|
||||
var wg sync.WaitGroup
|
||||
|
Reference in New Issue
Block a user