I have a sequence like 1,2,5,4 and this sequence keeps on repeating. I am using opf to predict the next value in the sequence but I want the HTM model to stop learning at some point. How do I achieve this in Nupic?
I believe the method youāre looking for is finishLearning()
found in nupic.frameworks.opf.model
.
I found it in the online docs for version 0.7.0.
The function you are looking for is disableLearning()
.
@rhyolight Ahh, quite right. If Iām understanding the docs correctly, finishLearning()
would place the model in a āpermanent āfinished learningā modeā, which may or may not be what you want.
Thanx a lot. the disableLearning() method was what I was looking for.
Also is there any way to reset the whole model so that I can start the learning from scratch without actually exiting the program?
SOLVED
I have created a function called resetModel and in it I am again rebuilding the model. That way all the previous learning experiences will get deleted and the model will start learning from scratch. I guess thatās one way to do it.
> def resetModel():
> model = ModelFactory.create(MODEL_PARAMS)
> model.enableInference({āpredictedFieldā: āfuturemoveā})