ConwayLife.com - A community for Conway's Game of Life and related cellular automata
Home  •  LifeWiki  •  Forums  •  Download Golly

apgsearch v4.0

For general discussion about Conway's Game of Life.

Re: apgsearch v4.0

Postby Apple Bottom » January 4th, 2018, 2:15 pm

Majestas32 wrote:You do realized you just revealed your payosha256 key right danny?


Not the first time anyone's done that -- but all it allows others to do is submit results in his name, so it's hardly a big deal, is it.
If you speak, your speech must be better than your silence would have been. — Arabian proverb

Catagolue: Apple Bottom • Life Wiki: Apple Bottom • Twitter: @_AppleBottom_

Proud member of the Pattern Raiders!
User avatar
Apple Bottom
 
Posts: 1024
Joined: July 27th, 2015, 2:06 pm

Re: apgsearch v4.0

Postby muzik » January 11th, 2018, 11:38 am

Is it just me or is object separation getting worse?
Bored of using the Moore neighbourhood for everything? Introducing the Range-2 von Neumann isotropic non-totalistic rulespace!
muzik
 
Posts: 3301
Joined: January 28th, 2016, 2:47 pm
Location: Scotland

Re: apgsearch v4.0

Postby 77topaz » January 25th, 2018, 7:49 pm

muzik wrote:EDIT: A third time as well. Can that yl82 be rescued from its apgcode?
(yl82_1_13_442e9e06ce8ff98bb88fbf07d6b84fd0)


The linear growth pattern in that yl82 (which also contains a lot of chaos) is this:
x = 9, y = 6, rule = B026/S1
7bo$8bo$5bo$6bo$3bo$o3bo!
User avatar
77topaz
 
Posts: 1345
Joined: January 12th, 2018, 9:19 pm

Re: apgsearch v4.0

Postby danny » January 25th, 2018, 8:15 pm

77topaz wrote:The linear growth pattern in that yl82 (which also contains a lot of chaos) is this:

FALSEHOOD! It is actually a p41 gun:
x = 13, y = 17, rule = R2,C0,M1,S10..19,B4..4,NM
6b2o2bo$5bo$7b3o2bo$3bo3b3o2bo$2bo2b6obo$bo2b2ob2o3bo$3bo3bob2o$ob9o$
2b3o2bob3o$ob9o$3bo3bob2o$bo2b2ob2o3bo$2bo2b6obo$3bo3b3o2bo$7b3o2bo$5b
o$6b2o2bo!
she/they // Please stop using my full name. Refer to me as dani.

"I'm always on duty, even when I'm off duty." -Cody Kolodziejzyk, Ph.D.
User avatar
danny
 
Posts: 945
Joined: October 27th, 2017, 3:43 pm
Location: New Jersey, USA

Re: apgsearch v4.0

Postby Rhombic » January 25th, 2018, 9:05 pm

Apple Bottom wrote:
Majestas32 wrote:You do realized you just revealed your payosha256 key right danny?


Not the first time anyone's done that -- but all it allows others to do is submit results in his name, so it's hardly a big deal, is it.

To be fair, you can claim the key by submitting it as your own key as I did back in the day with WWei, so that all their hauls are submitted in your name. ;)
SoL : FreeElectronics : DeadlyEnemies : 6a-ite : Rule X3VI
what is “sesame oil”?
User avatar
Rhombic
 
Posts: 1056
Joined: June 1st, 2013, 5:41 pm

Re: apgsearch v4.0

Postby danny » January 25th, 2018, 11:26 pm

Rhombic wrote:To be fair, you can claim the key by submitting it as your own key as I did back in the day with WWei, so that all their hauls are submitted in your name. ;)

which is why i switched
she/they // Please stop using my full name. Refer to me as dani.

"I'm always on duty, even when I'm off duty." -Cody Kolodziejzyk, Ph.D.
User avatar
danny
 
Posts: 945
Joined: October 27th, 2017, 3:43 pm
Location: New Jersey, USA

Re: apgsearch v4.0

Postby 77topaz » January 26th, 2018, 4:54 am

danny wrote:FALSEHOOD! It is actually a p41 gun:
x = 13, y = 17, rule = R2,C0,M1,S10..19,B4..4,NM
6b2o2bo$5bo$7b3o2bo$3bo3b3o2bo$2bo2b6obo$bo2b2ob2o3bo$3bo3bob2o$ob9o$
2b3o2bob3o$ob9o$3bo3bob2o$bo2b2ob2o3bo$2bo2b6obo$3bo3b3o2bo$7b3o2bo$5b
o$6b2o2bo!


Oops, my bad. Several of the soups/errors Muzik was referring to in that conversation originated from B026/S1, so I thought that apgcode was also referring to a pattern in that rule, and in B026/S1 said apgcode did indeed produce a linear growth pattern along with a lot of replicator-y chaos which apgsearch would struggle with. I should've realised it would be weird for a p16 rake to be tagged as p82. :oops:
User avatar
77topaz
 
Posts: 1345
Joined: January 12th, 2018, 9:19 pm

Re: apgsearch v4.0

Postby tod222 » January 26th, 2018, 5:05 pm

I recently started running apgmera v3.28 again after many months idle. It's generally running with 2-8 threads depending on what else I'm doing.

For b3s23/C1 is there an advantage to running v4? Is it faster or better?
Catagolue: @th222 • Twitter: @th222
tod222
 
Posts: 21
Joined: August 23rd, 2010, 12:43 am

Re: apgsearch v4.0

Postby Apple Bottom » January 26th, 2018, 5:14 pm

tod222 wrote:I recently started running apgmera v3.28 again after many months idle. It's generally running with 2-8 threads depending on what else I'm doing.

For b3s23/C1 is there an advantage to running v4? Is it faster or better?


v4 has a couple of improvements, at least some of which should also translate to faster performance, but in my experience it's actually a bit slower for B3/S23/C1. And there's been some issues with sample soups not generating the objects they were reported to, unaddressed so far, so my personal (!) recommendation is to stick with 3.28 for the time being -- for Conway Life anyway.
If you speak, your speech must be better than your silence would have been. — Arabian proverb

Catagolue: Apple Bottom • Life Wiki: Apple Bottom • Twitter: @_AppleBottom_

Proud member of the Pattern Raiders!
User avatar
Apple Bottom
 
Posts: 1024
Joined: July 27th, 2015, 2:06 pm

Re: apgsearch v4.0

Postby 77topaz » March 9th, 2018, 5:24 pm

My apgsearch has suddenly stopped working properly:

When I try to search b3s23/C1, I get this error message:
Traceback (most recent call last):
  File "lifelib/avxlife/rule2asm.py", line 939, in <module>
    main()
  File "lifelib/avxlife/rule2asm.py", line 853, in main
    makeasm(rulestring)
  File "lifelib/avxlife/rule2asm.py", line 784, in makeasm
    ix.genlogic(logstring)
  File "lifelib/avxlife/rule2asm.py", line 234, in genlogic
    for i in xrange(8):
NameError: name 'xrange' is not defined


For another rule (b2ci3ae4ety5ciy678s2cek3-aij4-w5cejry6-e78/C1), I get this:
Configuring rule b2ci3ae4ety5ciy678s2cek3-aij4-w5cejry6-e78; symmetry C1
Traceback (most recent call last):
  File "ntcanon.py", line 34, in <module>
    for i in xrange(512):
NameError: name 'xrange' is not defined
Valid symmetry: C1
Success!
g++ -c -Wall -O3 -march=native --std=c++11 main.cpp -o main.o
In file included from main.cpp:16:
In file included from ./lifelib/upattern.h:3:
./lifelib/avxlife/uli.h:5:10: fatal error: 'lifelogic/iterators_all.h' file not found
#include "lifelogic/iterators_all.h"
         ^~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.
make: *** [main.o] Error 1


Yet b36is234j/C1 searches normally, without any errors.
User avatar
77topaz
 
Posts: 1345
Joined: January 12th, 2018, 9:19 pm

Re: apgsearch v4.0

Postby Apple Bottom » March 9th, 2018, 5:26 pm

77topaz wrote:My apgsearch has suddenly stopped working properly:


You seem to be having a problem with your Python installation. What OS are you on? Did you recently update your packages, install a new system, or something else along those lines?
If you speak, your speech must be better than your silence would have been. — Arabian proverb

Catagolue: Apple Bottom • Life Wiki: Apple Bottom • Twitter: @_AppleBottom_

Proud member of the Pattern Raiders!
User avatar
Apple Bottom
 
Posts: 1024
Joined: July 27th, 2015, 2:06 pm

Re: apgsearch v4.0

Postby dvgrn » March 9th, 2018, 5:42 pm

Apple Bottom wrote:
77topaz wrote:My apgsearch has suddenly stopped working properly:


You seem to be having a problem with your Python installation. What OS are you on? Did you recently update your packages, install a new system, or something else along those lines?

Specifically, since xrange() is available in Python 2.x but not in Python 3.x, a superficially plausible theory is that your system is now trying to run apgsearch with Python 3.x (for whatever reason).
User avatar
dvgrn
Moderator
 
Posts: 5627
Joined: May 17th, 2009, 11:00 pm
Location: Madison, WI

Re: apgsearch v4.0

Postby 77topaz » March 9th, 2018, 6:02 pm

dvgrn wrote:Specifically, since xrange() is available in Python 2.x but not in Python 3.x, a superficially plausible theory is that your system is now trying to run apgsearch with Python 3.x (for whatever reason).


I recently installed Anaconda for one of my university classes, which I think includes Python 3.x, but apgsearch still says it's running Python 2.7.10 (which is the computer's built-in version of Python). How could I fix this problem?
User avatar
77topaz
 
Posts: 1345
Joined: January 12th, 2018, 9:19 pm

Re: apgsearch v4.0

Postby dvgrn » March 9th, 2018, 7:00 pm

77topaz wrote:
dvgrn wrote:Specifically, since xrange() is available in Python 2.x but not in Python 3.x, a superficially plausible theory is that your system is now trying to run apgsearch with Python 3.x (for whatever reason).


I recently installed Anaconda for one of my university classes, which I think includes Python 3.x, but apgsearch still says it's running Python 2.7.10 (which is the computer's built-in version of Python). How could I fix this problem?

Yikes, no idea. I mean, theoretically you could rewrite ntcanon.py to be Python 3 compatible, but that's a really lousy idea since you'd probably have to do the same thing for rule2asm.py, etc...

Maybe the place to start is to prove that the problem really is that this line in rule2asm.py, which is clearly running in Python 2.x (it's full of xranges also) --

            status = os.system('python ntcanon.py "%s"' % rulestring)

-- is now invoking Python 3 on your system. A diagnostic print statement added at the beginning of lifelib/avxlife/ntcanon.py might do the trick. Does adding this to say line 4 of ntcanon.py --

print(sys.version)

-- send a version string to the console window, before the error message shows up?

I'm assuming that this will in fact report Python 3.x... which basically means that your Anaconda installation (or something since then) has modified the PATH variable on your system, such that the path to Python 3.x now comes before the path to Python 2.x.

Or something like that. I probably have the details wrong, and I'm not particularly good at fixing this kind of multi-Python mess anyway.

I'm guessing if you renamed your Python 3 executable temporarily, apgluxe would stop throwing those errors. So that's another thing you could try --!
User avatar
dvgrn
Moderator
 
Posts: 5627
Joined: May 17th, 2009, 11:00 pm
Location: Madison, WI

Re: apgsearch v4.0

Postby 77topaz » March 9th, 2018, 7:42 pm

The print(sys.version) thing doesn't work, because the "sys" itself creates an error:
Configuring rule b2ci3ae4ety5ciy678s2cek3-aij4-w5cejry6-e78; symmetry C1
Traceback (most recent call last):
  File "ntcanon.py", line 4, in <module>
    print(sys.version)
NameError: name 'sys' is not defined
Valid symmetry: C1
Success!
g++ -c -Wall -O3 -march=native --std=c++11 main.cpp -o main.o
In file included from main.cpp:16:
In file included from ./lifelib/upattern.h:3:
./lifelib/avxlife/uli.h:5:10: fatal error: 'lifelogic/iterators_all.h' file not found
#include "lifelogic/iterators_all.h"
         ^~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.
make: *** [main.o] Error 1


Note that when I run b36is234j/C1, it still says this:
Lifelib version: ll1.23
Compiler version: 4.2.1 Compatible Apple LLVM 9.0.0 (clang-900.0.39.2)
Python version: '2.7.10 (default, Jul 30 2016, 19:40:32)  [GCC 4.2.1 Compatible Apple LLVM 8.0.0 (clang-800.0.34)]'


EDIT: When I open a new console window and type "python --version", it returns this:
Python 3.6.4 :: Anaconda, Inc.
User avatar
77topaz
 
Posts: 1345
Joined: January 12th, 2018, 9:19 pm

Re: apgsearch v4.0

Postby dvgrn » March 9th, 2018, 9:04 pm

77topaz wrote:The print(sys.version) thing doesn't work, because the "sys" itself creates an error...

Sorry, yeah, add another line "import sys" just before the print line, to take care of that.

77topaz wrote:Note that when I run b36is234j/C1, it still says this:
Lifelib version: ll1.23
Compiler version: 4.2.1 Compatible Apple LLVM 9.0.0 (clang-900.0.39.2)
Python version: '2.7.10 (default, Jul 30 2016, 19:40:32)  [GCC 4.2.1 Compatible Apple LLVM 8.0.0 (clang-800.0.34)]'


EDIT: When I open a new console window and type "python --version", it returns this:
Python 3.6.4 :: Anaconda, Inc.

That's all definitely consistent with the theory that -- for some reason -- running Python from inside Python gets hold of a %PATH% variable (or Mac equivalent, I don't know the details) that points to Python 3.6.4, whereas the console window where you're running recompile.sh -- for some reason -- is accessing a version of %PATH% that doesn't know about the Anaconda Python.

I suspect your easiest solution may be to modify the lifelib/avxlife/rule2asm.py line to say specifically

            status = os.system("/specific/path/to/python ntcanon.py "%s"' % rulestring)

-- you figure out where exactly your 2.7.10 Python is located, and edit the above to point to that path.
User avatar
dvgrn
Moderator
 
Posts: 5627
Joined: May 17th, 2009, 11:00 pm
Location: Madison, WI

Re: apgsearch v4.0

Postby 77topaz » March 9th, 2018, 9:23 pm

dvgrn wrote:-- you figure out where exactly your 2.7.10 Python is located, and edit the above to point to that path.


I think I found the correct directory for Python 2.7, so I changed the line to this:
            status = os.system('/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7 ntcanon.py "%s"' % rulestring)


However, I still get an error for non-totalistic rules:
Configuring rule b2ci3ae4ety5ciy678s2cek3-aij4-w5cejry6-e78; symmetry C1
sh: /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7: is a directory
Valid symmetry: C1
Success!
g++ -c -Wall -O3 -march=native --std=c++11 main.cpp -o main.o
In file included from main.cpp:16:
In file included from ./lifelib/upattern.h:3:
./lifelib/avxlife/uli.h:5:10: fatal error: 'lifelogic/iterators_all.h' file not found
#include "lifelogic/iterators_all.h"
         ^~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.
make: *** [main.o] Error 1


And my error for b3s23/C1 is still exactly the same as before.
User avatar
77topaz
 
Posts: 1345
Joined: January 12th, 2018, 9:19 pm

Re: apgsearch v4.0

Postby dvgrn » March 9th, 2018, 9:29 pm

77topaz wrote:Configuring rule b2ci3ae4ety5ciy678s2cek3-aij4-w5cejry6-e78; symmetry C1
sh: /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7: is a directory...

The error is trying to tell you exactly what the problem is. The original line started with "python", which is an executable file not a directory. You probably just need

status = os.system('/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7/python ntcanon.py "%s"' % rulestring)
User avatar
dvgrn
Moderator
 
Posts: 5627
Joined: May 17th, 2009, 11:00 pm
Location: Madison, WI

Re: apgsearch v4.0

Postby 77topaz » March 9th, 2018, 9:33 pm

dvgrn wrote:The error is trying to tell you exactly what the problem is. The original line started with "python", which is an executable file not a directory. You probably just need

status = os.system('/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7/python ntcanon.py "%s"' % rulestring)


There is no file just called "python", though, and trying exactly the line you wrote gave me "No such file or directory". There is, however, a file named Python.h, but trying that doesn't work either, as I get "Permission denied":
Configuring rule b2ci3ae4ety5ciy678s2cek3-aij4-w5cejry6-e78; symmetry C1
sh: /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7/Python.h: Permission denied
Valid symmetry: C1
Success!
g++ -c -Wall -O3 -march=native --std=c++11 main.cpp -o main.o
In file included from main.cpp:16:
In file included from ./lifelib/upattern.h:3:
./lifelib/avxlife/uli.h:5:10: fatal error: 'lifelogic/iterators_all.h' file not found
#include "lifelogic/iterators_all.h"
         ^~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.
make: *** [main.o] Error 1
User avatar
77topaz
 
Posts: 1345
Joined: January 12th, 2018, 9:19 pm

Re: apgsearch v4.0

Postby dvgrn » March 9th, 2018, 9:46 pm

77topaz wrote:There is no file just called "python", though, and trying exactly the line you wrote gave me "No such file or directory". There is, however, a file named Python.h, but trying that doesn't work either...

Yeah, you've dug way down into source code somewhere. Try looking elsewhere.

Here's a suggestion from StackOverflow: try running in a console window

type -a python

or possibly

which Python
...?
User avatar
dvgrn
Moderator
 
Posts: 5627
Joined: May 17th, 2009, 11:00 pm
Location: Madison, WI

Re: apgsearch v4.0

Postby 77topaz » March 9th, 2018, 11:30 pm

dvgrn wrote:Yeah, you've dug way down into source code somewhere. Try looking elsewhere.

Here's a suggestion from StackOverflow: try running in a console window

type -a python

or possibly

which Python
...?


The first search gave two results: the Python file from Anaconda, plus another one at "/usr/bin/python", a directory which I didn't even know existed (though it's mentioned in the very first line of rule2asm.py). The second one gave only the Anaconda one. So, I changed the line in rule2asm.py to:
            status = os.system('/usr/bin/python ntcanon.py "%s"' % rulestring)


But this only gave me a new kind of error, again involving the "xrange":
Configuring rule b2ci3ae4ety5ciy678s2cek3-aij4-w5cejry6-e78; symmetry C1
Compressing 512-bit lookup table for rule b2ci3ae4ety5ciy678s2cek3-aij4-w5cejry6-e78...
Creating magic sauce for rule b2ci3ae4ety5ciy678s2cek3-aij4-w5cejry6-e78...
...completed.
Traceback (most recent call last):
  File "lifelib/avxlife/rule2asm.py", line 939, in <module>
    main()
  File "lifelib/avxlife/rule2asm.py", line 905, in main
    for hist in xrange(3):
NameError: name 'xrange' is not defined
User avatar
77topaz
 
Posts: 1345
Joined: January 12th, 2018, 9:19 pm

Re: apgsearch v4.0

Postby dvgrn » March 10th, 2018, 9:35 am

77topaz wrote:Traceback (most recent call last):
File "lifelib/avxlife/rule2asm.py", line 939, in <module>
main()
File "lifelib/avxlife/rule2asm.py", line 905, in main
for hist in xrange(3):
NameError: name 'xrange' is not defined
[/code]

Okay, that is fairly strange. Whereas before your system seemed to be successfully running rule2asm.py, now it's acting as if it's trying to use your Anaconda Python 3 to run that file as well. That's pretty mysterious behavior, as if Anaconda is very gradually taking over your computer.

Theoretically the solution is the same as before. This time, edit lines 60 and 61 in recompile.sh --

python lifelib/avxlife/rule2asm.py $rulearg
python mkparams.py $rulearg $symmarg

-- to point specifically to your Python 2.7.10 install:

/usr/bin/python lifelib/avxlife/rule2asm.py $rulearg
/usr/bin/python mkparams.py $rulearg $symmarg

Disclaimer again: I'm just making all this up as I go along.
User avatar
dvgrn
Moderator
 
Posts: 5627
Joined: May 17th, 2009, 11:00 pm
Location: Madison, WI

Re: apgsearch v4.0

Postby 77topaz » March 10th, 2018, 3:31 pm

Okay, I changed those lines in recompile.sh, and it works normally now! :D Thank you very much for your help!
User avatar
77topaz
 
Posts: 1345
Joined: January 12th, 2018, 9:19 pm

Re: apgsearch v4.0

Postby 2718281828 » March 15th, 2018, 5:26 am

I am not sure if this suggestion should go to the catagolue discussion thread or here.

I would like that apgsearch does not only allow 2^N x 2^(8-N)
1x256
2x128
4x64
8x32
I would like to run the other numbers as well (at least up to 7), i.e.
3x85
5x51
6x42
7x36
9x28
10x25
11x23
12x21
13x19
14x18
15x17
Of course a few bits would remain unused, but that shouldn't be a problem.
I think esp. 3x85 (1 bit is unused) would be of interest for glider/spaceship synthesis. I happens that certain objects does not or only trivially occur in the actual soups, but might pop up in a synthesis suitable way in such a soup.
User avatar
2718281828
 
Posts: 684
Joined: August 8th, 2017, 5:38 pm

Re: apgsearch v4.0

Postby Apple Bottom » March 15th, 2018, 5:43 am

2718281828 wrote:I would like to run the other numbers as well (at least up to 7), i.e.
3x85
5x51
6x42
7x36
9x28
10x25
11x23
12x21
13x19
14x18
15x17
Of course a few bits would remain unused, but that shouldn't be a problem.
I think esp. 3x85 (1 bit is unused) would be of interest for glider/spaceship synthesis. I happens that certain objects does not or only trivially occur in the actual soups, but might pop up in a synthesis suitable way in such a soup.


You could probably implement without too much difficulty -- the soup generation code is in includes/hashsoup2.h, hashsoup_inner(). Be sure to use a _Test symmetry if you do! :)
If you speak, your speech must be better than your silence would have been. — Arabian proverb

Catagolue: Apple Bottom • Life Wiki: Apple Bottom • Twitter: @_AppleBottom_

Proud member of the Pattern Raiders!
User avatar
Apple Bottom
 
Posts: 1024
Joined: July 27th, 2015, 2:06 pm

PreviousNext

Return to General Discussion

Who is online

Users browsing this forum: No registered users and 7 guests