MCPcopy Create free account
hub / github.com/OpenDriveLab/TCP / GlobalConfig

Class GlobalConfig

TCP/config.py:3–64  ·  view source on GitHub ↗

base architecture configurations

Source from the content-addressed store, hash-verified

1import os
2
3class GlobalConfig:
4 """ base architecture configurations """
5 # Data
6 seq_len = 1 # input timesteps
7 pred_len = 4 # future waypoints predicted
8
9 # data root
10 root_dir_all = "tcp_carla_data"
11
12 train_towns = ['town01', 'town03', 'town04', 'town06', ]
13 val_towns = ['town02', 'town05', 'town07', 'town10']
14 train_data, val_data = [], []
15 for town in train_towns:
16 train_data.append(os.path.join(root_dir_all, town))
17 train_data.append(os.path.join(root_dir_all, town+'_addition'))
18 for town in val_towns:
19 val_data.append(os.path.join(root_dir_all, town+'_val'))
20
21 ignore_sides = True # don't consider side cameras
22 ignore_rear = True # don't consider rear cameras
23
24 input_resolution = 256
25
26 scale = 1 # image pre-processing
27 crop = 256 # image pre-processing
28
29 lr = 1e-4 # learning rate
30
31 # Controller
32 turn_KP = 0.75
33 turn_KI = 0.75
34 turn_KD = 0.3
35 turn_n = 40 # buffer size
36
37 speed_KP = 5.0
38 speed_KI = 0.5
39 speed_KD = 1.0
40 speed_n = 40 # buffer size
41
42 max_throttle = 0.75 # upper limit on throttle signal value in dataset
43 brake_speed = 0.4 # desired speed below which brake is triggered
44 brake_ratio = 1.1 # ratio of speed to desired speed at which brake is triggered
45 clip_delta = 0.25 # maximum change in speed input to logitudinal controller
46
47
48 aim_dist = 4.0 # distance to search around for aim point
49 angle_thresh = 0.3 # outlier control detection angle
50 dist_thresh = 10 # target point y-distance for outlier filtering
51
52
53 speed_weight = 0.05
54 value_weight = 0.001
55 features_weight = 0.05
56
57 rl_ckpt = "roach/log/ckpt_11833344.pth"
58
59 img_aug = True
60

Callers 2

setupMethod · 0.90
train.pyFile · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected