Files
hao-ai-lab-FastVideo/pretty_json.py
T
2024-10-29 21:10:50 +00:00

11 lines
214 B
Python

import json
import os
path = "data/Mochi-Synthetic-Data/videos2caption.json"
with open(path, 'r') as f:
data = json.load(f)
# save with indent
with open(path, 'w') as f:
json.dump(data, f, indent=4)