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

Reduce heavy mandatory dependencies for simple functionality #726

Open
andmis opened this issue Mar 17, 2022 · 3 comments
Open

Reduce heavy mandatory dependencies for simple functionality #726

andmis opened this issue Mar 17, 2022 · 3 comments

Comments

@andmis
Copy link

andmis commented Mar 17, 2022

I would like to use some nice, general-purpose utilities from TF-Agents, for example the replay buffers. Is it possible to set things up so that utilities like this are usable without depending on, for example, libraries like MuJoCo or OpenAI Gym? It doesn't seem correct that something like tf_agents.replay_buffers depends on on something like MuJoCo. This causes downstream problems: for example, it's not currently straightforward to use MuJoCo on a Mac M1, so it's not currently straightforward to use tf_agents on a Mac M1 (pip3 install tf-agents && python3 -m tf_agents results in OSError: Cannot find MuJoCo library at /Users/mishchea/.mujoco/mujoco210/bin/libmujoco210.dylib.).

@sguada
Copy link
Member

sguada commented Mar 17, 2022

You should be able to use replay_buffers or any other utils from TF-Agents, although you probably need to clone the repository and use it directly, instead of pip install it.

@andmis
Copy link
Author

andmis commented Mar 17, 2022

My concern isn't related to just getting things to work. I know I could copy-paste the relevant Python modules or just comment-out the imports I don't need.

My concern is, if I intend to share my code with someone else, or run it in another environment, I don't want to have to worry about either (1) copying my hacks/edits everywhere, or (2) requiring the deps for everyone, everywhere.

@sguada
Copy link
Member

sguada commented Mar 17, 2022

If you are interested in creating a PR which add an install option that avoids installing mujoco pip3 install tf-agents[nomujoco] we can review it.

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

No branches or pull requests

2 participants