# BOFormer
for ft in AR ARa BC DR RBF_0.05 matern52_0.05 RE21 RE22 RE24 RE25; do
    echo python q_value_transformer_testing_offpolicy_ICML.py \
    --f_num 2 --T 100 --function_type $ft --device 0 --model_episode 1000 --initial_sample 1 --testing_episode 50 --n_positions 31 --ls_weight 0.8
done | xargs -d '\n' -P 1 -I {} sh -c '{}'

for ft in RE33 RE35 RE36 RE37 ARS ASR; do
    echo python q_value_transformer_testing_offpolicy_ICML.py \
    --f_num 3 --T 100 --function_type $ft --device 0 --model_episode 1000 --initial_sample 1 --testing_episode 50 --n_positions 31 --ls_weight 0.8
done | xargs -d '\n' -P 1 -I {} sh -c '{}'

# Baseline
for learner in qEHVI qNEHVI qParEGO JES qHVKG; do
    for ft in AR ARa BC DR RBF_0.05 matern52_0.05 RE21 RE22 RE24 RE25; do
        echo python test_botorch_baseline.py \
        --f_num 2 --T 100 --function_type $ft --learner $learner
    done
done | xargs -d '\n' -P 1 -I {} sh -c '{}'

for learner in qEHVI qNEHVI qParEGO JES qHVKG; do
    for ft in RE33 RE35 RE36 RE37 ARS ASR; do
        echo python test_botorch_baseline.py \
        --f_num 3 --T 100 --function_type $ft --learner $learner
    done
done | xargs -d '\n' -P 2 -I {} sh -c '{}'

# FSAF
for ft in AR ARa BC DR RBF_0.05 matern52_0.05 RE21 RE22 RE24 RE25; do
    echo python run_DQN_MAML.py --f_num 2 --T 100 --load_model_episode 500 --function_type $ft 
done | xargs -d '\n' -P 4 -I {} sh -c '{}'

for ft in RE33 RE35 RE36 RE37 ARS ASR; do
    echo python run_DQN_MAML.py --f_num 3 --T 100 --load_model_episode 300 --function_type $ft 
done | xargs -d '\n' -P 3 -I {} sh -c '{}'

# optformer
for ft in AR ARa BC DR RBF_0.05 matern52_0.05 RE21 RE22 RE24 RE25; do
    echo python optformer_testing.py --f_num 2 --T 100 --function_type $ft 
done | xargs -d '\n' -P 4 -I {} sh -c '{}'

for ft in RE33 RE35 RE36 RE37 ARS ASR; do
    echo python optformer_testing.py --f_num 3 --T 100 --function_type $ft 
done | xargs -d '\n' -P 3 -I {} sh -c '{}'

# QT
for ft in AR ARa BC DR RBF_0.05 matern52_0.05 RE21 RE22 RE24 RE25; do
    echo python q_transformer_testing.py --f_num 2 --T 100 --function_type $ft --episode 50
done | xargs -d '\n' -P 1 -I {} sh -c '{}'

for ft in RE33 RE35 RE36 RE37 ARS ASR; do
    echo python q_transformer_testing.py --f_num 3 --T 100 --function_type $ft --episode 50
done | xargs -d '\n' -P 2 -I {} sh -c '{}'

# training 
python optformer.py --f_num 2 
python optformer.py --f_num 3 
python q_transformer.py --f_num 2 
python q_transformer.py --f_num 3
python q_value_transformer_offpolicy.py --f_num 2 --update_step 10 
python q_value_transformer_offpolicy.py --f_num 3 --update_step 10 

# Ablation study
python q_value_transformer_offpolicy.py --f_num 2 --update_step 10 --n_positions 31 --demo_rate 0.0 --device 0
python q_value_transformer_offpolicy.py --f_num 2 --update_step 10 --n_positions 31 --batch_size 1 --buffer_size 1 --device 0
python q_value_transformer_offpolicy.py --f_num 2 --update_step 10 --n_positions 1 
python q_value_transformer_offpolicy.py --f_num 2 --update_step 10 --n_positions 11 
python q_value_transformer_offpolicy.py --f_num 2 --update_step 10 --n_positions 21 
python q_value_transformer_offpolicy.py --f_num 2 --update_step 10 --n_positions 91 
python q_value_transformer_offpolicy.py --f_num 2 --update_step 10 --n_positions 151 
python q_value_transformer_offpolicy.py --f_num 2 --update_step 10 --n_positions 301 
