用于保存数据
imoprt pickle
保存
with open('/data/hanjl/my_data/batch_data.pkl', 'wb') as f:
pickle.dump(my_data, f)
加载
with open('/data/hanjl/my_data/batch_data.pkl', 'rb') as f:
my_data = pickle.load(f)
用于保存数据
imoprt pickle
保存
with open('/data/hanjl/my_data/batch_data.pkl', 'wb') as f:
pickle.dump(my_data, f)
加载
with open('/data/hanjl/my_data/batch_data.pkl', 'rb') as f:
my_data = pickle.load(f)