-
Notifications
You must be signed in to change notification settings - Fork 1
/
object_indices.py
202 lines (199 loc) · 7.08 KB
/
object_indices.py
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
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
OBJECTS_NAME_TO_IDX = {
"large_blue_cone_metal": 0,
"large_blue_cube_metal": 1,
"large_blue_cylinder_metal": 2,
"large_blue_sphere_metal": 3,
"large_brown_cone_metal": 4,
"large_brown_cube_metal": 5,
"large_brown_cylinder_metal": 6,
"large_brown_sphere_metal": 7,
"large_cyan_cone_metal": 8,
"large_cyan_cube_metal": 9,
"large_cyan_cylinder_metal": 10,
"large_cyan_sphere_metal": 11,
"large_gray_cone_metal": 12,
"large_gray_cube_metal": 13,
"large_gray_cylinder_metal": 14,
"large_gray_sphere_metal": 15,
"large_green_cone_metal": 16,
"large_green_cube_metal": 17,
"large_green_cylinder_metal": 18,
"large_green_sphere_metal": 19,
"large_purple_cone_metal": 20,
"large_purple_cube_metal": 21,
"large_purple_cylinder_metal": 22,
"large_purple_sphere_metal": 23,
"large_red_cone_metal": 24,
"large_red_cube_metal": 25,
"large_red_cylinder_metal": 26,
"large_red_sphere_metal": 27,
"large_yellow_cone_metal": 28,
"large_yellow_cube_metal": 29,
"large_yellow_cylinder_metal": 30,
"large_yellow_sphere_metal": 31,
"large_blue_cone_rubber": 32,
"large_blue_cube_rubber": 33,
"large_blue_cylinder_rubber": 34,
"large_blue_sphere_rubber": 35,
"large_brown_cone_rubber": 36,
"large_brown_cube_rubber": 37,
"large_brown_cylinder_rubber": 38,
"large_brown_sphere_rubber": 39,
"large_cyan_cone_rubber": 40,
"large_cyan_cube_rubber": 41,
"large_cyan_cylinder_rubber": 42,
"large_cyan_sphere_rubber": 43,
"large_gray_cone_rubber": 44,
"large_gray_cube_rubber": 45,
"large_gray_cylinder_rubber": 46,
"large_gray_sphere_rubber": 47,
"large_green_cone_rubber": 48,
"large_green_cube_rubber": 49,
"large_green_cylinder_rubber": 50,
"large_green_sphere_rubber": 51,
"large_purple_cone_rubber": 52,
"large_purple_cube_rubber": 53,
"large_purple_cylinder_rubber": 54,
"large_purple_sphere_rubber": 55,
"large_red_cone_rubber": 56,
"large_red_cube_rubber": 57,
"large_red_cylinder_rubber": 58,
"large_red_sphere_rubber": 59,
"large_yellow_cone_rubber": 60,
"large_yellow_cube_rubber": 61,
"large_yellow_cylinder_rubber": 62,
"large_yellow_sphere_rubber": 63,
"medium_blue_cone_metal": 64,
"medium_blue_cube_metal": 65,
"medium_blue_cylinder_metal": 66,
"medium_blue_sphere_metal": 67,
"medium_brown_cone_metal": 68,
"medium_brown_cube_metal": 69,
"medium_brown_cylinder_metal": 70,
"medium_brown_sphere_metal": 71,
"medium_cyan_cone_metal": 72,
"medium_cyan_cube_metal": 73,
"medium_cyan_cylinder_metal": 74,
"medium_cyan_sphere_metal": 75,
"medium_gray_cone_metal": 76,
"medium_gray_cube_metal": 77,
"medium_gray_cylinder_metal": 78,
"medium_gray_sphere_metal": 79,
"medium_green_cone_metal": 80,
"medium_green_cube_metal": 81,
"medium_green_cylinder_metal": 82,
"medium_green_sphere_metal": 83,
"medium_purple_cone_metal": 84,
"medium_purple_cube_metal": 85,
"medium_purple_cylinder_metal": 86,
"medium_purple_sphere_metal": 87,
"medium_red_cone_metal": 88,
"medium_red_cube_metal": 89,
"medium_red_cylinder_metal": 90,
"medium_red_sphere_metal": 91,
"medium_yellow_cone_metal": 92,
"medium_yellow_cube_metal": 93,
"medium_yellow_cylinder_metal": 94,
"medium_yellow_sphere_metal": 95,
"medium_blue_cone_rubber": 96,
"medium_blue_cube_rubber": 97,
"medium_blue_cylinder_rubber": 98,
"medium_blue_sphere_rubber": 99,
"medium_brown_cone_rubber": 100,
"medium_brown_cube_rubber": 101,
"medium_brown_cylinder_rubber": 102,
"medium_brown_sphere_rubber": 103,
"medium_cyan_cone_rubber": 104,
"medium_cyan_cube_rubber": 105,
"medium_cyan_cylinder_rubber": 106,
"medium_cyan_sphere_rubber": 107,
"medium_gray_cone_rubber": 108,
"medium_gray_cube_rubber": 109,
"medium_gray_cylinder_rubber": 110,
"medium_gray_sphere_rubber": 111,
"medium_green_cone_rubber": 112,
"medium_green_cube_rubber": 113,
"medium_green_cylinder_rubber": 114,
"medium_green_sphere_rubber": 115,
"medium_purple_cone_rubber": 116,
"medium_purple_cube_rubber": 117,
"medium_purple_cylinder_rubber": 118,
"medium_purple_sphere_rubber": 119,
"medium_red_cone_rubber": 120,
"medium_red_cube_rubber": 121,
"medium_red_cylinder_rubber": 122,
"medium_red_sphere_rubber": 123,
"medium_yellow_cone_rubber": 124,
"medium_yellow_cube_rubber": 125,
"medium_yellow_cylinder_rubber": 126,
"medium_yellow_sphere_rubber": 127,
"small_blue_cone_metal": 128,
"small_blue_cube_metal": 129,
"small_blue_cylinder_metal": 130,
"small_blue_sphere_metal": 131,
"small_brown_cone_metal": 132,
"small_brown_cube_metal": 133,
"small_brown_cylinder_metal": 134,
"small_brown_sphere_metal": 135,
"small_cyan_cone_metal": 136,
"small_cyan_cube_metal": 137,
"small_cyan_cylinder_metal": 138,
"small_cyan_sphere_metal": 139,
"small_gold_spl_metal": 140,
"small_gray_cone_metal": 141,
"small_gray_cube_metal": 142,
"small_gray_cylinder_metal": 143,
"small_gray_sphere_metal": 144,
"small_green_cone_metal": 145,
"small_green_cube_metal": 146,
"small_green_cylinder_metal": 147,
"small_green_sphere_metal": 148,
"small_purple_cone_metal": 149,
"small_purple_cube_metal": 150,
"small_purple_cylinder_metal": 151,
"small_purple_sphere_metal": 152,
"small_red_cone_metal": 153,
"small_red_cube_metal": 154,
"small_red_cylinder_metal": 155,
"small_red_sphere_metal": 156,
"small_yellow_cone_metal": 157,
"small_yellow_cube_metal": 158,
"small_yellow_cylinder_metal": 159,
"small_yellow_sphere_metal": 160,
"small_blue_cone_rubber": 161,
"small_blue_cube_rubber": 162,
"small_blue_cylinder_rubber": 163,
"small_blue_sphere_rubber": 164,
"small_brown_cone_rubber": 165,
"small_brown_cube_rubber": 166,
"small_brown_cylinder_rubber": 167,
"small_brown_sphere_rubber": 168,
"small_cyan_cone_rubber": 169,
"small_cyan_cube_rubber": 170,
"small_cyan_cylinder_rubber": 171,
"small_cyan_sphere_rubber": 172,
"small_gray_cone_rubber": 173,
"small_gray_cube_rubber": 174,
"small_gray_cylinder_rubber": 175,
"small_gray_sphere_rubber": 176,
"small_green_cone_rubber": 177,
"small_green_cube_rubber": 178,
"small_green_cylinder_rubber": 179,
"small_green_sphere_rubber": 180,
"small_purple_cone_rubber": 181,
"small_purple_cube_rubber": 182,
"small_purple_cylinder_rubber": 183,
"small_purple_sphere_rubber": 184,
"small_red_cone_rubber": 185,
"small_red_cube_rubber": 186,
"small_red_cylinder_rubber": 187,
"small_red_sphere_rubber": 188,
"small_yellow_cone_rubber": 189,
"small_yellow_cube_rubber": 190,
"small_yellow_cylinder_rubber": 191,
"small_yellow_sphere_rubber": 192
}
OBJECTS_IDX_TO_NAME = {idx: name for name, idx in OBJECTS_NAME_TO_IDX.items()}
def is_cone_object(idx: int) -> int:
object_name = OBJECTS_IDX_TO_NAME[idx]
return int("_cone_" in object_name)