Last active
May 18, 2016 09:52
-
-
Save aabadie/7cba3385406d1cec7d3dd4407ba3f164 to your computer and use it in GitHub Desktop.
Base python script used to profile memory usage of joblib dump/load functions
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
import joblib | |
obj = [np.ones((5000, 5000)), np.random.random((5000, 5000))] | |
joblib.dump(obj, '/tmp/test.pkl', compress=True) | |
joblib.load('/tmp/test.pkl') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
How to use this script
@profile
decorator to joblibdump
andload
functions injoblib/numpy_pickle.py
$ mprof run profile_memory.py && mprof plot