Advertisement
Guest User

Wai.py

a guest
Jan 17th, 2018
68
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.18 KB | None | 0 0
  1. import numpy as np
  2.  
  3.  
  4.  
  5. # Save
  6. dictionary = {}
  7. np.save('my_file.npy', dictionary)
  8.  
  9.  
  10. # Load
  11. dictionary = np.load('my_file.npy').item()
  12. # print(dictionary['hello']) # displays "world"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement