【PYTHON】Read and Write using joblib library

 import joblib

data_dictionary = {'books'12'articles'100'subjects': ['math''programming''data science']}

joblib.dump(value=data_dictionary, filename='readings.job', compress=True)

data = joblib.load(filename='readings.job')
data

%%timeit
joblib.dump(value=data_dictionary, filename='readings.job', compress=True)

%%timeit
import pickle as pk

with open('readings.pk''wb'as f:
  pk.dump(data_dictionary, f)

%%timeit
data = joblib.load(filename='readings.job')

%%timeit
import pickle as pk
with open('readings.pk''rb'as f:
  data = pk.load(f)

No comments:

Power Is Shifting Rapidly to Indie Creators

The exodus from Twitter since the election is a sign of things to come ͏     ­͏     ­͏     ­͏     ­͏     ­͏     ­͏     ­͏     ­͏     ­͏     ...

Contact Form

Name

Email *

Message *