fix: script, docs: readme
Browse files- README.md +18 -2
- annotations.xml +0 -0
- cows-detection-dataset.py +2 -2
README.md
CHANGED
|
@@ -1,14 +1,30 @@
|
|
| 1 |
---
|
|
|
|
|
|
|
| 2 |
license: cc-by-nc-nd-4.0
|
| 3 |
task_categories:
|
| 4 |
- image-to-image
|
| 5 |
- image-classification
|
| 6 |
- object-detection
|
| 7 |
-
language:
|
| 8 |
-
- en
|
| 9 |
tags:
|
| 10 |
- biology
|
| 11 |
- code
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 12 |
---
|
| 13 |
|
| 14 |
# Cows Detection Dataset
|
|
|
|
| 1 |
---
|
| 2 |
+
language:
|
| 3 |
+
- en
|
| 4 |
license: cc-by-nc-nd-4.0
|
| 5 |
task_categories:
|
| 6 |
- image-to-image
|
| 7 |
- image-classification
|
| 8 |
- object-detection
|
|
|
|
|
|
|
| 9 |
tags:
|
| 10 |
- biology
|
| 11 |
- code
|
| 12 |
+
dataset_info:
|
| 13 |
+
features:
|
| 14 |
+
- name: id
|
| 15 |
+
dtype: int32
|
| 16 |
+
- name: image
|
| 17 |
+
dtype: image
|
| 18 |
+
- name: mask
|
| 19 |
+
dtype: image
|
| 20 |
+
- name: bboxes
|
| 21 |
+
dtype: string
|
| 22 |
+
splits:
|
| 23 |
+
- name: train
|
| 24 |
+
num_bytes: 184108240
|
| 25 |
+
num_examples: 51
|
| 26 |
+
download_size: 183666433
|
| 27 |
+
dataset_size: 184108240
|
| 28 |
---
|
| 29 |
|
| 30 |
# Cows Detection Dataset
|
annotations.xml
DELETED
|
The diff for this file is too large to render.
See raw diff
|
|
|
cows-detection-dataset.py
CHANGED
|
@@ -49,7 +49,7 @@ class CowsDetectionDataset(datasets.GeneratorBasedBuilder):
|
|
| 49 |
|
| 50 |
def _split_generators(self, dl_manager):
|
| 51 |
images = dl_manager.download(f"{_DATA}images.tar.gz")
|
| 52 |
-
masks = dl_manager.download(f"{_DATA}
|
| 53 |
annotations = dl_manager.download(f"{_DATA}{_NAME}.csv")
|
| 54 |
images = dl_manager.iter_archive(images)
|
| 55 |
masks = dl_manager.iter_archive(masks)
|
|
@@ -74,5 +74,5 @@ class CowsDetectionDataset(datasets.GeneratorBasedBuilder):
|
|
| 74 |
"id": annotations_df["image_id"].iloc[idx],
|
| 75 |
"image": {"path": image_path, "bytes": image.read()},
|
| 76 |
"mask": {"path": mask_path, "bytes": mask.read()},
|
| 77 |
-
"bboxes": annotations_df["
|
| 78 |
}
|
|
|
|
| 49 |
|
| 50 |
def _split_generators(self, dl_manager):
|
| 51 |
images = dl_manager.download(f"{_DATA}images.tar.gz")
|
| 52 |
+
masks = dl_manager.download(f"{_DATA}boxes.tar.gz")
|
| 53 |
annotations = dl_manager.download(f"{_DATA}{_NAME}.csv")
|
| 54 |
images = dl_manager.iter_archive(images)
|
| 55 |
masks = dl_manager.iter_archive(masks)
|
|
|
|
| 74 |
"id": annotations_df["image_id"].iloc[idx],
|
| 75 |
"image": {"path": image_path, "bytes": image.read()},
|
| 76 |
"mask": {"path": mask_path, "bytes": mask.read()},
|
| 77 |
+
"bboxes": annotations_df["annotations"].iloc[idx],
|
| 78 |
}
|