Datasets:
Update arhythmia.py
Browse files- arhythmia.py +1 -1
arhythmia.py
CHANGED
@@ -656,7 +656,7 @@ class Arhythmia(datasets.GeneratorBasedBuilder):
|
|
656 |
data.loc[:, "type_of_arhythmia"] = data["type_of_arhythmia"].apply(lambda x: label_encoding[x])
|
657 |
|
658 |
if config == "has_arhythmia":
|
659 |
-
data.loc[:, "
|
660 |
data = data.rename(columns={"type_of_arhytmia": "has_arhythmia"})
|
661 |
|
662 |
return data[list(features_types_per_config[config].keys())]
|
|
|
656 |
data.loc[:, "type_of_arhythmia"] = data["type_of_arhythmia"].apply(lambda x: label_encoding[x])
|
657 |
|
658 |
if config == "has_arhythmia":
|
659 |
+
data.loc[:, "type_of_arhythmia"] = data["type_of_arhythmia"].apply(lambda x: 0 if x == 0 else 1)
|
660 |
data = data.rename(columns={"type_of_arhytmia": "has_arhythmia"})
|
661 |
|
662 |
return data[list(features_types_per_config[config].keys())]
|