Implement a save/load mechanism
Closed this issue · 1 comments
gmaze commented
We need to be able to save a PCM once fitted for dissemination and later re-use.
Saving mechanism could go like:
m = pcm(K=8, feature_axis=np.arange(-500,0,2), feature_name='temperature')
m.save('my_pcm.nc')
We consequently need to be able to save a PCM in order to classify new data.
Possibly:
m = pcm('my_pcm.nc')
The file format could be netcdf or json.
A PCM does not hold much data.
In the PCM Matlab toolbox a netcdf format was used:
https://github.com/obidam/pcm/blob/master/matlab/src/pcmload.m
https://github.com/obidam/pcm/blob/master/matlab/src/pcmsave.m
gmaze commented
This is done since gmaze/pyxpcm@2a21af1