Skip to content

Commit

Permalink
No public description
Browse files Browse the repository at this point in the history
PiperOrigin-RevId: 568048412
  • Loading branch information
DeepMind authored and copybara-github committed Sep 24, 2023
1 parent 49fd98e commit d2a31e8
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion android_env/components/coordinator.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ def __init__(
self._tmp_dir = tmp_dir or tempfile.gettempdir()
self._orientation = np.zeros(4, dtype=np.uint8)
self._interaction_rate_sec = interaction_rate_sec
self._interaction_thread = None
self._interaction_thread: InteractionThread | None = None

# The size of the device screen in pixels (H x W).
self._screen_size = np.array([0, 0], dtype=np.int32)
Expand Down Expand Up @@ -362,6 +362,7 @@ def _gather_simulator_signals(self) -> dict[str, np.ndarray]:

# Grab pixels.
if self._interaction_rate_sec > 0:
assert self._interaction_thread is not None
pixels = self._interaction_thread.screenshot() # Async mode.
else:
pixels = self._simulator.get_screenshot() # Sync mode.
Expand Down

0 comments on commit d2a31e8

Please sign in to comment.