Datasets:
Tasks:
Text Classification
Languages:
Persian
mahdiyehebrahimi
commited on
Commit
•
325e07d
1
Parent(s):
449f840
Update Tc.py
Browse files
Tc.py
CHANGED
@@ -9,8 +9,8 @@ IUT Ticket Classification
|
|
9 |
|
10 |
_DOWNLOAD_URLS = {
|
11 |
|
12 |
-
"train": "https://huggingface.co/datasets/mahdiyehebrahimi/University_Ticket_Classification/raw/main/
|
13 |
-
"test": "https://huggingface.co/datasets/mahdiyehebrahimi/University_Ticket_Classification/raw/main/
|
14 |
}
|
15 |
|
16 |
|
@@ -21,10 +21,10 @@ class SentimentDKSF(datasets.GeneratorBasedBuilder):
|
|
21 |
return datasets.DatasetInfo(
|
22 |
description=_DESCRIPTION,
|
23 |
features=datasets.Features(
|
24 |
-
{"label": datasets.features.ClassLabel(names=["drop_withdraw", "centralauthentication_email",
|
25 |
),
|
26 |
supervised_keys=None,
|
27 |
-
homepage="https://huggingface.co/datasets/
|
28 |
task_templates=[TextClassification(text_column="text", label_column="label")],
|
29 |
)
|
30 |
|
@@ -46,6 +46,7 @@ class SentimentDKSF(datasets.GeneratorBasedBuilder):
|
|
46 |
# skip the first row if your csv file has a header row
|
47 |
next(csv_reader, None)
|
48 |
for id_, row in enumerate(csv_reader):
|
49 |
-
|
50 |
label = label2id(label)
|
51 |
yield id_, {"text": text, "label": label}
|
|
|
|
9 |
|
10 |
_DOWNLOAD_URLS = {
|
11 |
|
12 |
+
"train": "https://huggingface.co/datasets/mahdiyehebrahimi/University_Ticket_Classification/raw/main/Tc_train.csv",
|
13 |
+
"test": "https://huggingface.co/datasets/mahdiyehebrahimi/University_Ticket_Classification/raw/main/Tc_test.csv"
|
14 |
}
|
15 |
|
16 |
|
|
|
21 |
return datasets.DatasetInfo(
|
22 |
description=_DESCRIPTION,
|
23 |
features=datasets.Features(
|
24 |
+
{"text": datasets.Value("string"), "label": datasets.features.ClassLabel(names=["drop_withdraw", "centralauthentication_email","supervisor_seminar_proposal_defense", "registration"])}
|
25 |
),
|
26 |
supervised_keys=None,
|
27 |
+
homepage="https://huggingface.co/datasets/hezarai/sentiment-dksf",
|
28 |
task_templates=[TextClassification(text_column="text", label_column="label")],
|
29 |
)
|
30 |
|
|
|
46 |
# skip the first row if your csv file has a header row
|
47 |
next(csv_reader, None)
|
48 |
for id_, row in enumerate(csv_reader):
|
49 |
+
text, label = row
|
50 |
label = label2id(label)
|
51 |
yield id_, {"text": text, "label": label}
|
52 |
+
yield id_, {"text": text, "label": label}
|