Create app.py
Browse files
app.py
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
from huggingface_hub import upload_folder, upload_file
|
| 2 |
+
|
| 3 |
+
repo_id = "Neon-coding/Ureola-vision"
|
| 4 |
+
repo_type = "dataset"
|
| 5 |
+
|
| 6 |
+
# 1. Upload parquet shards into /data
|
| 7 |
+
upload_folder(
|
| 8 |
+
folder_path="/data/image-shards", # your local folder
|
| 9 |
+
path_in_repo="data", # goes into /data in repo
|
| 10 |
+
repo_id=repo_id,
|
| 11 |
+
repo_type=repo_type
|
| 12 |
+
)
|
| 13 |
+
|
| 14 |
+
# 2. Upload JSON to root
|
| 15 |
+
upload_file(
|
| 16 |
+
path_or_fileobj="/data/images_state.json",
|
| 17 |
+
path_in_repo="images_state.json",
|
| 18 |
+
repo_id=repo_id,
|
| 19 |
+
repo_type=repo_type
|
| 20 |
+
)
|
| 21 |
+
|
| 22 |
+
print("Done. Structure is correct.")
|