예제 #1
0
// invalid method
func TestFourDimensionalPlaneShouldFail7(t *testing.T) {
	var err error

	model := NewLogistic(base.OptimizationMethod("Not A Method!!!"), 1, 0, 800, fourDX, fourDY)

	err = model.Learn()
	assert.NotNil(t, err, "Learning error should not be nil")
}
예제 #2
0
// invalid optimization method
func TestFlatLineShouldFail6(t *testing.T) {
	var err error

	model := NewLeastSquares(base.OptimizationMethod("Not A Method!!!"), 1, 0, 800, flatX, flatY)

	err = model.Learn()
	assert.NotNil(t, err, "Learning error should not be nil")
}
예제 #3
0
// invalid method
func TestFourDimensionalSoftmaxShouldFail7(t *testing.T) {
	var err error

	model := NewSoftmax(base.OptimizationMethod("Not A Method!!!"), 1, 0, 3, 800, fdx, fdy)

	err = model.Learn()
	assert.NotNil(t, err, "Learning error should not be nil")
}