<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE article PUBLIC "-//NLM//DTD Journal Publishing DTD v2.3 20070202//EN" "journalpublishing.dtd">
<article xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink" article-type="research-article">
<front>
<journal-meta>
<journal-id journal-id-type="publisher-id">Front. Robot. AI</journal-id>
<journal-title>Frontiers in Robotics and AI</journal-title>
<abbrev-journal-title abbrev-type="pubmed">Front. Robot. AI</abbrev-journal-title>
<issn pub-type="epub">2296-9144</issn>
<publisher>
<publisher-name>Frontiers Media S.A.</publisher-name>
</publisher>
</journal-meta>
<article-meta>
<article-id pub-id-type="doi">10.3389/frobt.2016.00081</article-id>
<article-categories>
<subj-group subj-group-type="heading">
<subject>Robotics and AI</subject>
<subj-group>
<subject>Original Research</subject>
</subj-group>
</subj-group>
</article-categories>
<title-group>
<article-title>A Mathematical Formalization of Hierarchical Temporal Memory&#x02019;s Spatial Pooler</article-title>
</title-group>
<contrib-group>
<contrib contrib-type="author" corresp="yes">
<name><surname>Mnatzaganian</surname> <given-names>James</given-names></name>
<xref ref-type="aff" rid="aff1"><sup>1</sup></xref>
<xref ref-type="corresp" rid="cor1">&#x0002A;</xref>
<uri xlink:href="http://frontiersin.org/people/u/373983"/>
</contrib>
<contrib contrib-type="author">
<name><surname>Fokou&#x000E9;</surname> <given-names>Ernest</given-names></name>
<xref ref-type="aff" rid="aff2"><sup>2</sup></xref>
<uri xlink:href="http://frontiersin.org/people/u/336841"/>
</contrib>
<contrib contrib-type="author">
<name><surname>Kudithipudi</surname> <given-names>Dhireesha</given-names></name>
<xref ref-type="aff" rid="aff1"><sup>1</sup></xref>
</contrib>
</contrib-group>
<aff id="aff1"><sup>1</sup><institution>NanoComputing Research Laboratory, Computer Engineering Department, Kate Gleason College of Engineering, Rochester Institute of Technology</institution>, <addr-line>Rochester, NY</addr-line>, <country>USA</country></aff>
<aff id="aff2"><sup>2</sup><institution>Data Science Research Group, School of Mathematical Sciences, College of Science, Rochester Institute of Technology</institution>, <addr-line>Rochester, NY</addr-line>, <country>USA</country></aff>
<author-notes>
<fn fn-type="edited-by"><p>Edited by: Christof Teuscher, Portland State University, USA</p></fn>
<fn fn-type="edited-by"><p>Reviewed by: Ashley Prater, United States Air Force Research Laboratory, USA; Subutai Ahmad, Numenta Inc., USA</p></fn>
<corresp content-type="corresp" id="cor1">&#x0002A;Correspondence: James Mnatzaganian, <email>jamesmnatzaganian&#x00040;outlook.com</email></corresp>
<fn fn-type="other" id="fn001"><p>Specialty section: This article was submitted to Computational Intelligence, a section of the journal Frontiers in Robotics and AI</p></fn>
</author-notes>
<pub-date pub-type="epub">
<day>30</day>
<month>01</month>
<year>2017</year>
</pub-date>
<pub-date pub-type="collection">
<year>2016</year>
</pub-date>
<volume>3</volume>
<elocation-id>81</elocation-id>
<history>
<date date-type="received">
<day>08</day>
<month>09</month>
<year>2016</year>
</date>
<date date-type="accepted">
<day>26</day>
<month>12</month>
<year>2016</year>
</date>
</history>
<permissions>
<copyright-statement>Copyright &#x000A9; 2017 Mnatzaganian, Fokou&#x000E9; and Kudithipudi.</copyright-statement>
<copyright-year>2017</copyright-year>
<copyright-holder>Mnatzaganian, Fokou&#x000E9; and Kudithipudi</copyright-holder>
<license xlink:href="http://creativecommons.org/licenses/by/4.0/"><p>This is an open-access article distributed under the terms of the Creative Commons Attribution License (CC BY). The use, distribution or reproduction in other forums is permitted, provided the original author(s) or licensor are credited and that the original publication in this journal is cited, in accordance with accepted academic practice. No use, distribution or reproduction is permitted which does not comply with these terms.</p></license>
</permissions>
<abstract>
<p>Hierarchical temporal memory (HTM) is an emerging machine learning algorithm, with the potential to provide a means to perform predictions on spatiotemporal data. The algorithm, inspired by the neocortex, currently does not have a comprehensive mathematical framework. This work brings together all aspects of the spatial pooler (SP), a critical learning component in HTM, under a single unifying framework. The primary learning mechanism is explored, where a maximum likelihood estimator for determining the degree of permanence update is proposed. The boosting mechanisms are studied and found to be a secondary learning mechanism. The SP is demonstrated in both spatial and categorical multi-class classification, where the SP is found to perform exceptionally well on categorical data. Observations are made relating HTM to well-known algorithms such as competitive learning and attribute bagging. Methods are provided for using the SP for classification as well as dimensionality reduction. Empirical evidence verifies that given the proper parameterizations, the SP may be used for feature learning.</p>
</abstract>
<kwd-group>
<kwd>hierarchical temporal memory</kwd>
<kwd>spatial pooler</kwd>
<kwd>machine learning</kwd>
<kwd>neural networks</kwd>
<kwd>self-organizing feature maps</kwd>
<kwd>unsupervised learning</kwd>
</kwd-group>
<counts>
<fig-count count="8"/>
<table-count count="4"/>
<equation-count count="34"/>
<ref-count count="22"/>
<page-count count="14"/>
<word-count count="11719"/>
</counts>
</article-meta>
</front>
<body>
<sec id="S1" sec-type="introduction">
<label>1</label> <title>Introduction</title>
<p>Hierarchical temporal memory (HTM), created by Hawkins and George (<xref ref-type="bibr" rid="B10">2007</xref>), is a machine learning algorithm that was inspired by the neocortex and designed to learn sequences and make predictions. In its idealized form, it should be able to produce generalized representations for similar inputs. Given time-series data, HTM should be able to use its learned representations to perform a type of time-dependent regression. Such a system would prove to be incredibly useful in many applications utilizing spatiotemporal data. One instance for using HTM with time-series data was recently demonstrated by Cui et al. (<xref ref-type="bibr" rid="B5">2016</xref>), where HTM was used to predict taxi passenger counts. Lavin and Ahmad (<xref ref-type="bibr" rid="B14">2015</xref>), additionally, used HTM for anomaly detection. HTM&#x02019;s prominence in the machine learning community has been hampered, largely due to the evolving nature of HTM&#x02019;s algorithmic definition and the lack of a formalized mathematical model. This work aims to bridge the gap between a neuroscience inspired algorithm and a math-based algorithm by constructing a purely mathematical framework around HTM&#x02019;s original algorithmic definition.</p>
<p>HTM models at a high-level, some of the structures and functionality of the neocortex. Its structure follows that of the cortical minicolumns, where an HTM region is comprised of many columns, each consisting of multiple cells. One or more regions form a level. Levels are stacked hierarchically in a tree-like structure to form the full network depicted in Figure <xref ref-type="fig" rid="F1">1</xref>. Within HTM, connections are made <italic>via</italic> synapses, where both proximal and distal synapses are utilized to form feedforward and neighboring connections, respectively.</p>
<fig position="float" id="F1">
<label>Figure 1</label>
<caption><p><bold>Depiction of HTM, showing the various levels of detail</bold>.</p></caption>
<graphic xlink:href="frobt-03-00081-g001.tif"/>
</fig>
<p>The current version of HTM is the successor to HTM cortical learning algorithm (Hawkins et al., <xref ref-type="bibr" rid="B9">2011</xref>). In the current version of HTM, the two primary algorithms are the spatial pooler (SP) and the temporal memory (TM). The SP is responsible for taking an input, in the format of a sparse distributed representation (SDR), and producing a new SDR, where an SDR is a binary vector typically having a sparse number of active bits, i.e., a bit with a value of &#x0201C;1&#x0201D; (Ahmad and Hawkins, <xref ref-type="bibr" rid="B1">2015</xref>). In this manner, the SP can be viewed as a mapping function from the input domain to a new feature domain. In the feature domain, a single SDR should be used to represent similar SDRs from the input domain. The algorithm is a type of unsupervised competitive learning algorithm (Rumelhart and Zipser, <xref ref-type="bibr" rid="B20">1985</xref>) that uses a form of vector quantization (Gersho and Gray, <xref ref-type="bibr" rid="B7">2012</xref>) resembling self-organizing maps (Kohonen, <xref ref-type="bibr" rid="B12">1982</xref>). The TM is responsible for learning sequences and making predictions. This algorithm follows Hebb&#x02019;s rule (Hebb, <xref ref-type="bibr" rid="B11">1949</xref>), where connections are formed between cells that were previously active. Through the formation of those connections, a sequence may be learned. The TM can then use its learned knowledge of the sequences to form predictions.</p>
<p>HTM originated as an abstraction of the neocortex; as such, it does not have an explicit mathematical formulation. Without a mathematical framework, it is difficult to understand the key characteristics of the algorithm and how it can be improved. In general, very little work exists regarding the mathematics behind HTM. Hawkins and Ahmad (<xref ref-type="bibr" rid="B8">2016</xref>) recently provided a starting mathematical formulation for the TM. Ahmad and Hawkins (<xref ref-type="bibr" rid="B1">2015</xref>) additionally provided some initial formalizations for the SP. Lattner (<xref ref-type="bibr" rid="B13">2014</xref>) provided an initial insight about the SP, by relating it to vector quantization. He additionally provided some equations governing computing overlap and performing learning; however, those equations were not generalized to account for local inhibition. Byrne (<xref ref-type="bibr" rid="B4">2015</xref>) began the use of matrix notation and provided a basis for those equations; however, certain components of the algorithm, such as boosting, were not included. Leake et al. (<xref ref-type="bibr" rid="B15">2015</xref>) provided some insights regarding the initialization of the SP. He also provided further insights into how the initialization may affect the initial calculations within the network; however, his focus was largely on the network initialization. The goal of this work is to provide a complete mathematical framework for HTM&#x02019;s SP and to demonstrate how it may be used in various machine learning tasks. Having a mathematical framework creates a basis for future algorithmic improvements, allows for a more efficient software implementation, and eases the path for hardware engineers to develop scalable HTM hardware.</p>
<p>The major, novel contributions provided by this work are as follows:
<list list-type="bullet">
<list-item><p>Creation of a complete mathematical framework for the SP, including boosting and local inhibition.</p></list-item>
<list-item><p>Using the SP to perform feature learning.</p></list-item>
<list-item><p>Using the SP as a preprocessor for non-spatial (categorical) data.</p></list-item>
<list-item><p>Creation of a possible mathematical explanation for the permanence update amount.</p></list-item>
<list-item><p>Insights into the permanence selection.</p></list-item>
</list></p>
</sec>
<sec id="S2">
<label>2</label> <title>Spatial Pooler Algorithm</title>
<p>The SP consists of three phases, namely overlap, inhibition, and learning. In this section, the three phases will be presented based off their original, algorithmic definition. This algorithm follows an iterative, online approach, where the learning updates occur after the presentation of each input. Before the execution of the algorithm, some initializations must take place.</p>
<p>Within an SP, there exist many columns. Each column has a unique set of proximal synapses connected <italic>via</italic> a proximal dendrite segment. Each proximal synapse tentatively connects to a single column from the input, i.e., each column in the SP connects to a specific attribute within the input. The input column&#x02019;s activity level is used as the synaptic input, i.e., an active column is a &#x0201C;1&#x0201D; and an inactive column is a &#x0201C;0&#x0201D;.</p>
<p>To determine whether a synapse is connected or not, the synapse&#x02019;s permanence value is checked. If the permanence value is at least equal to the connected threshold the synapse is connected; otherwise, it is unconnected. The permanence values are scalars in the closed interval [0, 1].</p>
<p>Prior to the first execution of the algorithm, the potential connections of proximal synapses to the input space and the initial permanence values must be determined. Following Hawkins et al. (<xref ref-type="bibr" rid="B9">2011</xref>), each synapse is randomly connected to a unique attribute in the input, i.e., the number of synapses per column and the number of attributes are binomial coefficients. The permanences of the synapses are then randomly initialized to a value close to the connected permanence threshold. The permanences are then adjusted such that shorter distances between the SP column&#x02019;s position and the input column&#x02019;s position will result in larger initial permanence values. The three phases of the SP are explained in the following subsections.</p>
<sec id="S2-1">
<label>2.1</label> <title>Phase 1: Overlap</title>
<p>The first phase of the SP is used to compute the overlap between each column and its respective input, as shown in Algorithm <xref ref-type="table" rid="AL1">1</xref>. In Algorithm <xref ref-type="table" rid="AL1">1</xref>, the SP is represented by the object <italic>sp</italic>. The method <italic>col</italic>.connected_synapses() returns an instance to each synapse on <italic>col</italic>&#x02019;s proximal segment that is connected, i.e., synapses having permanence values greater than the permanence connected threshold, <italic>psyn_th</italic>. The method <italic>syn</italic>.active() returns &#x0201C;1&#x0201D; if <italic>syn</italic>&#x02019;s input is active and &#x0201C;0&#x0201D; otherwise. <italic>pseg_th</italic><xref ref-type="fn" rid="fn1"><sup>1</sup></xref> is a parameter that determines the activation threshold of a proximal segment, such that there must be at least <italic>pseg_th</italic> active connected proximal synapses on a given proximal segment for it to become active. The parameter <italic>col.boost</italic> is the boost value for <italic>col</italic>, which is initialized to &#x0201C;1&#x0201D;.</p>
<table-wrap position="float" id="AL1">
<label>Algorithm 1</label>
<caption><p><bold>SP phase 1: overlap</bold>.</p></caption>
<table frame="hsides" rules="groups">
<tbody>
<tr>
<td align="left">1: <bold>for all</bold> <italic>col</italic> &#x02208;&#x02009;<italic>sp.columns</italic> <bold>do</bold></td>
</tr>
<tr>
<td align="left">2:&#x02003;&#x02003;<italic>col.overlap</italic> &#x02190;&#x02009;0</td>
</tr>
<tr>
<td align="left">3:&#x02003;&#x02003;<bold>for all</bold> <italic>syn</italic> &#x02208;&#x02009;<italic>col</italic>.connected_synapses(&#x02009;) <bold>do</bold></td>
</tr>
<tr>
<td align="left">4:&#x02003;&#x02003;&#x02003;&#x02003;<italic>col.overlap</italic> &#x02190;&#x02009;<italic>col.overlap</italic> &#x0002B; <italic>syn</italic>.active(&#x02009;)</td>
</tr>
<tr>
<td align="left">5:&#x02003;&#x02003;<bold>if</bold> <italic>col.overlap</italic> &#x0003C; <italic>pseg</italic>_<italic>th</italic> <bold>then</bold></td>
</tr>
<tr>
<td align="left">6:&#x02003;&#x02003;&#x02003;&#x02003;<italic>col.overlap</italic> &#x02190;&#x02009;0</td>
</tr>
<tr>
<td align="left">7:&#x02003;&#x02003;<bold>else</bold></td>
</tr>
<tr>
<td align="left">8:&#x02003;&#x02003;&#x02003;&#x02003;<italic>col.overlap</italic> &#x02190;&#x02009;<italic>col.overlap</italic> &#x02217; <italic>col.boost</italic></td>
</tr>
</tbody>
</table>
</table-wrap>
</sec>
<sec id="S2-2">
<label>2.2</label> <title>Phase 2: Inhibition</title>
<p>The second phase of the SP is used to compute the set of active columns after they have been inhibited, as shown in Algorithm <xref ref-type="table" rid="AL2">2</xref>. In Algorithm <xref ref-type="table" rid="AL2">2</xref>, kmax_overlap(<italic>C, k</italic>) is a function that returns the <italic>k</italic>-th largest overlap of the columns in <italic>C</italic>. The method <italic>sp</italic>.neighbors(<italic>col</italic>) returns the columns that are within <italic>col</italic>&#x02019;s neighborhood, including <italic>col</italic>, where the size of the neighborhood is determined by the inhibition radius. The parameter <italic>k</italic> is the desired column activity level. In line 2 in Algorithm <xref ref-type="table" rid="AL2">2</xref>, the <italic>k</italic>-th largest overlap value out of <italic>col</italic>&#x02019;s neighborhood is being computed. A column is then said to be active if its overlap value is greater than zero and the computed minimum overlap, <italic>mo</italic>.</p>
<table-wrap position="float" id="AL2">
<label>Algorithm 2</label>
<caption><p><bold>SP phase 2: inhibition</bold>.</p></caption>
<table frame="hsides" rules="groups">
<tbody>
<tr>
<td align="left">1: <bold>for all</bold> col &#x02208;&#x02009;<italic>sp.columns</italic> <bold>do</bold></td>
</tr>
<tr>
<td align="left">2:&#x02003;&#x02003;<italic>mo</italic>&#x02009;&#x02190;&#x02009;kmax_overlap(<italic>sp</italic>.neighbors(<italic>col</italic>), <italic>k</italic>)</td>
</tr>
<tr>
<td align="left">3:&#x02003;&#x02003;<bold>if</bold> <italic>col.overlap</italic> &#x0003E; 0 <bold>and</bold> <italic>col.overlap</italic> &#x02265;&#x02009;<italic>mo</italic> <bold>then</bold></td>
</tr>
<tr>
<td align="left">4:&#x02003;&#x02003;&#x02003;&#x02003;<italic>col.active</italic> &#x02190;&#x02009;1</td>
</tr>
<tr>
<td align="left">5:&#x02003;&#x02003;<bold>else</bold></td>
</tr>
<tr>
<td align="left">6:&#x02003;&#x02003;&#x02003;&#x02003;<italic>col.active</italic> &#x02190;&#x02009;0</td>
</tr>
</tbody>
</table>
</table-wrap>
</sec>
<sec id="S2-3">
<label>2.3</label> <title>Phase 3: Learning</title>
<p>The third phase of the SP is used to conduct the learning operations, as shown in Algorithm <xref ref-type="table" rid="AL3">3</xref>. This code contains three parts &#x02013; permanence adaptation, boosting operations, and the inhibition radius update. In Algorithm <xref ref-type="table" rid="AL3">3</xref>, <italic>syn.p</italic> refers to the permanence value of <italic>syn</italic>. The functions min and max return the minimum and maximum values of their arguments, respectively, and are used to keep the permanence values bounded in the closed interval [0, 1]. The constants <italic>syn.psyn_inc</italic> and <italic>syn.psyn_dec</italic> are the proximal synapse permanence increment and decrement amounts, respectively.</p>
<table-wrap position="float" id="AL3">
<label>Algorithm 3</label>
<caption><p><bold>SP phase 3: learning</bold>.</p></caption>
<table frame="hsides" rules="groups">
<tbody>
<tr>
<td align="left">&#x02003;&#x00023; Adapt permanences</td>
</tr>
<tr>
<td align="left">1: <bold>for all</bold> <italic>col</italic> &#x02208;&#x02009;<italic>sp.columnns</italic> <bold>do</bold></td>
</tr>
<tr>
<td align="left">2:&#x02003;&#x02003;<bold>if</bold> <italic>col.active</italic> <bold>then</bold></td>
</tr>
<tr>
<td align="left">3:&#x02003;&#x02003;&#x02003;&#x02003;<bold>for all</bold> <italic>syn</italic> &#x02208;&#x02009;<italic>col.synapses</italic> <bold>do</bold></td>
</tr>
<tr>
<td align="left">4:&#x02003;&#x02003;&#x02003;&#x02003;&#x02003;&#x02003;<bold>if</bold> <italic>syn</italic>.active(&#x02009;) <bold>then</bold></td>
</tr>
<tr>
<td align="left">5:&#x02003;&#x02003;&#x02003;&#x02003;&#x02003;&#x02003;&#x02003;&#x02003;<italic>syn.p</italic> &#x02190;&#x02009;min (1, <italic>syn.p</italic> &#x0002B; <italic>syn.psyn_inc</italic>)</td>
</tr>
<tr>
<td align="left">6:&#x02003;&#x02003;&#x02003;&#x02003;&#x02003;&#x02003;<bold>else</bold></td>
</tr>
<tr>
<td align="left">7:&#x02003;&#x02003;&#x02003;&#x02003;&#x02003;&#x02003;&#x02003;&#x02003;<italic>syn.p</italic> &#x02190;&#x02009;max (0, <italic>syn.p</italic> &#x02212;<italic>syn.psyn_dec</italic>)</td>
</tr>
<tr>
<td align="left">&#x02003;&#x00023; Perform boosting operations</td>
</tr>
<tr>
<td align="left">8: <bold>for all</bold> col &#x02208;&#x02009;<italic>sp.columns</italic> <bold>do</bold></td>
</tr>
<tr>
<td align="left">9:&#x02003;&#x02003;<italic>col.mdc</italic> &#x02190;&#x02009;0.01 &#x02217; max_adc(<italic>sp</italic>.neighbors(<italic>col</italic>))</td>
</tr>
<tr>
<td align="left">10:&#x02003;&#x02003;<italic>col</italic>.update_active_duty_cycle(&#x02009;)</td>
</tr>
<tr>
<td align="left">11:&#x02003;&#x02003;<italic>col</italic>.update_boost(&#x02009;)</td>
</tr>
<tr>
<td align="left">12:&#x02003;&#x02003;<italic>col</italic>.update_overlap_duty_cycle(&#x02009;)</td>
</tr>
<tr>
<td align="left">13:&#x02003;&#x02003;<bold>if</bold> <italic>col.odc</italic> &#x0003C; <italic>col.mdc</italic> <bold>then</bold></td>
</tr>
<tr>
<td align="left">14:&#x02003;&#x02003;&#x02003;&#x02003;<bold>for all</bold> <italic>syn</italic> &#x02208;&#x02009;<italic>col.synapses</italic> <bold>do</bold></td>
</tr>
<tr>
<td align="left">15:&#x02003;&#x02003;&#x02003;&#x02003;&#x02003;&#x02003;<italic>syn.p</italic> &#x02190;&#x02009;min(1; <italic>syn.p</italic> &#x0002B; 0.1 &#x02217; <italic>psyn_th</italic>)</td>
</tr>
<tr>
<td align="left">16: <italic>sp</italic>.update_inhibition_radius(&#x02009;)</td>
</tr>
</tbody>
</table>
</table-wrap>
<p>The function max_adc(<italic>C</italic>) returns the maximum active duty cycle of the columns in <italic>C</italic>, where the active duty cycle is a moving average denoting the frequency of column activation. Similarly, the overlap duty cycle is a moving average denoting the frequency of the column&#x02019;s overlap value being at least equal to the proximal segment activation threshold. The functions <italic>col</italic>.update_active_duty_cycle() and <italic>col</italic>.update_overlap_duty_ cycle() are used to update the active and overlap duty cycles, respectively, by computing the new moving averages. The parameters <italic>col.odc</italic>, <italic>col.adc</italic>, and <italic>col.mdc</italic> refer to <italic>col</italic>&#x02019;s overlap duty cycle, active duty cycle, and minimum duty cycle, respectively. Those duty cycles are used to ensure that columns have a certain degree of activation.</p>
<p>The method <italic>col</italic>.update_boost() is used to update the boost for column, <italic>col</italic>, as shown in Algorithm <xref ref-type="table" rid="AL4">4</xref>, where <italic>maxb</italic> refers to the maximum boost value. It is important to note that the whitepaper did not explicitly define how the boost should be computed. This boost function was obtained from the source code of Numenta&#x02019;s implementation of HTM, Numenta platform for intelligent computing (NuPIC) (Numenta, <xref ref-type="bibr" rid="B18">2016</xref>).</p>
<table-wrap position="float" id="AL4">
<label>Algorithm 4</label>
<caption><p><bold>Boost update: <italic>col</italic>.update_boost(&#x02009;)</bold>.</p></caption>
<table frame="hsides" rules="groups">
<tbody>
<tr>
<td align="left">1: <bold>if</bold> <italic>col.mdc</italic> &#x0003D; &#x0003D; 0 <bold>then</bold></td>
</tr>
<tr>
<td align="left">2:&#x02003;&#x02003;<italic>col.boost</italic> &#x02190;&#x02009;<italic>maxb</italic></td>
</tr>
<tr>
<td align="left">3: <bold>else if</bold> <italic>col.adc</italic> &#x0003E; <italic>col.mdc</italic> <bold>then</bold></td>
</tr>
<tr>
<td align="left">4:&#x02003;&#x02003;<italic>col.boost</italic> &#x02190;&#x02009;1</td>
</tr>
<tr>
<td align="left">5: <bold>else</bold></td>
</tr>
<tr>
<td align="left">6:&#x02003;&#x02003;<italic>col.boost</italic> &#x0003D; <italic>col.adc</italic> &#x02217; ((1&#x02212;<italic>maxb</italic>)/<italic>col.mdc</italic>) &#x0002B; <italic>maxb</italic></td>
</tr>
</tbody>
</table>
</table-wrap>
<p>The method <italic>sp</italic>.update_inhibition_radius() is used to update the inhibition radius. The inhibition radius is set to the average receptive field size, which is average distance between all connected synapses and their respective columns in the input and the SP.</p>
</sec>
</sec>
<sec id="S3">
<label>3</label> <title>Mathematical Formalization</title>
<p>The aforementioned operation of the SP lends itself to a vectorized notation. By redefining the operations to work with vectors it is possible not only to create a mathematical representation but also to greatly improve upon the efficiency of the operations. The notation described in this section will be used as the notation for the remainder of the document.</p>
<p>All vectors will be lowercase, bold-faced letters with an arrow hat. Vectors are assumed to be row vectors, such that the transpose of the vector will produce a column vector. All matrices will be uppercase, bold-faced letters. Subscripts on vectors and matrices are used to denote where elements are being indexed, following a row&#x02013;column convention, such that <bold><italic>X</italic></bold><italic><sub>i,j</sub></italic>&#x02009;&#x02208;&#x02009;<bold><italic>X</italic></bold> refers to <bold><italic>X</italic></bold> at row index<xref ref-type="fn" rid="fn2"><sup>2</sup></xref> <italic>i</italic> and column index <italic>j</italic>. Similarly, <bold><italic>X</italic></bold><italic><sub>i</sub></italic> is a row vector containing all elements in row <italic>i</italic>. The symbols &#x02299; and &#x02295; are used to represent element-wise multiplication and addition, respectively. Element-wise operations between a vector and a matrix are performed columnwise, such that <inline-formula><mml:math id="M1"><mml:mrow><mml:msup><mml:mover accent='true'><mml:mi mathvariant="bold-italic">x</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mi>T</mml:mi></mml:msup><mml:mo>&#x02299;</mml:mo><mml:mi mathvariant="bold-italic">Y</mml:mi><mml:mo>=</mml:mo><mml:msub><mml:mover accent='true'><mml:mi mathvariant="bold-italic">x</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mi>i</mml:mi></mml:msub><mml:msub><mml:mi mathvariant="bold-italic">Y</mml:mi><mml:mrow><mml:mi>i</mml:mi><mml:mo>,</mml:mo><mml:mi>j</mml:mi></mml:mrow></mml:msub><mml:mtext>&#x02009;</mml:mtext><mml:msub><mml:mo>&#x02200;</mml:mo><mml:mi>i</mml:mi></mml:msub><mml:msub><mml:mo>&#x02200;</mml:mo><mml:mi>j</mml:mi></mml:msub></mml:mrow></mml:math></inline-formula>.</p>
<p>Let I(<italic>k</italic>) be defined as the indicator function, such that the function will return 1 if event <italic>k</italic> is true and 0 otherwise. If the input to this function is a vector of events or a matrix of events, each event will be evaluated independently, with the function returning a vector or matrix of the same size as its input. Any variable with a superscript in parentheses is used to denote the type of that variable. For example, <inline-formula><mml:math id="M2"><mml:mrow><mml:msup><mml:mover accent='true'><mml:mi mathvariant="bold-italic">x</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mrow><mml:mrow><mml:mo>(</mml:mo><mml:mi>y</mml:mi><mml:mo>)</mml:mo></mml:mrow></mml:mrow></mml:msup></mml:mrow></mml:math></inline-formula> is used to state that the variable <inline-formula><mml:math id="M3"><mml:mover accent='true'><mml:mi mathvariant="bold-italic">x</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula> is of type <italic>y</italic>. In the event that an operation has a before and after the states will be denoted using superscripts, such that <inline-formula><mml:math id="M4"><mml:msup><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">x</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mi>i</mml:mi></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:mrow></mml:msup></mml:math></inline-formula> and <inline-formula><mml:math id="M5"><mml:msup><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">x</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mi>f</mml:mi></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:mrow></mml:msup></mml:math></inline-formula> will represent the initial and final versions of <inline-formula><mml:math id="M6"><mml:mover accent='true'><mml:mi mathvariant="bold-italic">x</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula>, respectively.</p>
<p>All of the user-defined parameters are defined in Table <xref ref-type="table" rid="T1">1</xref>.<xref ref-type="fn" rid="fn3"><sup>3</sup></xref> These are parameters that must be defined before the initialization of the algorithm. All of those parameters are constants. Let the terms <italic>s</italic>, <italic>a</italic>, <italic>i</italic>, <italic>j</italic>, and <italic>k</italic> be defined as integer indices. They are henceforth bounded as follows: <italic>s</italic>&#x02009;&#x02208;&#x02009;[0, <italic>n<sub>s</sub></italic>), <italic>a</italic>&#x02009;&#x02208;&#x02009;[0, <italic>n<sub>a</sub></italic>), <italic>i</italic>&#x02009;&#x02208;&#x02009;[0, <italic>n<sub>c</sub></italic>), <italic>j</italic>&#x02009;&#x02208;&#x02009;[0, <italic>n<sub>c</sub></italic>], and <italic>k</italic>&#x02009;&#x02208;&#x02009;[0, <italic>n<sub>ps</sub></italic>).</p>
<table-wrap position="float" id="T1">
<label>Table 1</label>
<caption><p><bold>User-defined parameters for the SP</bold>.</p></caption>
<table frame="hsides" rules="groups">
<thead>
<tr>
<th align="left" valign="top">Parameter</th>
<th align="left" valign="top">Domain</th>
<th align="left" valign="top">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td align="left" valign="top"><italic>n<sub>s</sub></italic></td>
<td align="left" valign="top">{<italic>n<sub>s</sub></italic>&#x02009;&#x02208;&#x02009;&#x02115;<sub>&#x0003E;0</sub>}</td>
<td align="left" valign="top">Number of inputs/samples</td>
</tr>
<tr>
<td align="left" valign="top"><italic>n<sub>a</sub></italic></td>
<td align="left" valign="top">{<italic>n<sub>a</sub></italic>&#x02009;&#x02208;&#x02009;&#x02115;<sub>&#x0003E;0</sub>}</td>
<td align="left" valign="top">Number of attributes in a input</td>
</tr>
<tr>
<td align="left" valign="top"><italic>n<sub>c</sub></italic></td>
<td align="left" valign="top">{<italic>n<sub>c</sub></italic>&#x02009;&#x02208;&#x02009;&#x02115;<sub>&#x0003E;0</sub>}</td>
<td align="left" valign="top">Number of columns</td>
</tr>
<tr>
<td align="left" valign="top"><italic>n<sub>ps</sub></italic></td>
<td align="left" valign="top">{<italic>n<sub>ps</sub></italic>&#x02009;&#x02208;&#x02009;&#x02115; &#x0007C; 0&#x02009;&#x0003C;&#x02009;<italic>n<sub>ps</sub></italic>&#x02009;&#x02264;&#x02009;<italic>n<sub>a</sub></italic>}</td>
<td align="left" valign="top">Number of proximal synapses per column</td>
</tr>
<tr>
<td align="left" valign="top"><italic>&#x003D5;</italic><sub>&#x0002B;</sub></td>
<td align="left" valign="top"><italic>&#x003D5;</italic><sub>&#x0002B;</sub>&#x02009;&#x02208;&#x02009;[0,1]</td>
<td align="left" valign="top">Permanence increment amount</td>
</tr>
<tr>
<td align="left" valign="top"><italic>&#x003D5;</italic><sub>&#x02212;</sub></td>
<td align="left" valign="top"><italic>&#x003D5;</italic><sub>&#x02212;</sub>&#x02009;&#x02208;&#x02009;[0,1]</td>
<td align="left" valign="top">Permanence decrement amount</td>
</tr>
<tr>
<td align="left" valign="top"><italic>&#x003D5;</italic><sub>&#x003B4;</sub></td>
<td align="left" valign="top">{<italic>&#x003D5;</italic><sub>&#x003B4;</sub>&#x02009;&#x02208;&#x02009;[0,1) &#x0007C; <italic>&#x003D5;</italic><sub>&#x003B4;</sub>&#x02009;&#x02264;&#x02009;<italic>&#x003C1;</italic><sub><italic>s</italic></sub> &#x02227; <italic>&#x003D5;</italic><sub>&#x003B4;</sub>&#x02009;&#x02264;&#x02009;1&#x02009;&#x02212;&#x02009;<italic>&#x003C1;</italic><sub><italic>s</italic></sub>}</td>
<td align="left" valign="top">Window of permanence initialization</td>
</tr>
<tr>
<td align="left" valign="top"><italic>&#x003C1;</italic><sub><italic>d</italic></sub></td>
<td align="left" valign="top">{<italic>&#x003C1;</italic><sub><italic>d</italic></sub>&#x02009;&#x02208;&#x02009;&#x02115; &#x0007C; 0&#x02009;&#x02264;&#x02009;<italic>&#x003C1;</italic><sub><italic>d</italic></sub>&#x02009;&#x02264;&#x02009;<italic>n<sub>ps</sub></italic>}</td>
<td align="left" valign="top">Proximal dendrite segment activation threshold</td>
</tr>
<tr>
<td align="left" valign="top"><italic>&#x003C1;</italic><sub><italic>s</italic></sub></td>
<td align="left" valign="top"><italic>&#x003C1;</italic><sub><italic>s</italic></sub>&#x02009;&#x02208;&#x02009;(0,1)</td>
<td align="left" valign="top">Proximal synapse activation threshold</td>
</tr>
<tr>
<td align="left" valign="top"><italic>&#x003C1;</italic><sub><italic>c</italic></sub></td>
<td align="left" valign="top">{<italic>&#x003C1;</italic><sub><italic>c</italic></sub>&#x02009;&#x02208;&#x02009;&#x02115; &#x0007C; 0&#x02009;&#x0003C;&#x02009;<italic>&#x003C1;</italic><sub><italic>c</italic></sub>&#x02009;&#x0003C;&#x02009;<italic>n<sub>c</sub></italic>}</td>
<td align="left" valign="top">Desired column activity level</td>
</tr>
<tr>
<td align="left" valign="top">&#x003BA;<sub><italic>a</italic></sub></td>
<td align="left" valign="top">&#x003BA;<sub><italic>a</italic></sub>&#x02009;&#x02208;&#x02009;(0,1]</td>
<td align="left" valign="top">Minimum activity level scaling factor</td>
</tr>
<tr>
<td align="left" valign="top">&#x003BA;<sub><italic>b</italic></sub></td>
<td align="left" valign="top">&#x003BA;<sub><italic>b</italic></sub>&#x02009;&#x02208;&#x02009;(0,1]</td>
<td align="left" valign="top">Permanence boosting scaling factor</td>
</tr>
<tr>
<td align="left" valign="top"><italic>&#x003B2;</italic><sub>0</sub></td>
<td align="left" valign="top"><italic>&#x003B2;</italic><sub>0</sub>&#x02009;&#x02208;&#x02009;[1,<italic>n<sub>ps</sub></italic>]</td>
<td align="left" valign="top">Maximum boost</td>
</tr>
<tr>
<td align="left" valign="top"><italic>&#x003C4;</italic></td>
<td align="left" valign="top">{<italic>&#x003C4;</italic>&#x02009;&#x02208;&#x02009;&#x02115; &#x0007C; 0&#x02009;&#x0003C;&#x02009;<italic>&#x003C4;</italic>&#x02009;&#x02264;&#x02009;<italic>n<sub>s</sub></italic>}</td>
<td align="left" valign="top">Duty cycle period</td>
</tr>
</tbody>
</table>
</table-wrap>
<sec id="S3-4">
<label>3.1</label> <title>Initialization</title>
<p>Competitive learning networks typically have each node fully connected to each attribute in the input. The SP follows a different line of logic, posing a new problem concerning the visibility of an input. As previously explained, the subset of input attributes that connect to a particular column are determined randomly. Let <inline-formula><mml:math id="M7"><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msup><mml:mrow><mml:mrow><mml:mo class="MathClass-open">&#x0007B;</mml:mo><mml:mrow><mml:mn>0</mml:mn><mml:mo class="MathClass-punc">,</mml:mo><mml:mn>1</mml:mn><mml:mo class="MathClass-punc">,</mml:mo><mml:mo class="MathClass-op">&#x02026;</mml:mo><mml:mo class="MathClass-punc">,</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>1</mml:mn></mml:mrow><mml:mo class="MathClass-close">&#x0007D;</mml:mo></mml:mrow></mml:mrow><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x000D7;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:math></inline-formula> be defined as the set of all columns indices, such that <inline-formula><mml:math id="M8"><mml:msub><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula> is the column&#x02019;s index at <italic>i</italic>. Let <inline-formula><mml:math id="M9"><mml:mtext mathvariant="bold-italic">U</mml:mtext><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msup><mml:mrow><mml:mrow><mml:mo class="MathClass-open">&#x0007B;</mml:mo><mml:mrow><mml:mn>0</mml:mn><mml:mo class="MathClass-punc">,</mml:mo><mml:mn>1</mml:mn></mml:mrow><mml:mo class="MathClass-close">&#x0007D;</mml:mo></mml:mrow></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>s</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x000D7;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>a</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:math></inline-formula> be defined as the set of attributes for all inputs, such that <bold><italic>U</italic></bold><italic><sub>s,a</sub></italic> is the attribute for input <italic>s</italic> at index <italic>a</italic>. Let <inline-formula><mml:math id="M10"><mml:mi mathvariant="bold">&#x0039B;</mml:mi><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msup><mml:mrow><mml:mrow><mml:mo class="MathClass-open">&#x0007B;</mml:mo><mml:mrow><mml:mn>0</mml:mn><mml:mo class="MathClass-punc">,</mml:mo><mml:mn>1</mml:mn><mml:mo class="MathClass-punc">,</mml:mo><mml:mo class="MathClass-op">&#x02026;</mml:mo><mml:mo class="MathClass-punc">,</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>a</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>1</mml:mn></mml:mrow><mml:mo class="MathClass-close">&#x0007D;</mml:mo></mml:mrow></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x000D7;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:math></inline-formula> be the source column indices for each proximal synapse on each column, such that <inline-formula><mml:math id="M11"><mml:msub><mml:mrow><mml:mi mathvariant="bold">&#x0039B;</mml:mi></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula> is the source column&#x02019;s index of <inline-formula><mml:math id="M12"><mml:msub><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula>&#x02019;s proximal synapse at index <italic>k</italic>. In other words, each <inline-formula><mml:math id="M13"><mml:msub><mml:mtext mathvariant="bold">&#x0039B;</mml:mtext><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula> refers to a specific index in <bold><italic>U</italic></bold><italic><sub>s</sub></italic>.</p>
<p>Let <inline-formula><mml:math id="M14"><mml:mrow><mml:mover accent='true'><mml:mrow><mml:mtext mathvariant="bold-italic">ac</mml:mtext></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msup><mml:mrow><mml:mrow><mml:mo class="MathClass-open">&#x0007B;</mml:mo><mml:mrow><mml:mn>0</mml:mn><mml:mo class="MathClass-punc">,</mml:mo><mml:mn>1</mml:mn></mml:mrow><mml:mo class="MathClass-close">&#x0007D;</mml:mo></mml:mrow></mml:mrow><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x000D7;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>a</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:math></inline-formula> be defined as vector of events, such that <inline-formula><mml:math id="M15"><mml:msub><mml:mrow><mml:mover accent='true'><mml:mrow><mml:mtext mathvariant="bold-italic">ac</mml:mtext></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>a</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x02261;</mml:mo><mml:mo class="MathClass-rel">&#x02203;</mml:mo><mml:mo class="MathClass-punc">!</mml:mo><mml:mi>a</mml:mi><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msub><mml:mtext mathvariant="bold">&#x0039B;</mml:mtext><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub><mml:mspace width="1em" class="nbsp"/><mml:mo class="MathClass-rel">&#x02200;</mml:mo><mml:mi>a</mml:mi></mml:math></inline-formula>. Therefore, <inline-formula><mml:math id="M16"><mml:mrow><mml:msub><mml:mrow><mml:mover accent='true'><mml:mrow><mml:mi mathvariant="bold-italic">ac</mml:mi></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mi>a</mml:mi></mml:msub></mml:mrow></mml:math></inline-formula> is the event of attribute <italic>a</italic> connecting to column <italic>a</italic>, where <inline-formula><mml:math id="M17"><mml:mo class="MathClass-rel">&#x02203;</mml:mo><mml:mo class="MathClass-punc">!</mml:mo></mml:math></inline-formula> is defined to be the uniqueness quantification. The probability of a single attribute, <bold><italic>U</italic></bold><italic><sub>s,a</sub></italic>, connecting to a column is the ratio of <italic>n<sub>ps</sub></italic> and <italic>n<sub>a</sub></italic>, as shown in equation (<xref ref-type="disp-formula" rid="E1">1</xref>).</p>
<disp-formula id="E1"><label>(1)</label><mml:math id="M18"><mml:mi mathvariant="double-struck">P</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msub><mml:mrow><mml:mover accent='true'><mml:mrow><mml:mtext mathvariant="bold-italic">ac</mml:mtext></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>a</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mfrac><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>a</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:mfrac></mml:math></disp-formula>
<p>It is also desired to know the average number of columns an attribute will connect with. To calculate this, let <inline-formula><mml:math id="M19"><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003BB;</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:mo class="MathClass-open">&#x0007B;</mml:mo><mml:mrow><mml:mn>0</mml:mn><mml:mo class="MathClass-punc">,</mml:mo><mml:mn>1</mml:mn><mml:mo class="MathClass-punc">,</mml:mo><mml:mo class="MathClass-op">&#x02026;</mml:mo><mml:mo class="MathClass-punc">,</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x0002B;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub><mml:msup><mml:mo class="MathClass-close">&#x0007D;</mml:mo><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x000D7;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>a</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:mrow></mml:math></inline-formula> be defined as a vector of random quantities, such that <inline-formula><mml:math id="M20"><mml:mrow><mml:msub><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003BB;</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mi>a</mml:mi></mml:msub></mml:mrow><mml:mo class="MathClass-rel">&#x02261;</mml:mo><mml:msubsup><mml:mrow><mml:mo class="MathClass-op">&#x02211;</mml:mo></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>0</mml:mn></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>1</mml:mn></mml:mrow></mml:msubsup><mml:msubsup><mml:mrow><mml:mo class="MathClass-op">&#x02211;</mml:mo></mml:mrow><mml:mrow><mml:mi>k</mml:mi><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>0</mml:mn></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>1</mml:mn></mml:mrow></mml:msubsup><mml:mi mathvariant="normal">I</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mi>a</mml:mi><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:msub><mml:mrow><mml:mi mathvariant="bold">&#x0039B;</mml:mi></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></inline-formula>. Therefore, <inline-formula><mml:math id="M21"><mml:mrow><mml:msub><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003BB;</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mi>a</mml:mi></mml:msub></mml:mrow></mml:math></inline-formula> is the count of connections between each attribute and all columns. Recognizing that the probability of a connection forming in <italic>n<sub>c</sub></italic> follows a binomial distribution, the expected number of columns that an attribute will connect to is simply equation (<xref ref-type="disp-formula" rid="E2">2</xref>).</p>
<disp-formula id="E2"><label>(2)</label><mml:math id="M22"><mml:mi mathvariant="double-struck">E</mml:mi><mml:mfenced separators="" open="[" close="]"><mml:mrow><mml:msub><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003BB;</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>a</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:mfenced><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub><mml:mi mathvariant="double-struck">P</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msub><mml:mrow><mml:mrow><mml:mover accent='true'><mml:mrow><mml:mtext mathvariant="bold-italic">ac</mml:mtext></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover></mml:mrow></mml:mrow><mml:mrow><mml:mi>a</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></disp-formula>
<p>Using equation (<xref ref-type="disp-formula" rid="E1">1</xref>), it is possible to calculate the probability of an attribute never connecting, as shown in equation (<xref ref-type="disp-formula" rid="E3">3</xref>). Since the probabilities are independent, it simply reduces to the product of the probability of an attribute not connecting to a column, taken over all columns. Let <inline-formula><mml:math id="M23"><mml:mn>&#x003BB;</mml:mn><mml:mo class="MathClass-rel">&#x02032;</mml:mo><mml:mo class="MathClass-rel">&#x02261;</mml:mo><mml:msubsup><mml:mrow><mml:mo class="MathClass-op">&#x02211;</mml:mo></mml:mrow><mml:mrow><mml:mi>a</mml:mi><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>0</mml:mn></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>a</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>1</mml:mn></mml:mrow></mml:msubsup><mml:mi mathvariant="normal">I</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msub><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003BB;</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mi>a</mml:mi></mml:msub></mml:mrow><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>0</mml:mn></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:math></inline-formula>, the random variable governing the number of unconnected attributes. From equation (<xref ref-type="disp-formula" rid="E3">3</xref>), the expected number of unobserved attributes may then be trivially obtained as equation (<xref ref-type="disp-formula" rid="E4">4</xref>). Using equations (<xref ref-type="disp-formula" rid="E3">3</xref>) and (<xref ref-type="disp-formula" rid="E2">2</xref>), it is possible to obtain a lower bound for <italic>n<sub>c</sub></italic> and <italic>n<sub>ps</sub></italic>, by choosing those parameters such that a certain amount of attribute visibility is obtained. To ensure, with high probability, the observance of all attributes, equation (<xref ref-type="disp-formula" rid="E3">3</xref>) must be sufficiently close to zero. This is obtained by fully connecting the SP columns to the input columns or by having a sufficiently large number of columns. Once that is satisfied, the desired number of times an attribute is observed may be determined by using equation (<xref ref-type="disp-formula" rid="E2">2</xref>).</p>
<disp-formula id="E3"><label>(3)</label><mml:math id="M24"><mml:mi mathvariant="double-struck">P</mml:mi><mml:mfenced separators="" open="(" close=")"><mml:mrow><mml:msub><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003BB;</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>a</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>0</mml:mn></mml:mrow></mml:mfenced><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:msup><mml:mrow><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mi mathvariant="double-struck">P</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msub><mml:mrow><mml:mrow><mml:mover accent='true'><mml:mrow><mml:mtext mathvariant="bold-italic">ac</mml:mtext></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover></mml:mrow></mml:mrow><mml:mrow><mml:mi>a</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:math></disp-formula>
<disp-formula id="E4"><label>(4)</label><mml:math id="M25"><mml:mi mathvariant="double-struck">E</mml:mi><mml:mrow><mml:mo class="MathClass-open">[</mml:mo><mml:mrow><mml:msup><mml:mi mathvariant="bold-italic">&#x003BB;</mml:mi><mml:mo>&#x02032;</mml:mo></mml:msup></mml:mrow><mml:mo class="MathClass-close">]</mml:mo></mml:mrow><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>a</mml:mi></mml:mrow></mml:msub><mml:mi mathvariant="double-struck">P</mml:mi><mml:mfenced separators="" open="(" close=")"><mml:mrow><mml:msub><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003BB;</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>a</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>0</mml:mn></mml:mrow></mml:mfenced></mml:math></disp-formula>
<p>Once each column has its set of inputs, the permanences must be initialized. As previously stated, permanences were defined to be initialized with a random value close to <italic>&#x003C1;</italic><sub><italic>s</italic></sub> but biased based off the distance between the synapse&#x02019;s source (input column) and destination (SP column). To obtain further clarification, NuPIC&#x02019;s source code (Numenta, <xref ref-type="bibr" rid="B18">2016</xref>) was consulted. It was found that the permanences were randomly initialized, with approximately half of the permanences creating connected proximal synapses and the remaining permanences creating potential (unconnected) proximal synapses. Additionally, to ensure that each column has a fair chance of being selected during inhibition, there are at least <italic>&#x003C1;</italic><sub><italic>d</italic></sub> connected proximal synapses on each column.</p>
<p>Let <inline-formula><mml:math id="M26"><mml:mi mathvariant="bold">&#x003A6;</mml:mi><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msup><mml:mrow><mml:mi mathvariant="double-struck">R</mml:mi></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x000D7;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:math></inline-formula> be defined as the set of permanences for each column, such that <inline-formula><mml:math id="M27"><mml:msub><mml:mtext mathvariant="bold">&#x003A6;</mml:mtext><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula> is the set of permanences for the proximal synapses for <inline-formula><mml:math id="M28"><mml:msub><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula>. Let <inline-formula><mml:math id="M29"><mml:mi mathvariant="normal">max</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">v</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></inline-formula> be defined as a function that will return the maximum value in <inline-formula><mml:math id="M30"><mml:mover accent='true'><mml:mi mathvariant="bold-italic">v</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula>. Similarly, let <inline-formula><mml:math id="M31"><mml:mi mathvariant="normal">min</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">v</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></inline-formula> be defined as a function that will return the minimum value in <inline-formula><mml:math id="M32"><mml:mover accent='true'><mml:mi mathvariant="bold-italic">v</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula>. Each <inline-formula><mml:math id="M33"><mml:msub><mml:mi mathvariant="bold">&#x003A6;</mml:mi><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula> is randomly initialized as shown in equation (<xref ref-type="disp-formula" rid="E5">5</xref>), where Unif represents the uniform distribution. Using equation (<xref ref-type="disp-formula" rid="E5">5</xref>), the expected permanence value is <italic>&#x003C1;</italic><sub><italic>s</italic></sub>; therefore, half of the proximal synapses connected to each column will be initialized in the connected state. This means that <italic>&#x003C1;</italic><sub><italic>d</italic></sub> should be chosen such that <italic>&#x003C1;</italic><sub><italic>d</italic></sub>&#x02009;&#x02264;&#x02009;<italic>n</italic><sub><italic>ps</italic></sub>/2 to sufficiently ensure that each column will have a greater than zero probability for becoming active. Additionally, the columns&#x02019; inputs must also be taken into consideration, such that <italic>&#x003C1;</italic><sub><italic>d</italic></sub> should be chosen to be small enough to take into consideration the sparseness in the input.</p>
<disp-formula id="E5"><label>(5)</label><mml:math id="M34"><mml:msub><mml:mrow><mml:mtext mathvariant="bold">&#x003A6;</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x0223C;</mml:mo><mml:mtext>Unif</mml:mtext><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msub><mml:mrow><mml:mi>&#x003C1;</mml:mi></mml:mrow><mml:mrow><mml:mi>s</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:msub><mml:mrow><mml:mi>&#x003D5;</mml:mi></mml:mrow><mml:mrow><mml:mn>&#x003B4;</mml:mn></mml:mrow></mml:msub><mml:mo class="MathClass-punc">,</mml:mo><mml:msub><mml:mrow><mml:mi>&#x003C1;</mml:mi></mml:mrow><mml:mrow><mml:mi>s</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x0002B;</mml:mo><mml:msub><mml:mrow><mml:mi>&#x003D5;</mml:mi></mml:mrow><mml:mrow><mml:mn>&#x003B4;</mml:mn></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></disp-formula>
<p>It is possible to predict, before training, the initial response of the SP to a given input. This insight allows parameters to be crafted in a manner that ensures a desired amount of column activity. Let <inline-formula><mml:math id="M35"><mml:mtext mathvariant="bold-italic">X</mml:mtext><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msup><mml:mrow><mml:mrow><mml:mo class="MathClass-open">&#x0007B;</mml:mo><mml:mrow><mml:mn>0</mml:mn><mml:mo class="MathClass-punc">,</mml:mo><mml:mn>1</mml:mn></mml:mrow><mml:mo class="MathClass-close">&#x0007D;</mml:mo></mml:mrow></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x000D7;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:math></inline-formula> be defined as the set of inputs for each column, such that <bold><italic>X</italic></bold><italic><sub>i</sub></italic> is the set of inputs for <inline-formula><mml:math id="M36"><mml:msub><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula>. Each <bold><italic>X</italic></bold><italic><sub>i,k</sub></italic> is mapped to a specific <bold><italic>U</italic></bold><italic><sub>s,a</sub></italic>, such that <bold><italic>X</italic></bold><italic><sub>i</sub></italic>&#x02009;&#x02282;&#x02009;<bold><italic>U</italic></bold><italic><sub>s</sub></italic> when <italic>n<sub>ps</sub></italic>&#x02009;&#x02260;&#x02009;<italic>n<sub>a</sub></italic> and <bold><italic>X</italic></bold><italic><sub>i</sub></italic>&#x02009;&#x02286;&#x02009;<bold><italic>U</italic></bold><italic><sub>s</sub></italic> otherwise. Let <inline-formula><mml:math id="M37"><mml:mtext mathvariant="bold-italic">A</mml:mtext><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msup><mml:mrow><mml:mrow><mml:mo class="MathClass-open">&#x0007B;</mml:mo><mml:mrow><mml:mn>0</mml:mn><mml:mo class="MathClass-punc">,</mml:mo><mml:mn>1</mml:mn></mml:mrow><mml:mo class="MathClass-close">&#x0007D;</mml:mo></mml:mrow></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x000D7;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:math></inline-formula> be defined as a matrix of events, such that <bold><italic>A</italic></bold><italic><sub>i,k</sub></italic>&#x02009;&#x02261;&#x02009;<bold><italic>X</italic></bold><italic><sub>i,k</sub></italic>&#x02009;&#x0003D;&#x02009;1. <bold><italic>A</italic></bold><italic><sub>i,k</sub></italic> is therefore the event that the attribute connected <italic>via</italic> proximal synapse <italic>k</italic> to column <italic>i</italic> is active. Let <inline-formula><mml:math id="M38"><mml:mi mathvariant="double-struck">P</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">A</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></inline-formula> be defined as the probability of the attribute connected <italic>via</italic> proximal synapse <italic>k</italic> to column <italic>i</italic> being active. Therefore, <inline-formula><mml:math id="M39"><mml:mi mathvariant="double-struck">P</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mo class="MathClass-rel">&#x02203;</mml:mo><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">A</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">A</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></inline-formula> is defined to be the probability of any proximal synapse connected to column <italic>i</italic> being active. Similarly, <inline-formula><mml:math id="M40"><mml:mi mathvariant="double-struck">P</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mo class="MathClass-rel">&#x02203;</mml:mo><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">A</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:mtext mathvariant="bold-italic">A</mml:mtext></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></inline-formula> is defined to be the probability of any proximal synapse on any column being active. The relationship between these probabilities is given in equations (<xref ref-type="disp-formula" rid="E6">6</xref>) and (<xref ref-type="disp-formula" rid="E7">7</xref>).</p>
<disp-formula id="E6"><label>(6)</label><mml:math id="M41"><mml:mi mathvariant="double-struck">P</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mo class="MathClass-rel">&#x02203;</mml:mo><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">A</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">A</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:msup><mml:mrow><mml:mfenced separators="" open="(" close=")"><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mi mathvariant="double-struck">P</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">A</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:mrow></mml:mfenced></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>a</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:math></disp-formula>
<disp-formula id="E7"><label>(7)</label><mml:math id="M42"><mml:mi mathvariant="double-struck">P</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mo class="MathClass-rel">&#x02203;</mml:mo><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">A</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:mtext mathvariant="bold-italic">A</mml:mtext></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:msup><mml:mrow><mml:mfenced separators="" open="(" close=")"><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mi mathvariant="double-struck">P</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mo class="MathClass-rel">&#x02203;</mml:mo><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">A</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">A</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:mrow></mml:mfenced></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:math></disp-formula>
<p>Let <inline-formula><mml:math id="M43"><mml:mrow><mml:mover accent='true'><mml:mrow><mml:mtext mathvariant="bold-italic">as</mml:mtext></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msup><mml:mrow><mml:mrow><mml:mo class="MathClass-open">&#x0007B;</mml:mo><mml:mrow><mml:mn>0</mml:mn><mml:mo class="MathClass-punc">,</mml:mo><mml:mn>1</mml:mn><mml:mo class="MathClass-punc">,</mml:mo><mml:mo class="MathClass-op">&#x02026;</mml:mo><mml:mo class="MathClass-punc">,</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">&#x0007D;</mml:mo></mml:mrow></mml:mrow><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x000D7;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:math></inline-formula> be defined as a vector of random quantities, such that <inline-formula><mml:math id="M44"><mml:msub><mml:mrow><mml:mover accent='true'><mml:mrow><mml:mtext mathvariant="bold-italic">as</mml:mtext></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x02261;</mml:mo><mml:msubsup><mml:mrow><mml:mo class="MathClass-op">&#x02211;</mml:mo></mml:mrow><mml:mrow><mml:mi>k</mml:mi><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>0</mml:mn></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>1</mml:mn></mml:mrow></mml:msubsup><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula>. Therefore, <inline-formula><mml:math id="M45"><mml:msub><mml:mrow><mml:mover accent='true'><mml:mrow><mml:mtext mathvariant="bold-italic">as</mml:mtext></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula> is the number of active proximal synapses on column <italic>i</italic>. The expected number of active proximal synapses on column <italic>i</italic> is then given by equation (<xref ref-type="disp-formula" rid="E8">8</xref>). Let <inline-formula><mml:math id="M46"><mml:mi mathvariant="italic">as</mml:mi><mml:mo class="MathClass-rel">&#x02261;</mml:mo><mml:mfrac><mml:mrow><mml:mn>1</mml:mn></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:mfrac><mml:msubsup><mml:mrow><mml:mo class="MathClass-op">&#x02211;</mml:mo></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>0</mml:mn></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>1</mml:mn></mml:mrow></mml:msubsup><mml:msubsup><mml:mrow><mml:mo class="MathClass-op">&#x02211;</mml:mo></mml:mrow><mml:mrow><mml:mi>k</mml:mi><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>0</mml:mn></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>1</mml:mn></mml:mrow></mml:msubsup><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula>, the random variable governing the average number of active proximal synapses on a column. Equation (<xref ref-type="disp-formula" rid="E8">8</xref>) is then generalized to equation (<xref ref-type="disp-formula" rid="E9">9</xref>), the expected number of active proximal synapses for each column. If <inline-formula><mml:math id="M47"><mml:mi mathvariant="double-struck">E</mml:mi><mml:mrow><mml:mo class="MathClass-open">[</mml:mo><mml:mrow><mml:mi mathvariant="italic">as</mml:mi></mml:mrow><mml:mo class="MathClass-close">]</mml:mo></mml:mrow><mml:mo class="MathClass-rel">&#x0003C;</mml:mo><mml:msub><mml:mrow><mml:mi>&#x003C1;</mml:mi></mml:mrow><mml:mrow><mml:mi>d</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula>, it is very unlikely that there will be enough active proximal synapses on a given column for that column to become active. This could result in an insufficient level of column activations, thereby degrading the quality of the SP&#x02019;s produced output. Therefore, it is recommended to select <italic>&#x003C1;</italic><sub><italic>d</italic></sub> as a function of the sparseness of the input, such that <inline-formula><mml:math id="M48"><mml:msub><mml:mrow><mml:mi>&#x003C1;</mml:mi></mml:mrow><mml:mrow><mml:mi>d</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x0003C;</mml:mo><mml:mi mathvariant="double-struck">E</mml:mi><mml:mrow><mml:mo class="MathClass-open">[</mml:mo><mml:mrow><mml:mi mathvariant="italic">as</mml:mi></mml:mrow><mml:mo class="MathClass-close">]</mml:mo></mml:mrow></mml:math></inline-formula>. Reducing <italic>&#x003C1;</italic><sub><italic>d</italic></sub> will increase the level of competition among columns; however, it will also increase the probability of including noisy columns, i.e., columns whose synapses&#x02019; inputs are connected to attributes within the input that collectively provide little contextual meaning.</p>
<disp-formula id="E8"><label>(8)</label><mml:math id="M49"><mml:mi mathvariant="double-struck">E</mml:mi><mml:mrow><mml:mo class="MathClass-open">[</mml:mo><mml:mrow><mml:msub><mml:mrow><mml:mover accent='true'><mml:mrow><mml:mtext mathvariant="bold-italic">as</mml:mtext></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">]</mml:mo></mml:mrow><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub><mml:mi mathvariant="double-struck">P</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mo class="MathClass-rel">&#x02203;</mml:mo><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x02223;</mml:mo><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>1</mml:mn></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></disp-formula>
<disp-formula id="E9"><label>(9)</label><mml:math id="M50"><mml:mi mathvariant="double-struck">E</mml:mi><mml:mrow><mml:mo class="MathClass-open">[</mml:mo><mml:mrow><mml:mi mathvariant="italic">as</mml:mi></mml:mrow><mml:mo class="MathClass-close">]</mml:mo></mml:mrow><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub><mml:mi mathvariant="double-struck">P</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mo class="MathClass-rel">&#x02203;</mml:mo><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:mtext mathvariant="bold-italic">X</mml:mtext><mml:mo class="MathClass-rel">&#x02223;</mml:mo><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>1</mml:mn></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></disp-formula>
<p>Let <inline-formula><mml:math id="M51"><mml:mtext mathvariant="bold-italic">AC</mml:mtext><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msup><mml:mrow><mml:mrow><mml:mo class="MathClass-open">&#x0007B;</mml:mo><mml:mrow><mml:mn>0</mml:mn><mml:mo class="MathClass-punc">,</mml:mo><mml:mn>1</mml:mn></mml:mrow><mml:mo class="MathClass-close">&#x0007D;</mml:mo></mml:mrow></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x000D7;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:math></inline-formula> be defined as a matrix of events, such that <inline-formula><mml:math id="M52"><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">AC</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x02261;</mml:mo><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">A</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02229;</mml:mo><mml:mtext>I</mml:mtext><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:msub><mml:mrow><mml:mtext mathvariant="bold">&#x003A6;</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x02265;</mml:mo><mml:msub><mml:mrow><mml:mi>&#x003C1;</mml:mi></mml:mrow><mml:mrow><mml:mi>s</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:math></inline-formula>. Therefore, <inline-formula><mml:math id="M53"><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">AC</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula> is the event that proximal synapse <italic>k</italic> is active and connected on column <italic>i</italic>. Let <inline-formula><mml:math id="M54"><mml:mrow><mml:mover accent='true'><mml:mrow><mml:mi mathvariant="bold-italic">ac</mml:mi></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msup><mml:mrow><mml:mrow><mml:mo class="MathClass-open">&#x0007B;</mml:mo><mml:mrow><mml:mn>0</mml:mn><mml:mo class="MathClass-punc">,</mml:mo><mml:mn>1</mml:mn><mml:mo class="MathClass-punc">,</mml:mo><mml:mo class="MathClass-op">&#x02026;</mml:mo><mml:mo class="MathClass-punc">,</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">&#x0007D;</mml:mo></mml:mrow></mml:mrow><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x000D7;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:math></inline-formula> be defined as a vector of random quantities, such that <inline-formula><mml:math id="M55"><mml:mrow><mml:mover accent='true'><mml:mrow><mml:msub><mml:mi mathvariant="bold-italic">ac</mml:mi><mml:mi>i</mml:mi></mml:msub></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mo class="MathClass-rel">&#x02261;</mml:mo><mml:msubsup><mml:mrow><mml:mo class="MathClass-op">&#x02211;</mml:mo></mml:mrow><mml:mrow><mml:mi>k</mml:mi><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>0</mml:mn></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>1</mml:mn></mml:mrow></mml:msubsup><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">AC</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula>. Therefore, <inline-formula><mml:math id="M56"><mml:mrow><mml:mover accent='true'><mml:mrow><mml:msub><mml:mi mathvariant="bold-italic">ac</mml:mi><mml:mi>i</mml:mi></mml:msub></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover></mml:mrow></mml:math></inline-formula> is the count of active and connected proximal synapses for column <italic>i</italic>. Let <inline-formula><mml:math id="M57"><mml:mi mathvariant="double-struck">P</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">AC</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>1</mml:mn></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow><mml:mo class="MathClass-rel">&#x02261;</mml:mo><mml:mi mathvariant="double-struck">P</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">A</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow><mml:msub><mml:mrow><mml:mi>&#x003C1;</mml:mi></mml:mrow><mml:mrow><mml:mi>s</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula>, the probability that a proximal synapse is active and connected.<xref ref-type="fn" rid="fn4"><sup>4</sup></xref> Following equation (<xref ref-type="disp-formula" rid="E8">8</xref>), the expected number of active connected proximal synapses on column <italic>i</italic> is given by equation (<xref ref-type="disp-formula" rid="E10">10</xref>).</p>
<disp-formula id="E10"><label>(10)</label><mml:math id="M58"><mml:mi mathvariant="double-struck">E</mml:mi><mml:mrow><mml:mo class="MathClass-open">[</mml:mo><mml:mrow><mml:msub><mml:mrow><mml:mover accent='true'><mml:mrow><mml:mtext mathvariant="bold-italic">ac</mml:mtext></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">]</mml:mo></mml:mrow><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mstyle displaystyle='true'><mml:munderover><mml:mo>&#x02211;</mml:mo><mml:mrow><mml:mi>k</mml:mi><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>0</mml:mn></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>1</mml:mn></mml:mrow></mml:munderover></mml:mstyle><mml:mi mathvariant="double-struck">P</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">AC</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>1</mml:mn></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></disp-formula>
<p>Let Bin(<italic>k; n, p</italic>) be defined as the probability mass function (PMF) of a binomial distribution, where <italic>k</italic> is the number of successes, <italic>n</italic> is the number of trials, and <italic>p</italic> is the success probability in each trial. Let <inline-formula><mml:math id="M59"><mml:mi mathvariant="italic">at</mml:mi><mml:mo class="MathClass-rel">&#x02261;</mml:mo><mml:msubsup><mml:mrow><mml:mo class="MathClass-op">&#x02211;</mml:mo></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>0</mml:mn></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>1</mml:mn></mml:mrow></mml:msubsup><mml:mtext>I</mml:mtext><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msubsup><mml:mrow><mml:mo class="MathClass-op">&#x02211;</mml:mo></mml:mrow><mml:mrow><mml:mi>k</mml:mi><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>0</mml:mn></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>1</mml:mn></mml:mrow></mml:msubsup><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow><mml:mo class="MathClass-rel">&#x02265;</mml:mo><mml:msub><mml:mrow><mml:mi>&#x003C1;</mml:mi></mml:mrow><mml:mrow><mml:mi>d</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></inline-formula>, the random variable governing the number of columns having at least <italic>&#x003C1;</italic><sub><italic>d</italic></sub> active proximal synapses. Let <inline-formula><mml:math id="M60"><mml:mi mathvariant="italic">act</mml:mi><mml:mo class="MathClass-rel">&#x02261;</mml:mo><mml:msubsup><mml:mrow><mml:mo class="MathClass-op">&#x02211;</mml:mo></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>0</mml:mn></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>1</mml:mn></mml:mrow></mml:msubsup><mml:mtext>I</mml:mtext><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msubsup><mml:mrow><mml:mo class="MathClass-op">&#x02211;</mml:mo></mml:mrow><mml:mrow><mml:mi>k</mml:mi><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>0</mml:mn></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>1</mml:mn></mml:mrow></mml:msubsup><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">AC</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow><mml:mo class="MathClass-rel">&#x02265;</mml:mo><mml:msub><mml:mrow><mml:mi>&#x003C1;</mml:mi></mml:mrow><mml:mrow><mml:mi>d</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></inline-formula>, the random variable governing the number of columns having at least <italic>&#x003C1;</italic><sub><italic>d</italic></sub> active connected proximal synapses. Let &#x003C0;<sub><italic>x</italic></sub> and &#x003C0;<sub><italic>ac</italic></sub> be defined as random variables that are equal to the overall mean of <inline-formula><mml:math id="M61"><mml:mi mathvariant="double-struck">P</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mtext mathvariant="bold-italic">A</mml:mtext></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></inline-formula> and <inline-formula><mml:math id="M62"><mml:mi mathvariant="double-struck">P</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mtext mathvariant="bold-italic">AC</mml:mtext></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></inline-formula>, respectively. The expected number of columns with at least <italic>&#x003C1;</italic><sub><italic>d</italic></sub> active proximal synapses and the expected number of columns with at least <italic>&#x003C1;</italic><sub><italic>d</italic></sub> active connected proximal synapses are then given by equations (<xref ref-type="disp-formula" rid="E11">11</xref>) and (<xref ref-type="disp-formula" rid="E12">12</xref>), respectively.</p>
<p>In equation (<xref ref-type="disp-formula" rid="E11">11</xref>), the summation computes the probability of having less than <italic>&#x003C1;</italic><sub><italic>d</italic></sub> active connected proximal synapses, where the individual probabilities within the summation follow the PMF of a binomial distribution. To obtain the desired probability, the complement of that probability is taken. It is then clear that the mean is nothing more than that probability multiplied by <italic>n<sub>c</sub></italic>. For equation (<xref ref-type="disp-formula" rid="E12">12</xref>), the logic is similar, with the key difference being that the probability of a success is a function of both <bold><italic>X</italic></bold> and <italic>&#x003C1;</italic><sub><italic>s</italic></sub>, as it was in equation (<xref ref-type="disp-formula" rid="E10">10</xref>).</p>
<disp-formula id="E11"><label>(11)</label><mml:math id="M63"><mml:mi mathvariant="double-struck">E</mml:mi><mml:mrow><mml:mo class="MathClass-open">[</mml:mo><mml:mrow><mml:mi mathvariant="italic">at</mml:mi></mml:mrow><mml:mo class="MathClass-close">]</mml:mo></mml:mrow><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub><mml:mfenced separators="" open="[" close="]"><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mstyle displaystyle='true'><mml:munderover><mml:mo>&#x02211;</mml:mo><mml:mrow><mml:mi>t</mml:mi><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>0</mml:mn></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>&#x003C1;</mml:mi></mml:mrow><mml:mrow><mml:mi>d</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>1</mml:mn></mml:mrow></mml:munderover></mml:mstyle><mml:mtext>Bin</mml:mtext><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mi>t</mml:mi><mml:mo class="MathClass-punc">;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-punc">,</mml:mo><mml:msub><mml:mrow><mml:mn>&#x003C0;</mml:mn></mml:mrow><mml:mrow><mml:mi>x</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:mrow></mml:mfenced></mml:math></disp-formula>
<disp-formula id="E12"><label>(12)</label><mml:math id="M64"><mml:mi mathvariant="double-struck">E</mml:mi><mml:mrow><mml:mo class="MathClass-open">[</mml:mo><mml:mrow><mml:mi mathvariant="italic">act</mml:mi></mml:mrow><mml:mo class="MathClass-close">]</mml:mo></mml:mrow><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub><mml:mfenced separators="" open="[" close="]"><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mstyle displaystyle='true'><mml:munderover><mml:mo>&#x02211;</mml:mo><mml:mrow><mml:mi>t</mml:mi><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>0</mml:mn></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>&#x003C1;</mml:mi></mml:mrow><mml:mrow><mml:mi>d</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>1</mml:mn></mml:mrow></mml:munderover></mml:mstyle><mml:mtext>Bin</mml:mtext><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mi>t</mml:mi><mml:mo class="MathClass-punc">;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-punc">,</mml:mo><mml:msub><mml:mrow><mml:mn>&#x003C0;</mml:mn></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ac</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:mrow></mml:mfenced></mml:math></disp-formula>
</sec>
<sec id="S3-5">
<label>3.2</label> <title>Phase 1: Overlap</title>
<p>Let <inline-formula><mml:math id="M65"><mml:mover accent='true'><mml:mtext mathvariant="bold-italic">b</mml:mtext><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msup><mml:mrow><mml:msub><mml:mrow><mml:mi mathvariant="double-struck">R</mml:mi></mml:mrow><mml:mrow><mml:mo class="MathClass-rel">&#x0003E;</mml:mo><mml:mn>0</mml:mn></mml:mrow></mml:msub></mml:mrow><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x000D7;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:math></inline-formula> be defined as the set of boost values for all columns, such that <inline-formula><mml:math id="M66"><mml:msub><mml:mrow><mml:mover accent='true'><mml:mtext mathvariant="bold-italic">b</mml:mtext><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula> is the boost for <inline-formula><mml:math id="M67"><mml:msub><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula>. Let <inline-formula><mml:math id="M68"><mml:mtext mathvariant="bold-italic">Y</mml:mtext><mml:mo class="MathClass-rel">&#x02261;</mml:mo><mml:mtext>I</mml:mtext><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msub><mml:mrow><mml:mi mathvariant="bold">&#x003A6;</mml:mi></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x02265;</mml:mo><mml:msub><mml:mrow><mml:mi>&#x003C1;</mml:mi></mml:mrow><mml:mrow><mml:mi>s</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow><mml:mo class="MathClass-rel">&#x02200;</mml:mo><mml:mi>i</mml:mi></mml:math></inline-formula>, the bit-mask for the proximal synapse&#x02019;s activations. Therefore, <bold><italic>Y</italic></bold><italic><sub>i</sub></italic> is a row-vector bit-mask, with each &#x0201C;1&#x0201D; representing a connected synapse and each &#x0201C;0&#x0201D; representing an unconnected synapse. In this manner, the connectivity (or lack thereof) for each synapse on each column is obtained. The overlap for all columns, <inline-formula><mml:math id="M69"><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003B1;</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msup><mml:mrow><mml:msub><mml:mrow><mml:mi mathvariant="double-struck">R</mml:mi></mml:mrow><mml:mrow><mml:mo class="MathClass-rel">&#x02265;</mml:mo><mml:mn>0</mml:mn></mml:mrow></mml:msub></mml:mrow><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x000D7;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:math></inline-formula>, is defined by equation (<xref ref-type="disp-formula" rid="E13">13</xref>), which is a function of <inline-formula><mml:math id="M70"><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003B1;</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msup><mml:mrow><mml:msub><mml:mrow><mml:mi mathvariant="double-struck">N</mml:mi></mml:mrow><mml:mrow><mml:mo class="MathClass-rel">&#x0003E;</mml:mo><mml:mn>0</mml:mn></mml:mrow></mml:msub></mml:mrow><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x000D7;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:math></inline-formula>. <inline-formula><mml:math id="M71"><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003B1;</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula> is the sum of the active connected proximal synapses for all columns and is defined by equation (<xref ref-type="disp-formula" rid="E14">14</xref>).</p>
<p>Comparing these equations with Algorithm <xref ref-type="table" rid="AL1">1</xref>, it is clear that <inline-formula><mml:math id="M72"><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003B1;</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula> will have the same value as <italic>col.overlap</italic> before line five and that the final value of <italic>col.overlap</italic> will be equal to <inline-formula><mml:math id="M73"><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003B1;</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula>. To help provide further understanding, a simple example demonstrating the functionality of this phase is shown in Figure <xref ref-type="fig" rid="F2">2</xref>.</p>
<disp-formula id="E13"><label>(13)</label><mml:math id="M74"><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003B1;</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mo class="MathClass-rel">&#x02261;</mml:mo><mml:mfenced separators="" open="{" close=""><mml:mrow><mml:mtable class="array"><mml:mtr><mml:mtd class="array" columnalign="left"><mml:mrow><mml:msub><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003B1;</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mi>i</mml:mi></mml:msub><mml:msub><mml:mover accent='true'><mml:mi mathvariant="bold-italic">b</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mi>i</mml:mi></mml:msub></mml:mrow></mml:mtd><mml:mtd class="array" columnalign="left"><mml:mrow><mml:msub><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003B1;</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mi>i</mml:mi></mml:msub></mml:mrow><mml:mo class="MathClass-rel">&#x02265;</mml:mo><mml:msub><mml:mrow><mml:mi>&#x003C1;</mml:mi></mml:mrow><mml:mrow><mml:mi>d</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-punc">,</mml:mo></mml:mtd></mml:mtr><mml:mtr><mml:mtd class="array" columnalign="left"><mml:mn>0</mml:mn></mml:mtd><mml:mtd class="array" columnalign="left"><mml:mtext>otherwise</mml:mtext></mml:mtd></mml:mtr></mml:mtable></mml:mrow></mml:mfenced><mml:mspace width="1em" class="nbsp"/><mml:mo class="MathClass-rel">&#x02200;</mml:mo><mml:mi>i</mml:mi></mml:math></disp-formula>
<disp-formula id="E14"><label>(14)</label><mml:math id="M75"><mml:msub><mml:mrow><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003B1;</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x02261;</mml:mo><mml:mrow><mml:msubsup><mml:mi mathvariant="bold-italic">X</mml:mi><mml:mi>i</mml:mi><mml:mi>T</mml:mi></mml:msubsup><mml:msub><mml:mrow><mml:mi>Y</mml:mi></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:math></disp-formula>
<fig position="float" id="F2">
<label>Figure 2</label>
<caption><p><bold>SP phase 1 example where <italic>n<sub>c</sub></italic>&#x02009;&#x0003D;&#x02009;12, <italic>n<sub>ps</sub></italic>&#x02009;&#x0003D;&#x02009;5, and <italic>&#x003C1;</italic><sub><italic>d</italic></sub>&#x02009;&#x0003D;&#x02009;2</bold>. It was assumed that the boost for all columns is at the initial value of &#x0201C;1&#x0201D;. For simplicity, only the connections for the example column, highlighted in gray, are shown. The example column&#x02019;s overlap is two since it has exactly two active and connected synapses.</p></caption>
<graphic xlink:href="frobt-03-00081-g002.tif"/>
</fig>
</sec>
<sec id="S3-6">
<label>3.3</label> <title>Phase 2: Inhibition</title>
<p>Let <inline-formula><mml:math id="M76"><mml:mtext mathvariant="bold-italic">H</mml:mtext><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msup><mml:mrow><mml:mrow><mml:mo class="MathClass-open">&#x0007B;</mml:mo><mml:mrow><mml:mn>0</mml:mn><mml:mo class="MathClass-punc">,</mml:mo><mml:mn>1</mml:mn></mml:mrow><mml:mo class="MathClass-close">&#x0007D;</mml:mo></mml:mrow></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x000D7;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:math></inline-formula> be defined as the neighborhood mask for all columns, such that <bold><italic>H</italic></bold><italic><sub>i</sub></italic> is the neighborhood for <inline-formula><mml:math id="M77"><mml:msub><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula>. <inline-formula><mml:math id="M78"><mml:msub><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>j</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula> is then said to be in <inline-formula><mml:math id="M79"><mml:msub><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula>&#x02019;s neighborhood if and only if <bold><italic>H</italic></bold><italic><sub>i,j</sub></italic> is &#x0201C;1&#x0201D;. Let kmax(<italic>S, k</italic>) be defined as the <italic>k</italic>-th largest element of <italic>S</italic>. The set of active columns, <inline-formula><mml:math id="M80"><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msup><mml:mrow><mml:mrow><mml:mo class="MathClass-open">&#x0007B;</mml:mo><mml:mrow><mml:mn>0</mml:mn><mml:mo class="MathClass-punc">,</mml:mo><mml:mn>1</mml:mn></mml:mrow><mml:mo class="MathClass-close">&#x0007D;</mml:mo></mml:mrow></mml:mrow><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x000D7;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:math></inline-formula>, is defined by equation (<xref ref-type="disp-formula" rid="E15">15</xref>), such that <inline-formula><mml:math id="M81"><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula> is an indicator vector representing the activation (or lack of activation) for each column. The result of the indicator function is determined by <inline-formula><mml:math id="M82"><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003B3;</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msup><mml:mrow><mml:mi mathvariant="double-struck">N</mml:mi></mml:mrow><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x000D7;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:math></inline-formula>, which is defined by equation (<xref ref-type="disp-formula" rid="E16">16</xref>) as the <italic>&#x003C1;</italic><sub><italic>c</italic></sub>-th largest overlap (lower bounded by one) in the neighborhood of <inline-formula><mml:math id="M83"><mml:msub><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub><mml:mspace width="1em" class="nbsp"/><mml:mo class="MathClass-rel">&#x02200;</mml:mo><mml:mi>i</mml:mi></mml:math></inline-formula>.</p>
<p>Comparing these equations with Algorithm <xref ref-type="table" rid="AL2">2</xref>, <inline-formula><mml:math id="M84"><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003B3;</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula> is a slightly altered version of <italic>mo</italic>. Instead of just being the <italic>&#x003C1;</italic><sub><italic>c</italic></sub>-th largest overlap for each column, it is additionally lower bounded by one. Referring back to Algorithm <xref ref-type="table" rid="AL2">2</xref>, line 3 is a biconditional statement evaluating to true if the overlap is at least <italic>mo</italic> and greater than zero. By simply enforcing <italic>mo</italic> to be at least one, the biconditional is reduced to a single condition. That condition is evaluated within the indicator function; therefore, equation (<xref ref-type="disp-formula" rid="E15">15</xref>) carries out the logic in the if statement in Algorithm <xref ref-type="table" rid="AL2">2</xref>. Continuing with the demonstration shown in Figures <xref ref-type="fig" rid="F2">2</xref> and <xref ref-type="fig" rid="F3">3</xref> shows an example execution of phase two.</p>
<disp-formula id="E15"><label>(15)</label><mml:math id="M85"><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mo class="MathClass-rel">&#x02261;</mml:mo><mml:mtext>I</mml:mtext><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msub><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003B1;</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x02265;</mml:mo><mml:msub><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003B3;</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow><mml:mspace width="1em" class="nbsp"/><mml:mo class="MathClass-rel">&#x02200;</mml:mo><mml:mi>i</mml:mi></mml:math></disp-formula>
<disp-formula id="E16"><label>(16)</label><mml:math id="M86"><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003B3;</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mo class="MathClass-rel">&#x02261;</mml:mo><mml:mtext>max</mml:mtext><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mtext>kmax</mml:mtext><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">H</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02299;</mml:mo><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003B1;</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mo class="MathClass-punc">,</mml:mo><mml:msub><mml:mrow><mml:mi>&#x003C1;</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow><mml:mo class="MathClass-punc">,</mml:mo><mml:mn>1</mml:mn></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow><mml:mspace width="1em" class="nbsp"/><mml:mo class="MathClass-rel">&#x02200;</mml:mo><mml:mi>i</mml:mi></mml:math></disp-formula>
<fig position="float" id="F3">
<label>Figure 3</label>
<caption><p><bold>SP phase 2 example where <italic>&#x003C1;</italic><sub><italic>c</italic></sub>&#x02009;&#x0003D;&#x02009;2 and the inhibition radius has a size of two</bold>. The overlap values were determined from the SP phase 1 example. The ellipse represents the inhibition radius, extending two units in all directions from the example column. The example column is active, because it has an overlap value of two which is at least as large as the <italic>&#x003C1;</italic><sub><italic>c</italic></sub>-th largest overlap value. It is noted that in this example, within the example column&#x02019;s inhibition radius, more than <italic>&#x003C1;</italic><sub><italic>c</italic></sub> columns are active. This situation is valid and occurs when neighboring columns have overlap values that are large enough and close to the example column.</p></caption>
<graphic xlink:href="frobt-03-00081-g003.tif"/>
</fig>
</sec>
<sec id="S3-7">
<label>3.4</label> <title>Phase 3: Learning</title>
<p>Let clip(<bold><italic>M</italic></bold>, <italic>lb</italic>, <italic>ub</italic>) be defined as a function that will clip all values in the matrix <bold><italic>M</italic></bold> outside of the range [<italic>lb</italic>, <italic>ub</italic>] to <italic>lb</italic> if the value is less than <italic>lb</italic>, or to <italic>ub</italic> if the value is greater than <italic>ub</italic>. <bold>&#x003A6;</bold> is then recalculated by equation (<xref ref-type="disp-formula" rid="E17">17</xref>), where <bold><italic>&#x003B4;</italic>&#x003A6;</bold> is the proximal synapse&#x02019;s permanence update amount given by equation (<xref ref-type="disp-formula" rid="E18">18</xref>).<xref ref-type="fn" rid="fn5"><sup>5</sup></xref></p>
<disp-formula id="E17"><label>(17)</label><mml:math id="M87"><mml:msup><mml:mrow><mml:mtext mathvariant="bold">&#x003A6;</mml:mtext></mml:mrow><mml:mrow><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mi>f</mml:mi></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:mrow></mml:msup><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mtext>clip</mml:mtext><mml:mfenced separators="" open="(" close=")"><mml:mrow><mml:msup><mml:mrow><mml:mtext mathvariant="bold">&#x003A6;</mml:mtext></mml:mrow><mml:mrow><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mi>i</mml:mi></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:mrow></mml:msup><mml:mo class="MathClass-bin">&#x02295;</mml:mo><mml:mi mathvariant="bold">&#x003B4;&#x003A6;</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mn>0</mml:mn><mml:mo class="MathClass-punc">,</mml:mo><mml:mn>1</mml:mn></mml:mrow></mml:mfenced></mml:math></disp-formula>
<disp-formula id="E18"><label>(18)</label><mml:math id="M88"><mml:mtext mathvariant="bold">&#x003B4;&#x003A6;</mml:mtext><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mrow><mml:msup><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mi>T</mml:mi></mml:msup></mml:mrow><mml:mo class="MathClass-bin">&#x02299;</mml:mo><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msub><mml:mrow><mml:mi>&#x003D5;</mml:mi></mml:mrow><mml:mrow><mml:mo class="MathClass-bin">&#x0002B;</mml:mo></mml:mrow></mml:msub><mml:mtext mathvariant="bold-italic">X</mml:mtext><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msub><mml:mrow><mml:mi>&#x003D5;</mml:mi></mml:mrow><mml:mrow><mml:mo class="MathClass-bin">&#x02212;</mml:mo></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x000AC;</mml:mo><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></disp-formula>
<p>The result of these two equations is equivalent to the result of executing the first seven lines in Algorithm <xref ref-type="table" rid="AL3">3</xref>. If a column is active, it will be denoted as such in <inline-formula><mml:math id="M89"><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula>; therefore, using that vector as a mask, the result of equation (<xref ref-type="disp-formula" rid="E18">18</xref>) will be a zero if the column is inactive, otherwise it will be the update amount. From Algorithm <xref ref-type="table" rid="AL3">3</xref>, the update amount should be <italic>&#x003D5;</italic><sub>&#x0002B;</sub> if the synapse was active and <italic>&#x003D5;</italic><sub>&#x02212;</sub> if the synapse was inactive. A synapse is active only if its source column is active. That activation is determined by the corresponding value in <bold><italic>X</italic></bold>. In this manner, <bold><italic>X</italic></bold> is also being used as a mask, such that active synapses will result in the update equaling <italic>&#x003D5;</italic><sub>&#x0002B;</sub> and inactive synapses (selected by inverting <bold><italic>X</italic></bold>) will result in the update equaling <italic>&#x003D5;</italic><sub>&#x02212;</sub>. By clipping the element-wise sum of <bold>&#x003A6;</bold> and <bold>&#x003B4;&#x003A6;</bold>, the permanences stay bounded between [0, 1]. As with the previous two phases, the visual demonstration is continued, with Figure <xref ref-type="fig" rid="F4">4</xref> illustrating the primary functionality of this phase.</p>
<fig position="float" id="F4">
<label>Figure 4</label>
<caption><p><bold>SP phase 3 example, demonstrating the adaptation of the permanences</bold>. The gray columns are used to denote the active columns, where those activations were determined from the SP phase 2 example. Permanences are adapted based off the synaptic input for all active columns. If the synaptic input is active, the permanence is incremented otherwise it is decremented.</p></caption>
<graphic xlink:href="frobt-03-00081-g004.tif"/>
</fig>
<p>Let <inline-formula><mml:math id="M90"><mml:mrow><mml:mover accent='true'><mml:mrow><mml:msup><mml:mi mathvariant="bold-italic">&#x003B7;</mml:mi><mml:mrow><mml:mrow><mml:mo>(</mml:mo><mml:mi>a</mml:mi><mml:mo>)</mml:mo></mml:mrow></mml:mrow></mml:msup></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msup><mml:mrow><mml:msub><mml:mrow><mml:mi mathvariant="double-struck">R</mml:mi></mml:mrow><mml:mrow><mml:mo class="MathClass-rel">&#x02265;</mml:mo><mml:mn>0</mml:mn></mml:mrow></mml:msub></mml:mrow><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x000D7;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:math></inline-formula> be defined as the set of active duty cycles for all columns, such that <inline-formula><mml:math id="M91"><mml:mrow><mml:mover accent='true'><mml:mrow><mml:msubsup><mml:mi mathvariant="bold-italic">&#x003B7;</mml:mi><mml:mi>i</mml:mi><mml:mrow><mml:mrow><mml:mo>(</mml:mo><mml:mi>a</mml:mi><mml:mo>)</mml:mo></mml:mrow></mml:mrow></mml:msubsup></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover></mml:mrow></mml:math></inline-formula> is the active duty cycle for <inline-formula><mml:math id="M92"><mml:mrow><mml:msub><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mi>i</mml:mi></mml:msub></mml:mrow></mml:math></inline-formula>. Let <inline-formula><mml:math id="M93"><mml:mrow><mml:mover accent='true'><mml:mrow><mml:msubsup><mml:mi mathvariant="bold-italic">&#x003B7;</mml:mi><mml:mi>i</mml:mi><mml:mrow><mml:mrow><mml:mo>(</mml:mo><mml:mrow><mml:mi mathvariant="italic">min</mml:mi></mml:mrow><mml:mo>)</mml:mo></mml:mrow></mml:mrow></mml:msubsup></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msup><mml:mrow><mml:msub><mml:mrow><mml:mi mathvariant="double-struck">R</mml:mi></mml:mrow><mml:mrow><mml:mo class="MathClass-rel">&#x02265;</mml:mo><mml:mn>0</mml:mn></mml:mrow></mml:msub></mml:mrow><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x000D7;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:math></inline-formula> be defined by equation (<xref ref-type="disp-formula" rid="E19">19</xref>) as the set of minimum active duty cycles for all columns, such that <inline-formula><mml:math id="M94"><mml:mrow><mml:mover accent='true'><mml:mrow><mml:msubsup><mml:mi mathvariant="bold-italic">&#x003B7;</mml:mi><mml:mi>i</mml:mi><mml:mrow><mml:mrow><mml:mo>(</mml:mo><mml:mrow><mml:mi mathvariant="italic">min</mml:mi></mml:mrow><mml:mo>)</mml:mo></mml:mrow></mml:mrow></mml:msubsup></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover></mml:mrow></mml:math></inline-formula> is the minimum active duty cycle for <inline-formula><mml:math id="M95"><mml:mrow><mml:msub><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mi>i</mml:mi></mml:msub></mml:mrow></mml:math></inline-formula>. This equation is clearly the same as line 9 in Algorithm <xref ref-type="table" rid="AL3">3</xref>.</p>
<disp-formula id="E19"><label>(19)</label><mml:math id="M96"><mml:mrow><mml:mover accent='true'><mml:mrow><mml:msup><mml:mi mathvariant="bold-italic">&#x003B7;</mml:mi><mml:mrow><mml:mrow><mml:mo>(</mml:mo><mml:mrow><mml:mi mathvariant="italic">min</mml:mi></mml:mrow><mml:mo>)</mml:mo></mml:mrow></mml:mrow></mml:msup></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mo class="MathClass-rel">&#x02261;</mml:mo><mml:msub><mml:mrow><mml:mn>&#x003BA;</mml:mn></mml:mrow><mml:mrow><mml:mi>a</mml:mi></mml:mrow></mml:msub><mml:mi mathvariant="normal">max</mml:mi><mml:mfenced separators="" open="(" close=")"><mml:mrow><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">H</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02299;</mml:mo><mml:mrow><mml:mover accent='true'><mml:mrow><mml:msup><mml:mi mathvariant="bold-italic">&#x003B7;</mml:mi><mml:mrow><mml:mrow><mml:mo>(</mml:mo><mml:mi>a</mml:mi><mml:mo>)</mml:mo></mml:mrow></mml:mrow></mml:msup></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover></mml:mrow></mml:mrow></mml:mfenced><mml:mspace width="1em" class="nbsp"/><mml:mo class="MathClass-rel">&#x02200;</mml:mo><mml:mi>i</mml:mi></mml:math></disp-formula>
<p>Let update_active_duty_cycle (<inline-formula><mml:math id="M97"><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula>) be defined as a function that updates the moving average duty cycle for the active duty cycle for each <inline-formula><mml:math id="M98"><mml:msub><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mtext mathvariant="bold-italic">i</mml:mtext></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula>. That function should compute the frequency of each column&#x02019;s activation. After calling update_active_duty_cycle (<inline-formula><mml:math id="M99"><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula>), the boost for each column is updated by using equation (<xref ref-type="disp-formula" rid="E20">20</xref>). In Equation (<xref ref-type="disp-formula" rid="E20">20</xref>), <inline-formula><mml:math id="M100"><mml:mrow><mml:mi>&#x003B2;</mml:mi><mml:mrow><mml:mo>(</mml:mo><mml:mrow><mml:mover accent='true'><mml:mrow><mml:msubsup><mml:mi mathvariant="bold-italic">&#x003B7;</mml:mi><mml:mi>i</mml:mi><mml:mrow><mml:mrow><mml:mo>(</mml:mo><mml:mi>a</mml:mi><mml:mo>)</mml:mo></mml:mrow></mml:mrow></mml:msubsup></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover><mml:mo>,</mml:mo><mml:mtext>&#x02009;</mml:mtext><mml:mover accent='true'><mml:mrow><mml:msubsup><mml:mi mathvariant="bold-italic">&#x003B7;</mml:mi><mml:mi>i</mml:mi><mml:mrow><mml:mrow><mml:mo>(</mml:mo><mml:mrow><mml:mi mathvariant="bold-italic">min</mml:mi></mml:mrow><mml:mo>)</mml:mo></mml:mrow></mml:mrow></mml:msubsup></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mo>)</mml:mo></mml:mrow></mml:mrow></mml:math></inline-formula> is defined as the boost function, following equation (<xref ref-type="disp-formula" rid="E21">21</xref>).<xref ref-type="fn" rid="fn6"><sup>6</sup></xref> The functionality of equation (<xref ref-type="disp-formula" rid="E20">20</xref>) is therefore shown to be equivalent to Algorithm <xref ref-type="table" rid="AL4">4</xref>.</p>
<disp-formula id="E20"><label>(20)</label><mml:math id="M101"><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">b</mml:mi><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mo class="MathClass-rel">&#x02261;</mml:mo><mml:mrow><mml:mi>&#x003B2;</mml:mi><mml:mrow><mml:mo>(</mml:mo><mml:mrow><mml:mover accent='true'><mml:mrow><mml:msubsup><mml:mi mathvariant="bold-italic">&#x003B7;</mml:mi><mml:mi>i</mml:mi><mml:mrow><mml:mrow><mml:mo>(</mml:mo><mml:mi>a</mml:mi><mml:mo>)</mml:mo></mml:mrow></mml:mrow></mml:msubsup></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover><mml:mo>,</mml:mo><mml:mtext>&#x02009;</mml:mtext><mml:mover accent='true'><mml:mrow><mml:msubsup><mml:mi mathvariant="bold-italic">&#x003B7;</mml:mi><mml:mi>i</mml:mi><mml:mrow><mml:mrow><mml:mo>(</mml:mo><mml:mrow><mml:mi mathvariant="bold-italic">min</mml:mi></mml:mrow><mml:mo>)</mml:mo></mml:mrow></mml:mrow></mml:msubsup></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mo>)</mml:mo></mml:mrow></mml:mrow><mml:mspace width="1em" class="nbsp"/><mml:mo class="MathClass-rel">&#x02200;</mml:mo><mml:mi>i</mml:mi></mml:math></disp-formula>
<disp-formula id="E21"><label>(21)</label><mml:math id="M102"><mml:mrow><mml:mi>&#x003B2;</mml:mi><mml:mrow><mml:mo>(</mml:mo><mml:mrow><mml:mover accent='true'><mml:mrow><mml:msubsup><mml:mi mathvariant="bold-italic">&#x003B7;</mml:mi><mml:mi>i</mml:mi><mml:mrow><mml:mrow><mml:mo>(</mml:mo><mml:mi>a</mml:mi><mml:mo>)</mml:mo></mml:mrow></mml:mrow></mml:msubsup></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover><mml:mo>,</mml:mo><mml:mtext>&#x02009;</mml:mtext><mml:mover accent='true'><mml:mrow><mml:msubsup><mml:mi mathvariant="bold-italic">&#x003B7;</mml:mi><mml:mi>i</mml:mi><mml:mrow><mml:mrow><mml:mo>(</mml:mo><mml:mrow><mml:mi mathvariant="bold-italic">min</mml:mi></mml:mrow><mml:mo>)</mml:mo></mml:mrow></mml:mrow></mml:msubsup></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mo>)</mml:mo></mml:mrow></mml:mrow><mml:mo class="MathClass-rel">&#x02261;</mml:mo><mml:mfenced separators="" open="{" close=""><mml:mrow><mml:mtable class="array"><mml:mtr><mml:mtd class="array" columnalign="left"><mml:msub><mml:mrow><mml:mi>&#x003B2;</mml:mi></mml:mrow><mml:mrow><mml:mn>0</mml:mn></mml:mrow></mml:msub></mml:mtd><mml:mtd class="array" columnalign="left"><mml:mrow><mml:mover accent='true'><mml:mrow><mml:msubsup><mml:mi mathvariant="bold-italic">&#x003B7;</mml:mi><mml:mi>i</mml:mi><mml:mrow><mml:mrow><mml:mo>(</mml:mo><mml:mrow><mml:mi mathvariant="italic">min</mml:mi></mml:mrow><mml:mo>)</mml:mo></mml:mrow></mml:mrow></mml:msubsup></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover><mml:mo>=</mml:mo><mml:mn>0</mml:mn></mml:mrow></mml:mtd></mml:mtr><mml:mtr><mml:mtd class="array" columnalign="left"><mml:mn>1</mml:mn></mml:mtd><mml:mtd class="array" columnalign="left"><mml:mrow><mml:mover accent='true'><mml:mrow><mml:msubsup><mml:mi mathvariant="bold-italic">&#x003B7;</mml:mi><mml:mi>i</mml:mi><mml:mrow><mml:mrow><mml:mo>(</mml:mo><mml:mi>a</mml:mi><mml:mo>)</mml:mo></mml:mrow></mml:mrow></mml:msubsup></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover><mml:mo>&#x0003E;</mml:mo><mml:mover accent='true'><mml:mrow><mml:msubsup><mml:mi mathvariant="bold-italic">&#x003B7;</mml:mi><mml:mi>i</mml:mi><mml:mrow><mml:mrow><mml:mo>(</mml:mo><mml:mrow><mml:mi mathvariant="italic">min</mml:mi></mml:mrow><mml:mo>)</mml:mo></mml:mrow></mml:mrow></mml:msubsup></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover></mml:mrow></mml:mtd></mml:mtr><mml:mtr><mml:mtd class="array" columnalign="left"><mml:mrow><mml:mover accent='true'><mml:mrow><mml:msubsup><mml:mi mathvariant="bold-italic">&#x003B7;</mml:mi><mml:mi>i</mml:mi><mml:mrow><mml:mrow><mml:mo>(</mml:mo><mml:mi>a</mml:mi><mml:mo>)</mml:mo></mml:mrow></mml:mrow></mml:msubsup></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover><mml:mtext>&#x02009;</mml:mtext><mml:mfrac><mml:mrow><mml:mn>1</mml:mn><mml:mo>&#x02212;</mml:mo><mml:msub><mml:mi>&#x003B2;</mml:mi><mml:mn>0</mml:mn></mml:msub></mml:mrow><mml:mrow><mml:msubsup><mml:mi mathvariant="bold-italic">&#x003B7;</mml:mi><mml:mi>i</mml:mi><mml:mrow><mml:mrow><mml:mo>(</mml:mo><mml:mrow><mml:mi mathvariant="italic">min</mml:mi></mml:mrow><mml:mo>)</mml:mo></mml:mrow></mml:mrow></mml:msubsup></mml:mrow></mml:mfrac><mml:mo>+</mml:mo><mml:msub><mml:mi>&#x003B2;</mml:mi><mml:mn>0</mml:mn></mml:msub></mml:mrow></mml:mtd><mml:mtd class="array" columnalign="left"><mml:mi mathvariant="normal">otherwise</mml:mi></mml:mtd></mml:mtr></mml:mtable></mml:mrow></mml:mfenced></mml:math></disp-formula>
<p>Let <inline-formula><mml:math id="M103"><mml:mrow><mml:mover accent='true'><mml:mrow><mml:msup><mml:mi mathvariant="bold-italic">&#x003B7;</mml:mi><mml:mrow><mml:mrow><mml:mo>(</mml:mo><mml:mtext>o</mml:mtext><mml:mo>)</mml:mo></mml:mrow></mml:mrow></mml:msup></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msup><mml:mrow><mml:msub><mml:mrow><mml:mi mathvariant="double-struck">R</mml:mi></mml:mrow><mml:mrow><mml:mo class="MathClass-rel">&#x02265;</mml:mo><mml:mn>0</mml:mn></mml:mrow></mml:msub></mml:mrow><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x000D7;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:math></inline-formula> be defined as the set of overlap duty cycles for all columns, such that <inline-formula><mml:math id="M104"><mml:mrow><mml:mover accent='true'><mml:mrow><mml:msubsup><mml:mi mathvariant="bold-italic">&#x003B7;</mml:mi><mml:mi>i</mml:mi><mml:mrow><mml:mrow><mml:mo>(</mml:mo><mml:mtext>o</mml:mtext><mml:mo>)</mml:mo></mml:mrow></mml:mrow></mml:msubsup></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover></mml:mrow></mml:math></inline-formula> is the overlap duty cycle for <inline-formula><mml:math id="M105"><mml:msub><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula>. Let update_overlap_duty_cycle(<inline-formula><mml:math id="M106"><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula>) be defined as a function that updates the moving average duty cycle for the overlap duty cycle for each <inline-formula><mml:math id="M107"><mml:msub><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula>. That function should compute the frequency of each column&#x02019;s overlap being at least equal to <italic>&#x003C1;</italic><sub><italic>d</italic></sub>. After applying update_overlap_duty_cycle(<inline-formula><mml:math id="M108"><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula>), the permanences are then boosted by using equation (<xref ref-type="disp-formula" rid="E22">22</xref>). This equation is equivalent to lines 13&#x02013;15 in Algorithm <xref ref-type="table" rid="AL3">3</xref>, where the multiplication with the indicator function is used to accomplish the conditional and clipping is done to ensure the permanences stay within bounds.</p>
<disp-formula id="E22"><label>(22)</label><mml:math id="M109"><mml:msup><mml:mrow><mml:mtext mathvariant="bold">&#x003A6;</mml:mtext></mml:mrow><mml:mrow><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mi>f</mml:mi></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:mrow></mml:msup><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mtext>clip</mml:mtext><mml:mfenced separators="" open="(" close=")"><mml:mrow><mml:msup><mml:mrow><mml:mtext mathvariant="bold">&#x003A6;</mml:mtext></mml:mrow><mml:mrow><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mi>i</mml:mi></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:mrow></mml:msup><mml:mo class="MathClass-bin">&#x02295;</mml:mo><mml:msub><mml:mrow><mml:mn>&#x003BA;</mml:mn></mml:mrow><mml:mrow><mml:mi>b</mml:mi></mml:mrow></mml:msub><mml:msub><mml:mrow><mml:mi>&#x003C1;</mml:mi></mml:mrow><mml:mrow><mml:mi>s</mml:mi></mml:mrow></mml:msub><mml:mtext>I</mml:mtext><mml:mrow><mml:mrow><mml:mo>(</mml:mo><mml:mrow><mml:mover accent='true'><mml:mrow><mml:msubsup><mml:mi>&#x03B7;</mml:mi><mml:mi>i</mml:mi><mml:mrow><mml:mo stretchy='false'>(</mml:mo><mml:mi>o</mml:mi><mml:mo stretchy='false'>)</mml:mo></mml:mrow></mml:msubsup></mml:mrow><mml:mo stretchy='true'>&#x21C0;</mml:mo></mml:mover><mml:mo>&#x003C;</mml:mo><mml:mover accent='true'><mml:mrow><mml:msubsup><mml:mi>&#x03B7;</mml:mi><mml:mi>i</mml:mi><mml:mrow><mml:mo stretchy='false'>(</mml:mo><mml:mi>min</mml:mi><mml:mo stretchy='false'>)</mml:mo></mml:mrow></mml:msubsup></mml:mrow><mml:mo stretchy='true'>&#x21C0;</mml:mo></mml:mover></mml:mrow><mml:mo>)</mml:mo></mml:mrow></mml:mrow><mml:mo class="MathClass-punc">,</mml:mo><mml:mn>0</mml:mn><mml:mo class="MathClass-punc">,</mml:mo><mml:mn>1</mml:mn></mml:mrow></mml:mfenced></mml:math></disp-formula>
<p>Let d(<italic>x, y</italic>) be defined as the distance function<xref ref-type="fn" rid="fn7"><sup>7</sup></xref> that computes the distance between <italic>x</italic> and <italic>y</italic>. To simplify the notation,<xref ref-type="fn" rid="fn8"><sup>8</sup></xref> let pos(<italic>c, r</italic>) be defined as a function that will return the position of the column indexed at <italic>c</italic> located <italic>r</italic> regions away from the current region. For example, pos(0, 0) returns the position of the first column located in the SP and pos(0, &#x02212;1) returns the position of the first column located in the previous region. The distance between <inline-formula><mml:math id="M110"><mml:mi mathvariant="normal">pos</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msub><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-punc">,</mml:mo><mml:mn>0</mml:mn></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></inline-formula> and pos<inline-formula><mml:math id="M111"><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:msub><mml:mrow><mml:mi mathvariant="bold">&#x0039B;</mml:mi></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-punc">,</mml:mo><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>1</mml:mn></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:math></inline-formula> is then determined by <inline-formula><mml:math id="M112"><mml:mi mathvariant="normal">d</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mi mathvariant="normal">pos</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msub><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-punc">,</mml:mo><mml:mn>0</mml:mn></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow><mml:mo class="MathClass-punc">,</mml:mo><mml:mi mathvariant="normal">pos</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:msub><mml:mrow><mml:mi mathvariant="bold">&#x0039B;</mml:mi></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-punc">,</mml:mo><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>1</mml:mn></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:math></inline-formula>.</p>
<p>Let <inline-formula><mml:math id="M113"><mml:mtext mathvariant="bold-italic">D</mml:mtext><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msup><mml:mrow><mml:msub><mml:mrow><mml:mi mathvariant="double-struck">R</mml:mi></mml:mrow><mml:mrow><mml:mo class="MathClass-rel">&#x0003E;</mml:mo><mml:mn>0</mml:mn></mml:mrow></mml:msub></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x000D7;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:math></inline-formula> be defined as the distance between an SP column and its corresponding connected synapses&#x02019; source columns, such that <inline-formula><mml:math id="M114"><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">D</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula> is the distance between <inline-formula><mml:math id="M115"><mml:msub><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula> and <inline-formula><mml:math id="M116"><mml:msub><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula>&#x02019;s proximal synapse&#x02019;s input at index <italic>k</italic>. <bold><italic>D</italic></bold> is defined by equation (<xref ref-type="disp-formula" rid="E23">23</xref>), where <bold><italic>Y</italic></bold><italic><sub>i</sub></italic> is used as a mask to ensure that only connected synapses may contribute to the distance calculation. The result of that element-wise multiplication would be the distance between the two columns or zero for connected and unconnected synapses, respectively.<xref ref-type="fn" rid="fn9"><sup>9</sup></xref></p>
<disp-formula id="E23"><label>(23)</label><mml:math id="M117"><mml:mtext mathvariant="bold-italic">D</mml:mtext><mml:mo class="MathClass-rel">&#x02261;</mml:mo><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mtext>d</mml:mtext><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mtext>pos</mml:mtext><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msub><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-punc">,</mml:mo><mml:mn>0</mml:mn></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow><mml:mo class="MathClass-punc">,</mml:mo><mml:mtext>pos</mml:mtext><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:msub><mml:mrow><mml:mtext mathvariant="bold">&#x0039B;</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-punc">,</mml:mo><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>1</mml:mn></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow><mml:mo class="MathClass-bin">&#x02299;</mml:mo><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">Y</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub><mml:mspace width="0.3em" class="nbsp"/><mml:mo class="MathClass-rel">&#x02200;</mml:mo><mml:mi>k</mml:mi></mml:mrow><mml:mo class="MathClass-close">)</mml:mo><mml:mspace width="0.3em" class="nbsp"/><mml:mo class="MathClass-rel">&#x02200;</mml:mo><mml:mi>i</mml:mi></mml:math></disp-formula>
<p>The inhibition radius, <italic>&#x003C3;</italic><sub>0</sub>, is defined by equation (<xref ref-type="disp-formula" rid="E24">24</xref>). The division in equation (<xref ref-type="disp-formula" rid="E24">24</xref>) is the sum of the distances divided by the number of connected synapses.<xref ref-type="fn" rid="fn10"><sup>10</sup></xref> That division represents the average distance between connected synapses&#x02019; source and destination columns and is therefore the average receptive field size. The inhibition radius is then set to the average receptive field size after it has been floored and raised to a minimum value of one, ensuring that the radius is an integer at least equal to one. Comparing equation (<xref ref-type="disp-formula" rid="E24">24</xref>) to line 16 in Algorithm <xref ref-type="table" rid="AL3">3</xref>, the two are equivalent.</p>
<disp-formula id="E24"><label>(24)</label><mml:math id="M118"><mml:msub><mml:mrow><mml:mi>&#x003C3;</mml:mi></mml:mrow><mml:mrow><mml:mi>o</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x02261;</mml:mo><mml:mtext>max</mml:mtext><mml:mfenced separators="" open="(" close=")"><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-punc">,</mml:mo><mml:mfenced separators="" open="&#x0230A;" close="&#x0230B;"><mml:mrow><mml:mfrac><mml:mrow><mml:msubsup><mml:mrow><mml:mo class="MathClass-op">&#x02211;</mml:mo></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>0</mml:mn></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>1</mml:mn></mml:mrow></mml:msubsup><mml:msubsup><mml:mrow><mml:mo class="MathClass-op">&#x02211;</mml:mo></mml:mrow><mml:mrow><mml:mi>k</mml:mi><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>0</mml:mn></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>1</mml:mn></mml:mrow></mml:msubsup><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">D</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mrow><mml:mtext>max</mml:mtext><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-punc">,</mml:mo><mml:msubsup><mml:mrow><mml:mo class="MathClass-op">&#x02211;</mml:mo></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>0</mml:mn></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>1</mml:mn></mml:mrow></mml:msubsup><mml:msubsup><mml:mrow><mml:mo class="MathClass-op">&#x02211;</mml:mo></mml:mrow><mml:mrow><mml:mi>k</mml:mi><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>0</mml:mn></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>1</mml:mn></mml:mrow></mml:msubsup><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">Y</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:mrow></mml:mfrac></mml:mrow></mml:mfenced></mml:mrow></mml:mfenced></mml:math></disp-formula>
<p>Two types of inhibition exist, namely global and local inhibition. With global inhibition, the neighborhood is taken to be all columns in the SP, i.e., every value in <bold><italic>H</italic></bold> would be set to one regardless of the system&#x02019;s topology. With local inhibition, the neighborhood is determined by the inhibition radius. Using the desired inhibition type, the neighborhood for each column is updated. This is done using the function <inline-formula><mml:math id="M119"><mml:mtext>h</mml:mtext><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msub><mml:mrow><mml:mover accent="true"><mml:mrow><mml:mtext mathvariant="bold-italic">c</mml:mtext></mml:mrow><mml:mrow><mml:mo class="MathClass-rel">&#x021C0;</mml:mo></mml:mrow></mml:mover></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></inline-formula>, which is dependent upon the type of inhibition as well as the topology of the system. This function is shown in equation (<xref ref-type="disp-formula" rid="E25">25</xref>), where <inline-formula><mml:math id="M120"><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003B6;</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula> represents all of the columns located at the set of integer Cartesian coordinates bounded by an <italic>n</italic>-dimensional shape. Typically the <italic>n</italic>-dimensional shape is a represented by an <italic>n</italic>-dimensional hypercube. Note that if global inhibition is used, additional optimizations of equations (<xref ref-type="disp-formula" rid="E16">16</xref>) and (<xref ref-type="disp-formula" rid="E19">19</xref>) may be made, and the need for equations (<xref ref-type="disp-formula" rid="E24">24</xref>) and (<xref ref-type="disp-formula" rid="E25">25</xref>) is eliminated. For simplicity, only the generalized forms of the equations, supporting both global and local inhibition, were shown.</p>
<disp-formula id="E25"><label>(25)</label><mml:math id="M121"><mml:mtext>h</mml:mtext><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msub><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mfenced separators="" open="{" close=""><mml:mrow><mml:mtable equalrows="false" columnlines="none" equalcolumns="false" class="array"><mml:mtr><mml:mtd class="array" columnalign="left"><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mspace width="1em" class="quad"/></mml:mtd><mml:mtd class="array" columnalign="left"><mml:mtext mathvariant="italic">global inhibition</mml:mtext></mml:mtd></mml:mtr><mml:mtr><mml:mtd class="array" columnalign="left"><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003B6;</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mtd><mml:mtd class="array" columnalign="left"><mml:mtext mathvariant="italic">local inhibition</mml:mtext></mml:mtd></mml:mtr></mml:mtable></mml:mrow></mml:mfenced></mml:math></disp-formula>
</sec>
</sec>
<sec id="S4">
<label>4</label> <title>Boosting</title>
<p>It is important to understand the dynamics of boosting utilized by the SP. The SP&#x02019;s boosting mechanism is similar to DeSieno (<xref ref-type="bibr" rid="B6">1988</xref>) conscience mechanism. In that work, clusters that were too frequently active were penalized, allowing weak clusters to contribute to learning. The SP&#x02019;s primary boosting mechanism takes the reverse approach by rewarding infrequently active columns. Clearly, the boosting frequency and amount will impact the SP&#x02019;s learned representations.</p>
<p>The degree of activation is determined by the boost function, equation (<xref ref-type="disp-formula" rid="E21">21</xref>). From that equation, it is clear that a column&#x02019;s boost is determined by the column&#x02019;s minimum active duty cycle as well as the column&#x02019;s active duty cycle. Those two values are coupled, as a column&#x02019;s minimum active duty cycle is a function of its duty cycle, as shown in equation (<xref ref-type="disp-formula" rid="E19">19</xref>). To study how those two parameters affect a column&#x02019;s boost, Figure <xref ref-type="fig" rid="F5">5</xref> was created. From this plot, it is found that the non-boundary conditions for a column&#x02019;s boost follow the shape <inline-formula><mml:math id="M122"><mml:mrow><mml:mn>1</mml:mn><mml:mo>/</mml:mo><mml:mover accent='true'><mml:mrow><mml:msubsup><mml:mi mathvariant="bold-italic">&#x003B7;</mml:mi><mml:mi>i</mml:mi><mml:mrow><mml:mrow><mml:mo>(</mml:mo><mml:mrow><mml:mi mathvariant="italic">min</mml:mi></mml:mrow><mml:mo>)</mml:mo></mml:mrow></mml:mrow></mml:msubsup></mml:mrow><mml:mo stretchy='true'>&#x021C0;</mml:mo></mml:mover></mml:mrow></mml:math></inline-formula>. It additionally shows the importance of evaluating the piecewise boost function in order. If the second condition is evaluated before the first condition, the boost will be set to its minimum, instead of its maximum value.</p>
<fig position="float" id="F5">
<label>Figure 5</label>
<caption><p><bold>Demonstration of boost as a function of a column&#x02019;s minimum active duty cycle and active duty cycle</bold>.</p></caption>
<graphic xlink:href="frobt-03-00081-g005.tif"/>
</fig>
<p>To study the frequency of boosting, the average number of boosted columns was observed by varying the level of sparseness in the input for both types of inhibition, as shown in Figure <xref ref-type="fig" rid="F6">6</xref>.<xref ref-type="fn" rid="fn11"><sup>11</sup></xref> For the overlap boosting mechanism, equation (<xref ref-type="disp-formula" rid="E20">20</xref>), very little boosting occurs, with boosting occurring more frequently for denser inputs. This is to be expected, as more input columns would be active; thus, causing more competition to occur among the SP&#x02019;s columns.</p>
<fig position="float" id="F6">
<label>Figure 6</label>
<caption><p><bold>Demonstration of frequency of both boosting mechanisms as a function of the sparseness of the input</bold>. The top figure shows the results for global inhibition and the bottom figure shows the results for local inhibition.</p></caption>
<graphic xlink:href="frobt-03-00081-g006.tif"/>
</fig>
<p>For the permanence boosting mechanism, equation (<xref ref-type="disp-formula" rid="E22">22</xref>), boosting primarily occurs when the sparsity is between 70 and 76%, with almost no boosting occurring outside of that range. That boosting is a result of the SP&#x02019;s parameters. In this experiment, <italic>n<sub>ps</sub></italic>&#x02009;&#x0003D;&#x02009;40 and <italic>&#x003C1;</italic><sub><italic>d</italic></sub>&#x02009;&#x0003D;&#x02009;15. Based off those parameters, there must be at least 25 active connected proximal synapses on a column for it have a non-zero overlap; i.e., if the sparsity is 75%, a column would have to be connected to each active column in the input to obtain a non-zero overlap. As such, if the sparsity is greater than 75%, it will not be possible for the SP&#x02019;s columns to have a non-zero overlap, resulting in no boosting. For lower amounts of sparsity, boosting was not needed, since adequate coverage of the active input columns is obtained.</p>
<p>Recall that the initialization of the SP is performed randomly. Additionally, the positions of active columns for this dataset are random. That randomness combined with a starved level of activity results in a high degree of volatility. This is observed by the extremely large error bars. Some of the SP&#x02019;s initializations resulted in more favorable circumstances, since the columns were able to connect to the active input columns.</p>
<p>For the SP to adapt to the lack of active input columns, it would have to boost its permanence. This would result in a large amount of initial boosting, until the permanences reached a high enough value. Once the permanences reach that value, boosting will only be required occasionally, to ensure the permanences never fully decay. This behavior is observed in Figure <xref ref-type="fig" rid="F7">7</xref>, where the permanence boosting frequency was plotted for a sparsity of 74%. The delayed start occurs because the SP has not yet determined which columns will need to be boosted. Once that set is determined, a large amount of boosting occurs. The trend follows a decaying exponential that falls until its minimum level is reached, at which point the overall degree of boosting remains constant. This trend was common among the sparsities that resulted in a noticeable degree of permanence boosting. The right-skewed decaying exponential was also observed in DeSieno (<xref ref-type="bibr" rid="B6">1988</xref>) work.</p>
<fig position="float" id="F7">
<label>Figure 7</label>
<caption><p><bold>Frequency of boosting for the permanence boosting mechanism for a sparsity of 74%</bold>. The top figure shows the results for global inhibition and the bottom figure shows the results for local inhibition. Only the first 200 iterations were shown, for clarity, as the remaining 800 propagated the trend.</p></caption>
<graphic xlink:href="frobt-03-00081-g007.tif"/>
</fig>
<p>These results show that the need for boosting can be eliminated by simply choosing appropriate values for <italic>n<sub>ps</sub></italic> and <italic>&#x003C1;</italic><sub><italic>d</italic></sub>.<xref ref-type="fn" rid="fn12"><sup>12</sup></xref> It is thus concluded that these boosting mechanisms are secondary learning mechanisms, with the primary learning occurring from the permanence update in equation (<xref ref-type="disp-formula" rid="E17">17</xref>). These findings allow resource limited systems (especially hardware designs) to exclude boosting, while still obtaining comparable results; thereby, greatly reducing the complexity of the system.</p>
</sec>
<sec id="S5">
<label>5</label> <title>Feature Learning</title>
<sec id="S5-8">
<label>5.1</label> <title>Feature Selection and Dimensionality Reduction</title>
<p>It is convenient to think of a permanence value as a probability. That probability is used to determine if a synapse is connected or unconnected. It also represents the probability that the synapse&#x02019;s input is important. It is possible for a given synaptic input to be represented in multiple contexts, where the context for a specific instance is defined to be the set of inputs connected, <italic>via</italic> proximal synapses, to a column. Due to the initialization of the network, it is apparent that each context represents a random subspace; therefore, each column is learning the probability of importance for its random subset of attributes in the feature space. This is evident in equation (<xref ref-type="disp-formula" rid="E18">18</xref>), as permanences contributing to a column&#x02019;s activation are positively reinforced and permanences not contributing to a column&#x02019;s activation are negatively reinforced.</p>
<p>If all contexts for a given synaptic input are observed, the overall importance of that input is obtained. Multiple techniques could be conjured for determining how the contexts are combined. The most generous method is simply to observe the maximum. In this manner, if the attribute was important in at least one of the random subspaces, it would be observed. Using those new probabilities the degree of influence of an attribute may be obtained. Let <inline-formula><mml:math id="M123"><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003D5;</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msup><mml:mrow><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mn>0</mml:mn><mml:mo class="MathClass-punc">,</mml:mo><mml:mn>1</mml:mn></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:mrow><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x000D7;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>a</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:math></inline-formula> be defined as the set of learned attribute probabilities, such that <inline-formula><mml:math id="M124"><mml:mrow><mml:msub><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003D5;</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mi>a</mml:mi></mml:msub></mml:mrow></mml:math></inline-formula> represents the probability of <bold><italic>U</italic></bold><italic><sub>s,a</sub></italic> being a meaningful attribute. One form of <inline-formula><mml:math id="M125"><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003D5;</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula> is shown in equation (<xref ref-type="disp-formula" rid="E26">26</xref>).<xref ref-type="fn" rid="fn13"><sup>13</sup></xref> In equation (<xref ref-type="disp-formula" rid="E26">26</xref>), the indicator function is used to mask the permanence values for <bold><italic>U</italic></bold><italic><sub>s,a</sub></italic>. Multiplying that value by every permanence in <bold>&#x003A6;</bold> obtains all of the permanences for <bold><italic>U</italic></bold><italic><sub>s,a</sub></italic>.</p>
<disp-formula id="E26"><label>(26)</label><mml:math id="M126"><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003D5;</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mtext>max</mml:mtext><mml:mfenced separators="" open="(" close=")"><mml:mrow><mml:msub><mml:mrow><mml:mi mathvariant="bold">&#x003A6;</mml:mi></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub><mml:mtext>I</mml:mtext><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msub><mml:mrow><mml:mi mathvariant="bold">&#x0039B;</mml:mi></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mi>a</mml:mi></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow><mml:mspace width="0.3em" class="nbsp"/><mml:mo class="MathClass-rel">&#x02200;</mml:mo><mml:mi>i</mml:mi><mml:mspace width="0.3em" class="nbsp"/><mml:mo class="MathClass-rel">&#x02200;</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:mfenced><mml:mspace width="0.3em" class="nbsp"/><mml:mo class="MathClass-rel">&#x02200;</mml:mo><mml:mi>a</mml:mi></mml:math></disp-formula>
<p>Using <inline-formula><mml:math id="M127"><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003D5;</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula> it is possible to extract a set of meaningful features from the original set of input attributes. This is done by selecting attributes whose corresponding <inline-formula><mml:math id="M128"><mml:mrow><mml:msub><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003D5;</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mi>a</mml:mi></mml:msub></mml:mrow></mml:math></inline-formula> is above some threshold. In the case of equation (<xref ref-type="disp-formula" rid="E26">26</xref>), the threshold is <italic>&#x003C1;</italic><sub><italic>s</italic></sub>. This is because <inline-formula><mml:math id="M129"><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003D5;</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula> is representative of the maximum permanence for each attribute in <bold><italic>U</italic></bold><sub><italic>s</italic></sub>, and for a given <bold><italic>U</italic></bold><italic><sub>s,a</sub></italic> to be observed it must be connected, which may only happen when its permanence is at least equal to <italic>&#x003C1;</italic><sub><italic>s</italic></sub>. The original set of attributes may then be reduced to a new set of meaningful features. This is done by selecting all attributes whose indexes are in <inline-formula><mml:math id="M130"><mml:mover accent='true'><mml:mi mathvariant="bold-italic">u</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula>, which is obtained by equation (<xref ref-type="disp-formula" rid="E27">27</xref>). Therefore, <inline-formula><mml:math id="M131"><mml:mover accent='true'><mml:mi mathvariant="bold-italic">u</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula> will contain the set of all indexes in <inline-formula><mml:math id="M132"><mml:mrow><mml:mo class="MathClass-open">&#x0007B;</mml:mo><mml:mrow><mml:mn>0</mml:mn><mml:mo class="MathClass-punc">,</mml:mo><mml:mn>1</mml:mn><mml:mo class="MathClass-punc">,</mml:mo><mml:mo class="MathClass-op">&#x02026;</mml:mo><mml:mo class="MathClass-punc">,</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>a</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>1</mml:mn></mml:mrow><mml:mo class="MathClass-close">&#x0007D;</mml:mo></mml:mrow></mml:math></inline-formula> whose <inline-formula><mml:math id="M133"><mml:mrow><mml:msub><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003D5;</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mi>a</mml:mi></mml:msub></mml:mrow><mml:mo class="MathClass-rel">&#x02265;</mml:mo><mml:msub><mml:mrow><mml:mi>&#x003C1;</mml:mi></mml:mrow><mml:mrow><mml:mi>s</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula>. The dimensionality of <bold><italic>U</italic></bold><italic><sub>s</sub></italic> may be reduced to the size of <inline-formula><mml:math id="M134"><mml:mover accent='true'><mml:mi mathvariant="bold-italic">u</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula>, which will have a length of <italic>n<sub>a</sub></italic> or less.</p>
<disp-formula id="E27"><label>(27)</label><mml:math id="M135"><mml:mover accent='true'><mml:mi mathvariant="bold-italic">u</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mrow><mml:mo class="MathClass-open">&#x0007B;</mml:mo><mml:mrow><mml:mi>a</mml:mi><mml:mo>&#x0007C;</mml:mo></mml:mrow><mml:mrow><mml:msub><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003D5;</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mi>a</mml:mi></mml:msub></mml:mrow><mml:mo class="MathClass-rel">&#x02265;</mml:mo><mml:msub><mml:mrow><mml:mi>&#x003C1;</mml:mi></mml:mrow><mml:mrow><mml:mi>s</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">&#x0007D;</mml:mo><mml:mspace width="0.3em" class="nbsp"/><mml:mo class="MathClass-rel">&#x02200;</mml:mo><mml:mi>a</mml:mi></mml:math></disp-formula>
</sec>
<sec id="S5-9">
<label>5.2</label> <title>Input Reconstruction</title>
<p>Building off the feature selection technique, it is possible to obtain the SP&#x02019;s learned representation of a specific input. To reconstruct the input, the SP&#x02019;s active columns for that input must be captured. This is naturally done during inhibition, where <inline-formula><mml:math id="M136"><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula> is constructed. <inline-formula><mml:math id="M137"><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula>, a function of <bold><italic>U</italic></bold><italic><sub>s</sub></italic>, is used to represent a specific input in the context of the SP.</p>
<p>Determining which permanences caused the activation is as simple as using <inline-formula><mml:math id="M138"><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula> to mask <bold>&#x003A6;</bold>. Once that representation has been obtained, <inline-formula><mml:math id="M139"><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003D5;</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula> is used to obtain the overall permanence for the attributes. Those steps will produce a valid probability for each attribute; however, it is likely that there will exist probabilities that are not explicitly in {0, 1}. To account for that, the same technique used for dimensionality reduction is applied, by simply thresholding the probability at <italic>&#x003C1;</italic><sub><italic>s</italic></sub>. This process is shown in equation (<xref ref-type="disp-formula" rid="E28">28</xref>),<xref ref-type="fn" rid="fn14"><sup>14</sup></xref> where <inline-formula><mml:math id="M140"><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">u</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msup><mml:mrow><mml:mrow><mml:mo class="MathClass-open">&#x0007B;</mml:mo><mml:mrow><mml:mn>0</mml:mn><mml:mo class="MathClass-punc">,</mml:mo><mml:mn>1</mml:mn></mml:mrow><mml:mo class="MathClass-close">&#x0007D;</mml:mo></mml:mrow></mml:mrow><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x000D7;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>a</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:math></inline-formula> is defined to be the reconstructed input.</p>
<p>Thornton and Srbic (<xref ref-type="bibr" rid="B22">2013</xref>) used a similar approach for showing how the representation of the input to the SP is understood. The key advantage of this approach is that the input is able to be reconstructed based solely off the permanences and the active columns. This is a novel approach that allows for the input to be decoupled from the system.</p>
<disp-formula id="E28"><label>(28)</label><mml:math id="M141"><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">u</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mtext>I</mml:mtext><mml:mfenced separators="" open="(" close=")"><mml:mrow><mml:mfenced separators="" open="[" close="]"><mml:mrow><mml:mtext>max</mml:mtext><mml:mfenced separators="" open="(" close=")"><mml:mrow><mml:msub><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mi>i</mml:mi></mml:msub><mml:msub><mml:mover accent='true'><mml:mover accent='true'><mml:mi>&#x003D5;</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mi>a</mml:mi></mml:msub></mml:mrow><mml:mspace width="0.3em" class="nbsp"/><mml:mrow><mml:msub><mml:mo>&#x02200;</mml:mo><mml:mi>i</mml:mi></mml:msub></mml:mrow></mml:mfenced><mml:mo class="MathClass-rel">&#x02265;</mml:mo><mml:msub><mml:mrow><mml:mi>&#x003C1;</mml:mi></mml:mrow><mml:mrow><mml:mi>s</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:mfenced></mml:mrow></mml:mfenced><mml:mspace width="0.3em" class="nbsp"/><mml:mo class="MathClass-rel">&#x02200;</mml:mo><mml:mi>a</mml:mi></mml:math></disp-formula>
</sec>
</sec>
<sec id="S6" sec-type="discussion">
<label>6</label> <title>Experimental Results and Discussion</title>
<p>To empirically investigate the performance of the SP, a Python implementation of the SP was created, called math HTM (mHTM).<xref ref-type="fn" rid="fn15"><sup>15</sup></xref> This library was built using the mathematical framework described in this work. An initial implementation of the SP was previously created following the original algorithmic definition. Using the new math-based framework, a speedup of three orders of magnitude was obtained.</p>
<p>The SP was tested on both spatial data as well as categorical data. The details of those experiments are explained in the ensuing subsections.</p>
<sec id="S6-10">
<label>6.1</label> <title>Spatial Data</title>
<p>The SP is a spatial algorithm, as such, it should perform well with inherently spatial data. To investigate this, the SP was tested with a well-known computer vision task. The SP requires a binary input; as such, it was desired to work with images that were originally black and white or could be readily made black and white without losing too much information. Another benefit of using this type of image is that the encoder<xref ref-type="fn" rid="fn16"><sup>16</sup></xref> may be de-emphasized, allowing for the primary focus to be on the SP. With those constraints, the modified National Institute of Standards and Technology&#x02019;s (MNIST&#x02019;s) database of handwritten digits (LeCun et al., <xref ref-type="bibr" rid="B16">1998</xref>) was chosen as the dataset.</p>
<p>The MNIST images are simple 28&#x02009;&#x000D7;&#x02009;28 grayscale images, with the bulk of the pixels being black or white. To convert them to black and white images, each pixel was set to &#x0201C;1&#x0201D; if the value was greater than or equal to 255/2 and &#x0201C;0&#x0201D; otherwise. Each image was additionally transformed to be one-dimensional by horizontally stacking the rows. The SP has a large number of parameters, making it difficult to optimize the parameter selection. To help with this, 1,000 independent trials were created, all having a unique set of parameters. The parameters were randomly selected within reasonable limits.<xref ref-type="fn" rid="fn17"><sup>17</sup></xref> Additionally, parameters were selected such that <inline-formula><mml:math id="M142"><mml:mi mathvariant="double-struck">E</mml:mi><mml:mrow><mml:mo class="MathClass-open">[</mml:mo><mml:mrow><mml:mn>&#x003BB;</mml:mn><mml:mo class="MathClass-rel">&#x02032;</mml:mo></mml:mrow><mml:mo class="MathClass-close">]</mml:mo></mml:mrow><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>0</mml:mn></mml:math></inline-formula>. To reduce the computational load, the size of the MNIST dataset was reduced to 800 training inputs and 200 testing inputs. The inputs were chosen from their respective initial sets using a stratified shuffle split with a total of five splits. To ensure repeatability and to allow proper comparisons, care was taken to ensure that both within and across experiments the same random initializations were occurring. After performing the initial experimental batch, the final parameters were selected. Using those parameters, the full MNIST dataset was used. To perform the classification, a linear support vector machine (SVM) was utilized. The input to the SVM was the corresponding output of the SP.</p>
<p>Three comparisons were explored for both global and local inhibition: using the set of active columns as the features (denoted as &#x0201C;column&#x0201D;), using <inline-formula><mml:math id="M143"><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003D5;</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula> as the features (denoted as &#x0201C;probabilistic&#x0201D;) and using the dimensionality reduced version of the original input as the new input (denoted as &#x0201C;reduction&#x0201D;). The results are shown in Table <xref ref-type="table" rid="T2">2</xref><xref ref-type="fn" rid="fn18"><sup>18</sup></xref> and Table <xref ref-type="table" rid="T3">3</xref><xref ref-type="fn" rid="fn19"><sup>19</sup></xref> for global and local inhibition, respectively. For reference, the same SVM without the SP resulted in an error of 7.95%. The number of dimensions was reduced by 38.01 and 35.71% for global and local inhibition, respectively. Both the probabilistic and reduction methods only performed marginally worse than the base SVM classifier. Considering that these two techniques are used to modify the raw input, it is likely that the learned features were the face of the numbers (referring to attributes equaling &#x0201C;1&#x0201D;). In that case, those methods would almost act as pass through filters, as the SVM is already capable of determining which attributes are more/less significant. That being said, being able to reduce the number of attributes by over two thirds, for the local inhibition case, while still performing relatively close to the case where all attributes are used is quite desirable.</p>
<table-wrap position="float" id="T2">
<label>Table 2</label>
<caption><p><bold>SP performance on MNIST using global inhibition</bold>.</p></caption>
<table frame="hsides" rules="groups">
<thead>
<tr>
<th align="left">Method</th>
<th align="center">Error (%)</th>
</tr>
</thead>
<tbody>
<tr>
<td align="left">Column</td>
<td align="center">7.61</td>
</tr>
<tr>
<td align="left">Probabilistic</td>
<td align="center">9.02</td>
</tr>
<tr>
<td align="left">Reduction</td>
<td align="center">9.04</td>
</tr>
</tbody>
</table>
</table-wrap>
<table-wrap position="float" id="T3">
<label>Table 3</label>
<caption><p><bold>SP performance on MNIST using local inhibition</bold>.</p></caption>
<table frame="hsides" rules="groups">
<thead>
<tr>
<th align="left">Method</th>
<th align="center">Error (%)</th>
</tr>
</thead>
<tbody>
<tr>
<td align="left">Column</td>
<td align="center">7.73</td>
</tr>
<tr>
<td align="left">Probabilistic</td>
<td align="center">8.98</td>
</tr>
<tr>
<td align="left">Reduction</td>
<td align="center">9.07</td>
</tr>
</tbody>
</table>
</table-wrap>
<p>Using the active columns as the learned feature is the default behavior, and it is those activations that would become the feedforward input to the next level (assuming an HTM with multiple SPs and/or TMs). Both global and local inhibition outperformed the SVM, but only by a slight amount. Considering that only one SP region was utilized, that the SP&#x02019;s primary goal is to map the input into a new domain to be understood by the TM, and that the SP did not hurt the SVM&#x02019;s ability to classify, the SP&#x02019;s overall performance is acceptable. It is also possible that given a two-dimensional topology and restricting the initialization of synapses to a localized radius may improve the accuracy of the network. Comparing global to local inhibition, comparable results are obtained. This is likely due to the globalized formation of synaptic connections upon initialization, since that results in a loss of the initial network topology.</p>
<p>To explore the input reconstruction technique, a random instance of each class from MNIST was selected. The input was then reconstructed as shown in Figure <xref ref-type="fig" rid="F8">8</xref>.<xref ref-type="fn" rid="fn20"><sup>20</sup></xref> The top row shows the original representation of the inputs. The middle row shows the SDR of the inputs. The bottom row shows the reconstructed versions. The representations are by no means perfect, but it is evident that the SP is indeed learning an accurate representation of the input.</p>
<fig position="float" id="F8">
<label>Figure 8</label>
<caption><p><bold>Reconstruction of the input from the context of the SP</bold>. Shown are the original input images (top), the SDRs (middle), and the reconstructed version (bottom).</p></caption>
<graphic xlink:href="frobt-03-00081-g008.tif"/>
</fig>
</sec>
<sec id="S6-11">
<label>6.2</label> <title>Categorical Data</title>
<p>One of the main purposes of the SP is to create a spatial representation of its input through the process of mapping its input to SDRs. To explore this, the SP was tested on Bohanec and Rajkovic (<xref ref-type="bibr" rid="B2">1988</xref>) and Lichman (<xref ref-type="bibr" rid="B17">2013</xref>) car evaluation dataset. This dataset consists of four classes and six attributes. Each attribute has a finite number of states with no missing values. To encode the attributes, a multivariate encoder comprised of categorical encoders was used.<xref ref-type="fn" rid="fn21"><sup>21</sup></xref> The class labels were also encoded, by using a single category encoder.<xref ref-type="fn" rid="fn22"><sup>22</sup></xref></p>
<p>The selection of the SP&#x02019;s parameters was determined through manual experimentation.<xref ref-type="fn" rid="fn23"><sup>23</sup></xref> Cross validation was used, by partitioning the data using a stratified shuffle split with eight splits. To perform the classification an SVM was utilized, where the output of the SP was the corresponding input to the SVM. The SP&#x02019;s performance was also compared to just using the linear SVM and using a random forest classifier.<xref ref-type="fn" rid="fn24"><sup>24</sup></xref> For those classifiers, a simple preprocessing step was performed to map the text-based values to integers.</p>
<p>The results are shown in Table <xref ref-type="table" rid="T4">4</xref>.<xref ref-type="fn" rid="fn25"><sup>25</sup></xref> The SVM performed poorly, having an error of 26.01%. Not surprisingly, the random forest classifier performed much better, obtaining an error of 8.96%. The SP was able to far outperform either classifier, obtaining an error of only 2.32%. From literature, the best known error on this dataset was 0.37%, which was obtained from a boosted multilayer perceptron (Oza, <xref ref-type="bibr" rid="B19">2005</xref>).</p>
<table-wrap position="float" id="T4">
<label>Table 4</label>
<caption><p><bold>Comparison of classifiers on car evaluation dataset</bold>.</p></caption>
<table frame="hsides" rules="groups">
<thead>
<tr>
<th align="left">Classifier</th>
<th align="center">Error (%)</th>
</tr>
</thead>
<tbody>
<tr>
<td align="left">Linear SVM</td>
<td align="center">26.01</td>
</tr>
<tr>
<td align="left">Random forest</td>
<td align="center">8.96</td>
</tr>
<tr>
<td align="left">SP&#x02009;&#x0002B;&#x02009;linear SVM</td>
<td align="center">2.32</td>
</tr>
</tbody>
</table>
</table-wrap>
<p>This result shows that the SP was able to map the input data into a suitable format for the SVM, thereby drastically improving the SVM&#x02019;s classification. Based off this, it is determined that the SP produced a suitable encoding.</p>
</sec>
<sec id="S6-12">
<label>6.3</label> <title>Extended Discussion</title>
<p>Comparing the SP&#x02019;s performance on spatial data to that of categorical data provides some interesting insights. It was observed that on spatial data the SP effectively acted as a pass through filter. This behavior occurs because the data is inherently spatial. The SP maps the spatial data to a new spatial representation. This mapping allows classifiers, such as an SVM, to be able to classify the data with equal effectiveness.</p>
<p>Preprocessing the categorical data with the SP provided the SVM with a new spatial representation. That spatial representation was understood by the SVM as readily as if it were inherently spatial. This implies that the SP may be used to create a spatial representation from non-spatial data. This would thereby provide other algorithms, such as the TM and traditional spatial classifiers, a means to interpret non-spatial data.</p>
</sec>
</sec>
<sec id="S7">
<label>7</label> <title>Exploring the Primary Learning Mechanism</title>
<p>To complete the mathematical formulation, it is necessary to define a function governing the primary learning process. Within the SP, there are many learned components: the set of active columns, the neighborhood (through the inhibition radius), and both of the boosting mechanisms. All of those components are a function of the permanence, which serves as the probability of an input column being active in various contexts.</p>
<p>Let <inline-formula><mml:math id="M144"><mml:mi mathvariant="bold">&#x00394;&#x003A6;</mml:mi><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msup><mml:mrow><mml:mrow><mml:mo class="MathClass-open">[</mml:mo><mml:mrow><mml:mn>0</mml:mn><mml:mo class="MathClass-punc">,</mml:mo><mml:mn>1</mml:mn></mml:mrow><mml:mo class="MathClass-close">]</mml:mo></mml:mrow></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x000D7;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:math></inline-formula> be defined as the permanence update amount, as shown in equation (<xref ref-type="disp-formula" rid="E29">29</xref>), where <inline-formula><mml:math id="M145"><mml:mtext mathvariant="bold-italic">J</mml:mtext><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msup><mml:mrow><mml:mrow><mml:mo class="MathClass-open">&#x0007B;</mml:mo><mml:mrow><mml:mn>1</mml:mn></mml:mrow><mml:mo class="MathClass-close">&#x0007D;</mml:mo></mml:mrow></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x000D7;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:math></inline-formula>. <bold>&#x003B4;&#x003A6;</bold> may then be rewritten as <inline-formula><mml:math id="M146"><mml:mi mathvariant="bold">&#x003B4;&#x003A6;</mml:mi><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mrow><mml:msup><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mi>T</mml:mi></mml:msup></mml:mrow><mml:mo class="MathClass-bin">&#x02299;</mml:mo><mml:mi mathvariant="bold">&#x00394;&#x003A6;</mml:mi></mml:math></inline-formula>. Similarly, the permanence update for <inline-formula><mml:math id="M147"><mml:msub><mml:mi mathvariant="bold">&#x003A6;</mml:mi><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula> is given by <inline-formula><mml:math id="M148"><mml:msub><mml:mi mathvariant="bold">&#x003B4;&#x003A6;</mml:mi><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:msub><mml:mrow><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub><mml:msub><mml:mi mathvariant="bold">&#x00394;&#x003A6;</mml:mi><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula>, where <inline-formula><mml:math id="M149"><mml:msub><mml:mi mathvariant="bold">&#x00394;&#x003A6;</mml:mi><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:msub><mml:mrow><mml:mi>&#x003D5;</mml:mi></mml:mrow><mml:mrow><mml:mo class="MathClass-bin">&#x0002B;</mml:mo></mml:mrow></mml:msub><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:msub><mml:mrow><mml:mi>&#x003D5;</mml:mi></mml:mrow><mml:mrow><mml:mo class="MathClass-bin">&#x02212;</mml:mo></mml:mrow></mml:msub><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></inline-formula>.</p>
<disp-formula id="E29"><label>(29)</label><mml:math id="M150"><mml:mi mathvariant="bold">&#x00394;&#x003A6;</mml:mi><mml:mo class="MathClass-rel">&#x02261;</mml:mo><mml:msub><mml:mrow><mml:mi>&#x003D5;</mml:mi></mml:mrow><mml:mrow><mml:mo class="MathClass-bin">&#x0002B;</mml:mo></mml:mrow></mml:msub><mml:mtext mathvariant="bold-italic">X</mml:mtext><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:msub><mml:mrow><mml:mi>&#x003D5;</mml:mi></mml:mrow><mml:mrow><mml:mo class="MathClass-bin">&#x02212;</mml:mo></mml:mrow></mml:msub><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mtext mathvariant="bold-italic">J</mml:mtext><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></disp-formula>
<p>The permanence update equation is then logically split into two distinct components. The first component is the set of active columns, which is used to determine the set of permanences to update. The second component is <bold>&#x00394;&#x003A6;</bold>, which is used to determine the permanence update amount.</p>
<sec id="S7-13">
<label>7.1</label> <title>Plausible Origin for the Permanence Update Amount</title>
<p>It is noticed that <bold>&#x00394;&#x003A6;</bold> represents an unlearned function of a random variable coming from a prior distribution. That random variable is nothing more than <bold><italic>X</italic></bold>. It is required that <inline-formula><mml:math id="M151"><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x0223C;</mml:mo><mml:mtext>Ber</mml:mtext><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mi mathvariant="double-struck">P</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msub><mml:mrow><mml:mi>A</mml:mi></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></inline-formula>, where Ber is used to denote the Bernoulli distribution. Recall that the initialization of the SP is performed such that each <bold><italic>X</italic></bold><italic><sub>i,k</sub></italic>&#x02009;&#x02208;&#x02009;<bold><italic>X</italic></bold><italic><sub>i</sub></italic> is obtained by randomly sampling without replacement from <bold><italic>U</italic></bold><italic><sub>s</sub></italic>. Each <bold><italic>X</italic></bold><italic><sub>i</sub></italic>&#x02009;&#x02208;&#x02009;<bold><italic>X</italic></bold> is independent, since they are obtained by sampling from the same <bold><italic>U</italic></bold><italic><sub>s</sub></italic>. This initialization scheme means that each <bold><italic>X</italic></bold><italic><sub>i</sub></italic>&#x02009;&#x02208;&#x02009;<bold><italic>X</italic></bold> is independent and identically distributed (i.i.d.), but that each <bold><italic>X</italic></bold><italic><sub>i,k</sub></italic>&#x02009;&#x02208;&#x02009;<bold><italic>X</italic></bold><italic><sub>i</sub></italic> is not i.i.d.</p>
<p>If the initialization scheme is redefined such that <bold><italic>X</italic></bold><italic><sub>i,k</sub></italic>&#x02009;&#x02208;&#x02009;<bold><italic>X</italic></bold><italic><sub>i</sub></italic> is obtained by sampling with replacement, then each <bold><italic>X</italic></bold><italic><sub>i,k</sub></italic>&#x02009;&#x02208;&#x02009;<bold><italic>X</italic></bold> would be i.i.d. This slight change to the initialization would mean that a given input attribute may be observed by a column zero up to <italic>n<sub>ps</sub></italic> times. If <italic>n<sub>c</sub></italic> is set to be sufficiently large, then each <bold><italic>U</italic></bold><italic><sub>s,a</sub></italic> will still be observed and the overall impact of this change should be minor. Assuming that this new initialization scheme is utilized, then <inline-formula><mml:math id="M152"><mml:mrow><mml:msup><mml:mi>X</mml:mi><mml:munder accentunder='true'><mml:mi mathvariant="italic">i.i.d.</mml:mi><mml:mo>&#x002DC;</mml:mo></mml:munder></mml:msup></mml:mrow></mml:math></inline-formula> Ber(<italic>&#x003B8;</italic>), where <italic>&#x003B8;</italic> is defined to be the probability of an input being active. Using the PMF of the Bernoulli distribution, the likelihood of <italic>&#x003B8;</italic> given <bold><italic>X</italic></bold> is obtained in equation (<xref ref-type="disp-formula" rid="E30">30</xref>), where <italic>t</italic> &#x02261; <italic>n<sub>c</sub>n<sub>ps</sub></italic> and <inline-formula><mml:math id="M153"><mml:mover accent="false" class="mml-overline"><mml:mrow><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mo accent="true">&#x000AF;</mml:mo></mml:mover><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mfrac><mml:mrow><mml:mn>1</mml:mn></mml:mrow><mml:mrow><mml:mi>t</mml:mi></mml:mrow></mml:mfrac><mml:msubsup><mml:mrow><mml:mo class="MathClass-op">&#x02211;</mml:mo></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>0</mml:mn></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>1</mml:mn></mml:mrow></mml:msubsup><mml:mspace width="1em"/><mml:msubsup><mml:mrow><mml:mo class="MathClass-op">&#x02211;</mml:mo></mml:mrow><mml:mrow><mml:mi>k</mml:mi><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>0</mml:mn></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>1</mml:mn></mml:mrow></mml:msubsup><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula>, the overall mean of <bold><italic>X</italic></bold>. The corresponding log-likelihood of <italic>&#x003B8;</italic> given <bold><italic>X</italic></bold> is given in equation (<xref ref-type="disp-formula" rid="E31">31</xref>).</p>
<disp-formula id="E30"><label>(30)</label><mml:math id="M154"><mml:mtable columnalign="left" class="align"><mml:mtr><mml:mtd columnalign="left" class="align-odd"><mml:mi mathvariant="script">L</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mi>&#x003B8;</mml:mi><mml:mo class="MathClass-punc">;</mml:mo><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mstyle displaystyle='true'><mml:munderover><mml:mo>&#x0220F;</mml:mo><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>0</mml:mn></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>1</mml:mn></mml:mrow></mml:munderover></mml:mstyle><mml:mstyle displaystyle='true'><mml:munderover><mml:mo>&#x0220F;</mml:mo><mml:mrow><mml:mi>k</mml:mi><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>0</mml:mn></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>1</mml:mn></mml:mrow></mml:msub></mml:mrow></mml:munderover></mml:mstyle><mml:msup><mml:mrow><mml:mi>&#x003B8;</mml:mi></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup><mml:msup><mml:mrow><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mi>&#x003B8;</mml:mi></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:mrow><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup></mml:mtd></mml:mtr><mml:mtr><mml:mtd><mml:mspace width="2em"/><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:msup><mml:mrow><mml:mi>&#x003B8;</mml:mi></mml:mrow><mml:mrow><mml:mi>t</mml:mi><mml:mover accent="false" class="mml-overline"><mml:mrow><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mo accent="true">&#x000AF;</mml:mo></mml:mover></mml:mrow></mml:msup><mml:msup><mml:mrow><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mi>&#x003B8;</mml:mi></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:mrow><mml:mrow><mml:mi>t</mml:mi><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mi>t</mml:mi><mml:mover accent="false" class="mml-overline"><mml:mrow><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mo accent="true">&#x000AF;</mml:mo></mml:mover></mml:mrow></mml:msup></mml:mtd></mml:mtr></mml:mtable></mml:math></disp-formula>
<disp-formula id="E31"><label>(31)</label><mml:math id="M155"><mml:mi>&#x02113;</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mi>&#x003B8;</mml:mi><mml:mo class="MathClass-punc">;</mml:mo><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mi>t</mml:mi><mml:mover accent="false" class="mml-overline"><mml:mrow><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mo accent="true">&#x000AF;</mml:mo></mml:mover><mml:mtext>log</mml:mtext><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mi>&#x003B8;</mml:mi></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow><mml:mo class="MathClass-bin">&#x0002B;</mml:mo><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mi>t</mml:mi><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mi>t</mml:mi><mml:mover accent="false" class="mml-overline"><mml:mrow><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mo accent="true">&#x000AF;</mml:mo></mml:mover></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow><mml:mtext>log</mml:mtext><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mi>&#x003B8;</mml:mi></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></disp-formula>
<p>Taking the gradient of the log-likelihood of equation (<xref ref-type="disp-formula" rid="E31">31</xref>) with respect to <italic>&#x003B8;</italic> results in equation (<xref ref-type="disp-formula" rid="E32">32</xref>). Similarly, the partial derivative of the log-likelihood for a single <bold><italic>X</italic></bold><italic><sub>i,k</sub></italic> results in equation (<xref ref-type="disp-formula" rid="E33">33</xref>). Equation (<xref ref-type="disp-formula" rid="E33">33</xref>) suggests by its form that an unconstrained local update of <italic>&#x003B8;</italic> may be obtained. Let <inline-formula><mml:math id="M156"><mml:mi mathvariant="bold-italic">&#x00398;</mml:mi><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:msup><mml:mrow><mml:mrow><mml:mo class="MathClass-open">[</mml:mo><mml:mrow><mml:mn>0</mml:mn><mml:mo class="MathClass-punc">,</mml:mo><mml:mn>1</mml:mn></mml:mrow><mml:mo class="MathClass-close">]</mml:mo></mml:mrow></mml:mrow><mml:mrow><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x000D7;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi mathvariant="italic">ps</mml:mi></mml:mrow></mml:msub></mml:mrow></mml:msup><mml:mo class="MathClass-rel">&#x02261;</mml:mo><mml:mi mathvariant="double-struck">P</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mo class="MathClass-rel">&#x02203;</mml:mo><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">A</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:mtext mathvariant="bold-italic">A</mml:mtext></mml:mrow></mml:math></inline-formula>), such that <bold><italic>&#x00398;</italic></bold><italic><sub>i,k</sub></italic>&#x02009;&#x0003D;&#x02009;&#x02119;(<bold><italic>A</italic></bold><italic><sub>i,k</sub></italic>). Recall that <bold><italic>X</italic></bold> is populated based off the entries in a single <bold><italic>U</italic></bold><italic><sub>s</sub></italic>, i.e., <bold><italic>X</italic></bold> represents the current input to the SP, not all of the inputs. Solving equation (<xref ref-type="disp-formula" rid="E32">32</xref>) for the maximum-likelihood estimator results in maximizing the likelihood of the current sample rather than the population. Realizing this, an approach similar to stochastic gradient ascent is used to obtain equation (<xref ref-type="disp-formula" rid="E34">34</xref>), where <inline-formula><mml:math id="M157"><mml:mn>&#x003B4;</mml:mn><mml:msub><mml:mrow><mml:mi>&#x003D5;</mml:mi></mml:mrow><mml:mrow><mml:mo class="MathClass-bin">&#x0002B;</mml:mo></mml:mrow></mml:msub><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msub><mml:mi mathvariant="bold-italic">&#x00398;</mml:mi><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></inline-formula> and <inline-formula><mml:math id="M158"><mml:mn>&#x003B4;</mml:mn><mml:msub><mml:mrow><mml:mi>&#x003D5;</mml:mi></mml:mrow><mml:mrow><mml:mo class="MathClass-bin">&#x0002B;</mml:mo></mml:mrow></mml:msub><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msub><mml:mi mathvariant="bold-italic">&#x00398;</mml:mi><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></inline-formula> are functions of <inline-formula><mml:math id="M159"><mml:msub><mml:mi mathvariant="bold-italic">&#x00398;</mml:mi><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula> that compute the permanence increment and decrement amount for each <inline-formula><mml:math id="M160"><mml:msub><mml:mi mathvariant="bold-italic">&#x00398;</mml:mi><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula>, respectively.</p>
<disp-formula id="E32"><label>(32)</label><mml:math id="M161"><mml:mi mathvariant="bold-italic">&#x02207;</mml:mi><mml:mi>&#x02113;</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mi>&#x003B8;</mml:mi><mml:mo class="MathClass-punc">;</mml:mo><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mfrac><mml:mrow><mml:mi>t</mml:mi></mml:mrow><mml:mrow><mml:mi>&#x003B8;</mml:mi></mml:mrow></mml:mfrac><mml:mover accent="false" class="mml-overline"><mml:mrow><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mo accent="true">&#x000AF;</mml:mo></mml:mover><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mfrac><mml:mrow><mml:mi>t</mml:mi></mml:mrow><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mi>&#x003B8;</mml:mi></mml:mrow></mml:mfrac><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mover accent="false" class="mml-overline"><mml:mrow><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mo accent="true">&#x000AF;</mml:mo></mml:mover></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></disp-formula>
<disp-formula id="E33"><label>(33)</label><mml:math id="M162"><mml:mfrac><mml:mrow><mml:mi>&#x02202;</mml:mi></mml:mrow><mml:mrow><mml:mi>&#x02202;</mml:mi><mml:mi>&#x003B8;</mml:mi></mml:mrow></mml:mfrac><mml:mi>&#x02113;</mml:mi><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mi>&#x003B8;</mml:mi><mml:mo class="MathClass-punc">;</mml:mo><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mfrac><mml:mrow><mml:mn>1</mml:mn></mml:mrow><mml:mrow><mml:mi>&#x003B8;</mml:mi></mml:mrow></mml:mfrac><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mfrac><mml:mrow><mml:mn>1</mml:mn></mml:mrow><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mi>&#x003B8;</mml:mi></mml:mrow></mml:mfrac><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></disp-formula>
<disp-formula id="E34"><label>(34)</label><mml:math id="M163"><mml:msub><mml:mi mathvariant="bold">&#x00394;&#x003A6;</mml:mi><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x0003D;</mml:mo><mml:mn>&#x003B4;</mml:mn><mml:msub><mml:mrow><mml:mi>&#x003D5;</mml:mi></mml:mrow><mml:mrow><mml:mo class="MathClass-bin">&#x0002B;</mml:mo></mml:mrow></mml:msub><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msub><mml:mi mathvariant="bold-italic">&#x00398;</mml:mi><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>&#x003B4;</mml:mn><mml:msub><mml:mrow><mml:mi>&#x003D5;</mml:mi></mml:mrow><mml:mrow><mml:mo class="MathClass-bin">&#x02212;</mml:mo></mml:mrow></mml:msub><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msub><mml:mi mathvariant="bold-italic">&#x00398;</mml:mi><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mn>1</mml:mn><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:msub><mml:mrow><mml:mtext mathvariant="bold-italic">X</mml:mtext></mml:mrow><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></disp-formula>
<p>Relating equation (<xref ref-type="disp-formula" rid="E34">34</xref>) to equation (<xref ref-type="disp-formula" rid="E29">29</xref>), <inline-formula><mml:math id="M164"><mml:mn>&#x003B4;</mml:mn><mml:msub><mml:mrow><mml:mi>&#x003D5;</mml:mi></mml:mrow><mml:mrow><mml:mo class="MathClass-bin">&#x0002B;</mml:mo></mml:mrow></mml:msub><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msub><mml:mi mathvariant="bold-italic">&#x00398;</mml:mi><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></inline-formula> and <inline-formula><mml:math id="M165"><mml:mn>&#x003B4;</mml:mn><mml:msub><mml:mrow><mml:mi>&#x003D5;</mml:mi></mml:mrow><mml:mrow><mml:mo class="MathClass-bin">&#x0002B;</mml:mo></mml:mrow></mml:msub><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:msub><mml:mi mathvariant="bold-italic">&#x00398;</mml:mi><mml:mrow><mml:mi>i</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:mi>k</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></inline-formula> were defined to return the constants <italic>&#x003D5;</italic><sub>&#x0002B;</sub> and <italic>&#x003D5;</italic><sub>&#x02212;</sub>, respectively. If the probabilities of each <bold><italic>X</italic></bold><italic><sub>i,k</sub></italic>&#x02009;&#x0003D;&#x02009;1 are sufficiently close in value for all <bold><italic>U</italic></bold><italic><sub>s</sub></italic>&#x02009;&#x02208;&#x02009;<bold><italic>U</italic></bold>, then global constants may be sufficient. Using constants also simplifies the permanence update equation, which is likely why the original permanence update method, equation (<xref ref-type="disp-formula" rid="E18">18</xref>), used this approach. For more complicated inputs, it is unlikely that this assumption will hold true. To address that, this new method allows for a local and adaptive way to tune the permanences.</p>
</sec>
<sec id="S7-14">
<label>7.2</label> <title>Discussing the Permanence Selection</title>
<p>The set of active columns is the learned component in equation (<xref ref-type="disp-formula" rid="E18">18</xref>). Those columns are used to determine which permanences are selected for update. Obtaining the set of active columns is done through a process similar to competitive learning (Rumelhart and Zipser, <xref ref-type="bibr" rid="B20">1985</xref>). In a competitive learning network, each neuron in the competitive learning layer is fully connected to each input neuron. The neurons in the competitive layer then compete, with one neuron winning the competition. The neuron that wins sets its output to &#x0201C;1&#x0201D; while all other neurons set their output to &#x0201C;0&#x0201D;. At a global scale, this resembles the SP with two key differences. The SP permits multiple columns to be active at a time and each column is connected to a different subset of the input&#x02019;s attributes.</p>
<p>Posit that each column is equivalent to a competitive learning network. This would create a network with one neuron in the competitive layer and <italic>n<sub>ps</sub></italic> neurons in the input layer. The neuron in the competitive layer may only have the state of &#x0201C;1&#x0201D; or &#x0201C;0&#x0201D;; therefore, only one neuron would be active at a time. Given this context, each column is shown to follow the competitive learning rule.</p>
<p>Taking into context the full SP, with each column as a competitive learning network, the SP could be defined to be a bag of competitive learning networks, i.e., an ensemble with a type of competitive learning network as its base learner. Recalling that <bold><italic>X</italic></bold>&#x02009;&#x02286;&#x02009;<bold><italic>U</italic></bold><sub>s</sub>, each <bold><italic>X</italic></bold><italic><sub>i</sub></italic> is an input for <inline-formula><mml:math id="M166"><mml:msub><mml:mrow><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:mrow><mml:mrow><mml:mi>i</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula>. Additionally, each <bold><italic>X</italic></bold><italic><sub>i</sub></italic> is obtained by randomly sampling <bold><italic>U</italic></bold><italic><sub>s</sub></italic> without replacement. Comparing this ensemble to attribute bagging (Bryll et al., <xref ref-type="bibr" rid="B3">2003</xref>), the primary difference is that sampling is done without replacement instead of with replacement.</p>
<p>In attribute bagging, a scheme, such as voting, must be used to determine what the result of the ensemble should be. For the SP, a form of voting is performed through the construction of <inline-formula><mml:math id="M167"><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003B1;</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover></mml:math></inline-formula>. Each base learner (column) computes its degree of influence. The max degree of influence is <italic>n<sub>ps</sub></italic>. Since that value is a constant, each <inline-formula><mml:math id="M168"><mml:mrow><mml:msub><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003B1;</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mi>i</mml:mi></mml:msub></mml:mrow></mml:math></inline-formula> may be represented as a probability by simply dividing <inline-formula><mml:math id="M169"><mml:mrow><mml:msub><mml:mover accent='true'><mml:mi mathvariant="bold-italic">&#x003B1;</mml:mi><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mi>i</mml:mi></mml:msub></mml:mrow></mml:math></inline-formula> by <italic>q</italic>. In this context, each column is trying to maximize its probability of being selected. During the inhibition phase, a column is chosen to be active if its probability is at least equal to the <italic>&#x003C1;</italic><sub><italic>c</italic></sub>-th largest probability in its neighborhood. This process may then be viewed as a form of voting, as all columns within a neighborhood cast their overlap value as their vote. If the column being evaluated has enough votes, it will be placed in the active state.</p>
</sec>
</sec>
<sec id="S8">
<label>8</label> <title>Conclusion and Future Work</title>
<p>In this work, a mathematical framework for HTM&#x02019;s SP was presented. Using the framework, it was demonstrated how the SP can be used for feature learning. The primary learning mechanism of the SP was explored. It was shown that the mechanism consists of two distinct components, permanence selection and the degree of permanence update. A plausible estimator was provided for determining the degree of permanence update, and insight was given on the behavior of the permanence selection.</p>
<p>The findings in this work provide a basis for intelligently initializing the SP. Due to the mathematical framework, the provided equations could be used to optimize hardware designs. Such optimizations may include removing the boosting mechanism, limiting support to global inhibition, exploiting the matrix operations to improve performance, reducing power through the reduction of multiplexers, etc&#x02026; In the future, it is planned to explore optimized hardware designs. Additionally, it is planned to make the SP more flexible and adaptive. Finally, it is planned to expand this work to provide the same level of understanding for the TM.</p>
</sec>
<sec id="S9">
<title>Author Contributions</title>
<p>JM wrote the paper, formulated the initial mathematics, developed mHTM, and conducted the experiments. EF assisted in the formalization of the mathematics. DK initiated the work and assisted in experimental design. All listed authors made substantial intellectual contributions to the work and approve it for publication.</p>
</sec>
<sec id="S10">
<title>Conflict of Interest Statement</title>
<p>The authors declare that the research was conducted in the absence of any commercial or financial relationships that could be construed as a potential conflict of interest.</p>
</sec>
</body>
<back>
<ack>
<p>The authors would like to thank Kevin Gomez of Seagate Technology, the staff at RIT&#x02019;s research computing, and the members of the NanoComputing Research Lab, in particular Amanda Hartung and Cory Merkel, for their support and critical feedback. The authors would also like to thank the reviewers for their exhaustive feedback to enhance the overall quality of the paper.</p>
</ack>
<ref-list>
<title>References</title>
<ref id="B1"><citation citation-type="web"><person-group person-group-type="author"><name><surname>Ahmad</surname> <given-names>S.</given-names></name> <name><surname>Hawkins</surname> <given-names>J.</given-names></name></person-group> (<year>2015</year>). <article-title>Properties of sparse distributed representations and their application to hierarchical temporal memory</article-title>. arXiv preprint arXiv:1503.07469. Available at: <uri xlink:href="https://arxiv.org/abs/1503.07469">https://arxiv.org/abs/1503.07469</uri></citation></ref>
<ref id="B2"><citation citation-type="confproc"><person-group person-group-type="author"><name><surname>Bohanec</surname> <given-names>M.</given-names></name> <name><surname>Rajkovic</surname> <given-names>V.</given-names></name></person-group> (<year>1988</year>). <article-title>&#x0201C;Knowledge acquisition and explanation for multi-attribute decision making,&#x0201D;</article-title> in <conf-name>8th Intl Workshop on Expert Systems and Their Applications</conf-name>, (<conf-loc>Avignon</conf-loc>) <fpage>59</fpage>&#x02013;<lpage>78</lpage>.</citation></ref>
<ref id="B3"><citation citation-type="journal"><person-group person-group-type="author"><name><surname>Bryll</surname> <given-names>R.</given-names></name> <name><surname>Gutierrez-Osuna</surname> <given-names>R.</given-names></name> <name><surname>Quek</surname> <given-names>F.</given-names></name></person-group> (<year>2003</year>). <article-title>Attribute bagging: improving accuracy of classifier ensembles by using random feature subsets</article-title>. <source>Pattern Recognit.</source> <volume>36</volume>, <fpage>1291</fpage>&#x02013;<lpage>1302</lpage>.<pub-id pub-id-type="doi">10.1016/S0031-3203(02)00121-8</pub-id></citation></ref>
<ref id="B4"><citation citation-type="web"><person-group person-group-type="author"><name><surname>Byrne</surname> <given-names>F.</given-names></name></person-group> (<year>2015</year>). <article-title>Encoding reality: prediction-assisted cortical learning algorithm in hierarchical temporal memory</article-title>. arXiv preprint arXiv:1509.08255. Available at: <uri xlink:href="https://arxiv.org/abs/1509.08255">https://arxiv.org/abs/1509.08255</uri></citation></ref>
<ref id="B5"><citation citation-type="journal"><person-group person-group-type="author"><name><surname>Cui</surname> <given-names>Y.</given-names></name> <name><surname>Ahmad</surname> <given-names>S.</given-names></name> <name><surname>Hawkins</surname> <given-names>J.</given-names></name></person-group> (<year>2016</year>). <article-title>Continuous online sequence learning with an unsupervised neural network model</article-title>. <source>Neural Comput.</source> <volume>28</volume>, <fpage>2474</fpage>&#x02013;<lpage>2504</lpage>.<pub-id pub-id-type="doi">10.1162/NECO_a_00893</pub-id><pub-id pub-id-type="pmid">27626963</pub-id></citation></ref>
<ref id="B6"><citation citation-type="confproc"><person-group person-group-type="author"><name><surname>DeSieno</surname> <given-names>D.</given-names></name></person-group> (<year>1988</year>). <article-title>&#x0201C;Adding a conscience to competitive learning,&#x0201D;</article-title> in <conf-name>IEEE International Conference on Neural Networks, 1988</conf-name> (<conf-loc>San Diego, CA</conf-loc>: <conf-sponsor>IEEE</conf-sponsor>), <fpage>117</fpage>&#x02013;<lpage>124</lpage>.</citation></ref>
<ref id="B7"><citation citation-type="book"><person-group person-group-type="author"><name><surname>Gersho</surname> <given-names>A.</given-names></name> <name><surname>Gray</surname> <given-names>R. M.</given-names></name></person-group> (<year>2012</year>). <source>Vector Quantization and Signal Compression</source>, Vol. <volume>159</volume>. <publisher-loc>New York</publisher-loc>: <publisher-name>Springer Science &#x00026; Business Media</publisher-name>.</citation></ref>
<ref id="B8"><citation citation-type="journal"><person-group person-group-type="author"><name><surname>Hawkins</surname> <given-names>J.</given-names></name> <name><surname>Ahmad</surname> <given-names>S.</given-names></name></person-group> (<year>2016</year>). <article-title>Why neurons have thousands of synapses, a theory of sequence memory in neocortex</article-title>. <source>Front. Neural Circuits</source> <volume>10</volume>:<fpage>1</fpage>&#x02013;<lpage>13</lpage>.<pub-id pub-id-type="doi">10.3389/fncir.2016.00023</pub-id></citation></ref>
<ref id="B9"><citation citation-type="web"><person-group person-group-type="author"><name><surname>Hawkins</surname> <given-names>J.</given-names></name> <name><surname>Ahmad</surname> <given-names>S.</given-names></name> <name><surname>Dubinsky</surname> <given-names>D.</given-names></name></person-group> (<year>2011</year>). <source>Hierarchical Temporal Memory Including htm Cortical Learning Algorithms</source>. Available at: <uri xlink:href="http://numenta.org/resources/HTM_CorticalLearningAlgorithms.pdf">http://numenta.org/resources/HTM_CorticalLearningAlgorithms.pdf</uri></citation></ref>
<ref id="B10"><citation citation-type="web"><person-group person-group-type="author"><name><surname>Hawkins</surname> <given-names>J.</given-names></name> <name><surname>George</surname> <given-names>D.</given-names></name></person-group> (<year>2007</year>). <source>Directed Behavior using a Hierarchical Temporal Memory Based System</source>. Google Patents. Available at: <uri xlink:href="https://www.google.com/patents/US20070192268">https://www.google.com/patents/US20070192268</uri>. US Patent App. 11/622,448.</citation></ref>
<ref id="B11"><citation citation-type="book"><person-group person-group-type="author"><name><surname>Hebb</surname> <given-names>D. O.</given-names></name></person-group> (<year>1949</year>). <source>The Organization of Behavior: A Neuropsychological Approach</source>. <publisher-loc>New York</publisher-loc>: <publisher-name>John Wiley &#x00026; Sons</publisher-name>.</citation></ref>
<ref id="B12"><citation citation-type="journal"><person-group person-group-type="author"><name><surname>Kohonen</surname> <given-names>T.</given-names></name></person-group> (<year>1982</year>). <article-title>Self-organized formation of topologically correct feature maps</article-title>. <source>Biol. Cybern.</source> <volume>43</volume>, <fpage>59</fpage>&#x02013;<lpage>69</lpage>.<pub-id pub-id-type="doi">10.1007/BF00337288</pub-id></citation></ref>
<ref id="B13"><citation citation-type="thesis"><person-group person-group-type="author"><name><surname>Lattner</surname> <given-names>S.</given-names></name></person-group> (<year>2014</year>). <source>Hierarchical Temporal Memory-Investigations, Ideas, and Experiments</source>. Master&#x02019;s thesis, <publisher-loc>Linz</publisher-loc>: <publisher-name>Johannes Kepler Universit&#x000E4;t</publisher-name>.</citation></ref>
<ref id="B14"><citation citation-type="confproc"><person-group person-group-type="author"><name><surname>Lavin</surname> <given-names>A.</given-names></name> <name><surname>Ahmad</surname> <given-names>S.</given-names></name></person-group> (<year>2015</year>). <article-title>&#x0201C;Evaluating real-time anomaly detection algorithms&#x02013;the numenta anomaly benchmark,&#x0201D;</article-title> in <conf-name>IEEE 14th International Conference on Machine Learning and Applications (ICMLA)</conf-name> (<conf-loc>Miami</conf-loc>: <conf-sponsor>IEEE</conf-sponsor>), <fpage>38</fpage>&#x02013;<lpage>44</lpage>.</citation></ref>
<ref id="B15"><citation citation-type="journal"><person-group person-group-type="author"><name><surname>Leake</surname> <given-names>M.</given-names></name> <name><surname>Xia</surname> <given-names>L.</given-names></name> <name><surname>Rocki</surname> <given-names>K.</given-names></name> <name><surname>Imaino</surname> <given-names>W.</given-names></name></person-group> (<year>2015</year>). <article-title>A probabilistic view of the spatial pooler in hierarchical temporal memory</article-title>. <source>World Acad. Sci. Eng. Technol. Int. J. Comput. Electr. Autom. Control Inform. Eng.</source> <volume>9</volume>, <fpage>1111</fpage>&#x02013;<lpage>1118</lpage>.</citation></ref>
<ref id="B16"><citation citation-type="journal"><person-group person-group-type="author"><name><surname>LeCun</surname> <given-names>Y.</given-names></name> <name><surname>Bottou</surname> <given-names>L.</given-names></name> <name><surname>Bengio</surname> <given-names>Y.</given-names></name> <name><surname>Haffner</surname> <given-names>P.</given-names></name></person-group> (<year>1998</year>). <article-title>Gradient-based learning applied to document recognition</article-title>. <source>Proc. IEEE</source> <volume>86</volume>, <fpage>2278</fpage>&#x02013;<lpage>2324</lpage>.<pub-id pub-id-type="doi">10.1109/5.726791</pub-id></citation></ref>
<ref id="B17"><citation citation-type="web"><person-group person-group-type="author"><name><surname>Lichman</surname> <given-names>M.</given-names></name></person-group> (<year>2013</year>). <source>UCI Machine Learning Repository</source>. Available at: <uri xlink:href="http://archive.ics.uci.edu/ml">http://archive.ics.uci.edu/ml</uri></citation></ref>
<ref id="B18"><citation citation-type="web"><collab>Numenta</collab>. (<year>2016</year>). <source>Numenta Platform for Intelligent Computing (Nupic)</source>. Available at: <uri xlink:href="http://numenta.org/">http://numenta.org/</uri></citation></ref>
<ref id="B19"><citation citation-type="confproc"><person-group person-group-type="author"><name><surname>Oza</surname> <given-names>N. C.</given-names></name></person-group> (<year>2005</year>). <article-title>&#x0201C;Online bagging and boosting,&#x0201D;</article-title> in <conf-name>IEEE International Conference on Systems, Man and Cybernetics</conf-name>, Vol. <volume>3</volume> (<conf-loc>Waikoloa</conf-loc>: <conf-sponsor>IEEE</conf-sponsor>), <fpage>2340</fpage>&#x02013;<lpage>2345</lpage>.</citation></ref>
<ref id="B20"><citation citation-type="journal"><person-group person-group-type="author"><name><surname>Rumelhart</surname> <given-names>D. E.</given-names></name> <name><surname>Zipser</surname> <given-names>D.</given-names></name></person-group> (<year>1985</year>). <article-title>Feature discovery by competitive learning</article-title>. <source>Cogn. Sci.</source> <volume>9</volume>, <fpage>75</fpage>&#x02013;<lpage>112</lpage>.<pub-id pub-id-type="doi">10.1207/s15516709cog0901_5</pub-id></citation></ref>
<ref id="B21"><citation citation-type="web"><collab>scikit-learn</collab>. (<year>2016</year>). <source>scikit-learn</source>. Available at: <uri xlink:href="http://scikit-learn.org/stable/index.html">http://scikit-learn.org/stable/index.html</uri></citation></ref>
<ref id="B22"><citation citation-type="journal"><person-group person-group-type="author"><name><surname>Thornton</surname> <given-names>J.</given-names></name> <name><surname>Srbic</surname> <given-names>A.</given-names></name></person-group> (<year>2013</year>). <article-title>Spatial pooling for greyscale images</article-title>. <source>Int. J. Mach. Learn. Cybern.</source> <volume>4</volume>, <fpage>207</fpage>&#x02013;<lpage>216</lpage>.<pub-id pub-id-type="doi">10.1007/s13042-012-0087-7</pub-id></citation></ref>
</ref-list>
<fn-group>
<fn id="fn1"><p><sup>1</sup>This parameter was originally referred to as the minimum overlap; however, it is renamed in this work to allow consistency between the SP and the TM.</p></fn>
<fn id="fn2"><p><sup>2</sup>All indices start at 0.</p></fn>
<fn id="fn3"><p><sup>3</sup>The parameters <inline-formula><mml:math id="M170"><mml:msub><mml:mrow><mml:mn>&#x003BA;</mml:mn></mml:mrow><mml:mrow><mml:mi>a</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula> and <inline-formula><mml:math id="M171"><mml:msub><mml:mrow><mml:mn>&#x003BA;</mml:mn></mml:mrow><mml:mrow><mml:mi>b</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula> have default values of 0.01 and 0.1, respectively.</p></fn>
<fn id="fn4"><p><sup>4</sup><inline-formula><mml:math id="M172"><mml:msub><mml:mrow><mml:mi>&#x003C1;</mml:mi></mml:mrow><mml:mrow><mml:mi>s</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula> was used as a probability. Because <inline-formula><mml:math id="M173"><mml:msub><mml:mrow><mml:mi>&#x003C1;</mml:mi></mml:mrow><mml:mrow><mml:mi>s</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:mi mathvariant="double-struck">R</mml:mi><mml:mo class="MathClass-punc">,</mml:mo><mml:msub><mml:mrow><mml:mi>&#x003C1;</mml:mi></mml:mrow><mml:mrow><mml:mi>s</mml:mi></mml:mrow></mml:msub><mml:mo class="MathClass-rel">&#x02208;</mml:mo><mml:mrow><mml:mo class="MathClass-open">(</mml:mo><mml:mrow><mml:mn>0</mml:mn><mml:mo class="MathClass-punc">,</mml:mo><mml:mn>1</mml:mn></mml:mrow><mml:mo class="MathClass-close">)</mml:mo></mml:mrow></mml:math></inline-formula>, permanences are uniformly initialized with a mean of <inline-formula><mml:math id="M174"><mml:msub><mml:mrow><mml:mi>&#x003C1;</mml:mi></mml:mrow><mml:mrow><mml:mi>s</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula>, and for a proximal synapse to be connected it must have a permanence value at least equal to <inline-formula><mml:math id="M175"><mml:msub><mml:mrow><mml:mi>&#x003C1;</mml:mi></mml:mrow><mml:mrow><mml:mi>s</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula>, <inline-formula><mml:math id="M176"><mml:msub><mml:mrow><mml:mi>&#x003C1;</mml:mi></mml:mrow><mml:mrow><mml:mi>s</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula> may be used to represent the probability that an initialized proximal synapse is connected.</p></fn>
<fn id="fn5"><p><sup>5</sup>Due to <bold><italic>X</italic></bold> being binary, a bitwise negation is equivalent to the shown logical negation. In a similar manner, the multiplications of <inline-formula><mml:math id="M177"><mml:mrow><mml:msup><mml:mover accent='true'><mml:mover accent='true'><mml:mi mathvariant="bold-italic">c</mml:mi><mml:mo>&#x0005E;</mml:mo></mml:mover><mml:mo>&#x021C0;</mml:mo></mml:mover><mml:mi>T</mml:mi></mml:msup></mml:mrow></mml:math></inline-formula> with <bold><italic>X</italic></bold> and &#x000AC;<bold><italic>X</italic></bold> can be replaced by an AND operation (logical or bitwise).</p></fn>
<fn id="fn6"><p><sup>6</sup>The conditions within the piecewise function must be evaluated top-down, such that the first condition takes precedence over the second condition which takes precedence over the third condition.</p></fn>
<fn id="fn7"><p><sup>7</sup>The distance function is typically the Euclidean distance.</p></fn>
<fn id="fn8"><p><sup>8</sup>In an actual system the positions would be explicitly defined.</p></fn>
<fn id="fn9"><p><sup>9</sup>It is assumed that an SP column and an input column do not coincide, i.e., their distance is greater than zero. If this occurs, <bold><italic>D</italic></bold> will be unstable, as zeros will refer to both valid and invalid distances. This instability is accounted for during the computation of the inhibition radius, such that it will not impact the actual algorithm.</p></fn>
<fn id="fn10"><p><sup>10</sup>The summation of the connected synapses is lower bounded by one to avoid division by zero.</p></fn>
<fn id="fn11"><p><sup>11</sup>To obtain Figure <xref ref-type="fig" rid="F6">6</xref>, the average number of boosted columns during each epoch is computed. The average, across all of those epochs, is then calculated. That average represents the percentage of columns boosted for a particular level of sparsity. It is important to note that because the SP&#x02019;s synaptic connections are randomly determined, the only dataset specific factors that will affect how the SP performs will be <italic>n<sub>a</sub></italic> and the number of active input columns. This means that it is possible to generalize the SP&#x02019;s behavior for any dataset, provided that the dataset has a relatively constant number of active columns for each input. For the purposes of this experiment, the number of active input columns was kept fixed, but the positions were varied; thereby creating a generalizable template. The inputs presented to the SP consisted of 100 randomly vectors with a width of 100 columns. Within each input, the columns were randomly set to be active. The sparseness is then the percentage of non-active input columns. Each simulation consisted of 10 epochs and was performed across 10 trials. The SP&#x02019;s parameters are as follows: <italic>n<sub>c</sub></italic>&#x02009;&#x0003D;&#x02009;2048, <italic>n<sub>a</sub></italic>&#x02009;&#x0003D;&#x02009;100, <italic>n<sub>ps</sub></italic>&#x02009;&#x0003D;&#x02009;40, <italic>&#x003C1;</italic><sub><italic>d</italic></sub>&#x02009;&#x0003D;&#x02009;15, <italic>&#x003C1;</italic><sub><italic>s</italic></sub>&#x02009;&#x0003D;&#x02009;0.5, <italic>&#x003D5;</italic><sub>&#x003B4;</sub>&#x02009;&#x0003D;&#x02009;0.05, <inline-formula><mml:math id="M178"><mml:msub><mml:mrow><mml:mi>&#x003C1;</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula>&#x02009;&#x0003D;&#x02009;<inline-formula><mml:math id="M179"><mml:mrow><mml:mo class="MathClass-open">&#x0230A;</mml:mo><mml:mrow><mml:mn>0</mml:mn><mml:mo class="MathClass-punc">.</mml:mo><mml:mn>02</mml:mn><mml:mo class="MathClass-bin">&#x02217;</mml:mo><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub></mml:mrow><mml:mo class="MathClass-close">&#x0230B;</mml:mo></mml:mrow></mml:math></inline-formula>, <italic>&#x003D5;</italic><sub>&#x0002B;</sub>&#x02009;&#x0003D;&#x02009;0.03, <italic>&#x003D5;</italic><sub>&#x02212;</sub>&#x02009;&#x0003D;&#x02009;0.05, <italic>&#x003B2;</italic><sub>0</sub>&#x02009;&#x0003D;&#x02009;10, and <italic>&#x003C4;</italic>&#x02009;&#x0003D;&#x02009;100. Synapses were trimmed if their permanence value ever reached or fell below 10<sup>&#x02212;4</sup>. On the figure, each point represents a partial box plot, i.e., the data point is the median, the upper error bar is the third quartile, and the lower error bar is the first quartile.</p></fn>
<fn id="fn12"><p><sup>12</sup>This assumes that there will be enough active columns in the input. If this is not the case, the input may be transformed to have an appropriate number of active columns.</p></fn>
<fn id="fn13"><p><sup>13</sup>The function max was used as an example. Other functions producing a valid probability are also valid.</p></fn>
<fn id="fn14"><p><sup>14</sup>The function max was used as an example. If a different function is utilized, it must be ensured that a valid probability is produced. If a sum is used, it could be normalized; however, if caution is not applied, thresholding with respect to <inline-formula><mml:math id="M180"><mml:msub><mml:mrow><mml:mi>&#x003C1;</mml:mi></mml:mrow><mml:mrow><mml:mi>s</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula> may be invalid and therefore require a new thresholding technique.</p></fn>
<fn id="fn15"><p><sup>15</sup>This implementation has been released under the MIT license and is available at: <uri xlink:href="https://github.com/tehtechguy/mHTM">https://github.com/tehtechguy/mHTM</uri>.</p></fn>
<fn id="fn16"><p><sup>16</sup>An encoder for HTM is any system that takes an arbitrary input and maps it to a new domain (whether by lossy or lossless means) where all values are mapped to the set 0, 1.</p></fn>
<fn id="fn17"><p><sup>17</sup>The following parameters were kept constant: <inline-formula><mml:math id="M181"><mml:msub><mml:mrow><mml:mi>&#x003C1;</mml:mi></mml:mrow><mml:mrow><mml:mi>s</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula>&#x02009;&#x0003D;&#x02009;0.5, 30 training epochs, and synapses were trimmed if their permanence value ever reached or fell below <inline-formula><mml:math id="M182"><mml:mn>10</mml:mn><mml:mo class="MathClass-bin">&#x02212;</mml:mo><mml:mn>4</mml:mn></mml:math></inline-formula>.</p></fn>
<fn id="fn18"><p><sup>18</sup>The following parameters were used to obtain these results: <italic>n<sub>c</sub></italic>&#x02009;&#x0003D;&#x02009;936, <italic>n<sub>ps</sub></italic>&#x02009;&#x0003D;&#x02009;353, <italic>&#x003C1;</italic><sub><italic>d</italic></sub>&#x02009;&#x0003D;&#x02009;14, <italic>&#x003D5;</italic><sub>&#x003B4;</sub>&#x02009;&#x0003D;&#x02009;0.0105, <italic>&#x003C1;</italic><sub><italic>c</italic></sub>&#x02009;&#x0003D;&#x02009;182, <italic>&#x003D5;</italic><sub>&#x0002B;</sub>&#x02009;&#x0003D;&#x02009;0.0355, <italic>&#x003D5;</italic><sub>&#x02212;</sub>&#x02009;&#x0003D;&#x02009;0.0024, <italic>&#x003B2;</italic><sub>0</sub>&#x02009;&#x0003D;&#x02009;18, and <italic>&#x003C4;</italic>&#x02009;&#x0003D;&#x02009;164.</p></fn>
<fn id="fn19"><p><sup>19</sup>The following parameters were used to obtain these results: <italic>n<sub>c</sub></italic>&#x02009;&#x0003D;&#x02009;786, <italic>n<sub>ps</sub></italic>&#x02009;&#x0003D;&#x02009;267, <italic>&#x003C1;</italic><sub><italic>d</italic></sub>&#x02009;&#x0003D;&#x02009;10, <italic>&#x003D5;</italic><sub>&#x003B4;</sub>&#x02009;&#x0003D;&#x02009;0.0425, <italic>&#x003C1;</italic><sub><italic>c</italic></sub>&#x02009;&#x0003D;&#x02009;57, <italic>&#x003D5;</italic><sub>&#x0002B;</sub>&#x02009;&#x0003D;&#x02009;0.0593, <italic>&#x003D5;</italic><sub>&#x02212;</sub>&#x02009;&#x0003D;&#x02009;0.0038, <italic>&#x003B2;</italic><sub>0</sub>&#x02009;&#x0003D;&#x02009;19, and <italic>&#x003C4;</italic>&#x02009;&#x0003D;&#x02009;755.</p></fn>
<fn id="fn20"><p><sup>20</sup>The following parameters were used to obtain these results: <italic>n<sub>c</sub></italic>&#x02009;&#x0003D;&#x02009;784, <italic>n<sub>ps</sub></italic>&#x02009;&#x0003D;&#x02009;392, <italic>&#x003C1;</italic><sub><italic>d</italic></sub>&#x02009;&#x0003D;&#x02009;10, <italic>&#x003D5;</italic><sub>&#x003B4;</sub>&#x02009;&#x0003D;&#x02009;0.01, <italic>&#x003C1;</italic><sub><italic>c</italic></sub>&#x02009;&#x0003D;&#x02009;10, <italic>&#x003D5;</italic><sub>&#x0002B;</sub>&#x02009;&#x0003D;&#x02009;0.001, <italic>&#x003D5;</italic><sub>&#x02212;</sub>&#x02009;&#x0003D;&#x02009;0.002, ten training epochs, global inhibition, and boosting was disabled. The number of columns was set to be equal to the number of attributes to allow for a 1:1 reconstruction of the SDRs.</p></fn>
<fn id="fn21"><p><sup>21</sup>A multivariate encoder is one which combines one or more other encoders. The multivariate encoder&#x02019;s output concatenates the output of each of the other encoders to form one SDR. A categorical encoder is one which losslessly converts an item to a unique SDR. To perform this conversion, the number of categories must be finite. For this experiment, each category encoder was set to produce an SDR with a total of 50 bits. The number of categories, for each encoder, was dynamically determined. This value was set to the number of unique instances for each attribute/class. No active bits were allowed to overlap across encodings. The number of active bits, for each encoding, was scaled to be the largest possible value. That scaling would result in utilizing as many of the 50 bits as possible, across all encodings. All encodings have the same number of active bits. In the event that the product of the number of categories and the number of active bits is less than the number of bits, the output was right padded with zeros.</p></fn>
<fn id="fn22"><p><sup>22</sup>This encoding followed the same process as the category encoders used for the attributes.</p></fn>
<fn id="fn23"><p><sup>23</sup>The following parameters were used: <italic>n<sub>c</sub></italic>&#x02009;&#x0003D;&#x02009;4096, <italic>n<sub>ps</sub></italic>&#x02009;&#x0003D;&#x02009;25, <italic>&#x003C1;</italic><sub><italic>d</italic></sub>&#x02009;&#x0003D;&#x02009;0, <italic>&#x003D5;</italic><sub>&#x003B4;</sub>&#x02009;&#x0003D;&#x02009;0.5, <italic>&#x003C1;</italic><sub><italic>c</italic></sub>&#x02009;&#x0003D;&#x02009;819, <italic>&#x003D5;</italic><sub>&#x0002B;</sub>&#x02009;&#x0003D;&#x02009;0.001, and <italic>&#x003D5;</italic><sub>&#x02212;</sub>&#x02009;&#x0003D;&#x02009;0.001. Boosting was disabled and global inhibition was used. Only a single training epoch was utilized. It was found that additional epochs were not required and could result in overfitting. <inline-formula><mml:math id="M183"><mml:msub><mml:mrow><mml:mi>&#x003C1;</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula> was intentionally set to be about 20% of <inline-formula><mml:math id="M184"><mml:msub><mml:mrow><mml:mi>n</mml:mi></mml:mrow><mml:mrow><mml:mi>c</mml:mi></mml:mrow></mml:msub></mml:math></inline-formula>. This deviates from the standard value of &#x0223C;2%. A value of 2% resulted in lower accuracies (across many different parameter settings) than 20%. This result is most likely a result of the chosen classifier. For use with the TM or a different classifier, additional experimentation will be required.</p></fn>
<fn id="fn24"><p><sup>24</sup>These classifiers were utilized from scikit-learn (<xref ref-type="bibr" rid="B21">2016</xref>).</p></fn>
<fn id="fn25"><p><sup>25</sup>The shown error is the median across all splits of the data.</p></fn>
</fn-group>
</back>
</article>