AttributeError with model.save related to TMCPPShim object

Hello,

I’m new to Nupic, and today I ran into a problem saving a model. My code is simple:

model = createModel()
model.enableInference({“predictedField”: “cpu1”})
model.save(fullpath)

“fullpath” refers to the full string path to the directory where I wish to save the model.
createModel() is largely based on the OPF example code, though the parameters in my .yaml file are more like the ones seen in Matt’s post here

The exact error is:
AttributeError: ("‘TMCPPShim’ object has no attribute ‘saveToFile’", u’occurred at index 0’)

I’m working on a mac - not sure if that’s relevant.

Any help getting through this saving issue would be appreciated.

1 Like

@scott TMCPPShim should get its serializability from TemporalMemory, or does this error look like something from the old pickle method of saving?

@Jody_Schechter By the way, what version of NuPIC are you running?

nupic 0.7.0
nupic.bindings 0.6.3

1 Like

Looks like a bug in the implementation. And yes, it is the old/current method.

@Jody_Schechter I’m hesitant to file a bug about this because we are about to release a new version with a new serialization technique that’s much faster and more compatible with other environments. But here it is, not sure we will pick it up as we’re all-hands-on-deck for the new version.

Alright, thank you. I will be on the lookout for the new version.