Spaces:
Sleeping
Sleeping
Evgueni Poloukarov
commited on
Commit
·
3f32d3a
1
Parent(s):
2c1d599
debug: add diagnostic logging to inference export step
Browse files
src/forecasting/chronos_inference.py
CHANGED
|
@@ -289,6 +289,15 @@ def run_inference(
|
|
| 289 |
forecast_days=forecast_days
|
| 290 |
)
|
| 291 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 292 |
# Export to parquet
|
| 293 |
output_filename = f"forecast_{run_date}_{forecast_type}.parquet"
|
| 294 |
output_path = os.path.join(output_dir, output_filename)
|
|
|
|
| 289 |
forecast_days=forecast_days
|
| 290 |
)
|
| 291 |
|
| 292 |
+
# Diagnostic logging
|
| 293 |
+
print(f"[DEBUG] Results summary:", flush=True)
|
| 294 |
+
print(f" Borders in results: {list(results['borders'].keys())}", flush=True)
|
| 295 |
+
for border, data in results['borders'].items():
|
| 296 |
+
if 'error' in data:
|
| 297 |
+
print(f" {border}: ERROR - {data['error']}", flush=True)
|
| 298 |
+
else:
|
| 299 |
+
print(f" {border}: OK (median values count: {len(data.get('median', []))})", flush=True)
|
| 300 |
+
|
| 301 |
# Export to parquet
|
| 302 |
output_filename = f"forecast_{run_date}_{forecast_type}.parquet"
|
| 303 |
output_path = os.path.join(output_dir, output_filename)
|