import random import json with open('/home/nguyendc/sonnh/embedding-clustering/filter/008_label_data_sample_seed_1997.json', 'r') as f: data = json.load(f) random.seed(8272025) random.shuffle(data) with open('/home/nguyendc/sonnh/embedding-clustering/filter/032_shuffle_008.json', 'w') as f: json.dump(data, f)