Datasets:
Tasks:
Object Detection
Size Categories:
1K<n<10K
Source Datasets:
original
Tags:
other-object-detection
PierreLeveau
commited on
Commit
•
26e6b2d
1
Parent(s):
af27ffa
dataset: versioning and info
Browse files- dataset_infos.json +98 -1
- plastic_in_river.py +4 -5
dataset_infos.json
CHANGED
@@ -1 +1,98 @@
|
|
1 |
-
{
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"default": {
|
3 |
+
"description": "\n This dataset contains photos of rivers on which there may be waste. The waste items are annotated\n through bounding boxes, and are assigned to one of the 4 following categories: plastic bottle, plastic bag,\n another plastic waste, or non-plastic waste. Note that some photos may not contain any waste.\n",
|
4 |
+
"citation": "",
|
5 |
+
"homepage": "",
|
6 |
+
"license": "",
|
7 |
+
"features": {
|
8 |
+
"image": { "decode": true, "id": null, "_type": "Image" },
|
9 |
+
"litter": {
|
10 |
+
"feature": {
|
11 |
+
"label": {
|
12 |
+
"num_classes": 4,
|
13 |
+
"names": [
|
14 |
+
"PLASTIC_BAG",
|
15 |
+
"PLASTIC_BOTTLE",
|
16 |
+
"OTHER_PLASTIC_WASTE",
|
17 |
+
"NOT_PLASTIC_WASTE"
|
18 |
+
],
|
19 |
+
"names_file": null,
|
20 |
+
"id": null,
|
21 |
+
"_type": "ClassLabel"
|
22 |
+
},
|
23 |
+
"bbox": {
|
24 |
+
"feature": { "dtype": "float32", "id": null, "_type": "Value" },
|
25 |
+
"length": 4,
|
26 |
+
"id": null,
|
27 |
+
"_type": "Sequence"
|
28 |
+
}
|
29 |
+
},
|
30 |
+
"length": -1,
|
31 |
+
"id": null,
|
32 |
+
"_type": "Sequence"
|
33 |
+
}
|
34 |
+
},
|
35 |
+
"post_processed": null,
|
36 |
+
"supervised_keys": null,
|
37 |
+
"task_templates": null,
|
38 |
+
"builder_name": "plastic_in_river",
|
39 |
+
"config_name": "default",
|
40 |
+
"version": {
|
41 |
+
"version_str": "1.0.0",
|
42 |
+
"description": null,
|
43 |
+
"major": 1,
|
44 |
+
"minor": 0,
|
45 |
+
"patch": 0
|
46 |
+
},
|
47 |
+
"splits": {
|
48 |
+
"train": {
|
49 |
+
"name": "train",
|
50 |
+
"num_bytes": 1382005709,
|
51 |
+
"num_examples": 1186,
|
52 |
+
"dataset_name": "plastic_in_river"
|
53 |
+
},
|
54 |
+
"test": {
|
55 |
+
"name": "test",
|
56 |
+
"num_bytes": 174268213,
|
57 |
+
"num_examples": 149,
|
58 |
+
"dataset_name": "plastic_in_river"
|
59 |
+
},
|
60 |
+
"validation": {
|
61 |
+
"name": "validation",
|
62 |
+
"num_bytes": 170939935,
|
63 |
+
"num_examples": 148,
|
64 |
+
"dataset_name": "plastic_in_river"
|
65 |
+
}
|
66 |
+
},
|
67 |
+
"download_checksums": {
|
68 |
+
"https://storage.googleapis.com/kili-datasets-public/plastic-in-river/v1.0.0/train/images.tar.gz": {
|
69 |
+
"num_bytes": 350379542,
|
70 |
+
"checksum": "38fcc632c2c158dc746933e385aecca9f60dac9288da6676f6594b3b585fc025"
|
71 |
+
},
|
72 |
+
"https://storage.googleapis.com/kili-datasets-public/plastic-in-river/v1.0.0/train/annotations.tar.gz": {
|
73 |
+
"num_bytes": 180827,
|
74 |
+
"checksum": "70015049c893a3bb2e1bd0ff6a5926250908221f236dc2b75d54833e84aee4e0"
|
75 |
+
},
|
76 |
+
"https://storage.googleapis.com/kili-datasets-public/plastic-in-river/v1.0.0/validation/images.tar.gz": {
|
77 |
+
"num_bytes": 43885822,
|
78 |
+
"checksum": "fd297e2c42a6b8480b9445522b69fb6daaffaf169d5e6735e1925a12ba4c07d6"
|
79 |
+
},
|
80 |
+
"https://storage.googleapis.com/kili-datasets-public/plastic-in-river/v1.0.0/validation/annotations.tar.gz": {
|
81 |
+
"num_bytes": 15474,
|
82 |
+
"checksum": "6ff36a120ac0759426800557de7751317ce6f2c2b02857f0c53527f640747bf5"
|
83 |
+
},
|
84 |
+
"https://storage.googleapis.com/kili-datasets-public/plastic-in-river/v1.0.0/test/images.tar.gz": {
|
85 |
+
"num_bytes": 44563692,
|
86 |
+
"checksum": "b869224b3204f4d2cab176a32f903b9afdb77005f9d15e1844c6bf8484b4bf8f"
|
87 |
+
},
|
88 |
+
"https://storage.googleapis.com/kili-datasets-public/plastic-in-river/v1.0.0/test/annotations.tar.gz": {
|
89 |
+
"num_bytes": 15155,
|
90 |
+
"checksum": "e30057eac9f05c4759baab31830f1752fe42ef51680523d17df02a44183ed274"
|
91 |
+
}
|
92 |
+
},
|
93 |
+
"download_size": 439040512,
|
94 |
+
"post_processing_size": null,
|
95 |
+
"dataset_size": 1727213857,
|
96 |
+
"size_in_bytes": 2166254369
|
97 |
+
}
|
98 |
+
}
|
plastic_in_river.py
CHANGED
@@ -16,10 +16,7 @@ _HOMEPAGE = ""
|
|
16 |
|
17 |
_LICENSE = ""
|
18 |
|
19 |
-
|
20 |
-
# # The HuggingFace Datasets library doesn't host the datasets but only points to the original files.
|
21 |
-
# # This can be an arbitrary nested dict/list of URLs (see below in `_split_generators` method)
|
22 |
-
_URL = "https://storage.googleapis.com/kili-datasets-public/plastic-in-river/"
|
23 |
|
24 |
_URLS = {
|
25 |
"train_images": f"{_URL}train/images.tar.gz",
|
@@ -55,7 +52,9 @@ class PlasticInRiver(datasets.GeneratorBasedBuilder):
|
|
55 |
)
|
56 |
|
57 |
def _split_generators(self, dl_manager):
|
58 |
-
|
|
|
|
|
59 |
|
60 |
return [
|
61 |
datasets.SplitGenerator(
|
16 |
|
17 |
_LICENSE = ""
|
18 |
|
19 |
+
_URL = "https://storage.googleapis.com/kili-datasets-public/plastic-in-river/<VERSION>/"
|
|
|
|
|
|
|
20 |
|
21 |
_URLS = {
|
22 |
"train_images": f"{_URL}train/images.tar.gz",
|
52 |
)
|
53 |
|
54 |
def _split_generators(self, dl_manager):
|
55 |
+
urls = {k: v.replace("<VERSION>", f"v{str(self.VERSION)}") for k, v in _URLS.items()}
|
56 |
+
|
57 |
+
downloaded_files = dl_manager.download(urls)
|
58 |
|
59 |
return [
|
60 |
datasets.SplitGenerator(
|