Jump to content

Connect SuperML | Leeroopedia MCP: Equip your AI agents with best practices, code verification, and debugging knowledge. Powered by Leeroo — building Organizational Superintelligence. Contact us at founders@leeroo.com.

Principle:Facebookresearch Habitat lab Hydra Config Wiring

From Leeroopedia
Knowledge Sources
Domains Configuration_Management, Software_Architecture
Last Updated 2026-02-15 02:00 GMT

Overview

Programmatic injection of custom component configurations into the Habitat config hierarchy using the read_write context manager.

Description

Hydra Config Wiring is the process of adding custom sensor, measure, and action config dataclasses to the appropriate sections of the Habitat config (task.lab_sensors, task.measurements, task.actions). Since the composed config is normally frozen (read-only), modifications require the read_write context manager. This step connects the custom config definitions to the runtime config that Habitat uses to instantiate components.

Usage

Use after defining config dataclasses and before creating the Habitat environment. This is the bridge between custom config definitions and the Habitat runtime.

Theoretical Basis

The wiring process modifies the frozen config tree:

# Abstract config injection
config = get_config("base_config.yaml")
with read_write(config):
    # Add custom sensor to config
    config.habitat.task.lab_sensors["my_sensor"] = MySensorConfig()
    # Add custom measure
    config.habitat.task.measurements["my_measure"] = MyMeasureConfig()
    # Add custom action
    config.habitat.task.actions["my_action"] = MyActionConfig()
# Config is re-frozen after context exits

Related Pages

Implemented By

Page Connections

Double-click a node to navigate. Hold to expand connections.
Principle
Implementation
Heuristic
Environment