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

Cache pytorch #58

Open
1 task
thequicksort opened this issue May 1, 2020 · 1 comment
Open
1 task

Cache pytorch #58

thequicksort opened this issue May 1, 2020 · 1 comment
Labels
enhancement New feature or request

Comments

@thequicksort
Copy link
Contributor

Pytorch takes a while to compile (> 30 minutes) and is wildly computationally intensive. For developers, this is a huge pain-point.

While the nix philosophy is all about reproducibility, maybe it's okay if we ease up on that promise for developers by using cached versions of pytorch. It's a fairly popular library, so perhaps justifiable?

Here are a few (non-exhaustive) options:

1. Use PytorchWorld

One approach is to use PyTorchWorld: Nix scripts for pytorch related libraries

Advantages:

  • Bespoke for Nix

Disadvantages:

  • Python 3.6 only right now (Python 3.7 is on the way)
  • Managed through Git Submodules (this introduces operational burden for developers)

2. Download Pre-builts

It's also possible for us to define the torch derivations locally in nix/pkgs and just pull pre-built versions from urls. This is described in post /#24 in Improving NixOS data science infrastructure

Advantages:

  • Independent of Python version
  • No extra package dependencies
Disadvantages
  • Need to specify build configurations for each OS, architecture (macos-cpu, linux-cpu, linux-gpu). Though based on the above posts, this isn't so bad.
  • Not as straight-forward as having a single dependency handle the configuration.
  • Requires maintenance for us (keeping versions in check, up-to-date, etc)

I'm actually leaning towards option 2.

  • Introduce cached Pytorch
@thequicksort thequicksort added the enhancement New feature or request label May 1, 2020
@thequicksort
Copy link
Contributor Author

Potentially related: #41

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant