(semi-)automated searches in rulespaces

For scripts to aid with computation or simulation in cellular automata.
Post Reply
User avatar
martin.novy
Posts: 142
Joined: October 22nd, 2014, 6:22 am
Location: Czechia, EU
Contact:

(semi-)automated searches in rulespaces

Post by martin.novy » June 22nd, 2020, 10:37 am

Links
a sub-topic: Automated tests whether a rule is explosive viewtopic.php?f=9&t=4566

----

I am interested in searching for rules (e.g. to find new rules with natural spaceships).

But it is not easy to find posts related to (semi-)automated searches in rulespaces.

So, first I would like to gather some quotes:
LaundryPizza03 wrote:
May 18th, 2020, 11:30 pm
How can I automatically search large batches of rules using apgsearch? Especially, how can I autoskip non-apgsearchable rules in a batch (whether due to explosiveness or tendency to form large clumps) or automatically determine apgserachability a priori?
--------
testitemqlstudop wrote:
March 27th, 2019, 11:22 pm
How difficult would it be to modify apgsearch so that it skips soups that can't be censused in 10 seconds?
Edit: later I realized, that my thought is probably very weakly related to the quote, but ...
BTW, I thought, as an alternative possibility in my program, about terminating the search process after a timeout ... in Linux (and in WSL??), there must be some utility for that already

--------
martin.novy wrote:
June 20th, 2020, 10:31 am
for automated finding of rules:
I am programming a new way
to detect the presence of spaceships:
...
--------
Naszvadi wrote:
March 27th, 2020, 8:11 am

There is a getallrules.py and getallrulesnt.py among the python scripts delivered with golly, they could be used in a batch in order to determine supported rules of a given pattern. ...
Last edited by martin.novy on June 23rd, 2020, 7:27 am, edited 2 times in total.

bprentice
Posts: 920
Joined: September 10th, 2009, 6:20 pm
Location: Coos Bay, Oregon

Re: (semi-)automated searches in rulespaces

Post by bprentice » June 22nd, 2020, 4:13 pm

martin.novy wrote:
June 22nd, 2020, 10:37 am
I am interested in searching for rules (e.g. to find new rules with natural spaceships).
This is a very general request! Square Cell has this capability. Simply select a rule family and press the 'N' key. This will generate a random rule from the selected family and run it starting with a random state. For example I've just selected the "Bits Counts' family and pressing 'N' a few times generated this rule:

p1.png
p1.png (69.14 KiB) Viewed 4868 times

which supports this ship:

Code: Select all

#Rule = Bit Counts
#States = 16
#NS 1,1,1,1,1,1,1,1,1
#NS 1,1,1,1,1,1,1,1,1
#NS 1,1,1,1,1,1,1,1,1
#NS 1,1,1,1,1,1,1,1,1
#RT 0,0,0,0,0,14,0,4,10,7,0,0,0,0,0,8,0,0,0,0,0,13,0,0,0,5,8,0,0,1,0,0,0,15,11,0,2
#Rows = 5
#Columns = 3
#L 2D$2GN$2.J$2GN$2D
I wrote a Golly script years ago to do the same thing. It is hidden in this forum somewhere.

Brian Prentice

lemon41625
Posts: 344
Joined: January 24th, 2020, 7:39 am
Location: 小红点 (if you know where that is)

Re: (semi-)automated searches in rulespaces

Post by lemon41625 » June 22nd, 2020, 9:00 pm

martin.novy wrote:
June 22nd, 2020, 10:37 am
I am interested in searching for rules (e.g. to find new rules with natural spaceships).

But it is not easy to find posts related to (semi-)automated searches in rulespaces.

One possibility is to generate a list of all rules in a rulespace and manually filter out which rules are explosive.

For example in the B3x/S23 rulespace where x is 1 totalistic transition.

Code: Select all

B13/S23 [Explosive]
B23/S23 [Explosive]
B34/S23 [Explosive]
B35/S23
B36/S23
B37/S23 [Explosive]
B38/S23
Afterwards, you can search those ships in apgsearch with an automated script such as this.

Code: Select all

while read line; do  
    ./apgluxe --rule $line -n 100000 -p 6 -k [REDACTED] -i 20
	sleep 600s 
	
done < apgsearch_list.txt
Alternatively, you could use lifelib and take note of the time taken to run a certain number of generations.
A more explosive rule would by right take longer to run. With that you can set a threshold for a explosive rule and a non explosive rule.

Alternatively, if you don't only want to focus on only on natural spaceships, you can use spaceship search programs such as qfind, ntzfind, LLS (R1 Moore INT Rules), gfind, WLS, JLS, lifesrc, LSSS (R1 Moore OT), rlifesrc (R1 Moore INT, MAP and generations), yfind (hexagonal INT), solid_ship.py (For Solid Ships in LtL).

At this point only solid_ship.py supports LtL but I will hopefully release my SAT solver program soon.

One issue with bprentice's approach is that you have to sit at the computer and look for spaceships manually.
Randomly generating rules and simply running them will also not help you find rarer natural spaceships while programs like apgsearch can.
That approach also will not systematically cover the entire rulespace.

BTW, how is your approach to automatically detect explosive rules by density? Also you won't need WLS if you use Linux. WLS is Windows Subsystems for Linux and is only need if you use Windows 10.
Download CAViewer: https://github.com/jedlimlx/Cellular-Automaton-Viewer

Supports:
BSFKL, Extended Generations, Regenerating Generations, Naive Rules, R1 Moore, R2 Cross and R2 Von Neumann INT
And some others...

bprentice
Posts: 920
Joined: September 10th, 2009, 6:20 pm
Location: Coos Bay, Oregon

Re: (semi-)automated searches in rulespaces

Post by bprentice » June 22nd, 2020, 11:27 pm

lemon41625 wrote:
June 22nd, 2020, 9:00 pm
One issue with bprentice's approach is that you have to sit at the computer and look for spaceships manually.
Randomly generating rules and simply running them will also not help you find rarer natural spaceships while programs like apgsearch can.
It depends on your particular interests in CA. For example I use CA simulators like a solitaire game. Unlike Conway's Life enthusiasts, I usually only spend a few hours with any particular rule. Just enough to understand the rules rhythms and perhaps construct some ships from puffers and some guns from oscillators.
lemon41625 wrote:
June 22nd, 2020, 9:00 pm
That approach also will not systematically cover the entire rulespace.
I doubt whether you will live long enough to do that!

Brian Prentice

User avatar
martin.novy
Posts: 142
Joined: October 22nd, 2014, 6:22 am
Location: Czechia, EU
Contact:

Re: (semi-)automated searches in rulespaces

Post by martin.novy » June 23rd, 2020, 6:11 am

lemon41625 wrote:
June 22nd, 2020, 9:00 pm

Alternatively, you could use lifelib and take note of the time taken to run a certain number of generations.
A more explosive rule would by right take longer to run. With that you can set a threshold for a explosive rule and a non explosive rule.
lifelib: yes
threshold:yes

today I hope I will finish a demo program, that automatically tests for explosiveness
EDIT: demo program posted
Last edited by martin.novy on June 23rd, 2020, 7:29 am, edited 1 time in total.

User avatar
martin.novy
Posts: 142
Joined: October 22nd, 2014, 6:22 am
Location: Czechia, EU
Contact:

Re: (semi-)automated searches in rulespaces

Post by martin.novy » June 23rd, 2020, 7:25 am

I have added a new thread:
Automated tests whether a rule is explosive
viewtopic.php?f=9&t=4566

User avatar
martin.novy
Posts: 142
Joined: October 22nd, 2014, 6:22 am
Location: Czechia, EU
Contact:

Re: (semi-)automated searches in rulespaces

Post by martin.novy » July 1st, 2020, 6:47 am

bprentice wrote:
June 22nd, 2020, 4:13 pm
martin.novy wrote:
June 22nd, 2020, 10:37 am
I am interested in searching for rules (e.g. to find new rules with natural spaceships).
This is a very general request! Square Cell has this capability. Simply select a rule family and press the 'N' key. This will generate a random rule from the selected family and run it starting with a random state.
...
I wrote a Golly script years ago to do the same thing. It is hidden in this forum somewhere.
for semi-automated searches of Gaussian and Primordia parameters,

I wonder, how easy/difficult additional programming would it be

to be able to run java -jar SquareCell.jar

*non-interactively*, from a shell script, many times,

something like , for example

java -jar SquareCell.jar -time-steps 900 input1.sqc output1.sqc

and it would compute
with world 1000*1000,
for 900 time-steps, and then write the output1.sqc, and then finish

(edit: or an alternative: to call not from a shell script, but from a jython script)
Last edited by martin.novy on July 1st, 2020, 10:40 am, edited 1 time in total.

lemon41625
Posts: 344
Joined: January 24th, 2020, 7:39 am
Location: 小红点 (if you know where that is)

Re: (semi-)automated searches in rulespaces

Post by lemon41625 » July 1st, 2020, 9:40 am

martin.novy wrote:
July 1st, 2020, 6:47 am
for semi-automated searches of Gaussian and Primordia parameters
Some options:
Use a script to autogenerate a ruletable for these rules.
If you're using R1 Moore neighbourhood, you can refer to these specifications:
https://github.com/GollyGang/ruletabler ... RuleFormat

The most important part is the table/tree. The rest doesn't really matter.
There is also a script to generate a rule tree in the golly files as well.

Apgsearch supports custom neighbourhoods as a list of cells (I wish golly did).

For example,

Code: Select all

n_states:2
neighborhood:[(0, 0), (1, -1), (1, 0), (1, 1), (0, 1), (-1, 1), (-1, 0), (-1, -1), (0, -1), (2, 0), (0, 2), (-2, 0), (0, -2), (0, 0)]
symmetries:none

# Variables for Death Transitions
var death0 = {0, 1}
var death1 = {0, 1}
var death2 = {0, 1}
var death3 = {0, 1}
var death4 = {0, 1}
var death5 = {0, 1}
var death6 = {0, 1}
var death7 = {0, 1}
var death8 = {0, 1}
var death9 = {0, 1}
var death10 = {0, 1}
var death11 = {0, 1}

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1,0,0,1,1,0,0,0,1
1,0,1,0,0,1,0,1,1,0,0,0,0,1
1,0,0,0,0,1,1,0,0,0,1,0,1,1
1,0,0,1,0,0,0,1,0,1,0,0,0,1
1,0,0,1,1,0,0,0,0,0,1,1,0,1

# Death Transitions
1,death0,death1,death2,death3,death4,death5,death6,death7,death8,death9,death10,death11,0
Note that rotate_4_reflect symmetry is not supported for custom neighbourhoods so you have to use none for weighted rules such as the above ruletable.

One issue is that apgsearch takes around half an hour to compile for a R2 Moore rule on permute symmetry though I don't think that will occur for weighted rules on none symmetry.

=================================================

You could also make use of your python script using convolutions.
To run them in a shell you would just need an array to rle converter and to accept cmd parameters via the something like the argparse module.
Download CAViewer: https://github.com/jedlimlx/Cellular-Automaton-Viewer

Supports:
BSFKL, Extended Generations, Regenerating Generations, Naive Rules, R1 Moore, R2 Cross and R2 Von Neumann INT
And some others...

User avatar
martin.novy
Posts: 142
Joined: October 22nd, 2014, 6:22 am
Location: Czechia, EU
Contact:

Re: (semi-)automated searches in rulespaces

Post by martin.novy » July 1st, 2020, 10:06 am

lemon41625 wrote:
July 1st, 2020, 9:40 am

Use a script to autogenerate a ruletable for these rules.
If you're using R1 Moore neighbourhood, you can refer to these specifications:
https://github.com/GollyGang/ruletabler ... RuleFormat

The most important part is the table/tree. The rest doesn't really matter.
There is also a script to generate a rule tree in the golly files as well.

...
One issue is that apgsearch takes around half an hour to compile for a R2 Moore rule on permute symmetry though I don't think that will occur for weighted rules on none symmetry.

You could also make use of your python script using convolutions.
I was afraid of exponential-sized ruletrees, but

now I realized ...

classical Primordia is R1;
with only 5 states,
there are /google 5 to the power of 9 == 1953125 situations,
that should be tractable
calling golly or maybe bgolly

and Gaussian: 32e6 situations,
that could be tractable

looks promising

BTW i don't have yet primordia using convolutions, but it is not difficult

edit: I thought also about generalizing primordia to range 2
Last edited by martin.novy on July 1st, 2020, 10:58 am, edited 1 time in total.

lemon41625
Posts: 344
Joined: January 24th, 2020, 7:39 am
Location: 小红点 (if you know where that is)

Re: (semi-)automated searches in rulespaces

Post by lemon41625 » July 1st, 2020, 10:12 am

martin.novy wrote:
July 1st, 2020, 10:06 am
and Gaussian: 32e6 situations,
that could be tractable
calling golly or maybe bgolly
Unfortunately, golly doesn't support R2 Moore neighbourhood in ruletables yet so you'll have to stick to lifelib for gaussian.
Download CAViewer: https://github.com/jedlimlx/Cellular-Automaton-Viewer

Supports:
BSFKL, Extended Generations, Regenerating Generations, Naive Rules, R1 Moore, R2 Cross and R2 Von Neumann INT
And some others...

User avatar
martin.novy
Posts: 142
Joined: October 22nd, 2014, 6:22 am
Location: Czechia, EU
Contact:

Re: (semi-)automated searches in rulespaces

Post by martin.novy » July 4th, 2020, 8:28 am

lemon41625 wrote:
July 1st, 2020, 9:40 am
martin.novy wrote:
July 1st, 2020, 6:47 am
for semi-automated searches of Gaussian and Primordia parameters
Some options:
...
or another option:
calling CAViewer's CAComputeParse.CACompute from a python script,
like I already did
viewtopic.php?f=9&t=4391&start=75#p96941

User avatar
martin.novy
Posts: 142
Joined: October 22nd, 2014, 6:22 am
Location: Czechia, EU
Contact:

Re: (semi-)automated searches in rulespaces

Post by martin.novy » July 28th, 2020, 7:34 am

bprentice wrote:
June 22nd, 2020, 4:13 pm
martin.novy wrote:
June 22nd, 2020, 10:37 am
I am interested in searching for rules (e.g. to find new rules with natural spaceships).
This is a very general request! Square Cell has this capability. Simply select a rule family and press the 'N' key.
...
@BPrentice:

(I should grep **.sqc in SquareCell.zip or maybe other zips?, but)

do you already have a subcollection of interesting rules with just 2 states or "generations-states" and 0/1 neigh. weights and state weights in range 2 ?

example what I mean:

Code: Select all

#Rule = Rule Table
#States = 2
#Counts = LESS-THAN-26
#SW 0,1
#NW 1,1,1,1,1
#NW 1,1,1,1,1
#NW 1,1,1,1,1
#NW 1,1,1,1,1
#NW 1,1,1,1,1

LifeViewer can now show them.

and would be even better for me ,than general R2 neighborhood: neighborhood: von Neumann or Circular

and would be the best: R2 neighborhood: Moore

Lifelib and apgsearch can do neighborhood: Moore
(HROT)

Why it is important for me:
one of the reasons:
I am doing an automated search for rules in R2 HROT, and I don't know:
whether to try B5 rules or not
how many "1"s in the #RT to try
etc.

Post Reply