Skip to content

Get timers from subprocess #2268

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

Merged
merged 33 commits into from
Jul 23, 2019
Merged

Get timers from subprocess #2268

merged 33 commits into from
Jul 23, 2019

Conversation

chriselion
Copy link
Contributor

Extends the previous timer code to return the timer from the subprocess workers, and merge them into the timer tree.

Deciding to represent this is the hardest part. Instead of trying to track real/user time, I went with a simpler approach of flagging the nodes that are run in parallel; this is set when merging the trees.

@chriselion chriselion requested review from harperj and xiaomaogy July 16, 2019 01:07
@@ -625,6 +627,7 @@ def _get_state(self, output: UnityRLOutput) -> Tuple[AllBrainInfo, bool]:
)
return _data, global_done

@timed
def _generate_step_input(
Copy link
Contributor

@xiaomaogy xiaomaogy Jul 23, 2019

Choose a reason for hiding this comment

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

What is the purpose of timing this in addition to timing the env.step time here? I thought we intend to benchmark the communication time, which is the self.communicator.exchange function that calls this function.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I put it there because that's where the protobuf serialization occurs. I'll put one on RpcCommunicator.communicate too.

@xiaomaogy
Copy link
Contributor

xiaomaogy commented Jul 23, 2019

Aside from my only comment, all seems reasonable to me.

@chriselion chriselion merged commit 1837840 into develop Jul 23, 2019
@awjuliani awjuliani deleted the develop-timers-subprocess branch July 23, 2019 20:21
@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 18, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants