MCPcopy Create free account
hub / github.com/WinVector/Logistic / testNormV2

Method testNormV2

test/com/winvector/logistic/TestOpt.java:76–85  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

74 }
75
76 public void testNormV2() {
77 // norm penalty should put max at 0 (and max value should be 0)
78 final int dim = 3;
79 final VectorFn f = new NormPenalty(dim,1.0e-2);
80 final double[] x = new double[dim];
81 x[1] = 0.1;
82 x[2] = -0.1;
83 final VEval f2 = f.eval(x,false,false);
84 assertTrue(f2.fx<0.0);
85 }
86
87 public void testNormGH() {
88 // norm penalty should put max at 0 (and max value should be 0)

Callers

nothing calls this directly

Calls 1

evalMethod · 0.95

Tested by

no test coverage detected