Skip to content

Commit a0c9ea5

Browse files
committed
resolved conflict
2 parents c2fe3ff + e1c6756 commit a0c9ea5

20 files changed

Lines changed: 1633 additions & 444 deletions

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,6 @@ build/
1414
*.swp
1515

1616
# Other custom files/folders
17-
resources/
17+
demos/
1818
tmp/
1919

MUJOCO_LOG.TXT

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
Sun Mar 8 18:16:15 2026
2+
WARNING: OpenGL error 0x501 in or before mjr_makeContext
3+
4+
Sun Mar 8 18:29:23 2026
5+
WARNING: OpenGL error 0x501 in or before mjr_makeContext
6+
7+
Sun Mar 8 23:02:37 2026
8+
WARNING: OpenGL error 0x501 in or before mjr_makeContext
9+
10+
Sun Mar 8 23:04:00 2026
11+
WARNING: OpenGL error 0x501 in or before mjr_makeContext
12+
13+
Sun Mar 8 23:10:13 2026
14+
WARNING: OpenGL error 0x501 in or before mjr_makeContext
15+
16+
Sun Mar 8 23:11:07 2026
17+
WARNING: OpenGL error 0x501 in or before mjr_makeContext
18+
19+
Sun Mar 8 23:45:51 2026
20+
WARNING: OpenGL error 0x501 in or before mjr_makeContext
21+
22+
Sun Mar 8 23:46:06 2026
23+
WARNING: OpenGL error 0x501 in or before mjr_makeContext
24+
25+
Sun Mar 8 23:48:20 2026
26+
WARNING: OpenGL error 0x501 in or before mjr_makeContext
27+

README.md

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,13 @@ OopsieVerse provides a damage-aware, simulator-agnostic framework and benchmark
1515

1616
# Commands
1717

18-
1. playback
18+
1. teleop (b1k)
19+
```bash
20+
python scripts/teleop_b1k.py --task_name shelve_item --live_feedback --save_video
21+
```
22+
23+
2. playback (b1k)
1924

2025
```bash
21-
python scripts/playback.py --task_name shelve_item --playback --collect_hdf5_path tests/data/teleop_data/behavior1k/shelve_item_safe.hdf5 --playback_hdf5_path resources/playback_data/shelve_item_safe.hdf5 --demo_ids 0 1
26+
python scripts/playback_b1k.py --task_name shelve_item --collect_hdf5_path demos/behavior1k/teleop_data/shelve_item.hdf5 --playback_hdf5_path demos/behavior1k/playback_data/shelve_item.hdf5 --playback --visualize --compute_metrics
2227
```

damagesim/omnigibson/damageable_env.py

Lines changed: 29 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -317,10 +317,25 @@ def enable_health_visualization(self):
317317
return False
318318

319319
def disable_health_visualization(self):
320+
# Clear object highlights
321+
if self._health_tracked_object_names is not None:
322+
for obj_name in self._health_tracked_object_names:
323+
try:
324+
obj = self.scene.object_registry("name", obj_name)
325+
if obj is not None:
326+
obj.highlighted = False
327+
except Exception:
328+
pass
320329
if self._health_fig is not None:
321330
try:
322331
import matplotlib.pyplot as plt
323-
plt.close(self._health_fig)
332+
if plt.fignum_exists(self._health_fig.number):
333+
plt.close(self._health_fig)
334+
except Exception:
335+
pass
336+
try:
337+
import matplotlib.pyplot as plt
338+
plt.ioff()
324339
except Exception:
325340
pass
326341
self._health_visualization_enabled = False
@@ -341,13 +356,25 @@ def update_health_visualization(self, obs=None):
341356
else:
342357
health_arr = np.asarray(health_arr)
343358
link_healths = {}
344-
for idx, name in enumerate(self.health_list_part_names):
359+
for idx, name in enumerate(self.health_list_link_names):
345360
if idx < len(health_arr):
346361
link_healths[name] = health_arr[idx]
347362
current = {}
348363
for obj_name in self._health_tracked_object_names:
349364
vals = [v for k, v in link_healths.items() if k.startswith(f"{obj_name}@")]
350365
current[obj_name] = min(vals) if vals else 100.0
366+
367+
# Live object coloring: tint objects red proportionally to damage
368+
for obj_name in self._health_tracked_object_names:
369+
try:
370+
obj = self.scene.object_registry("name", obj_name)
371+
if obj is not None:
372+
intensity = 10000 * (100.0 - current[obj_name]) / 100.0
373+
obj.set_highlight_properties(color=[255.0, 0.0, 0.0], intensity=intensity)
374+
obj.highlighted = True
375+
except Exception:
376+
pass
377+
351378
try:
352379
return update_live_health_bars(
353380
self._health_fig, self._health_ax, self._health_bars_dict,

damagesim/omnigibson/params/damage_params.py

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,14 @@
1616
"shelve_item": {
1717
"categories": ["bottle_of_beer", "bottle_of_wine", "wineglass", "bag_of_flour", "box_of_crackers"],
1818
"names": [],
19+
},
20+
"pour_water": {
21+
"categories": ["laptop", "coffee_cup"],
22+
"names": ["water_glass"],
23+
},
24+
"add_firewood": {
25+
"categories": ["agent"],
26+
"names": [],
1927
}
2028
}
2129

@@ -33,6 +41,7 @@
3341

3442
# ── Robots (OG category = "agent") ──────────────────────────────────
3543
"agent": {
44+
# TODO: Add mechanical damage evaluator back, need to debug mech damage params
3645
"damage_evaluators": ["mechanical", "thermal"],
3746
# dict_keys(['panda_link0', 'panda_link1', 'panda_link2', 'panda_link3', 'panda_link4', 'panda_link5', 'panda_link6', 'panda_link7', 'panda_hand', 'panda_leftfinger', 'panda_rightfinger', 'eef_link'])
3847
"damageablefrankapanda_damageable_links": [
@@ -223,6 +232,24 @@
223232
"damage_scale": 1.0,
224233
},
225234
},
235+
"log": {
236+
"damage_evaluators": ["mechanical"],
237+
"mechanical": {
238+
"impact_damage_sensitivity": 0.5,
239+
"qs_damage_sensitivity": 0.5,
240+
"damage_threshold": 100.0,
241+
"damage_scale": 1.0,
242+
},
243+
},
244+
"wood_fireplace": {
245+
"damage_evaluators": ["mechanical"],
246+
"mechanical": {
247+
"impact_damage_sensitivity": 0.1,
248+
"qs_damage_sensitivity": 0.1,
249+
"damage_threshold": 200.0,
250+
"damage_scale": 1.0,
251+
},
252+
},
226253
"bottom_cabinet": {
227254
"damage_evaluators": ["mechanical"],
228255
"mechanical": {

0 commit comments

Comments
 (0)