frtna commited on
Commit
981f92e
1 Parent(s): 21a4d09

Update ted_mt.py

Browse files
Files changed (1) hide show
  1. ted_mt.py +7 -7
ted_mt.py CHANGED
@@ -27,7 +27,7 @@ import datasets
27
  # Find for instance the citation on arxiv or on the dataset repo/website
28
  _CITATION = """\
29
  @InProceedings{phd,
30
- title = {Open Subtitles Machine Translation Dataset},
31
  author={hmtkvs, Inc.
32
  },
33
  year={2021}
@@ -37,7 +37,7 @@ year={2021}
37
  # TODO: Add description of the dataset here
38
  # You can copy an official description
39
  _DESCRIPTION = """\
40
- This new dataset is designed to be used in the scope of PhD project.
41
  """
42
 
43
  # TODO: Add a link to an official homepage for the dataset here
@@ -51,9 +51,9 @@ _LICENSE = ""
51
  # This can be an arbitrary nested dict/list of URLs (see below in `_split_generators` method)
52
  # url = "https://drive.google.com/drive/folders/1Jvvddj0abp9rMAGhqXqpPbE8-Y28iyM3?usp=sharing"
53
  _URLs = {
54
- "train": "train_.json",#"https://drive.google.com/uc?export=download&id=1-0r83eGwRfmfVAEtdyiregvneJ81ev1N",
55
- "validation": "validation_.json",#"https://drive.google.com/uc?export=download&id=1-0zTW12OKIPrH3Zmad6tvSte7bA8O4RR",
56
- "test": "test_.json"#"https://drive.google.com/uc?export=download&id=1-2U6BeDluJxIieMA6JTjLoij_KcMhl4Y"
57
  }
58
 
59
 
@@ -75,7 +75,7 @@ class NewDataset(datasets.GeneratorBasedBuilder):
75
  # data = datasets.load_dataset('my_dataset', 'first_domain')
76
  # data = datasets.load_dataset('my_dataset', 'second_domain')
77
  BUILDER_CONFIGS = [
78
- datasets.BuilderConfig(name="ted_mt", version=VERSION, description="This part of my dataset covers a first domain")
79
  ]
80
 
81
  # DEFAULT_CONFIG_NAME = "opus_books_es_it" # It's not mandatory to have a default configuration. Just use one if it make sense.
@@ -158,6 +158,6 @@ class NewDataset(datasets.GeneratorBasedBuilder):
158
  data = json.loads(line)
159
  yield id_, {
160
  "translation":{"Spanish": data["Spanish"],
161
- "Italian": data["Italian"]#"" if split == "test" else data["Italian"],
162
  }
163
  }
27
  # Find for instance the citation on arxiv or on the dataset repo/website
28
  _CITATION = """\
29
  @InProceedings{phd,
30
+ title = {Machine Translation Dataset},
31
  author={hmtkvs, Inc.
32
  },
33
  year={2021}
37
  # TODO: Add description of the dataset here
38
  # You can copy an official description
39
  _DESCRIPTION = """\
40
+ This new dataset is designed to be used in the scope of multilingual model project.
41
  """
42
 
43
  # TODO: Add a link to an official homepage for the dataset here
51
  # This can be an arbitrary nested dict/list of URLs (see below in `_split_generators` method)
52
  # url = "https://drive.google.com/drive/folders/1Jvvddj0abp9rMAGhqXqpPbE8-Y28iyM3?usp=sharing"
53
  _URLs = {
54
+ "train": "train_.json",
55
+ "validation": "validation_.json",
56
+ "test": "test_.json"
57
  }
58
 
59
 
75
  # data = datasets.load_dataset('my_dataset', 'first_domain')
76
  # data = datasets.load_dataset('my_dataset', 'second_domain')
77
  BUILDER_CONFIGS = [
78
+ datasets.BuilderConfig(name="ted_mt", version=VERSION, description="First domain")
79
  ]
80
 
81
  # DEFAULT_CONFIG_NAME = "opus_books_es_it" # It's not mandatory to have a default configuration. Just use one if it make sense.
158
  data = json.loads(line)
159
  yield id_, {
160
  "translation":{"Spanish": data["Spanish"],
161
+ "Italian": data["Italian"]#hide true labels >> if split == "test" else data["Italian"],
162
  }
163
  }