Spaces:
Running
Running
update app.py, add choice button for VisionTSpp base and large
Browse files
app.py
CHANGED
|
@@ -225,7 +225,7 @@ def visual_ts_with_quantiles(true_data, pred_median, pred_quantiles_list, model_
|
|
| 225 |
print(pred_median[:, i].shape)
|
| 226 |
print(pred_range.shape)
|
| 227 |
|
| 228 |
-
pred_median_visual = true_data[context_len-1:context_len, i]
|
| 229 |
print(pred_median_visual.shape)
|
| 230 |
|
| 231 |
ax.plot(pred_range, pred_median_visual, label='Prediction (Median)', color='red', linewidth=1.5)
|
|
@@ -233,8 +233,8 @@ def visual_ts_with_quantiles(true_data, pred_median, pred_quantiles_list, model_
|
|
| 233 |
|
| 234 |
for j in range(num_bands):
|
| 235 |
lower_quantile_pred, upper_quantile_pred = quantile_preds[j][:, i], quantile_preds[-(j+1)][:, i]
|
| 236 |
-
lower_quantile_pred_visual = true_data[context_len-1:context_len, i]
|
| 237 |
-
upper_quantile_pred_visual = true_data[context_len-1:context_len, i]
|
| 238 |
|
| 239 |
print(lower_quantile_pred.shape)
|
| 240 |
print(upper_quantile_pred.shape)
|
|
|
|
| 225 |
print(pred_median[:, i].shape)
|
| 226 |
print(pred_range.shape)
|
| 227 |
|
| 228 |
+
pred_median_visual = np.concatenate([true_data[context_len-1:context_len, i], pred_median[:, i]])
|
| 229 |
print(pred_median_visual.shape)
|
| 230 |
|
| 231 |
ax.plot(pred_range, pred_median_visual, label='Prediction (Median)', color='red', linewidth=1.5)
|
|
|
|
| 233 |
|
| 234 |
for j in range(num_bands):
|
| 235 |
lower_quantile_pred, upper_quantile_pred = quantile_preds[j][:, i], quantile_preds[-(j+1)][:, i]
|
| 236 |
+
lower_quantile_pred_visual = np.concatenate([true_data[context_len-1:context_len, i], lower_quantile_pred])
|
| 237 |
+
upper_quantile_pred_visual = np.concatenate([true_data[context_len-1:context_len, i], upper_quantile_pred])
|
| 238 |
|
| 239 |
print(lower_quantile_pred.shape)
|
| 240 |
print(upper_quantile_pred.shape)
|