Datasets:
Tasks:
Text Classification
Sub-tasks:
sentiment-classification
Languages:
English
Multilinguality:
monolingual
Size Categories:
10K<n<100K
Language Creators:
expert-generated
Annotations Creators:
expert-generated
Source Datasets:
extended|imdb
Tags:
License:
Francisco Castillo
commited on
Commit
•
2c3b9a3
1
Parent(s):
7635d84
wip
Browse files- reviews_with_drift.py +5 -5
reviews_with_drift.py
CHANGED
@@ -89,7 +89,7 @@ class ReviewsWithDrift(datasets.GeneratorBasedBuilder):
|
|
89 |
features = datasets.Features(
|
90 |
# These are the features of your dataset like images, labels ...
|
91 |
{
|
92 |
-
"prediction_ts": datasets.Value("
|
93 |
"age":datasets.Value("int16"),
|
94 |
"gender":datasets.Value("string"),
|
95 |
"context":datasets.Value("string"),
|
@@ -156,15 +156,15 @@ class ReviewsWithDrift(datasets.GeneratorBasedBuilder):
|
|
156 |
csv_reader = csv.reader(csv_file)
|
157 |
for id_, row in enumerate(csv_reader):
|
158 |
prediction_ts,age,gender,context,text,label = row
|
159 |
-
print(prediction_ts)
|
160 |
-
print(type(prediction_ts))
|
161 |
-
print(float(prediction_ts))
|
162 |
print(type(float(prediction_ts)))
|
163 |
print(age)
|
164 |
print(type(label))
|
165 |
print(label)
|
166 |
yield id_, {
|
167 |
-
"prediction_ts":
|
168 |
"age":15,
|
169 |
"gender":gender,
|
170 |
"context":context,
|
|
|
89 |
features = datasets.Features(
|
90 |
# These are the features of your dataset like images, labels ...
|
91 |
{
|
92 |
+
"prediction_ts": datasets.Value("float32"),
|
93 |
"age":datasets.Value("int16"),
|
94 |
"gender":datasets.Value("string"),
|
95 |
"context":datasets.Value("string"),
|
|
|
156 |
csv_reader = csv.reader(csv_file)
|
157 |
for id_, row in enumerate(csv_reader):
|
158 |
prediction_ts,age,gender,context,text,label = row
|
159 |
+
# print(prediction_ts)
|
160 |
+
# print(type(prediction_ts))
|
161 |
+
# print(float(prediction_ts))
|
162 |
print(type(float(prediction_ts)))
|
163 |
print(age)
|
164 |
print(type(label))
|
165 |
print(label)
|
166 |
yield id_, {
|
167 |
+
"prediction_ts":prediction_ts,
|
168 |
"age":15,
|
169 |
"gender":gender,
|
170 |
"context":context,
|