ShapeTable implements Serializable { public float getWinRate(long hash) { float result = 0; for (int i = 0; i < 3; i++) { int index = (int) (hash >> (21 * i) & 2097151); result += winRateTables[i][index]; } return result / 3; } ShapeTable();  ShapeTable(String filePath, float scalingFactor);  ShapeTable(float scalingFactor); void getRates(); float getScalingFactor(); double testGetRate(int index); float[][] getWinRateTables(); void update(long hash, boolean win); float getWinRate(long hash); void printIndividualWinRates(long hash);  }
@Test public void testTigersMouth() { table = new ShapeTable(OREGO_ROOT + "patterns/patterns3stones-SHAPE-sf999.data", 0.999f); Board board = new Board(9); CoordinateSystem coords = board.getCoordinateSystem(); board.play("d5"); board.pass(); board.play("f5"); board.pass(); board.play("e6"); long hash = PatternFinder.getHash(board, coords.at("e5"), 3, coords.at("a1")); assertTrue(table.getWinRate(hash) < 0.3); }