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

Move async interaction from Coordinator to BaseSimulator. #230

Merged
merged 1 commit into from
Oct 11, 2024

Conversation

copybara-service[bot]
Copy link

Move async interaction from Coordinator to BaseSimulator.

This change adds asynchronous interaction to all simulators (i.e. derived
classes of BaseSimulator), making this type of interaction less specific
about our specific usage in the Coordinator. This is an ongoing effort to
separate the RL parts in AndroidEnv (mostly AndroidEnv and TaskManager)
from the more generic parts like BaseSimulator. The interface of derived
classes changed a little: instead of implementing get_screenshot() they now
have to implement _get_screenshot_impl().

This change also contains a small fix to BaseSimulator.__init__() which
instead of taking individual params, it now takes a single SimulatorConfig,
making its initialization the same as other major components. This requires a
small change to the super().__init__() call in derived classes, but it
prepares them for future changes to SimulatorConfig.

@copybara-service copybara-service bot force-pushed the test_684273378 branch 3 times, most recently from efeac5e to 0c5b733 Compare October 11, 2024 16:44
This change adds asynchronous interaction to all simulators (i.e. derived
classes of `BaseSimulator`), making this type of interaction less specific
about our specific usage in the `Coordinator`. This is an ongoing effort to
separate the RL parts in AndroidEnv (mostly `AndroidEnv` and `TaskManager`)
from the more generic parts like `BaseSimulator`. The interface of *derived*
classes changed a little: instead of implementing `get_screenshot()` they now
have to implement `_get_screenshot_impl()`.

This change also contains a small fix to `BaseSimulator.__init__()` which
instead of taking individual params, it now takes a single `SimulatorConfig`,
making its initialization the same as other major components. This requires a
small change to the `super().__init__()` call in derived classes, but it
prepares them for future changes to `SimulatorConfig`.

PiperOrigin-RevId: 684870508
@copybara-service copybara-service bot merged commit de288c9 into main Oct 11, 2024
@copybara-service copybara-service bot deleted the test_684273378 branch October 11, 2024 16:56
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

Successfully merging this pull request may close these issues.

1 participant