[Bug]: Multiple TemperatureGrid sensors can share the first sensor's material

Author: peachtree0222Created Sep 26, 2026Updated Sep 26, 2026
Labelsbug

Bug Description

TemperatureGrid documents properties_dict as shared across all temperature sensors and says that their dictionaries are merged. With two sensors that each provide the material for their own link, the merged host dictionary contains both links, but the backend material tensor contains only the first material. The later sensor starts at the first sensor's base temperature and would also use its conductivity, emissivity, and density-times-specific-heat values.

TemperatureGridSensor.build creates link_material_properties with shape (4, material_count), then decides whether to rebuild it by comparing the number of merged materials with len(link_material_properties). After the first build, len(...) is always 4 because it measures property rows, not material columns. A second material therefore does not rebuild the projection.

In the attached CPU reproduction, link 0 is configured at 10 °C and link 1 at 90 °C. The public readings are 10 °C and 10 °C. Diagnostic output shows that the host dictionary has both keys, while the tensor shape is (4, 1) and the link mapping is [0, -1].

Steps to Reproduce

  1. Check out c27875eb56947808b3105d25d3c09b6dd96484b3 and install Genesis World and CPU PyTorch.
  2. Download the reproduction package from

temperature-material-schema-projection-poc.zip

  1. From the Genesis World checkout root, run uv run python /path/to/extracted/poc/reproducer.py.
  2. Observe that the second sensor reports 10 °C instead of its configured 90 °C.

The script uses a real gs.Scene, two real fixed rigid entities, two public scene.add_sensor calls, scene.build, and the public read_ground_truth method. No physics or sensor method is mocked.

Expected Behavior

The shared material tensor and link mapping should represent the complete merged configuration before any temperature sensor is initialized. The two readings should be 10 °C and 90 °C.

Screenshots/Videos

Not applicable; the public tensor readings and material-mapping trace are deterministic.

Relevant log output

bash
first_expected=10.0 first_actual=[10.0]
second_expected=90.0 second_actual=[10.0]
merged_material_ids=[0, 1]
backend_material_shape=(4, 1)
link_material_indices=[0, -1]

Environment

  • OS: Ubuntu 24.04.5 LTS, Linux 7.0.0-28-generic x86_64
  • GPU/CPU: Intel Core Ultra 7 265KF; CPU backend used
  • GPU-driver version: N/A for reproduction
  • CUDA / CUDA-toolkit version: N/A for reproduction
  • Python 3.12.13, PyTorch 2.11.0+cu128, Genesis World 1.4.1

Release version or Commit ID

Genesis World 1.4.1, main commit c27875eb56947808b3105d25d3c09b6dd96484b3.

Additional Context

Sources:

I have a tested patch that merges the complete class configuration before constructing the tensor projection and adds a production-scene regression. After this issue receives a number, I will open a pull request and link it here.

Source: Genesis-Embodied-AI/genesis-world