Ejemplo n.º 1
0
func main() {
	classifier := c.NewClassifier()

	worker(classifier, "uknames.csv")
	worker(classifier, "usnames.csv")
	classifier.WriteToFile("../classifier.serialized")
}
Ejemplo n.º 2
0
func main() {
	runtime.GOMAXPROCS(1)

	classifier := c.NewClassifier()

	done := make(chan bool, end-start)
	for i := start; i <= end; i++ {
		go worker(classifier, i, done)
	}
	for j := start; j <= end; j++ {
		<-done
	}
	classifier.WriteToFile("./classifier.serialized")
}