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 a mechanism for sending arbitrary data payloads to the backend #313

Merged
merged 6 commits into from
Jul 14, 2021

Conversation

ChrisCummins
Copy link
Contributor

This patch adds a mechanism to the CompilerGym client/service
architecture so that the client can send arbitrary data messages to
the service, which can then generate a response. This can be used by
particular client/service implementations to provide a "back door" for
talking to the service in a way that doesn't conform to the normal RL
environment communication pattern.

Fixes #312.

This patch adds a mechanism to the CompilerGym client/service
architecture so that the client can send arbitrary data messages to
the service, which can then generate a response. This can be used by
particular client/service implementations to provide a "back door" for
talking to the service in a way that doesn't conform to the normal RL
environment communication pattern.

github.com/facebookresearch/issues/312
@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Jul 9, 2021
@ChrisCummins ChrisCummins requested a review from hughleat July 9, 2021 11:24
@codecov-commenter
Copy link

codecov-commenter commented Jul 9, 2021

Codecov Report

Merging #313 (a43057f) into development (acd6405) will increase coverage by 0.01%.
The diff coverage is 92.85%.

Impacted file tree graph

@@               Coverage Diff               @@
##           development     #313      +/-   ##
===============================================
+ Coverage        85.61%   85.63%   +0.01%     
===============================================
  Files               87       87              
  Lines             4687     4700      +13     
===============================================
+ Hits              4013     4025      +12     
- Misses             674      675       +1     
Impacted Files Coverage Δ
compiler_gym/service/proto/__init__.py 100.00% <ø> (ø)
compiler_gym/service/compilation_session.py 63.15% <50.00%> (-1.55%) ⬇️
compiler_gym/envs/compiler_env.py 86.44% <100.00%> (+0.39%) ⬆️
...mpiler_gym/service/runtime/compiler_gym_service.py 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update acd6405...a43057f. Read the comment docs.

Fix an invalid variable name error and the return type annotation.
Don't make send_params() return type change based on the nunmber of
calling arguments. Instead, add an explicit singular version of the
method.

Issue facebookresearch#312.
@ChrisCummins
Copy link
Contributor Author

Updated based on @hughleat's feedback:

  1. send_params() always returns a list, rather than returning a singular value if called with a single parameter.
  2. Added a new send_param() API to be clear about singular param calls.

Cheers,
Chris

@ChrisCummins ChrisCummins merged commit bd186eb into facebookresearch:development Jul 14, 2021
@ChrisCummins ChrisCummins deleted the session-param branch July 14, 2021 01:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add a mechanism for sending arbitrary data payloads to the backend
3 participants