revert all changes in normalize_data()

This commit is contained in:
robcaulk 2022-09-03 19:48:30 +02:00
parent c21808ff98
commit 5cfb4154eb

View File

@ -288,12 +288,11 @@ class FreqaiDataKitchen:
:data_dictionary: updated dictionary with standardized values.
"""
df = data_dictionary["train_features"]
# standardize the data by training stats
train_max = df.max()
train_min = df.min()
df = (
2 * (df - train_min) / (train_max - train_min) - 1
train_max = data_dictionary["train_features"].max()
train_min = data_dictionary["train_features"].min()
data_dictionary["train_features"] = (
2 * (data_dictionary["train_features"] - train_min) / (train_max - train_min) - 1
)
data_dictionary["test_features"] = (
2 * (data_dictionary["test_features"] - train_min) / (train_max - train_min) - 1