Add function to dump raw data into npy file