numenta / nupic-legacy

Numenta Platform for Intelligent Computing is an implementation of Hierarchical Temporal Memory (HTM), a theory of intelligence based strictly on the neuroscience of the neocortex.
http://numenta.org/
GNU Affero General Public License v3.0
6.33k stars 1.56k forks source link

KeyError in complete-opf-example.py #3883

Open RootChenLQ opened 4 years ago

RootChenLQ commented 4 years ago

There is nan value in multistepBucketLikelihoods, when I use my own dataset, and set _NUM_RECORDS as 6000. The error is listed as below.

multistepBucketLikelihoods = {1: {499: 1.0}, 5: {499: nan, 501: 0.0}}
File "D:\ProgramData\PythonWorkspace\nupic\docs\examples\opf\test.py", line 52, in runHotgym fiveStepConfidence = allPredictions[5][fiveStep]
File "D:\ProgramData\PythonWorkspace\nupic\docs\examples\opf\test.py", line 65, in <module>
    results = runHotgym(_NUM_RECORDS)

Thank you for your Help.

rhyolight commented 4 years ago

It may be that your data set is missing some data?