Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[0.2.3][Hydra Migration] Made agents to be of type Dict[str, AgentConfig] and added migration readme #1007

Merged
merged 14 commits into from
Nov 29, 2022

Conversation

rpartsey
Copy link
Collaborator

@rpartsey rpartsey commented Nov 19, 2022

Motivation and Context

  • Made habitat.simulator.agents to be of type Dict[str, AgentConfig] to allow the possibility to dynamically configure the number of agents (in the future will simplify the multi-agent support).
  • Added migration README

How Has This Been Tested

Types of changes

  • Docs change / refactoring / dependency upgrade
  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document.
  • I have completed my CLA (see CONTRIBUTING)
  • I have added tests to cover my changes.
  • All new and existing tests passed.

@facebook-github-bot facebook-github-bot added the CLA Signed Do not delete this pull request or issue due to inactivity. label Nov 19, 2022
Comment on lines 960 to 963
# agent_0: AgentConfig = AgentConfig()
# agent_1: AgentConfig = (
# MISSING # temporary multi-agent rearrangement config fix
# )
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
# agent_0: AgentConfig = AgentConfig()
# agent_1: AgentConfig = (
# MISSING # temporary multi-agent rearrangement config fix
# )

@@ -306,7 +308,7 @@ def create_sim_config(
sim_config.scene_id = self.habitat_config.scene
agent_config = habitat_sim.AgentConfiguration()
overwrite_config(
config_from=self._get_agent_config(),
config_from=self._get_default_agent_config(),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not really default. Should it be _get_any_agent_config?

@@ -75,8 +75,7 @@ def merge_sim_episode_config(
episode.start_position is not None
and episode.start_rotation is not None
):
agent_name = sim_config.agents[sim_config.default_agent_id]
agent_cfg = getattr(sim_config, agent_name)
agent_cfg = next(iter(sim_config.agents.values()))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think there should be an assert that len(sim_config.agents.values()) == 1

@@ -65,12 +65,15 @@ def _make_habitat_gym_env(
config = habitat.get_config(cfg_file_path)
if use_render_mode:
with habitat.config.read_write(config):
default_agent = next(
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

assert len(config.habitat.simulator.agents.values()) == 1

@@ -1177,85 +1179,85 @@ class HabitatConfig(HabitatBaseConfig):

# Simulator Sensors
cs.store(
package="habitat.simulator.agent_0.sim_sensors.rgb_sensor",
package="habitat.simulator.agents.agent_0.sim_sensors.rgb_sensor",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Kind of awkward to have agent_0 in here now...

)

OmegaConf.set_readonly(cfg, True)
cfg = _habitat_get_config(config_paths, overrides, configs_dir)
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Habitat-Lab's configs are included in the Baselines config by specifying corresponding Habitat-Lab input config in the defaults list. In other words the Baselines config in an extension of the Habitat-Lab config. Therefore, Lab and Baselines configs have to be read/created by the same function. To make sure that all the possible custom validations/configs updates via code in Lab's config are also applied in the Baselines' get_config.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for deduplicating the code.

* added habitat-lab config readme
@vincentpierre vincentpierre changed the title [Hydra Migration] Made habitat.simulator.agents to be of type Dict[str, AgentConfig] [0.2.3][Hydra Migration] Made habitat.simulator.agents to be of type Dict[str, AgentConfig] Nov 28, 2022
@rpartsey rpartsey changed the title [0.2.3][Hydra Migration] Made habitat.simulator.agents to be of type Dict[str, AgentConfig] [0.2.3][Hydra Migration] Made agents to be of type Dict[str, AgentConfig] and added migration readme Nov 28, 2022
@vincentpierre vincentpierre mentioned this pull request Nov 28, 2022
7 tasks
@@ -0,0 +1,482 @@
Habitat-Lab Configuration System
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Rename to README.md


@dataclass
class CustomStructuredConfig:
custom_config_key: KeyType = DefayltValue
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
custom_config_key: KeyType = DefayltValue
custom_config_key: KeyType = DefaultValue

## Hydra Concepts used in Habitat-Lab

With Hydra, the [Output Config](https://hydra.cc/docs/advanced/terminology/#output-config)
is composed dynamically at the run time from
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
is composed dynamically at the run time from
is composed dynamically at run time from

config validation schemas to ensure that all the required fields are set and match the required type, and also as a
configs, in place of configuration yaml files. All Structured Configs are registered in
the [ConfigStore](https://hydra.cc/docs/tutorials/structured_config/config_store/) - in-memory
Structured Configs registry. Habitat-Lab's Structured Configs are defined and registered to the ConfigStore in the
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Structured Configs registry. Habitat-Lab's Structured Configs are defined and registered to the ConfigStore in the
Structured Configs registry. Habitat-Lab's Structured Configs are defined and registered to the ConfigStore in

Structured Configs registry. Habitat-Lab's Structured Configs are defined and registered to the ConfigStore in the
[habitat-lab/habitat/config/default_structured_configs.py](default_structured_configs.py).

Similar configs are grouped in the [Config Groups](https://hydra.cc/docs/advanced/terminology/#config-group)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Similar configs are grouped in the [Config Groups](https://hydra.cc/docs/advanced/terminology/#config-group)
Similar configs are grouped in [Config Groups](https://hydra.cc/docs/advanced/terminology/#config-group)

For example, Embodied AI task specifications supported by Habitat-Lab are placed in the `habitat/task` Config Group
and to use the PointNav task just add `habitat/task: pointnav` line to your config's Defaults List.

Where the content of each Input Config (Config Group Option) is placed in the Output Config is determined via
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Where the content of each Input Config (Config Group Option) is placed in the Output Config is determined via
Each Input Config's position in the Output Config is determined via


## What's changed?
<details>
<summary>Expand to see the Habitat-Lab input PointNav benchmark config example.</summary>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
<summary>Expand to see the Habitat-Lab input PointNav benchmark config example.</summary>
PointNav benchmark: Input config.</summary>

</details>

<details>
<summary>Expand to see the corresponding composed output config.</summary>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
<summary>Expand to see the corresponding composed output config.</summary>
<summary>
PointNav benchmark: Output config.</summary>

- `agent.sensors` is renamed to `agent.sim_sensors`, `task.sensors` is renamed to `task.lab_sensors`.
- Actions, agents, measurements and sensors configs are not directly attached to the simulator, task or agent
config nodes but are added to `task.actions`, `simulator.agents`, `task.measurements`, `task.lab_sensors`,
`simulator.agent_name.sim_sensors` sub-nodes of type `Dict[str, CorrespondingConfigNodeType]`
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It needs to be clear that agent name is not hard coded string.

Suggested change
`simulator.agent_name.sim_sensors` sub-nodes of type `Dict[str, CorrespondingConfigNodeType]`
`simulator.<agent_name>.sim_sensors` sub-nodes of type `Dict[str, CorrespondingConfigNodeType]`

Comment on lines 37 to 45
# head_rgb_sensor:
# width: 256
# height: 256
# arm_depth_sensor:
# height: 128
# width: 128
# arm_rgb_sensor:
# height: 128
# width: 128
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
# head_rgb_sensor:
# width: 256
# height: 256
# arm_depth_sensor:
# height: 128
# width: 128
# arm_rgb_sensor:
# height: 128
# width: 128


# Check if the `habitat.simulator.agents_order`
# is set and matches the agents' keys in `habitat.simulator.agents`.
assert set(sim_config.agents_order) == set(sim_config.agents.keys()), (
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Assert on the length of the two as well. agents_order could have duplicates

def get_full_config_path(
config_path: str, default_configs_dir: str = _HABITAT_CFG_DIR
) -> str:
def get_full_config_path(config_path: str, configs_dir: str) -> str:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Need string doc here to describe the function arguments and output.

if osp.exists(proposed_full_path):
return osp.abspath(proposed_full_path)

raise RuntimeError(f"No file found for config '{config_path}'")


get_full_habitat_config_path = partial(
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here. This functions will be frequently used and should have better documentation.

habitat-lab/habitat/config/default.py Show resolved Hide resolved
@@ -57,6 +73,19 @@ def get_config(
overrides=overrides if overrides is not None else [],
)

# In the single-agent setup use the agent's key from `habitat.simulator.agents`.
sim_config = cfg.habitat.simulator
if len(sim_config.agents) == 1:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's remove this non documented functionality. We plan to create "main_agent" for this purpose to be the default, those it won't be needed..

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We agreed to create just an alias. Actually, I'd leave it as it is forcing users to explicitly define / chose the agent. @vincentpierre your thoughts?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we should leave it as is. I do not want to have main_agent be defined in code (and that includes the default_structured_config file) but only be defined in the yamls that we provide. Nothing should prevent the user to name their unique agent anything they want and not need to modify agent_order

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't like the term "main" agent as "main" is an very overloaded term. Is there a better term we can use? Even agent_0 is more specific and easier to understand in my opinion.

# Check if the `habitat.simulator.agents_order`
# is set and matches the agents' keys in `habitat.simulator.agents`.
assert set(sim_config.agents_order) == set(sim_config.agents.keys()), (
"habitat.simulator.agents_order should be set explicitly "
Copy link
Contributor

@mathfac mathfac Nov 29, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's be more explicit:

Suggested change
"habitat.simulator.agents_order should be set explicitly "
"habitat.simulator.agents_order({sim_config.agents_order}) should be set explicitly "

# is set and matches the agents' keys in `habitat.simulator.agents`.
assert set(sim_config.agents_order) == set(sim_config.agents.keys()), (
"habitat.simulator.agents_order should be set explicitly "
"and match the agents' keys in habitat.simulator.agents"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
"and match the agents' keys in habitat.simulator.agents"
"and match the agents' keys in habitat.simulator.agents({set(sim_config.agents.keys())})"

Comment on lines 959 to 960
# if the number of agents is greater than one,
# then agents_order has to be set explicitly too
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe something like this:

Suggested change
# if the number of agents is greater than one,
# then agents_order has to be set explicitly too
# Agents order that will be used by simulator step and trainer policy.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

agent_order is only used to know in which order to return the observations and accept the actions when using the environment API correct?
In any case, we should explain here what the agent_order does for the user

Copy link
Contributor

@Skylion007 Skylion007 Nov 29, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Defining agent order like this seems a bit of an overkill. Why can't the order of the agents defined in the YAML just be the order of the agents? That seems a lot more intuitive to me instead of having this foreign key. Why cant the agents key be a list of of agents instead? Then the order is defined implicitly by the order the agents are added to the list. That's how it was going to be before in yacs with mutliagent support. Don't know why we changed the agent configs from an ordered list to a dict.

)


def get_agent_config(sim_config, agent_id: Optional[int] = None):
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added doc string and type for sim_config:

Suggested change
def get_agent_config(sim_config, agent_id: Optional[int] = None):
def get_agent_config(sim_config: DictConfig, agent_id: Optional[int] = None) -> DictConfig:
r"""Called to get agent's config node of default agent or based on index of the agent.
:param sim_config: config of :ref:`core.simulator.Simulator`.
:param agent_id: index of the agent (relevant for multi-agent setup).
:return: relevant agent's config.
"""

@@ -16,36 +17,51 @@
HabitatConfigPlugin,
register_hydra_plugin,
)
from habitat.config.read_write import read_write

_HABITAT_CFG_DIR = osp.dirname(inspect.getabsfile(inspect.currentframe()))
# This is equivalent to doing osp.dirname(osp.abspath(__file__))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
# This is equivalent to doing osp.dirname(osp.abspath(__file__))
# Habitat config directory inside the installed package.
# Used to access default predefined configs.
# This is equivalent to doing osp.dirname(osp.abspath(__file__))

width: 256
height: 256
agents:
rgbd_agent:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As we discussed let's have main_agent node for all single agent usecases.

position: [0, 1.09, 0]
type: HabitatSimRGBSensor
agents:
rgbds_agent:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
rgbds_agent:
main_agent:

@@ -128,7 +129,8 @@ the config object.
config = habitat.get_config(config_paths="benchmark/nav/pointnav/pointnav_mp3d.yaml")
with read_write(config):
config.habitat.dataset.split = "val"
config.habitat.simulator.agent_0.sim_sensors.update(
agent_config = get_agent_config(config.habitat.simulator)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In examples let's be more explicit:

Suggested change
agent_config = get_agent_config(config.habitat.simulator)
agent_config = get_agent_config(sim_config=config.habitat.simulator)

@@ -31,14 +32,15 @@ validate that transformation comparing projected and original views.
config = habitat.get_config(config_paths="benchmark/nav/pointnav/pointnav_habitat_test.yaml")
with read_write(config):
config.habitat.dataset.split = "val"
config.habitat.simulator.agent_0.sim_sensors.depth_sensor.normalize_depth = False
agent_config = get_agent_config(config.habitat.simulator)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In examples let's be more explicit:

Suggested change
agent_config = get_agent_config(config.habitat.simulator)
agent_config = get_agent_config(sim_config=config.habitat.simulator)

@@ -593,7 +594,8 @@ def has_pygame():

if not args.same_task:
sim_config.debug_render = True
sim_config.agent_0.sim_sensors.update(
agent_config = get_agent_config(sim_config)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
agent_config = get_agent_config(sim_config)
agent_config = get_agent_config(sim_config=sim_config)

@@ -92,7 +93,8 @@ def insert_render_options(config):
# Added settings to make rendering higher resolution for better visualization
with habitat.config.read_write(config):
config.habitat.simulator.concur_render = False
config.habitat.simulator.agent_0.sim_sensors.update(
agent_config = get_agent_config(config.habitat.simulator)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
agent_config = get_agent_config(config.habitat.simulator)
agent_config = get_agent_config(sim_config=config.habitat.simulator)

robot_urdf: ./data/robots/hab_fetch/robots/hab_fetch.urdf
robot_type: "FetchRobot"
agents:
agent_0:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
agent_0:
main_agent:

)

OmegaConf.set_readonly(cfg, True)
cfg = _habitat_get_config(config_paths, overrides, configs_dir)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for deduplicating the code.

# Other SimulatorConfig keys are omitted in this code snippet
seed: int = II("habitat.seed")
```
- [Multirun](https://hydra.cc/docs/tutorials/basic/running_your_app/multi-run/). For example, launching 3 experiments with three different learning rates:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- [Multirun](https://hydra.cc/docs/tutorials/basic/running_your_app/multi-run/). For example, launching 3 experiments with three different learning rates:
- [Parameter sweeping and multirun](https://hydra.cc/docs/tutorials/basic/running_your_app/multi-run/). For example, launching 3 experiments with three different learning rates:

python -u habitat_baselines/run.py --exp-config config.yaml --run-type train –-multirun \
habitat_baselines.rl.ppo.lr 2.5e-4,2.5e-5,2.5e-6
```

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- Seamless [SLURM](https://slurm.schedmd.com/documentation.html) integration through [Submitit Launcher](https://hydra.cc/docs/plugins/submitit_launcher/). To enable the feature Submitit plugin should be installed: `pip install hydra-submitit-launcher --upgrade` and specify launcher `hydra/launcher=submitit_slurm` in the command line:
```bash
python -u habitat_baselines/run.py --exp-config config.yaml --run-type train –-multirun \
habitat_baselines.rl.ppo.lr 2.5e-4,2.5e-5,2.5e-6 hydra/launcher=submitit_slurm

- /habitat/simulator/agents@habitat.simulator.agents.agent_0: depth_head_agent
- /habitat/simulator/agents@habitat.simulator.agents.agent_1: depth_head_agent
```
- Making the config key required by setting its value to `MISSING`. For example, we require the user to explicitly
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's move this point as the last one.

(not all possible actions, agents, measurements and sensors config nodes).
- `task.possible_actions` is removed.

### New features
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That would be good to mention that functionality is the result of the migration:

Suggested change
### New features
### New functionality enabled

# "+habitat=benchmark/rearrange/pick",
# "+sim_sensors@habitat.simulator.agent_0.sim_sensors.arm_rgb_sensor=arm_rgb_sensor",
# "+sim_sensors@habitat.simulator.agents.agent_0.sim_sensors.arm_rgb_sensor=arm_rgb_sensor",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should add the comments why the lines are commented out or remove them.

@@ -75,8 +75,10 @@ def merge_sim_episode_config(
episode.start_position is not None
and episode.start_rotation is not None
):
agent_name = sim_config.agents[sim_config.default_agent_id]
agent_cfg = getattr(sim_config, agent_name)
default_agent_name = sim_config.agents_order[
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should use get_agent_config method here to be consistent.

Comment on lines +285 to +288
len(
self.sim_config.agents[
self.habitat_config.default_agent_id
].action_space
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use get_agent_config for consistency:

Suggested change
len(
self.sim_config.agents[
self.habitat_config.default_agent_id
].action_space
len(
get_agent_config(self.sim_config).action_space

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here self.sim_config is not of type DictConfig it is of type habitat_sim.Configuration. So the code should be kept as it is.

@@ -57,6 +73,19 @@ def get_config(
overrides=overrides if overrides is not None else [],
)

# In the single-agent setup use the agent's key from `habitat.simulator.agents`.
sim_config = cfg.habitat.simulator
if len(sim_config.agents) == 1:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we should leave it as is. I do not want to have main_agent be defined in code (and that includes the default_structured_config file) but only be defined in the yamls that we provide. Nothing should prevent the user to name their unique agent anything they want and not need to modify agent_order

habitat-lab/habitat/config/default.py Outdated Show resolved Hide resolved
Comment on lines 959 to 960
# if the number of agents is greater than one,
# then agents_order has to be set explicitly too
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

agent_order is only used to know in which order to return the observations and accept the actions when using the environment API correct?
In any case, we should explain here what the agent_order does for the user

@@ -0,0 +1,5 @@
# @package habitat.simulator.agents.depth_agent
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

TODO later (not in this PR)
Make a 256 version of these to reduce complexity of benchmark configs

width: 256
height: 256
agents:
main_agent:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why are we changing agent_0 to main_agent? Seems less intuitive to me, especially for multi_agent support.

MISSING # temporary multi-agent rearrangement config fix
)
# we assume agent(s) to be set explicitly
agents: Dict[str, AgentConfig] = MISSING
Copy link
Contributor

@Skylion007 Skylion007 Nov 29, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
agents: Dict[str, AgentConfig] = MISSING
agents: List[AgentConfig] = MISSING

Why not that? Then agent order is defined, each agent has a unique ID given by its order in the list, right? Or is there some reason we can't do that. In the event taht does not work, does Hydrasupport that Dict just being an OrderedDict instead? ANd then the order still matters?
Or even more cleverly:

Suggested change
agents: Dict[str, AgentConfig] = MISSING
agents: OrderedDict[str, AgentConfig] = MISSING

Copy link
Contributor

@Skylion007 Skylion007 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I actually do not like how agent_order now needs to manually specified. It is error prone and that information can be specified by the user in a more intuitive way. We already have an agent order implicitly from the order the agents are defined in the YAML, can we need use that, either via an OrderedDict or via List?

robot_urdf: ./data/robots/hab_fetch/robots/hab_fetch.urdf
robot_type: "FetchRobot"
agents:
main_agent:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okay, so why are we naming the agent with dictionary keys instead of just introducing a harmless name object to the AgentConfig? Seems like we are just complicating multiagent support. Is there a good reason to do this? Is it due to limitations in YAML? That dictionaries are easier to merge together? Can we preserve the ordering of the dictionary somehow to specify agent order?

Copy link
Contributor

@Skylion007 Skylion007 Nov 29, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Better yet can we copy the way defaults is defined at the top fo the yaml

    agents:
        - main_agent: ...
        - agent_1: ...

Copy link
Contributor

@Skylion007 Skylion007 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fine without multiagent issues.

rpartsey and others added 4 commits November 30, 2022 01:00
Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>
…/habitat-lab into hydra_migration_3_v2_agents_upd
@vincentpierre vincentpierre merged commit b40736f into facebookresearch:hydra_migration_3_v2 Nov 29, 2022
vincentpierre added a commit that referenced this pull request Nov 30, 2022
* updated md files

* updated habitat2_gym_tutorial

* updated Habitat2_Quickstart

* updated Habitat_Lab

* updated docs

* partially removed YACS (note there are some inpedendent parts of code that still rely on YACS)

* made all DictConfig imports to be from omegaconf using if TYPE_CHECKING

* removed link to the outdated notebook

* fixed tests

* [Hydra Migration] Removing yacs and migratting the dataset generation code of rearrange (#1001)

* removing yacs and migratting the dataset generation code of rearrange

* addressing comments

* typechecking corrections

Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>

* renaming SensorConfig to LabSensorConfig

* fixing svg link

* fixing svg;

* using relative path is better for svg

* addressed comments

* [0.2.3][Hydra Migration] Made agents to be of type Dict[str, AgentConfig] and added migration readme (#1007)

* made habitat.simulator.agents be a Dict[str, AgentConfig]

* addressed comments

* refactored sim agents configuration

* moved rearrange agents declarations to agents folder; finised agents configuration updates; updated docs

* updated get_config import

* Cfg sys migration readme (#2)

* added habitat-lab config readme

* addressed most of the comments

* added main_agent alias

* renamed habitat config reagme and added baselines config readme

* Update habitat-lab/habitat/config/default.py

Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>

* added desctiption for the agents_order field

* added a dot :)

Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>

* fixing conflicts

Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>
Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>
ASzot pushed a commit that referenced this pull request Dec 3, 2022
* [v0.2.3] Add robot document (#1018)

* [v0.2.3] [Stretch] play stretch demo (#1014)

* [Fix] Documentation gym example path (#1016)

Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>

* [0.2.3]Hydra migration 3 v2 (#1000)

* updated md files

* updated habitat2_gym_tutorial

* updated Habitat2_Quickstart

* updated Habitat_Lab

* updated docs

* partially removed YACS (note there are some inpedendent parts of code that still rely on YACS)

* made all DictConfig imports to be from omegaconf using if TYPE_CHECKING

* removed link to the outdated notebook

* fixed tests

* [Hydra Migration] Removing yacs and migratting the dataset generation code of rearrange (#1001)

* removing yacs and migratting the dataset generation code of rearrange

* addressing comments

* typechecking corrections

Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>

* renaming SensorConfig to LabSensorConfig

* fixing svg link

* fixing svg;

* using relative path is better for svg

* addressed comments

* [0.2.3][Hydra Migration] Made agents to be of type Dict[str, AgentConfig] and added migration readme (#1007)

* made habitat.simulator.agents be a Dict[str, AgentConfig]

* addressed comments

* refactored sim agents configuration

* moved rearrange agents declarations to agents folder; finised agents configuration updates; updated docs

* updated get_config import

* Cfg sys migration readme (#2)

* added habitat-lab config readme

* addressed most of the comments

* added main_agent alias

* renamed habitat config reagme and added baselines config readme

* Update habitat-lab/habitat/config/default.py

Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>

* added desctiption for the agents_order field

* added a dot :)

Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>

* fixing conflicts

Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>
Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>

* Fix links in MANIFEST.in (#991)

* Fix broken links in MANIFEST.in

* fixig video_render_view

* fixing issue with gym maker

* editing test that changed with recent config modifications

* [v0.2.3] Fixing mypy (#1023)

* Unpin habitat-lab requirements

* Reorder dependencies

* Fix mypy config

* remove unnecessary mypy args

* Update mypy version

* Fix python lint

* Fix pre-commit mypy further

* fix mypy ignored errors

* fixing mypy

* fixing mypy

* more accurate type:ignores

* adding docs/ to exclude mypy

* trying to fix python_lint

* exlude arguments

* exlude arguments

* Container needs to be a string

Co-authored-by: Aaron Gokaslan <aaronGokaslan@gmail.com>
Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>

* removing the gym envs keys that were removed

Co-authored-by: Jimmy Yang <55121504+jimmytyyang@users.noreply.github.com>
Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>
Co-authored-by: Ruslan <partsey2412@gmail.com>
Co-authored-by: Mikaël Dallaire Côté <110583667+0mdc@users.noreply.github.com>
Co-authored-by: Aaron Gokaslan <aaronGokaslan@gmail.com>
ASzot added a commit that referenced this pull request Dec 7, 2022
* [bugfix] Reconfigure the sim even if the sim is not None

* addressing comments, better way to decide wether or not to reconfigure sim_obj

* same fix for the robot base

* Added back caching to pick task

* Fixed up nav to obj task

* Fixed up open and close skills

* Added back inits for nav to obj

* Batched HRL policy

* Updated task conditions

* Fixed key mismatch in TP-SRL

* Fixed issue with nav to obj skill

* Fixed early stop issue

* Fixed bad filter condition

* Updated training configs

* Refactored and cleaned up config files

* Fixed up reward. Renamed configs

* Added wandb resume

* Refactored eval with debug sensor code.

* Added get policy info

* Hopefully fixed resuming, added safe drop

* Added improved Fetch model

* Removed refactored files

* Added back default

* Removed habitat folder

* Fixed pick task

* Fixed navigation skill

* Removed redundancy in skill training configs

* Addressed some comments

* Removed nav pick

* Update .gitignore

Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>

* PR comments

* [v0.2.3] Hab2 fixup : merging main and resolving conflicts (#1022)

* [v0.2.3] Add robot document (#1018)

* [v0.2.3] [Stretch] play stretch demo (#1014)

* [Fix] Documentation gym example path (#1016)

Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>

* [0.2.3]Hydra migration 3 v2 (#1000)

* updated md files

* updated habitat2_gym_tutorial

* updated Habitat2_Quickstart

* updated Habitat_Lab

* updated docs

* partially removed YACS (note there are some inpedendent parts of code that still rely on YACS)

* made all DictConfig imports to be from omegaconf using if TYPE_CHECKING

* removed link to the outdated notebook

* fixed tests

* [Hydra Migration] Removing yacs and migratting the dataset generation code of rearrange (#1001)

* removing yacs and migratting the dataset generation code of rearrange

* addressing comments

* typechecking corrections

Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>

* renaming SensorConfig to LabSensorConfig

* fixing svg link

* fixing svg;

* using relative path is better for svg

* addressed comments

* [0.2.3][Hydra Migration] Made agents to be of type Dict[str, AgentConfig] and added migration readme (#1007)

* made habitat.simulator.agents be a Dict[str, AgentConfig]

* addressed comments

* refactored sim agents configuration

* moved rearrange agents declarations to agents folder; finised agents configuration updates; updated docs

* updated get_config import

* Cfg sys migration readme (#2)

* added habitat-lab config readme

* addressed most of the comments

* added main_agent alias

* renamed habitat config reagme and added baselines config readme

* Update habitat-lab/habitat/config/default.py

Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>

* added desctiption for the agents_order field

* added a dot :)

Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>

* fixing conflicts

Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>
Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>

* Fix links in MANIFEST.in (#991)

* Fix broken links in MANIFEST.in

* fixig video_render_view

* fixing issue with gym maker

* editing test that changed with recent config modifications

* [v0.2.3] Fixing mypy (#1023)

* Unpin habitat-lab requirements

* Reorder dependencies

* Fix mypy config

* remove unnecessary mypy args

* Update mypy version

* Fix python lint

* Fix pre-commit mypy further

* fix mypy ignored errors

* fixing mypy

* fixing mypy

* more accurate type:ignores

* adding docs/ to exclude mypy

* trying to fix python_lint

* exlude arguments

* exlude arguments

* Container needs to be a string

Co-authored-by: Aaron Gokaslan <aaronGokaslan@gmail.com>
Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>

* removing the gym envs keys that were removed

Co-authored-by: Jimmy Yang <55121504+jimmytyyang@users.noreply.github.com>
Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>
Co-authored-by: Ruslan <partsey2412@gmail.com>
Co-authored-by: Mikaël Dallaire Côté <110583667+0mdc@users.noreply.github.com>
Co-authored-by: Aaron Gokaslan <aaronGokaslan@gmail.com>

* Merged

* Removed bad file and fixed IK

* Env fixes

* Fixed precommit

* Fixed eval and fixed wandb logging

* Fix for the resume in VER and the force threshold for open tasks

* Update habitat-baselines/habitat_baselines/rl/ddppo/policy/resnet_policy.py

Co-authored-by: Aaron Gokaslan <skylion.aaron@gmail.com>

* tp-srl fixes

* tp-srl fixes

* Fixed more tests

* Cleaned up nav action

* Added tests for all tasks in baseline trainer

* Corrected test overrides

* Improved agents loop in resnet_policy

Improved agents loop in resnet_policy

Co-authored-by: Ruslan <partsey2412@gmail.com>

* Fixed policy docs and improvements. Added docs to spawn robot method.

* [0.2.3] 959 PR review suggested changes (#1029)

* removed habitat-baselines/habitat_baselines/config path prefix

* improved adding render view uuids to the gym obs_keys

* made config keys lowercase

* Updated docs

* Update habitat-lab/habitat/tasks/rearrange/rearrange_task.py

Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>

* Update habitat-baselines/habitat_baselines/rl/ddppo/policy/resnet_policy.py

Co-authored-by: Aaron Gokaslan <skylion.aaron@gmail.com>

* Fixed formatting

* tp-srl config fix

* fixing documentation ?

Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>
Co-authored-by: ASzot <me@andrewszot.com>
Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>
Co-authored-by: Jimmy Yang <55121504+jimmytyyang@users.noreply.github.com>
Co-authored-by: Ruslan <partsey2412@gmail.com>
Co-authored-by: Mikaël Dallaire Côté <110583667+0mdc@users.noreply.github.com>
Co-authored-by: Aaron Gokaslan <aaronGokaslan@gmail.com>
Co-authored-by: Aaron Gokaslan <skylion.aaron@gmail.com>
Co-authored-by: Oleksandr <maksymets.o@gmail.com>
Co-authored-by: Oleksandr Maksymets <maksymets@gmail.com>
Co-authored-by: SergioArnaud <sercharnaud@gmail.com>
dannymcy pushed a commit to dannymcy/habitat-lab that referenced this pull request Jul 8, 2024
* updated md files

* updated habitat2_gym_tutorial

* updated Habitat2_Quickstart

* updated Habitat_Lab

* updated docs

* partially removed YACS (note there are some inpedendent parts of code that still rely on YACS)

* made all DictConfig imports to be from omegaconf using if TYPE_CHECKING

* removed link to the outdated notebook

* fixed tests

* [Hydra Migration] Removing yacs and migratting the dataset generation code of rearrange (facebookresearch#1001)

* removing yacs and migratting the dataset generation code of rearrange

* addressing comments

* typechecking corrections

Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>

* renaming SensorConfig to LabSensorConfig

* fixing svg link

* fixing svg;

* using relative path is better for svg

* addressed comments

* [0.2.3][Hydra Migration] Made agents to be of type Dict[str, AgentConfig] and added migration readme (facebookresearch#1007)

* made habitat.simulator.agents be a Dict[str, AgentConfig]

* addressed comments

* refactored sim agents configuration

* moved rearrange agents declarations to agents folder; finised agents configuration updates; updated docs

* updated get_config import

* Cfg sys migration readme (facebookresearch#2)

* added habitat-lab config readme

* addressed most of the comments

* added main_agent alias

* renamed habitat config reagme and added baselines config readme

* Update habitat-lab/habitat/config/default.py

Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>

* added desctiption for the agents_order field

* added a dot :)

Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>

* fixing conflicts

Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>
Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>
dannymcy pushed a commit to dannymcy/habitat-lab that referenced this pull request Jul 8, 2024
…okresearch#959)

* [bugfix] Reconfigure the sim even if the sim is not None

* addressing comments, better way to decide wether or not to reconfigure sim_obj

* same fix for the robot base

* Added back caching to pick task

* Fixed up nav to obj task

* Fixed up open and close skills

* Added back inits for nav to obj

* Batched HRL policy

* Updated task conditions

* Fixed key mismatch in TP-SRL

* Fixed issue with nav to obj skill

* Fixed early stop issue

* Fixed bad filter condition

* Updated training configs

* Refactored and cleaned up config files

* Fixed up reward. Renamed configs

* Added wandb resume

* Refactored eval with debug sensor code.

* Added get policy info

* Hopefully fixed resuming, added safe drop

* Added improved Fetch model

* Removed refactored files

* Added back default

* Removed habitat folder

* Fixed pick task

* Fixed navigation skill

* Removed redundancy in skill training configs

* Addressed some comments

* Removed nav pick

* Update .gitignore

Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>

* PR comments

* [v0.2.3] Hab2 fixup : merging main and resolving conflicts (facebookresearch#1022)

* [v0.2.3] Add robot document (facebookresearch#1018)

* [v0.2.3] [Stretch] play stretch demo (facebookresearch#1014)

* [Fix] Documentation gym example path (facebookresearch#1016)

Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>

* [0.2.3]Hydra migration 3 v2 (facebookresearch#1000)

* updated md files

* updated habitat2_gym_tutorial

* updated Habitat2_Quickstart

* updated Habitat_Lab

* updated docs

* partially removed YACS (note there are some inpedendent parts of code that still rely on YACS)

* made all DictConfig imports to be from omegaconf using if TYPE_CHECKING

* removed link to the outdated notebook

* fixed tests

* [Hydra Migration] Removing yacs and migratting the dataset generation code of rearrange (facebookresearch#1001)

* removing yacs and migratting the dataset generation code of rearrange

* addressing comments

* typechecking corrections

Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>

* renaming SensorConfig to LabSensorConfig

* fixing svg link

* fixing svg;

* using relative path is better for svg

* addressed comments

* [0.2.3][Hydra Migration] Made agents to be of type Dict[str, AgentConfig] and added migration readme (facebookresearch#1007)

* made habitat.simulator.agents be a Dict[str, AgentConfig]

* addressed comments

* refactored sim agents configuration

* moved rearrange agents declarations to agents folder; finised agents configuration updates; updated docs

* updated get_config import

* Cfg sys migration readme (facebookresearch#2)

* added habitat-lab config readme

* addressed most of the comments

* added main_agent alias

* renamed habitat config reagme and added baselines config readme

* Update habitat-lab/habitat/config/default.py

Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>

* added desctiption for the agents_order field

* added a dot :)

Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>

* fixing conflicts

Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>
Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>

* Fix links in MANIFEST.in (facebookresearch#991)

* Fix broken links in MANIFEST.in

* fixig video_render_view

* fixing issue with gym maker

* editing test that changed with recent config modifications

* [v0.2.3] Fixing mypy (facebookresearch#1023)

* Unpin habitat-lab requirements

* Reorder dependencies

* Fix mypy config

* remove unnecessary mypy args

* Update mypy version

* Fix python lint

* Fix pre-commit mypy further

* fix mypy ignored errors

* fixing mypy

* fixing mypy

* more accurate type:ignores

* adding docs/ to exclude mypy

* trying to fix python_lint

* exlude arguments

* exlude arguments

* Container needs to be a string

Co-authored-by: Aaron Gokaslan <aaronGokaslan@gmail.com>
Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>

* removing the gym envs keys that were removed

Co-authored-by: Jimmy Yang <55121504+jimmytyyang@users.noreply.github.com>
Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>
Co-authored-by: Ruslan <partsey2412@gmail.com>
Co-authored-by: Mikaël Dallaire Côté <110583667+0mdc@users.noreply.github.com>
Co-authored-by: Aaron Gokaslan <aaronGokaslan@gmail.com>

* Merged

* Removed bad file and fixed IK

* Env fixes

* Fixed precommit

* Fixed eval and fixed wandb logging

* Fix for the resume in VER and the force threshold for open tasks

* Update habitat-baselines/habitat_baselines/rl/ddppo/policy/resnet_policy.py

Co-authored-by: Aaron Gokaslan <skylion.aaron@gmail.com>

* tp-srl fixes

* tp-srl fixes

* Fixed more tests

* Cleaned up nav action

* Added tests for all tasks in baseline trainer

* Corrected test overrides

* Improved agents loop in resnet_policy

Improved agents loop in resnet_policy

Co-authored-by: Ruslan <partsey2412@gmail.com>

* Fixed policy docs and improvements. Added docs to spawn robot method.

* [0.2.3] 959 PR review suggested changes (facebookresearch#1029)

* removed habitat-baselines/habitat_baselines/config path prefix

* improved adding render view uuids to the gym obs_keys

* made config keys lowercase

* Updated docs

* Update habitat-lab/habitat/tasks/rearrange/rearrange_task.py

Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>

* Update habitat-baselines/habitat_baselines/rl/ddppo/policy/resnet_policy.py

Co-authored-by: Aaron Gokaslan <skylion.aaron@gmail.com>

* Fixed formatting

* tp-srl config fix

* fixing documentation ?

Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>
Co-authored-by: ASzot <me@andrewszot.com>
Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>
Co-authored-by: Jimmy Yang <55121504+jimmytyyang@users.noreply.github.com>
Co-authored-by: Ruslan <partsey2412@gmail.com>
Co-authored-by: Mikaël Dallaire Côté <110583667+0mdc@users.noreply.github.com>
Co-authored-by: Aaron Gokaslan <aaronGokaslan@gmail.com>
Co-authored-by: Aaron Gokaslan <skylion.aaron@gmail.com>
Co-authored-by: Oleksandr <maksymets.o@gmail.com>
Co-authored-by: Oleksandr Maksymets <maksymets@gmail.com>
Co-authored-by: SergioArnaud <sercharnaud@gmail.com>
HHYHRHY pushed a commit to SgtVincent/EMOS that referenced this pull request Aug 31, 2024
* updated md files

* updated habitat2_gym_tutorial

* updated Habitat2_Quickstart

* updated Habitat_Lab

* updated docs

* partially removed YACS (note there are some inpedendent parts of code that still rely on YACS)

* made all DictConfig imports to be from omegaconf using if TYPE_CHECKING

* removed link to the outdated notebook

* fixed tests

* [Hydra Migration] Removing yacs and migratting the dataset generation code of rearrange (facebookresearch#1001)

* removing yacs and migratting the dataset generation code of rearrange

* addressing comments

* typechecking corrections

Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>

* renaming SensorConfig to LabSensorConfig

* fixing svg link

* fixing svg;

* using relative path is better for svg

* addressed comments

* [0.2.3][Hydra Migration] Made agents to be of type Dict[str, AgentConfig] and added migration readme (facebookresearch#1007)

* made habitat.simulator.agents be a Dict[str, AgentConfig]

* addressed comments

* refactored sim agents configuration

* moved rearrange agents declarations to agents folder; finised agents configuration updates; updated docs

* updated get_config import

* Cfg sys migration readme (#2)

* added habitat-lab config readme

* addressed most of the comments

* added main_agent alias

* renamed habitat config reagme and added baselines config readme

* Update habitat-lab/habitat/config/default.py

Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>

* added desctiption for the agents_order field

* added a dot :)

Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>

* fixing conflicts

Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>
Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>
HHYHRHY pushed a commit to SgtVincent/EMOS that referenced this pull request Aug 31, 2024
…okresearch#959)

* [bugfix] Reconfigure the sim even if the sim is not None

* addressing comments, better way to decide wether or not to reconfigure sim_obj

* same fix for the robot base

* Added back caching to pick task

* Fixed up nav to obj task

* Fixed up open and close skills

* Added back inits for nav to obj

* Batched HRL policy

* Updated task conditions

* Fixed key mismatch in TP-SRL

* Fixed issue with nav to obj skill

* Fixed early stop issue

* Fixed bad filter condition

* Updated training configs

* Refactored and cleaned up config files

* Fixed up reward. Renamed configs

* Added wandb resume

* Refactored eval with debug sensor code.

* Added get policy info

* Hopefully fixed resuming, added safe drop

* Added improved Fetch model

* Removed refactored files

* Added back default

* Removed habitat folder

* Fixed pick task

* Fixed navigation skill

* Removed redundancy in skill training configs

* Addressed some comments

* Removed nav pick

* Update .gitignore

Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>

* PR comments

* [v0.2.3] Hab2 fixup : merging main and resolving conflicts (facebookresearch#1022)

* [v0.2.3] Add robot document (facebookresearch#1018)

* [v0.2.3] [Stretch] play stretch demo (facebookresearch#1014)

* [Fix] Documentation gym example path (facebookresearch#1016)

Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>

* [0.2.3]Hydra migration 3 v2 (facebookresearch#1000)

* updated md files

* updated habitat2_gym_tutorial

* updated Habitat2_Quickstart

* updated Habitat_Lab

* updated docs

* partially removed YACS (note there are some inpedendent parts of code that still rely on YACS)

* made all DictConfig imports to be from omegaconf using if TYPE_CHECKING

* removed link to the outdated notebook

* fixed tests

* [Hydra Migration] Removing yacs and migratting the dataset generation code of rearrange (facebookresearch#1001)

* removing yacs and migratting the dataset generation code of rearrange

* addressing comments

* typechecking corrections

Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>

* renaming SensorConfig to LabSensorConfig

* fixing svg link

* fixing svg;

* using relative path is better for svg

* addressed comments

* [0.2.3][Hydra Migration] Made agents to be of type Dict[str, AgentConfig] and added migration readme (facebookresearch#1007)

* made habitat.simulator.agents be a Dict[str, AgentConfig]

* addressed comments

* refactored sim agents configuration

* moved rearrange agents declarations to agents folder; finised agents configuration updates; updated docs

* updated get_config import

* Cfg sys migration readme (#2)

* added habitat-lab config readme

* addressed most of the comments

* added main_agent alias

* renamed habitat config reagme and added baselines config readme

* Update habitat-lab/habitat/config/default.py

Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>

* added desctiption for the agents_order field

* added a dot :)

Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>

* fixing conflicts

Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>
Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>

* Fix links in MANIFEST.in (facebookresearch#991)

* Fix broken links in MANIFEST.in

* fixig video_render_view

* fixing issue with gym maker

* editing test that changed with recent config modifications

* [v0.2.3] Fixing mypy (facebookresearch#1023)

* Unpin habitat-lab requirements

* Reorder dependencies

* Fix mypy config

* remove unnecessary mypy args

* Update mypy version

* Fix python lint

* Fix pre-commit mypy further

* fix mypy ignored errors

* fixing mypy

* fixing mypy

* more accurate type:ignores

* adding docs/ to exclude mypy

* trying to fix python_lint

* exlude arguments

* exlude arguments

* Container needs to be a string

Co-authored-by: Aaron Gokaslan <aaronGokaslan@gmail.com>
Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>

* removing the gym envs keys that were removed

Co-authored-by: Jimmy Yang <55121504+jimmytyyang@users.noreply.github.com>
Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>
Co-authored-by: Ruslan <partsey2412@gmail.com>
Co-authored-by: Mikaël Dallaire Côté <110583667+0mdc@users.noreply.github.com>
Co-authored-by: Aaron Gokaslan <aaronGokaslan@gmail.com>

* Merged

* Removed bad file and fixed IK

* Env fixes

* Fixed precommit

* Fixed eval and fixed wandb logging

* Fix for the resume in VER and the force threshold for open tasks

* Update habitat-baselines/habitat_baselines/rl/ddppo/policy/resnet_policy.py

Co-authored-by: Aaron Gokaslan <skylion.aaron@gmail.com>

* tp-srl fixes

* tp-srl fixes

* Fixed more tests

* Cleaned up nav action

* Added tests for all tasks in baseline trainer

* Corrected test overrides

* Improved agents loop in resnet_policy

Improved agents loop in resnet_policy

Co-authored-by: Ruslan <partsey2412@gmail.com>

* Fixed policy docs and improvements. Added docs to spawn robot method.

* [0.2.3] 959 PR review suggested changes (facebookresearch#1029)

* removed habitat-baselines/habitat_baselines/config path prefix

* improved adding render view uuids to the gym obs_keys

* made config keys lowercase

* Updated docs

* Update habitat-lab/habitat/tasks/rearrange/rearrange_task.py

Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>

* Update habitat-baselines/habitat_baselines/rl/ddppo/policy/resnet_policy.py

Co-authored-by: Aaron Gokaslan <skylion.aaron@gmail.com>

* Fixed formatting

* tp-srl config fix

* fixing documentation ?

Co-authored-by: vincentpierre <vincentpierre@users.noreply.github.com>
Co-authored-by: ASzot <me@andrewszot.com>
Co-authored-by: Vincent-Pierre BERGES <28320361+vincentpierre@users.noreply.github.com>
Co-authored-by: Jimmy Yang <55121504+jimmytyyang@users.noreply.github.com>
Co-authored-by: Ruslan <partsey2412@gmail.com>
Co-authored-by: Mikaël Dallaire Côté <110583667+0mdc@users.noreply.github.com>
Co-authored-by: Aaron Gokaslan <aaronGokaslan@gmail.com>
Co-authored-by: Aaron Gokaslan <skylion.aaron@gmail.com>
Co-authored-by: Oleksandr <maksymets.o@gmail.com>
Co-authored-by: Oleksandr Maksymets <maksymets@gmail.com>
Co-authored-by: SergioArnaud <sercharnaud@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed Do not delete this pull request or issue due to inactivity.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants