Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Implement Column Pooler from htmresearch #94

Open
breznak opened this issue Nov 12, 2018 · 17 comments
Open

Implement Column Pooler from htmresearch #94

breznak opened this issue Nov 12, 2018 · 17 comments
Labels
CP Column pooler enhancement New feature or request

Comments

@breznak
Copy link
Member

breznak commented Nov 12, 2018

Column Pooler, CP, is implemented in python in HTM research. Used for sensory-motor experiments, it extends functionality of TM.

@breznak breznak added the enhancement New feature or request label Nov 12, 2018
@ctrl-z-9000-times
Copy link
Collaborator

Ive never heard of a column pooler, so what does it do? What features does the column pooler have which the SP / TM don't have?

@breznak
Copy link
Member Author

breznak commented Nov 12, 2018

there are papers on Column pooler and sensory-motor learning, "touch" experiments, invariant object representation. See eg https://numenta.com/assets/pdf/posters/CosynePoster_2017.pdf

@ctrl-z-9000-times
Copy link
Collaborator

We should incorporate the paper "Kropff & Treves 2008" into the column pooler. This paper describes simple modifications to the SP which make viewpoint invariance form naturally.

@Thanh-Binh
Copy link

@ctr-z-9000-times do you mean porting ColumnPooler from Python into c++? Or complete new ones?

@ctrl-z-9000-times
Copy link
Collaborator

I don't know, why do you ask? Im hoping to make a plan for this, but i dont have a plan yet.

@ctrl-z-9000-times
Copy link
Collaborator

ctrl-z-9000-times commented Jan 21, 2019

@Thanh-Binh ,

do you mean porting ColumnPooler from Python into c++? Or complete new ones?

I'd like to write the column pooler in C++, because C++ is fast and its the common language that all other languages have bindings for. After done, it should be very similar to the current python version.

Conceptually, the column pooler is similar to the (SP + TM) system; it does many of the same things. I hope we can copy-paste a lot of code from SP&TM to Column Pooler.

Python Column Pooler: https://github.com/numenta/htmresearch/blob/master/htmresearch/algorithms/column_pooler.py

@Thanh-Binh
Copy link

@ctr-z-9000-times: understood. The c++ porting is straight forwards

@ctrl-z-9000-times
Copy link
Collaborator

FYI: The column pooler should also implement multiple proximal segments. Each cell's overlap is the maximum of its segment's overlaps.

@ctrl-z-9000-times
Copy link
Collaborator

I've started work on branch columnPooler2
https://github.com/htm-community/nupic.cpp/tree/columnPooler2

See file: src/nupic/algorithms/ColumnPooler.cpp
So far it is an incomplete list of todo notes.

@ctrl-z-9000-times
Copy link
Collaborator

FYI everyone, the ColumnPooler should contain a complete and working SpatialPooler. To get just the SP functionality without any of the new stuff you'd use:

  • No distal segments, effectively disabling them
  • 1 proximal segment per neuron, each neuron is a mini-column in this context
  • Call cp.reset() before every use, which effectively disables the temporal aspects of the CP.

@Thanh-Binh, IIRC the Temporal Pooler was an early incarnation of the Column Pooler.

@breznak
Copy link
Member Author

breznak commented Feb 7, 2019

the ColumnPooler should contain a complete and working SpatialPooler.

does it have to, do we want to mix the functionality? Mostly if stuff like inhibition, boosting etc need to be implemented in CP.

OT, but if CP does need to implement the above for its own functionality, should we scratch the SP implementation and just make the class create instance of CP that acts as a SP as you described .. ?

o get just the SP functionality without any of the new stuff you'd use:

@ctrl-z-9000-times
Copy link
Collaborator

does it have to [...] ?

Yes. The column pooler needs everything in the SP and a more. In branch columnPooler2 where I'm keeping the work, I have copied the MNIST example and modified it to use a CP instead of an SP, and it currently scores 93% using all of the same parameters as the SP which scored 95%.

should we scratch the SP implementation?

No, at least not until the CP is far more complete, and we prove that it works as I'm advertising. Even if we could replace everything with it, it might be nice to keep the old stuff around for all of the same reasons why we will probably keep the python implementations of the algorithms.

@ctrl-z-9000-times
Copy link
Collaborator

More info about Kropff & Treves 2008:

@ctrl-z-9000-times
Copy link
Collaborator

I have a hypothesis about how the column pooler could function as a temporal memory. Im discussing it at https://discourse.numenta.org/t/column-pooler-as-a-temporal-memory/5384

@ctrl-z-9000-times
Copy link
Collaborator

Update: I have a prototype of the column pooler with the experimental changes described in the previous post. I'm testing it on sequence recognition where it currently scores 75% accuracy on a 50 category recognition task. I'm going to continue experimenting with the goal of making it work well enough to use in place of a temporal memory. Then I'm going to write a report about it.

@ctrl-z-9000-times
Copy link
Collaborator

I'd like to reproduce Numenta's Columns paper. They generate several artifical datasets to test their creation, which we should emulate. It does not need to be an exact reproduction, just close enough to verify the critical properties of the ColumnPooler. These properties include:

  • Network converges on a single answer, more columns helps converge faster.
  • Network recognizes objects, measure capacity.
  • Measure noise robustness.

https://www.frontiersin.org/articles/10.3389/fncir.2017.00081/full

@dkeeney
Copy link

dkeeney commented Mar 6, 2019

Sounds good to me. When you get the algorithm operational I will build a NetworkAPI plugin for it.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
CP Column pooler enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants