-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathConfigs.py
More file actions
80 lines (72 loc) · 1.77 KB
/
Configs.py
File metadata and controls
80 lines (72 loc) · 1.77 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
import argparse
from argparse import Namespace
class ARGS:
task_name='classification'
patch_size=16
stride=8
gpt_layers=3
d_ff=256
dropout=0.1
seed=321
droprate_data=0.2
model_dir_name='gpt4tsV2'
model_name='gpt_allzi'
seq_len=512
horizon_len=48
p2n_rate_train=-1
p2n_rate_test=1
data_stride_len_train=100
data_stride_len_test=100
batch_size=128
llm_model='GPT2'
tslm_model='GPT2'
n_runs=5
timestamp_type='fixed'
if_test_save=False
out_proj='First'
if_addtoken_grad=False
if_only_metavec=False
ifAdapter=False
# important
ifP_tuning=False
ifLoRA=False
adam_epsilon=1e-08
learning_rate=1e-05
# lr_scheduler
ifschedule_with_warmup=True
schedule_type='LambdaLR'
# vec->str
ifReprogram=False
Reprogram_type='ATT'
# if_decompose
if_decompose=True
decompose_type='Simple'
# ifAdapter
ifAdapter=False
if_dont_use_id=False
ifNoNorm=False
if_use_his01=False
if_use_meta=False
patience=15
MAX_epoches=200
npy_dir_path='<DATASET_ROOT>/seqlen_512_horizon_48_stride_50_noPeriod'
dir_path='<PROJECT_ROOT>'
kids_path='<DATASET_ROOT>/kids.npy'
meta_feats_path='<DATASET_ROOT>/kepler_meta_feats3.npy'
num_classes=2
dim_in=2
dim_meta_1=35
dim_meta_0=3000
dim_hid=128
d_model=768
@classmethod
def _get_class_variables(cls):
return {k: v for k, v in vars(cls).items() if not callable(v) and not k.startswith("_")}
@classmethod
def _update_class_variables(cls, updates):
if updates is None:
return
if isinstance(updates,Namespace):
updates=updates.__dict__
for k, v in updates.items():
setattr(cls, k, v)