[NumPy-Tickets] [NumPy] #1883: unpickling a pickled empty masked array error

NumPy Trac numpy-tickets@scipy....
Tue Jun 28 14:13:42 CDT 2011

#1883: unpickling a pickled empty masked array error
 Reporter:  mauro                |       Owner:  pierregm   
     Type:  defect               |      Status:  new        
 Priority:  normal               |   Milestone:  Unscheduled
Component:  numpy.ma             |     Version:  1.5.1      
 Keywords:  masked array pickle  |  
 When unpickling an empty masked array the following error is thrown:
 TypeError: object pickle not returning list


 import numpy as np

 import cPickle as pickle
 #import pickle as pickle

 ma = np.ma.core.MaskedArray()

 with open('tmp.pkl', 'wb') as fil:
     pickle.dump(ma, fil, protocol=pickle.HIGHEST_PROTOCOL)

 with open('tmp.pkl') as fil:

Ticket URL: <http://projects.scipy.org/numpy/ticket/1883>
NumPy <http://projects.scipy.org/numpy>
My example project

More information about the NumPy-Tickets mailing list