Serialize obj as bytes streamed into file protocol defaults to cloudpickle.DEFAULT_PROTOCOL which is an alias to pickle.HIGHEST_PROTOCOL. This setting favors maximum communication speed between processes running the same Python version. Set protocol=pickle.DEFAULT_PROTOCOL instead
(obj, file, protocol=None, buffer_callback=None)
| 1525 | |
| 1526 | |
| 1527 | def dump(obj, file, protocol=None, buffer_callback=None): |
| 1528 | """Serialize obj as bytes streamed into file |
| 1529 | |
| 1530 | protocol defaults to cloudpickle.DEFAULT_PROTOCOL which is an alias to |
| 1531 | pickle.HIGHEST_PROTOCOL. This setting favors maximum communication |
| 1532 | speed between processes running the same Python version. |
| 1533 | |
| 1534 | Set protocol=pickle.DEFAULT_PROTOCOL instead if you need to ensure |
| 1535 | compatibility with older versions of Python (although this is not always |
| 1536 | guaranteed to work because cloudpickle relies on some internal |
| 1537 | implementation details that can change from one Python version to the |
| 1538 | next). |
| 1539 | """ |
| 1540 | Pickler(file, protocol=protocol, buffer_callback=buffer_callback).dump(obj) |
| 1541 | |
| 1542 | |
| 1543 | def dumps(obj, protocol=None, buffer_callback=None): |