Skip to content

Commit

Permalink
Patch torch source instead
Browse files Browse the repository at this point in the history
  • Loading branch information
HGuillemet committed Aug 18, 2024
1 parent 1f7407c commit cc8680f
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 3 deletions.
4 changes: 2 additions & 2 deletions .github/actions/deploy-macosx/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@ runs:
fi
brew uninstall --force --ignore-dependencies gcc gcc@7 gcc@8 gcc@9 gcc@10 gcc@11 gcc@12 gcc@13 gcc@14 little-cms2 maven openblas r
brew install boost ccache swig autoconf-archive automake cmake libomp libtool libusb ant nasm xz pkg-config sdl2 gpg1 bison flex perl ragel binutils gmp isl libmpc mpfr geoip pcre ssdeep yajl
brew install --ignore-dependencies gradle # Don't try to overwrite Apple-provided Python
brew install boost ccache swig autoconf-archive automake cmake libomp libtool libusb ant nasm xz pkg-config sdl2 gpg1 bison flex perl ragel binutils gradle gmp isl libmpc mpfr geoip pcre ssdeep yajl
# echo Installing an older less buggy version of CMake
# curl -LO https://raw.githubusercontent.com/Homebrew/homebrew-core/30a3e5e02420a515f9bad02e3cfcde95316db529/Formula/cmake.rb
# brew unlink cmake
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pytorch.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ jobs:
steps:
- uses: HGuillemet/javacpp-presets/.github/actions/deploy-macosx@hg_pytorch
macosx-x86_64:
runs-on: macos-13
runs-on: macos-12
steps:
- uses: HGuillemet/javacpp-presets/.github/actions/deploy-macosx@hg_pytorch
windows-x86_64:
Expand Down
5 changes: 5 additions & 0 deletions pytorch/cppbuild.sh
Original file line number Diff line number Diff line change
Expand Up @@ -206,6 +206,11 @@ sedinplace 's/char(\(.*\))/\1/g' torch/csrc/jit/serialization/pickler.h
# some windows header defines a macro named "interface"
sedinplace 's/const std::string& interface)/const std::string\& interface_name)/g' torch/csrc/distributed/c10d/ProcessGroupGloo.hpp

# fix missing #include (Pytorch 2.4.0)
sedinplace 's/#include <stdexcept>/#include <stdexcept>\
#include <vector>\
#include <unordered_map>/' torch/csrc/distributed/c10d/control_plane/Handlers.cpp

# Remove pytorch adaptations of FindOpenMP.cmake that.
# On Windows without iomp and with new versions of VS 2019, including -openmp:experimental and libomp, causes
# final binary to be linked to both libomp and vcomp and produce incorrect results.
Expand Down

0 comments on commit cc8680f

Please sign in to comment.