After cloned the newest nupic, and use some simple data test it, I have to say “what a awesome projec it is!”. This make me curious about how HTM works.
[Hierarchical-temporal-memory-cortical-learning-algorithm-0.2.1-cn] shown a neuron can abstract as HTM cell as right side .
This modeling process moving so fast ,and hard to understanding how do we get logical design in right side. So I try to break down it .
(one post only can add one picture, Please see reply below)
There comes question:
Follow the description of “Dendrite segments”,
“- A proximal dendrite segment forms synapses with feed-forward inputs. The active
synapses on this type of segment are linearly summed to determine the feedforward
activation of a column.”
1.If "segment are linearly summed " ,does this means input data in there is a int or float(more like a analog value) , not a binary 1-0(only true or false)?
2.how the synapses works in logic,Is synapses in feed forward is a gain or gate? there have 2 types of synapses defined? And the Proximal Dendrite works as ADD than OR there?
3.For Feedback Loop(feed from other cell,in HTM defined as a predictive trigger path to cell) .I can understand Distal Dendrites perform as gating by threshold, What’s the role of the synapses exactly in HTM ?
And follow the description of section “Permanence”:
“Synapses are forming and unforming constantly during learning. As mentioned
before, we assign a scalar value to each synapse (0.0 to 1.0) to indicate how
permanent the connection is. When a connection is reinforced, its permanence is
increased. Under other conditions, the permanence is decreased. When the
permanence is above a threshold (e.g. 0.2), the synapse is considered to be
established. If the permanence is below the threshold, the synapse will have no
effect.”
4.As this description synapses more like a “Three-state logic with a comparator in circuitry” and perform a “gate role” ,how?
Here are the answers to these questions from my understanding.
1- Input data is a binary vector. This is how the HTM is designed, it runs on digital representations for implementation simplicity, not analog. But this does not mean that a binary vector cannot encapsulate an int or a float. You just need to encode your input value to a binary vector with arbitrary dimension. You can read about scalar encoding for a better grasp about for example converting scalar values into binary vectors.
To summarize, the input data is always binary vector but that binary vector can represent anything from a float to an abstract structure or the neural activation within a cortical layer.
The linear summing part involves adding the number of active bits (1’s) that a column is connected to on the input data. Imagine you have an input data of 1024 bits (binary vector). Let’s say the proximal dendrite of every column has around 100 synapses. In other words, every column is connected to 100 input bits among the input data. To compute the overlap/feedforward activation of every column with this input field, you would need to add all the active bits/synapses of it’s proximal dendrite. Out of 100 synapses on the proximal dendrites, if only 20 of them are active (meaning those input bits are 1) the feedforward activation for that particular column would be 20. So the feedforward activation is the linear sum of the active bits. In other words, the number of active bits on the proximal dendrite.
2- I updated your diagram based on my understanding. I believe this is more inline with HTM.
3- The role of distal dendrites is to predict the next neural activation based on the current activation through forming synapses between them. Check out the diagrams at page 5 in the paper below, I think those are the easiest way to understand.
4- The permanence is a scalar value. It can be represented by a floating point value between 0 and 1. It can also be represented by an integer inside some chosen interval such as 0 and 10000. In both cases there is a threshold value that controls the actual connection of the synapse. It is more like a two state logic. A synapse is either connected or disconnected. It gets connected after the permanence of the synapse exceed the preset threshold. For example, if the permanence is represented by a float between 0 and 1, the connection threshold can be set 0.2.
Again, these explanations are based on my own understanding.
Great thanks for your explanation . This help a lot.
I plan to start a standalone HTM implement for mobile device ,Before that I need to clarity whole picture of HTM.
For input data type, As the video you shared,HTM need transform input data into the form of serialized binary pattern by scalar encoding. Then mapping pattern as column activate representation. So each cell input accept a scalar encoded bit.
But this bring out questions:
1.Does SDR process have a mathematics explain?
2.Does SDR process make a one-one mapping?
3.Can we calculate the serial binary data from a certain column activation map? 4.As the description HTM doesn’t understand what input ,only restrict with “time sequence”, This seems HTM can ignore raw data encoding method (even the raw data been hashed before input), HTM network still can make the prediction.Do we have any mathematics support there?
One SDR process (without predirection’s case), HTM used a inhibitory concept to make competed cell column activation generate the representation map, Is this "inhibitory " simulated chemical process in neuron?
It depends on how many different combinations are there in the sensed data, combination count to column/cell count ratio and the activation thresholds. In the best case, yes you can and I have done it to reconstruct the input data from activation. But ideally, for a HTM to differentiate between what is important and what is noise inside the data, you wouldn’t want to be able reconstruct the complete input data from the activation. If the HTM you are working with can do that, it also means the HTM is not actually learning the abstract information about the data which is the main goal.
Generally a fuzzy version of the input data can be reconstructed from the activation because that is how it functions. It just generates more and more abstract representations about temporal and spatial information. You can extract the “big picture” from the activation but the details would be lost, and more importantly, should be lost. If you really need to reconstruct the exact input data from the activation, CLA/HTM is not the best way to do it as it is designed to do the opposite. Think of it as the dinner you had yesterday. Can you construct the complete audio visual stimuli from your memory? Probably not and why would you want to? Is the resolution of that fuzzy memory (activation) about that dinner enough for you to work with it? Depends on the goal.
I do not quite get your question, maybe you can try it in different words. Still, “what input” is not independent from its time sequence. Because things are represented with their context (sequence) in HTM and that is what makes it powerful and different from other approaches. Same red stimuli would mean love or blood in different contexts.
To generalize very badly;
spatial pooling / columnar activation / proximal dendrites encodes the what input
The inhibition is one of the biological backbones of HTM to create the competitive environment. So I would say yes. As far as I know, there are inhibitory cells that create the competition between the neurons. If I am not mistaken, the inhibition is carried out by the inhibitory cells on a macro column scale. Cells do not inhibit themselves, there are specialized cells for inhibiting others throughout the columns/layers. Maybe a more knowledgeable person could shed light on this.
The current implementations are just artificial inhibitions for the top overlapped/activated columns in whatever way we please without any strict biological constraints. There was a gentleman, Hideaki Suzuki who made a study about a faster and more biologically plausible local inhibition approach which I have also tried back in 2013 Numenta mailing lists.
Also, SDR is not a process and I am not sure what do you mean by saying SDR process. It is just a representation type as in Sparse Distributed Representation.
Thanks for reply.
“SDR process” should be a translation mistake(chinese thinking-logical issue), I just want to describe the process on generate a SDR representation.For question 3, I already got answer from the paper ,Please ignore it.