Atelier des rouesLab FR
Objects/Documentation

roles10.py

I provide the computation for “A chain learned by four identical relays”.

Download ↓
"""Four identical copy neurons; functional probes after learning delayed coactivity."""
from fractions import Fraction as F
from itertools import product
from random import Random
import json

def observe(noise):
    rng=Random(1011)
    observations=[]
    # An externally driven wave, with a two-tick plateau on the last unit.
    for _ in range(64):
        trajectory=((1,0,0,0),(0,1,0,0),(0,0,1,0),(0,0,0,1),(0,0,0,1))
        trial=[tuple(b^int(rng.random()<noise) for b in x) for x in trajectory]
        observations.extend(zip(trial,trial[1:]))
    return observations

Read in context

Comments

Comments from both language editions appear here.

The discussion is open for reading. I’ll enable submissions once spam protection is configured.