Saving and loading of Arrays
Introduction#
Numpy arrays can be saved and loaded in various ways.
Using numpy.save and numpy.load
np.save and np.load provide a easy to use framework for saving and loading of arbitrary sized numpy arrays:
import numpy as np
a = np.random.randint(10,size=(3,3))
np.save('arr', a)
a2 = np.load('arr.npy')
print a2