serialize#
- serialize(data, filename, file_format='auto', **kwargs)[source]#
Serialize data to file.
- Parameters:
- dataobject, list, or tuple
Data to serialize.
- filenamestr
Output filename.
- format{‘pickle’, ‘hdf5’, ‘auto’}
File format. Extension of filename determines format for ‘auto’.
- **kwargs
Keyword arguments passed to writer function.
Notes
Passing a filename with extension ‘pickle.gz’ will create a gzipped pickle.