introduce bitloops
This commit is contained in:
@@ -47,7 +47,7 @@ public class MainTest {
|
||||
this.tries = 1;
|
||||
this.verbose = false;
|
||||
}};
|
||||
static final Dict dict = loadDict(opts.wordsPath);
|
||||
static final Dict dict = DictData.DICT;//loadDict(opts.wordsPath);
|
||||
public static Dict loadDict(String wordsPath) {
|
||||
var map = new LongArrayList(100_000);
|
||||
try (var lines = Files.lines(Path.of(wordsPath), StandardCharsets.UTF_8)) {
|
||||
@@ -192,7 +192,7 @@ public class MainTest {
|
||||
"1 \n" +
|
||||
"1 \n" +
|
||||
"3 3 \n" +
|
||||
"3 0 3 \n" +
|
||||
"3 0 3 \n" +
|
||||
"3 \n" +
|
||||
"3 \n" +
|
||||
"222 3");
|
||||
@@ -200,8 +200,8 @@ public class MainTest {
|
||||
var slots = Masker.extractSlots(mask, dict.index());
|
||||
val slotInfo = Masker.scoreSlots(new int[slots.length], slots);
|
||||
var grid = mask.toGrid();
|
||||
var filled = fillMask(rng, slotInfo, grid, false);
|
||||
// val res = new PuzzleResult(new Clued(mask), new Gridded(grid), slotInfo, filled).exportFormatFromFilled(0, new Rewards(0, 0, 0));
|
||||
// var filled = fillMask(rng, slotInfo, grid, false);
|
||||
// val res = new PuzzleResult(new Clued(mask), new Gridded(grid), slotInfo, filled).exportFormatFromFilled(0, new Rewards(0, 0, 0));
|
||||
}
|
||||
@Test
|
||||
void testFiller() {
|
||||
@@ -236,7 +236,7 @@ public class MainTest {
|
||||
int foundSeed = -1;
|
||||
for (int i = 0; i < 50; i++) {
|
||||
int seed = opts.seed + i;
|
||||
res = Main.attempt(new Rng(seed), dict, opts);
|
||||
res = Main.attempt(new Rng(seed), DictData.DICT, opts);
|
||||
if (res != null && res.filled().ok()) {
|
||||
foundSeed = seed;
|
||||
System.out.println("[DEBUG_LOG] Seed found: " + seed);
|
||||
|
||||
Reference in New Issue
Block a user