float[] src = new float[] { 0.5f, 1, 1, 2, 1.5f, 3, 2, 4, 2.5f, 5, 3, 6, 3.5f, 7, 4f, 8, 4.5f, 9, 5f, 10, 5.5f, 11, 6f, 12, 6.5f, 13, 7f, 14, 8f, 16, 7.5f, 15, 8.5f, 17, 9f, 18, 9.5f, 19, 10f, 20, 10.5f, 21, 11f, 22, 11.5f, 23, 12f, 24, 12.5f, 25, 13f, 26, 13.5f, 27, 14f, 28, 14.5f, 29, 15f, 30, 16f, 32, 15.5f, 31 };
System.arraycopy(src, 0, vp.get(c.getInputLayer()).getElements(), vp.get(c.getInputLayer()).getStartIndex(), src.length);
calc.calculate(connections, vp, c.getOutputLayer());
Tensor o = vp.get(c.getOutputLayer());
assertEquals(1.75, o.get(0, 0, 0, 0), 0);
assertEquals(2.75, o.get(0, 0, 1, 0), 0);
assertEquals(5.75, o.get(0, 1, 0, 0), 0);
assertEquals(6.75, o.get(0, 1, 1, 0), 0);
assertEquals(9.75, o.get(1, 0, 0, 0), 0);
assertEquals(10.75, o.get(1, 0, 1, 0), 0);
assertEquals(13.75, o.get(1, 1, 0, 0), 0);
assertEquals(14.75, o.get(1, 1, 1, 0), 0);
assertEquals(3.5, o.get(0, 0, 0, 1), 0);
assertEquals(5.5, o.get(0, 0, 1, 1), 0);
assertEquals(11.5, o.get(0, 1, 0, 1), 0);
assertEquals(13.5, o.get(0, 1, 1, 1), 0);
assertEquals(19.5, o.get(1, 0, 0, 1), 0);
assertEquals(21.5, o.get(1, 0, 1, 1), 0);
assertEquals(27.5, o.get(1, 1, 0, 1), 0);
assertEquals(29.5, o.get(1, 1, 1, 1), 0);
}