object to bytes and reture
# pandas.core.series.Series
import pandas as pd
b_series = data.to_msgpack(compress='zlib') # pandas.core.series.Series轉為bytes
pd.read_msgpack(b_series) # bytes轉回pandas.core.series.Series
# sklearn.svm.classes.svr
import pickle
b_svr = pickle.dumps(data) # sklearn.svm.classes.svr轉為bytes
pickle.loads(b_svr) # bytes轉回sklearn.svm.classes.SVR