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
WIP: shell.nix that provides all the dependencies #162
Conversation
libtorch-ffi/libtorch-ffi.cabal
Outdated
, torch | ||
extra-ghci-libraries: stdc++ | ||
if os(darwin) | ||
ld-options: -Wl,-keep_dwarf_unwind | ||
ghc-options: -optc-D_GLIBCXX_USE_CXX11_ABI=0 -optc-std=c++11 -optc-xc++ | ||
ghc-options: -optc-D_GLIBCXX_USE_CXX11_ABI=1 -optc-std=c++11 -optc-xc++ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
-optc-D_GLIBCXX_USE_CXX11_ABI=1
is a default option of gcc.
So we can just remove it to use CXX11_ABI.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks! now I removed them.
@wavewave |
@junjihashimoto Yes. First, I am planning to fully nixify hasktorch and libtorch-ffi (as individual nix package), so it can be easier to be integrated. |
I enabled mkl now but i cannot figure out linking against mklml though, so still commented out mklml linking in libtorch-ffi. Maybe the pytorch packaging in nixpkgs does not yet incorporate mkl-dnn? |
Currently tied up and can't get too in depth, but @wavewave can you check if nix's mkl pulls in mklml/mkldnn? It might need to be added separately. If that is the case you could attempt to just use the older libtorch folder (which just pulls down the zip)? It will have all the binaries, but might not get hooked up correctly - verifiable by running hasktorch tests. |
Oh, also! PyTorch actually generates a caffe python module - could you check those outputs as well? |
@wavewave cool! I’ll try your shell now. |
This PR is subsumed by #164 which packages up hasktorch as a nix package. |
@tscholak oh. the nix packaging was there too. cool. thanks! |
close this PR, and let's unify the effort in #164. |
@stites As for caffe, I found that the following python modules are packaged:
and its C-dependencies
|
@stites As for mkl, basic mkl libraries are packaged but not mklml, mkldnn stuff:
|
@wavewave reading through https://intel.github.io/mkl-dnn/index.html... I don’t think mkldnn is part of mkl at all. |
To make hasktorch buildable simply.
Note: this is not yet finalized since I disabled
mkl
and adjusted C++11 ABI flag. I would like to have some discussion about them.