feat: dataset now persists to database

This commit is contained in:
2026-03-01 16:01:15 +00:00
parent 0be9ff4896
commit 5fb7710dc2
4 changed files with 104 additions and 16 deletions

View File

@@ -26,7 +26,7 @@ class DatasetProcessor:
return df
def enrich(self) -> pd.DataFrame:
self.df['timestamp'] = pd.to_numeric(self.df['timestamp'], errors='coerce')
self.df['timestamp'] = pd.to_numeric(self.df['timestamp'], errors='raise')
self.df['date'] = pd.to_datetime(self.df['timestamp'], unit='s').dt.date
self.df["dt"] = pd.to_datetime(self.df["timestamp"], unit="s", utc=True)
self.df["hour"] = self.df["dt"].dt.hour