Links

Read file json

Tags: #jupyternotebooks #naas #jupyter-notebooks #read #snippet #operations
Author: Florent Ravenel
Description: This notebook provides a guide to reading and manipulating JSON files using Jupyter Notebooks.

Input

Import libraries

import json
from pprint import pprint

Variables

# Input
notebook_path = "../template.ipynb"

Model

Open file

with open(notebook_path) as f:
nb = json.load(f)

Output

Display result

pprint(nb)