How does cells in TemopralMemory grow new distal connections to other cells?

I’m working on a pure numpy implementation of HTM algorithms (Then I can port the algorithm to TVM and by that running on a GPU). I have finished reading the HTM white-paper. However I can’t find how distal connections between cells are created and deleted. The document includes description about how the permanence changes, yet none about creating/deleting connections.

How is connections created and deleted? Or are all connection created when the layer is initialized and only the permanence change.

That appears to be an obsolete version of the algorithm. I would start with the TM algorithm details from BAMI instead.

That said, the function in that paper which creates new connections:

getSegmentActiveSynapses(c, i, t, s, newSynapses= false) Return a segmentUpdate data structure containing a list of proposed changes to segment s. Let activeSynapses be the list of active synapses where the originating cells have their activeState output = 1 at time step t. (This list is empty if s = -1 since the segment doesn’t exist.) newSynapses is an optional argument that defaults to false. If newSynapses is true, then newSynapseCount - count(activeSynapses) synapses are added to activeSynapses. These synapses are randomly chosen from the set of cells that have learnState output = 1 at time step t.

Connections once created are not deleted in the algorithm (permanence just goes below threshold)

1 Like

Thanks! Yeah… the white paper is old.

So that’s why HTM runs slower and slower as learning goes on…

You can set parameters to forget, or trim segments and synapses manually if you know what you’re doing.