diff --git a/load_data.py b/load_data.py index 13180bb06d836e76edb7ed62853fcbb1938de910..988cfb27ea3549b667bf59d0e0c9d809e1d8ca3d 100644 --- a/load_data.py +++ b/load_data.py @@ -38,7 +38,7 @@ def extract_charge_items(charge, battery_nb, charge_nb): df_charge['charge_nb'] = [charge_nb] * len( charge['voltage_measured']) df_charge['datetime'] = pd.Timestamp( - charge['datetime']) + pd.to_timedelta(charge['time'][0], + charge['datetime']) + pd.to_timedelta(charge['time'], unit='s') return df_charge @@ -188,3 +188,11 @@ def get_datas( ) return set_labels_Y(df_training), set_labels_Y(df_validation), set_labels_Y(df_test) + + +def example(): + df_train, df_validation, df_test = get_datas() + + +if __name__ == '__main__': + example()