Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: NixOS/nixpkgs
base: 11cdfc042490
Choose a base ref
...
head repository: NixOS/nixpkgs
compare: 2611e96bf3cc
Choose a head ref
  • 1 commit
  • 1 file changed
  • 1 contributor

Commits on Jul 12, 2020

  1. python3Packages.pytorch: create separate lib output

    At some point pytorch.dev was added to expose the libtorch headers and
    libraries to non-Python users of libtorch. However, this output
    currently has two disadvantages:
    
    1. An application that compiles against the dev output will also have
       the libtorch header files in its closure. This is not so nice when
       e.g. building Docker images of applications that use libtorch.
    2. The dev output has a large transitive closure with many dependencies
       that are not necessary when compiling against libtorch.
    
    This change adds the `lib` output so that applications that only link
    against libtorch libraries have a small closure.
    
    Before this change, the libtorch dependency adds 746MiB:
    
    % nix path-info -S `realpath result-dev`
    /nix/store/10rmy81bjk628sfpbj2szxlws6brq1xn-python3.8-pytorch-1.5.1-dev   782203848
    
    With this change it is reduced to 196MiB:
    
    % nix path-info -S `realpath result-lib`
    /nix/store/bck65lf0z7gdhcf89w1zs5nz333lhgwa-python3.8-pytorch-1.5.1-lib   205865056
    danieldk authored and FRidh committed Jul 12, 2020
    Copy the full SHA
    2611e96 View commit details
    Browse the repository at this point in the history