From 6a1f9d30f379ab7d099b481cd0eac77d6fca0809 Mon Sep 17 00:00:00 2001 From: gameloader Date: Thu, 11 Sep 2025 17:11:17 +0800 Subject: [PATCH] refactor(scripts): update xPatch_SparseChannel forecast scripts --- .../xPatch_SparseChannel_all-Copy1.sh | 2 +- .../xPatch_SparseChannel_all.sh | 80 ++++++++++--------- 2 files changed, 45 insertions(+), 37 deletions(-) diff --git a/scripts/long_term_forecast/xPatch_SparseChannel_all-Copy1.sh b/scripts/long_term_forecast/xPatch_SparseChannel_all-Copy1.sh index 40b9723..aa07a76 100644 --- a/scripts/long_term_forecast/xPatch_SparseChannel_all-Copy1.sh +++ b/scripts/long_term_forecast/xPatch_SparseChannel_all-Copy1.sh @@ -106,7 +106,7 @@ python -u run.py \ --n_heads 16 \ --patch_len 16 \ --stride 8 \ - --k_graph 8 \ + --k_graph 7 \ --dropout 0.1 \ --revin 1 \ --des 'Exp' \ diff --git a/scripts/long_term_forecast/xPatch_SparseChannel_all.sh b/scripts/long_term_forecast/xPatch_SparseChannel_all.sh index f870afe..b31cd17 100644 --- a/scripts/long_term_forecast/xPatch_SparseChannel_all.sh +++ b/scripts/long_term_forecast/xPatch_SparseChannel_all.sh @@ -2,6 +2,50 @@ model_name=xPatch_SparseChannel +# Traffic dataset +for pred_len in 96 192 336 720 +do +python -u run.py \ + --task_name long_term_forecast \ + --is_training 1 \ + --root_path ./dataset/traffic/ \ + --data_path traffic.csv \ + --model_id traffic_$pred_len'_'$pred_len \ + --model $model_name \ + --data custom \ + --features M \ + --seq_len 96 \ + --label_len 48 \ + --pred_len $pred_len \ + --e_layers 2 \ + --d_layers 1 \ + --enc_in 862 \ + --batch_size 256 \ + --learning_rate 0.0005 \ + --use_multi_gpu True \ + --lradj 'sigmoid' \ + --train_epochs 50 \ + --patience 5 \ + --c_out 862 \ + --d_model 128 \ + --d_ff 256 \ + --n_heads 16 \ + --patch_len 16 \ + --stride 8 \ + --k_graph 10 \ + --dropout 0.1 \ + --revin 1 \ + --des 'Exp' \ + --itr 1 \ + --season_encoder 'Transformer' \ + --thr_graph 0.6 \ + --symmetric_graph 1 \ + --degree_rescale 'none' \ + --gate_temperature 0.6667 \ + --tau_attn 1.0 \ + --season_l0_lambda 0.0000 +done + # ECL dataset for pred_len in 96 192 336 720 do @@ -39,39 +83,3 @@ python -u run.py \ --itr 1 done -# Traffic dataset -for pred_len in 96 192 336 720 -do -python -u run.py \ - --task_name long_term_forecast \ - --is_training 1 \ - --root_path ./dataset/traffic/ \ - --data_path traffic.csv \ - --model_id traffic_$pred_len'_'$pred_len \ - --model $model_name \ - --data custom \ - --features M \ - --seq_len 96 \ - --label_len 48 \ - --pred_len $pred_len \ - --e_layers 2 \ - --d_layers 1 \ - --enc_in 862 \ - --batch_size 256 \ - --learning_rate 0.0005 \ - --use_multi_gpu True \ - --lradj 'sigmoid' \ - --train_epochs 50 \ - --patience 5 \ - --c_out 862 \ - --d_model 128 \ - --d_ff 256 \ - --n_heads 16 \ - --patch_len 16 \ - --stride 8 \ - --k_graph 8 \ - --dropout 0.1 \ - --revin 1 \ - --des 'Exp' \ - --itr 1 -done