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

Add multiple vehicles with different action space #580

Open
baimukashev opened this issue Mar 20, 2024 · 1 comment
Open

Add multiple vehicles with different action space #580

baimukashev opened this issue Mar 20, 2024 · 1 comment

Comments

@baimukashev
Copy link

baimukashev commented Mar 20, 2024

Hi, I wanted to add multiple vehicles with different action space to the simulator without using multi-agent setting? for example, I want to spawn multiple IDM vehicles and add another ego with cont action space?

Env seems to have one action space for all vehicles, but is there any ways to do this?
self.action_type = action_factory(self, self.config["action"])

Thanks,

@eleurent
Copy link
Collaborator

Yes it is possible: the action_type is only relevant for the controlled vehicle(s) (or ego-vehicle).
Other (uncontrolled) vehicles in the scenes do not follow this action type. In the environment, the make_vehicles() method should simply create some IDMVehicles and add them to the scene (which is usually the case by default), and these vehicles will follow the IDM model, while you can still set a continuous action space for the ego-vehicle..

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants