facebookresearch / CompilerGym

Reinforcement learning environments for compiler and program optimization tasks
https://compilergym.ai/
MIT License
906 stars 127 forks source link

[examples] Use PyTorch rllib backend, drop Tensorflow dependency. #760

Closed ChrisCummins closed 1 year ago

ChrisCummins commented 2 years ago

TensorFlow is a heavyweight dependency. Drop it in favor of PyTorch, since we already depend on PyTorch for other example code.

Fixes #487.

codecov-commenter commented 2 years ago

Codecov Report

Merging #760 (2531a87) into development (06f81e1) will decrease coverage by 0.10%. The diff coverage is 100.00%.

Additional details and impacted files [![Impacted file tree graph](https://codecov.io/gh/facebookresearch/CompilerGym/pull/760/graphs/tree.svg?width=650&height=150&src=pr&token=2C4Q4HC12K&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=facebookresearch)](https://codecov.io/gh/facebookresearch/CompilerGym/pull/760?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=facebookresearch) ```diff @@ Coverage Diff @@ ## development #760 +/- ## =============================================== - Coverage 89.01% 88.90% -0.11% =============================================== Files 131 131 Lines 8063 8065 +2 =============================================== - Hits 7177 7170 -7 - Misses 886 895 +9 ``` | [Impacted Files](https://codecov.io/gh/facebookresearch/CompilerGym/pull/760?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=facebookresearch) | Coverage Δ | | |---|---|---| | [compiler\_gym/envs/llvm/llvm\_env.py](https://codecov.io/gh/facebookresearch/CompilerGym/pull/760/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=facebookresearch#diff-Y29tcGlsZXJfZ3ltL2VudnMvbGx2bS9sbHZtX2Vudi5weQ==) | `91.71% <100.00%> (+0.09%)` | :arrow_up: | | [compiler\_gym/errors/dataset\_errors.py](https://codecov.io/gh/facebookresearch/CompilerGym/pull/760/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=facebookresearch#diff-Y29tcGlsZXJfZ3ltL2Vycm9ycy9kYXRhc2V0X2Vycm9ycy5weQ==) | `100.00% <100.00%> (ø)` | | | [compiler\_gym/service/connection.py](https://codecov.io/gh/facebookresearch/CompilerGym/pull/760/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=facebookresearch#diff-Y29tcGlsZXJfZ3ltL3NlcnZpY2UvY29ubmVjdGlvbi5weQ==) | `79.28% <0.00%> (-1.95%)` | :arrow_down: | | [...loop\_tool/service/loop\_tool\_compilation\_session.py](https://codecov.io/gh/facebookresearch/CompilerGym/pull/760/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=facebookresearch#diff-Y29tcGlsZXJfZ3ltL2VudnMvbG9vcF90b29sL3NlcnZpY2UvbG9vcF90b29sX2NvbXBpbGF0aW9uX3Nlc3Npb24ucHk=) | `89.86% <0.00%> (-0.68%)` | :arrow_down: | | [...ompiler\_gym/service/client\_service\_compiler\_env.py](https://codecov.io/gh/facebookresearch/CompilerGym/pull/760/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=facebookresearch#diff-Y29tcGlsZXJfZ3ltL3NlcnZpY2UvY2xpZW50X3NlcnZpY2VfY29tcGlsZXJfZW52LnB5) | `90.98% <0.00%> (-0.42%)` | :arrow_down: |