Spaces:
Running
Running
File size: 424 Bytes
3811482 6e5b58a 3811482 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 |
# AUTOGENERATED! DO NOT EDIT! File to edit: ../nbs/05_utils.ipynb.
# %% auto 0
__all__ = ['load_json', 'dump_json']
# %% ../nbs/05_utils.ipynb 3
import json
# %% ../nbs/05_utils.ipynb 4
def load_json(file_path):
with open(file_path, "r") as file:
return json.load(file)
# %% ../nbs/05_utils.ipynb 5
def dump_json(data, path: str):
with open(path, "w") as fp:
return json.dump(data, fp, indent=2)
|