Allow to save/load query results
lambdamusic opened this issue · comments
Similar to what pickle
does with Python objects.
res = dsl.query(q)
# save
import pickle
with open('filename.pickle', 'wb') as handle:
pickle.dump(res, handle)
# => can be packed into res.save(filename)
Then loading
# full syntax
with open('filename.pickle', 'rb') as handle:
b = pickle.load(handle)
# => can be packed into
dsl.load(b) # => returns a dimcli.core.api.Result() object preloaded with data