Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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 actor alive interface #1919
Add actor alive interface #1919
Changes from 4 commits
3074d97
d48ee8f
0b1ca08
19e8593
2b1a636
fadb6a9
c8cd908
a80b03c
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We could modify an exisiting test or add a new test to check for the actors alive done criteria.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could we account for multiple vehicles of interest?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a pattern string, so it would account based on pattern matching. I could break it up into multiple for ease of use I suppose.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Broken up.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If possible, it might be better to combine or unify
agents_alive
andactors_alive
options together into one event configuration, because separateagents_alive
andactors_alive
options might conflict.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think what you are considering is the difference between AND and OR causing termination. It is slightly difficult to satisfy these complex cases without introducing expressions.
I think we do not have the case for AND currently.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When we use a single env to cater to two types of scenarios, namely (i) one which uses and terminates with the social agent as the leader, and (ii) one which uses and terminates with the sumo vehicle as the leader, we end up with a code which looks like
[Assume lines 151 to 158 are uncommented]
SMARTS/smarts/env/gymnasium/platoon_env.py
Lines 151 to 163 in 7cdc5c3
Here, the env will terminate immediately every time as one of the done criteria, namely
actors_alive
oragents_alive
will become true immediately at the start of the every scenario.Another issue here is the name of vehicle of interest differs in both scenarios, because
social-agent-leader
string gets prefixed to the agent name when using social agent as the leader.