AGarioud commited on
Commit
39cc5e0
·
verified ·
1 Parent(s): 69a954b

Add configs_train folder

Browse files
configs_train/config_modalities.yaml ADDED
@@ -0,0 +1,65 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ modalities:
2
+
3
+ inputs:
4
+ AERIAL_RGBI : False
5
+ AERIAL-RLT_PAN : False
6
+ DEM_ELEV : False
7
+ SPOT_RGBI : False
8
+ SENTINEL2_TS : True
9
+ SENTINEL1-ASC_TS : False
10
+ SENTINEL1-DESC_TS : False
11
+
12
+ inputs_channels:
13
+ AERIAL_RGBI :
14
+ SPOT_RGBI :
15
+ SENTINEL2_TS : [1,2,3,4,5,6,7,8,9,10]
16
+ SENTINEL1-ASC_TS :
17
+ SENTINEL1-DESC_TS :
18
+
19
+ aux_loss:
20
+ AERIAL_RGBI : False
21
+ AERIAL-RLT_PAN : False
22
+ DEM_ELEV : False
23
+ SPOT_RGBI : False
24
+ SENTINEL2_TS : False
25
+ SENTINEL1-ASC_TS : False
26
+ SENTINEL1-DESC_TS : False
27
+
28
+ aux_loss_weight: 1 # multiplier before adding to main loss
29
+
30
+ modality_dropout: # between 0 (no dropout) and 1 (complete systematic dropout)
31
+ AERIAL_RGBI : 0
32
+ AERIAL-RLT_PAN : 0
33
+ DEM_ELEV : 0
34
+ SPOT_RGBI : 0
35
+ SENTINEL2_TS : 0
36
+ SENTINEL1-ASC_TS : 0
37
+ SENTINEL1-DESC_TS : 0
38
+
39
+ pre_processings:
40
+ filter_sentinel2: True
41
+ filter_sentinel2_max_cloud : 1 # [0-100]
42
+ filter_sentinel2_max_snow : 1 # [0-100]
43
+ filter_sentinel2_max_frac_cover : 0.05 # [0-1]
44
+ temporal_average_sentinel2 : False # possible : False, monthly, semi-monthly
45
+ temporal_average_sentinel1 : False
46
+
47
+ calc_elevation : True
48
+ calc_elevation_stack_dsm : True
49
+
50
+ use_augmentation: False
51
+
52
+ normalization:
53
+ norm_type : custom # possible : custom, scaling, without
54
+
55
+ AERIAL_RGBI_means : [106.59, 105.66, 111.35]
56
+ AERIAL_RGBI_stds : [39.78, 52.23, 45.62]
57
+
58
+ AERIAL-RLT_PAN_means : [125.92]
59
+ AERIAL-RLT_PAN_stds : [38.45]
60
+
61
+ SPOT_RGBI_means : [1137.03, 433.26, 508.75]
62
+ SPOT_RGBI_stds : [543.11, 312.76, 284.61]
63
+
64
+ DEM_ELEV_means : [311.06, 311.06] # use same for both DSM/DTM to allow keeping differences of elevation
65
+ DEM_ELEV_stds : [537.55, 537.55] # use same for both DSM/DTM to allow keeping differences of elevation
configs_train/config_models.yaml ADDED
@@ -0,0 +1,23 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ models:
2
+
3
+ monotemp_model: # encoder-decoder from SMP
4
+
5
+ arch:
6
+ new_channels_init_mode:
7
+
8
+ multitemp_model:
9
+
10
+ ref_date: '05-15' # defined for whole dataset
11
+ encoder_widths: [64, 64, 64, 128] # last must be equivalent to decoder_widths
12
+ decoder_widths: [32, 32, 64, 128] # last must be equivalent to encoder_widths
13
+ out_conv: [32, 19]
14
+ str_conv_k: 3
15
+ str_conv_s: 1
16
+ str_conv_p: 1
17
+ agg_mode: "att_group"
18
+ encoder_norm: "group"
19
+ n_head: 16
20
+ d_model: 256
21
+ d_k: 4
22
+ pad_value: 0
23
+ padding_mode: "reflect"
configs_train/config_supervision.yaml ADDED
@@ -0,0 +1,37 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ labels:
2
+ - ALL_LABEL-LPIS
3
+
4
+ labels_configs:
5
+ ALL_LABEL-LPIS:
6
+ task_weight: 1
7
+ label_channel_nomenclature: 1
8
+ value_name:
9
+ 0 : 'grasses'
10
+ 1 : 'wheat'
11
+ 2 : 'barley'
12
+ 3 : 'maize'
13
+ 4 : 'other cereals'
14
+ 5 : 'rice'
15
+ 6 : 'flax/hemp/tobacco'
16
+ 7 : 'sunflower'
17
+ 8 : 'rapeseed'
18
+ 9 : 'other oilseed crops'
19
+ 10 : 'soy'
20
+ 11 : 'other protein crops'
21
+ 12 : 'fodder legumes'
22
+ 13 : 'beetroots'
23
+ 14 : 'potatoes'
24
+ 15 : 'other arable crops'
25
+ 16 : 'vineyard'
26
+ 17 : 'olive groves'
27
+ 18 : 'fruits orchards'
28
+ 19 : 'nut orchards'
29
+ 20 : 'other permanent crops'
30
+ 21 : 'mixed crops'
31
+ 22 : 'background'
32
+
33
+ value_weights:
34
+ default: 1
35
+ default_exceptions:
36
+ per_modality_exceptions:
37
+
configs_train/config_task.yaml ADDED
@@ -0,0 +1,61 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # SLURM
2
+
3
+ paths :
4
+
5
+ out_folder: '../'
6
+ out_model_name: 'FLAIR-HUB_LPIS-F_utae'
7
+
8
+ train_csv: '../TRAIN_FLAIR-INC.csv'
9
+ val_csv: '../VALID_FLAIR-INC.csv'
10
+ test_csv: '../TEST_FLAIR-INC.csv'
11
+ global_mtd_folder: '../GLOBAL_ALL_MTD/'
12
+ ckpt_model_path: ''
13
+
14
+
15
+ tasks:
16
+
17
+ train: True
18
+ train_tasks:
19
+ init_weights_only_from_ckpt: False
20
+ resume_training_from_ckpt: False
21
+
22
+ predict: True
23
+ write_files: False
24
+ georeferencing_output: False
25
+
26
+ metrics_only: False
27
+
28
+ hyperparams:
29
+
30
+ num_epochs: 150
31
+ batch_size: 5
32
+ seed: 2025
33
+ learning_rate: 0.00005
34
+
35
+ optimizer: adamw #sgd, adam, adamw
36
+ optim_weight_decay: 0.01
37
+ optim_betas: [0.9, 0.999]
38
+
39
+ scheduler: one_cycle_lr # [one_cycle_lr, reduce_on_plateau, cycle_then_plateau]
40
+ warmup_fraction: 0.2 #if using one_cycle_lr. [0-1]
41
+ plateau_patience: 5
42
+
43
+ hardware:
44
+ accelerator: 'gpu'
45
+ num_nodes: 6
46
+ gpus_per_node: 4
47
+ strategy: 'ddp_find_unused_parameters_true'
48
+ num_workers: 10
49
+
50
+ saving:
51
+ ckpt_save_also_last: True
52
+ ckpt_weights_only: False
53
+ ckpt_monitor: 'val_miou'
54
+ ckpt_monitor_mode: 'max'
55
+ ckpt_earlystopping_patience: 20
56
+ cp_csv_and_conf_to_output: True
57
+ enable_progress_bar: True
58
+ progress_rate: 10
59
+
60
+ ckpt_verbose: True
61
+ verbose_config: False