This commit is contained in:
Szymon Bartanowicz 2024-05-15 00:41:20 +02:00
parent adf3b77091
commit 17be57bcd3

View File

@ -9,8 +9,12 @@ from keras.metrics import MeanSquaredError
loaded_model = tf.keras.models.load_model('powerlifting_model.h5') loaded_model = tf.keras.models.load_model('powerlifting_model.h5')
data = pd.read_csv('openpowerlifting.csv') data = pd.read_csv('./data/train.csv')
data = data[['Sex', 'Age', 'BodyweightKg', 'TotalKg']].dropna() data = data[['Sex', 'Age', 'BodyweightKg', 'TotalKg']].dropna()
data['Age'] = pd.to_numeric(data['Age'], errors='coerce')
data['BodyweightKg'] = pd.to_numeric(data['BodyweightKg'], errors='coerce')
data['TotalKg'] = pd.to_numeric(data['TotalKg'], errors='coerce')
features = data[['Sex', 'Age', 'BodyweightKg']] features = data[['Sex', 'Age', 'BodyweightKg']]
target = data['TotalKg'] target = data['TotalKg']