Spaces:
Sleeping
Sleeping
Delete compare_jsons.py with huggingface_hub
Browse files- compare_jsons.py +0 -16
compare_jsons.py
DELETED
|
@@ -1,16 +0,0 @@
|
|
| 1 |
-
import json
|
| 2 |
-
import os
|
| 3 |
-
|
| 4 |
-
files = [
|
| 5 |
-
r'c:\react_projects\VortexCommerce\kaggle\extra_products_vortex.json',
|
| 6 |
-
r'c:\react_projects\VortexCommerce\backend\kaggle\extra_products_vortex.json'
|
| 7 |
-
]
|
| 8 |
-
|
| 9 |
-
for f_path in files:
|
| 10 |
-
if os.path.exists(f_path):
|
| 11 |
-
with open(f_path, "r", encoding="utf-8") as f:
|
| 12 |
-
data = json.load(f)
|
| 13 |
-
count = len(data["products"]) if isinstance(data, dict) and "products" in data else len(data)
|
| 14 |
-
print(f"{f_path}: {count} products")
|
| 15 |
-
else:
|
| 16 |
-
print(f"{f_path}: NOT FOUND")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|