Fix URL for the validation split
#4
by
orsharir
- opened
- README.md +3 -3
- dataset_infos.json +1 -1
- hyperpartisan_news_detection.py +4 -4
README.md
CHANGED
@@ -65,8 +65,8 @@ dataset_info:
|
|
65 |
num_bytes: 2805711609
|
66 |
num_examples: 600000
|
67 |
- name: validation
|
68 |
-
num_bytes:
|
69 |
-
num_examples:
|
70 |
download_size: 1003195420
|
71 |
dataset_size: 5611423218
|
72 |
---
|
@@ -198,7 +198,7 @@ The data fields are the same among all splits.
|
|
198 |
|
199 |
| |train |validation|
|
200 |
|-----------|-----:|---------:|
|
201 |
-
|bypublisher|600000|
|
202 |
|
203 |
## Dataset Creation
|
204 |
|
|
|
65 |
num_bytes: 2805711609
|
66 |
num_examples: 600000
|
67 |
- name: validation
|
68 |
+
num_bytes: 960356598
|
69 |
+
num_examples: 150000
|
70 |
download_size: 1003195420
|
71 |
dataset_size: 5611423218
|
72 |
---
|
|
|
198 |
|
199 |
| |train |validation|
|
200 |
|-----------|-----:|---------:|
|
201 |
+
|bypublisher|600000| 150000|
|
202 |
|
203 |
## Dataset Creation
|
204 |
|
dataset_infos.json
CHANGED
@@ -1 +1 @@
|
|
1 |
-
{"byarticle": {"description": "Hyperpartisan News Detection was a dataset created for PAN @ SemEval 2019 Task 4.\nGiven a news article text, decide whether it follows a hyperpartisan argumentation, i.e., whether it exhibits blind, prejudiced, or unreasoning allegiance to one party, faction, cause, or person.\n\nThere are 2 parts:\n- byarticle: Labeled through crowdsourcing on an article basis. The data contains only articles for which a consensus among the crowdsourcing workers existed.\n- bypublisher: Labeled by the overall bias of the publisher as provided by BuzzFeed journalists or MediaBiasFactCheck.com.\n", "citation": "@article{kiesel2019data,\n title={Data for pan at semeval 2019 task 4: Hyperpartisan news detection},\n author={Kiesel, Johannes and Mestre, Maria and Shukla, Rishabh and Vincent, Emmanuel and Corney, David and Adineh, Payam and Stein, Benno and Potthast, Martin},\n year={2019}\n}\n", "homepage": "https://pan.webis.de/semeval19/semeval19-web/", "license": "", "features": {"text": {"dtype": "string", "id": null, "_type": "Value"}, "title": {"dtype": "string", "id": null, "_type": "Value"}, "hyperpartisan": {"dtype": "bool", "id": null, "_type": "Value"}, "url": {"dtype": "string", "id": null, "_type": "Value"}, "published_at": {"dtype": "string", "id": null, "_type": "Value"}}, "post_processed": {"features": null, "resources_checksums": {"train": {}}}, "supervised_keys": {"input": "text", "output": "label"}, "builder_name": "hyperpartisan_news_detection", "config_name": "byarticle", "version": {"version_str": "1.0.0", "description": "Version Training and validation v1", "datasets_version_to_prepare": null, "major": 1, "minor": 0, "patch": 0}, "splits": {"train": {"name": "train", "num_bytes": 2803943, "num_examples": 645, "dataset_name": "hyperpartisan_news_detection"}}, "download_checksums": {"https://zenodo.org/record/1489920/files/articles-training-byarticle-20181122.zip?download=1": {"num_bytes": 971841, "checksum": "62b4a71275ef2724faddc74d6ff3d782ee9898c732cd66119c7976f6f5168990"}, "https://zenodo.org/record/1489920/files/ground-truth-training-byarticle-20181122.zip?download=1": {"num_bytes": 28511, "checksum": "0c02f4c33317287758e6fbbc976cbfd7a0978923899ddf30cb9dd2cd740af43c"}}, "download_size": 1000352, "post_processing_size": 0, "dataset_size": 2803943, "size_in_bytes": 3804295}, "bypublisher": {"description": "Hyperpartisan News Detection was a dataset created for PAN @ SemEval 2019 Task 4.\nGiven a news article text, decide whether it follows a hyperpartisan argumentation, i.e., whether it exhibits blind, prejudiced, or unreasoning allegiance to one party, faction, cause, or person.\n\nThere are 2 parts:\n- byarticle: Labeled through crowdsourcing on an article basis. The data contains only articles for which a consensus among the crowdsourcing workers existed.\n- bypublisher: Labeled by the overall bias of the publisher as provided by BuzzFeed journalists or MediaBiasFactCheck.com.\n", "citation": "@article{kiesel2019data,\n title={Data for pan at semeval 2019 task 4: Hyperpartisan news detection},\n author={Kiesel, Johannes and Mestre, Maria and Shukla, Rishabh and Vincent, Emmanuel and Corney, David and Adineh, Payam and Stein, Benno and Potthast, Martin},\n year={2019}\n}\n", "homepage": "https://pan.webis.de/semeval19/semeval19-web/", "license": "", "features": {"text": {"dtype": "string", "id": null, "_type": "Value"}, "title": {"dtype": "string", "id": null, "_type": "Value"}, "hyperpartisan": {"dtype": "bool", "id": null, "_type": "Value"}, "url": {"dtype": "string", "id": null, "_type": "Value"}, "published_at": {"dtype": "string", "id": null, "_type": "Value"}, "bias": {"num_classes": 5, "names": ["right", "right-center", "least", "left-center", "left"], "names_file": null, "id": null, "_type": "ClassLabel"}}, "post_processed": {"features": null, "resources_checksums": {"train": {}, "validation": {}}}, "supervised_keys": {"input": "text", "output": "label"}, "builder_name": "hyperpartisan_news_detection", "config_name": "bypublisher", "version": {"version_str": "1.0.
|
|
|
1 |
+
{"byarticle": {"description": "Hyperpartisan News Detection was a dataset created for PAN @ SemEval 2019 Task 4.\nGiven a news article text, decide whether it follows a hyperpartisan argumentation, i.e., whether it exhibits blind, prejudiced, or unreasoning allegiance to one party, faction, cause, or person.\n\nThere are 2 parts:\n- byarticle: Labeled through crowdsourcing on an article basis. The data contains only articles for which a consensus among the crowdsourcing workers existed.\n- bypublisher: Labeled by the overall bias of the publisher as provided by BuzzFeed journalists or MediaBiasFactCheck.com.\n", "citation": "@article{kiesel2019data,\n title={Data for pan at semeval 2019 task 4: Hyperpartisan news detection},\n author={Kiesel, Johannes and Mestre, Maria and Shukla, Rishabh and Vincent, Emmanuel and Corney, David and Adineh, Payam and Stein, Benno and Potthast, Martin},\n year={2019}\n}\n", "homepage": "https://pan.webis.de/semeval19/semeval19-web/", "license": "", "features": {"text": {"dtype": "string", "id": null, "_type": "Value"}, "title": {"dtype": "string", "id": null, "_type": "Value"}, "hyperpartisan": {"dtype": "bool", "id": null, "_type": "Value"}, "url": {"dtype": "string", "id": null, "_type": "Value"}, "published_at": {"dtype": "string", "id": null, "_type": "Value"}}, "post_processed": {"features": null, "resources_checksums": {"train": {}}}, "supervised_keys": {"input": "text", "output": "label"}, "builder_name": "hyperpartisan_news_detection", "config_name": "byarticle", "version": {"version_str": "1.0.0", "description": "Version Training and validation v1", "datasets_version_to_prepare": null, "major": 1, "minor": 0, "patch": 0}, "splits": {"train": {"name": "train", "num_bytes": 2803943, "num_examples": 645, "dataset_name": "hyperpartisan_news_detection"}}, "download_checksums": {"https://zenodo.org/record/1489920/files/articles-training-byarticle-20181122.zip?download=1": {"num_bytes": 971841, "checksum": "62b4a71275ef2724faddc74d6ff3d782ee9898c732cd66119c7976f6f5168990"}, "https://zenodo.org/record/1489920/files/ground-truth-training-byarticle-20181122.zip?download=1": {"num_bytes": 28511, "checksum": "0c02f4c33317287758e6fbbc976cbfd7a0978923899ddf30cb9dd2cd740af43c"}}, "download_size": 1000352, "post_processing_size": 0, "dataset_size": 2803943, "size_in_bytes": 3804295}, "bypublisher": {"description": "Hyperpartisan News Detection was a dataset created for PAN @ SemEval 2019 Task 4.\nGiven a news article text, decide whether it follows a hyperpartisan argumentation, i.e., whether it exhibits blind, prejudiced, or unreasoning allegiance to one party, faction, cause, or person.\n\nThere are 2 parts:\n- byarticle: Labeled through crowdsourcing on an article basis. The data contains only articles for which a consensus among the crowdsourcing workers existed.\n- bypublisher: Labeled by the overall bias of the publisher as provided by BuzzFeed journalists or MediaBiasFactCheck.com.\n", "citation": "@article{kiesel2019data,\n title={Data for pan at semeval 2019 task 4: Hyperpartisan news detection},\n author={Kiesel, Johannes and Mestre, Maria and Shukla, Rishabh and Vincent, Emmanuel and Corney, David and Adineh, Payam and Stein, Benno and Potthast, Martin},\n year={2019}\n}\n", "homepage": "https://pan.webis.de/semeval19/semeval19-web/", "license": "", "features": {"text": {"dtype": "string", "id": null, "_type": "Value"}, "title": {"dtype": "string", "id": null, "_type": "Value"}, "hyperpartisan": {"dtype": "bool", "id": null, "_type": "Value"}, "url": {"dtype": "string", "id": null, "_type": "Value"}, "published_at": {"dtype": "string", "id": null, "_type": "Value"}, "bias": {"num_classes": 5, "names": ["right", "right-center", "least", "left-center", "left"], "names_file": null, "id": null, "_type": "ClassLabel"}}, "post_processed": {"features": null, "resources_checksums": {"train": {}, "validation": {}}}, "supervised_keys": {"input": "text", "output": "label"}, "builder_name": "hyperpartisan_news_detection", "config_name": "bypublisher", "version": {"version_str": "1.0.1", "description": "Version Training and validation v1", "datasets_version_to_prepare": null, "major": 1, "minor": 0, "patch": 1}, "splits": {"train": {"name": "train", "num_bytes": 2805711609, "num_examples": 600000, "dataset_name": "hyperpartisan_news_detection"}, "validation": {"name": "validation", "num_bytes": 960356598, "num_examples": 150000, "dataset_name": "hyperpartisan_news_detection"}}, "download_checksums": {"https://zenodo.org/record/1489920/files/articles-training-bypublisher-20181122.zip?download=1": {"num_bytes": 980769009, "checksum": "e5816b0c9fecd1a38f6cba8eb4f6f77d04637b5c6209e714b7ab32dc3bc24e28"}, "https://zenodo.org/record/1489920/files/ground-truth-training-bypublisher-20181122.zip?download=1": {"num_bytes": 22426411, "checksum": "f1c0494af86ff1e961479a63d432d649ccda875d302888f4d080dbec0382b1ef"}, "https://zenodo.org/record/1489920/files/articles-validation-bypublisher-20181122.zip?download=1": {"num_bytes": 337386275, "checksum": "dd1cd3d7f34d7f35564ba2b7002cad796877507bec503cc1dd02076dc289ae34"}, "https://zenodo.org/record/1489920/files/ground-truth-validation-bypublisher-20181122.zip?download=1": {"num_bytes": 5239324, "checksum": "23f7cd8b410a91193e2b6548ba274d7da1061ea7c86083e9b5ced4cac9bb34e7"}}, "download_size": 1345821019, "post_processing_size": 0, "dataset_size": 3766068207, "size_in_bytes": 6614618638}}
|
hyperpartisan_news_detection.py
CHANGED
@@ -46,7 +46,7 @@ _URL_BASE = "https://zenodo.org/record/1489920/files/"
|
|
46 |
class HyperpartisanNewsDetection(datasets.GeneratorBasedBuilder):
|
47 |
"""Hyperpartisan News Detection Dataset."""
|
48 |
|
49 |
-
VERSION = datasets.Version("1.0.
|
50 |
BUILDER_CONFIGS = [
|
51 |
datasets.BuilderConfig(
|
52 |
name="byarticle",
|
@@ -62,7 +62,7 @@ class HyperpartisanNewsDetection(datasets.GeneratorBasedBuilder):
|
|
62 |
),
|
63 |
datasets.BuilderConfig(
|
64 |
name="bypublisher",
|
65 |
-
version=datasets.Version("1.0.
|
66 |
description=textwrap.dedent(
|
67 |
"""
|
68 |
This part of the data (filename contains "bypublisher") is labeled by the overall bias of the publisher as provided
|
@@ -107,8 +107,8 @@ class HyperpartisanNewsDetection(datasets.GeneratorBasedBuilder):
|
|
107 |
}
|
108 |
if self.config.name == "bypublisher":
|
109 |
urls[datasets.Split.VALIDATION] = {
|
110 |
-
"articles_file": _URL_BASE + "articles-
|
111 |
-
"labels_file": _URL_BASE + "ground-truth-
|
112 |
}
|
113 |
|
114 |
data_dir = {}
|
|
|
46 |
class HyperpartisanNewsDetection(datasets.GeneratorBasedBuilder):
|
47 |
"""Hyperpartisan News Detection Dataset."""
|
48 |
|
49 |
+
VERSION = datasets.Version("1.0.1")
|
50 |
BUILDER_CONFIGS = [
|
51 |
datasets.BuilderConfig(
|
52 |
name="byarticle",
|
|
|
62 |
),
|
63 |
datasets.BuilderConfig(
|
64 |
name="bypublisher",
|
65 |
+
version=datasets.Version("1.0.1", "Version Training and validation v1"),
|
66 |
description=textwrap.dedent(
|
67 |
"""
|
68 |
This part of the data (filename contains "bypublisher") is labeled by the overall bias of the publisher as provided
|
|
|
107 |
}
|
108 |
if self.config.name == "bypublisher":
|
109 |
urls[datasets.Split.VALIDATION] = {
|
110 |
+
"articles_file": _URL_BASE + "articles-validation-" + self.config.name + "-20181122.zip?download=1",
|
111 |
+
"labels_file": _URL_BASE + "ground-truth-validation-" + self.config.name + "-20181122.zip?download=1",
|
112 |
}
|
113 |
|
114 |
data_dir = {}
|