Code: Select all
$ python lls -c -b 16 6 -s p3 x0 y1
Traceback (most recent call last):
File "lls", line 7, in <module>
import src.search_patterns
ImportError: No module named src.search_patterns
Code: Select all
$ python lls -c -b 16 6 -s p3 x0 y1
Traceback (most recent call last):
File "lls", line 7, in <module>
import src.search_patterns
ImportError: No module named src.search_patterns
Since you were able to run the main script with "python lls", the script lls must be in the current directory. Check whether there is a subdirectory 'src' and a file 'src/search_patterns.py' there. If not, probably the files were not unpacked completely.muzik wrote: ↑March 25th, 2024, 7:08 amCode: Select all
$ python lls -c -b 16 6 -s p3 x0 y1 Traceback (most recent call last): File "lls", line 7, in <module> import src.search_patterns ImportError: No module named src.search_patterns
Affirmative. I've also tested the other two example commands; the second (for Brain) gives the same error as the first. The third reports that ".python" is not a valid command, so I'm not sure if there's a typo at the wiki or if the python installation I'm using is somehow at fault.confocaloid wrote: ↑March 25th, 2024, 7:16 amCheck whether there is a subdirectory 'src' and a file 'src/search_patterns.py' there.
Code: Select all
# python3 lls -c -b 16 6 -s p3 x0 y1
This did the trick. However, the second command on the page returns dart instead, which I don't think is right:confocaloid wrote: ↑March 25th, 2024, 7:32 amNot sure about the cause of the first error. On my system I have "python3" for Python 3, and the modified invocation (python -> python3) workedCode: Select all
# python3 lls -c -b 16 6 -s p3 x0 y1
Code: Select all
$ python3 lls -c -b 17 12 -s p3 x0 y1 -s "D2|"
Getting search pattern...
Done
Preprocessing...
Done
Width: 19
Height: 14
Duration: 4
Number of undetermined cells: 315
Number of variables: 424
Number of clauses: 43364
x = 19, y = 14, rule = B3/S23
bbbbbbbbbbbbbbbbbbb$
bbbbbbbbbbbbbbbbbbb$
bbbbbbbbbbbbbbbbbbb$
bbbooboboboboboobbb$
bbobbbooobooobbbobb$
bbbobooboboboobobbb$
bbbboboobbboobobbbb$
bbbbbbbobbbobbbbbbb$
bbbbbbbbbbbbbbbbbbb$
bbbbbbbobbbobbbbbbb$
bbbbbbbbooobbbbbbbb$
bbbbbbbbooobbbbbbbb$
bbbbbbbbbbbbbbbbbbb$
bbbbbbbbbbbbbbbbbbb!
Total solver time: 6.353018522262573
IIRC LLS traverses search space in different order on different invocations, and also depending on which SAT solver is used behind the scenes. If both spaceships are small enough to be solutions, either of them may be returned.
Code: Select all
# python3 lls -c -b 17 12 -s p3 x0 y1 -s "D2|" -n
Code: Select all
#C found using LLS/kissat with:
#C python3 lls -c -b 17 12 -s p3 x0 y1 -s "D2|" -p "=62"
#C Total solver time: 140.29749941825867
x = 19, y = 14, rule = B3/S23
bbbbbbbbbbbbbbbbbbb$
bbbbbbbooboobbbbbbb$
booobobbbbbbbobooob$
bbbbbbbbobobbbbbbbb$
bbbobbobobobobbobbb$
bbbooboboboboboobbb$
bbbbbbobobobobbbbbb$
bbbbbobbobobbobbbbb$
bobobbbooboobbbobob$
bobbboobbbbboobbbob$
bbooboobbbbbooboobb$
bboobbbbbbbbbbboobb$
bbbbbbbbbbbbbbbbbbb$
bbbbbbbbbbbbbbbbbbb!
Code: Select all
#C found using LLS/kissat with:
#C python3 lls -c -b 17 12 -s p3 x0 y1 -s "D2|" -p "<35"
#C Total solver time: 309.99119544029236
x = 19, y = 14, rule = B3/S23
bbbbbbbbbbbbbbbbbbb$
bbbobooboboboobobbb$
bbobbbbbobobbbbbobb$
bbboobbbobobbboobbb$
bbbbobbbobobbbobbbb$
bbbbbboobbboobbbbbb$
bbbbbbbbbbbbbbbbbbb$
bbbbbbbbooobbbbbbbb$
bbbbbbbobbbobbbbbbb$
bbbbbbbbobobbbbbbbb$
bbbbbbbbbobbbbbbbbb$
bbbbbbbbbbbbbbbbbbb$
bbbbbbbbbbbbbbbbbbb$
bbbbbbbbbbbbbbbbbbb!