Issue 1:
-- Building version 1.1.0a0+562fa55

make: *** No rule to make target 'install'. Stop.

Traceback (most recent call last):

File "setup.py", line 734, in

build_deps()

File "setup.py", line 281, in build_deps

build_dir='build')

File "/home/simon/Downloads/pytorch/tools/build_pytorch_libs.py", line 255, in build_caffe2

check_call(['make', '-j', str(max_jobs), 'install'], cwd=build_dir, env=my_env)

File "/usr/lib/python3.6/subprocess.py", line 291, in check_call

raise CalledProcessError(retcode, cmd)

subprocess.CalledProcessError: Command '['make', '-j', '8', 'install']' returned non-zero exit status 2.

simon@localhost:/Downloads/pytorch$ ls

CITATION aten modules test

CMakeLists.txt binaries mypy-README.md third_party

CODEOWNERS build mypy-files.txt tools

CONTRIBUTING.md c10 mypy.ini torch

LICENSE caffe2 requirements.txt ubsan.supp

Makefile cmake scripts

NOTICE docker setup.py

README.md docs submodules

simon@localhost:/Downloads/pytorch$ rm -rf build

simon@localhost:~/Downloads/pytorch$ python setup.py installBuilding wheel torch-1.1.0a0+562fa55

-- Building version 1.1.0a0+562fa55

['cmake',

'/home/simon/Downloads/pytorch',

'-DBUILDING_WITH_TORCH_LIBS=ON',

'-DBUILD_BINARY=False',

'-DBUILD_CAFFE2_OPS=True',

'-DBUILD_PYTHON=True',

'-DBUILD_SHARED_LIBS=ON',

'-DBUILD_TEST=True',

'-DBUILD_TORCH=ON',

'-DCAFFE2_STATIC_LINK_CUDA=False',

'-DCMAKE_BUILD_TYPE=Release',

'-DCMAKE_CXX_FLAGS= ',

'-DCMAKE_C_FLAGS= ',

'-DCMAKE_EXE_LINKER_FLAGS=',

'-DCMAKE_INSTALL_PREFIX=/home/simon/Downloads/pytorch/torch',

'-DCMAKE_PREFIX_PATH=/usr/lib/python3/dist-packages',

'-DCMAKE_SHARED_LINKER_FLAGS=',

'-DINSTALL_TEST=True',

'-DNCCL_EXTERNAL=False',

'-DNUMPY_INCLUDE_DIR=/usr/lib/python3/dist-packages/numpy/core/include',

'-DONNX_ML=False',

'-DONNX_NAMESPACE=onnx_torch',

'-DPYTHON_EXECUTABLE=/usr/local/bin/python3',

'-DPYTHON_INCLUDE_DIR=/usr/include/python3.6m',

'-DPYTHON_LIBRARY=/usr/lib/libpython3.6m.so.1.0',

'-DTHD_SO_VERSION=1',

'-DTORCH_BUILD_VERSION=1.1.0a0+562fa55',

'-DUSE_CUDA=False',

'-DUSE_DISTRIBUTED=True',

'-DUSE_FBGEMM=True',

'-DUSE_FFMPEG=False',

'-DUSE_LEVELDB=False',

'-DUSE_LMDB=False',

'-DUSE_MKLDNN=False',

'-DUSE_NCCL=False',

'-DUSE_NNPACK=True',

'-DUSE_NUMPY=True',

'-DUSE_OPENCV=False',

'-DUSE_QNNPACK=True',

'-DUSE_ROCM=False',

'-DUSE_SYSTEM_EIGEN_INSTALL=OFF',

'-DUSE_SYSTEM_NCCL=False',

'-DUSE_TENSORRT=False']

{'HOME': '/home/simon',

'LESSCLOSE': '/usr/bin/lesspipe %s %s',

'LESSOPEN': '| /usr/bin/lesspipe %s',

'LIBGL_ALWAYS_SOFTWARE': '1',

'LOGNAME': 'simon',

'LS_COLORS': 'rs=0:di=01;34:ln=01;36:mh=00:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:mi=00:su=37;41:sg=30;43:ca=30;41:tw=30;42:ow=34;42:st=37;44:ex=01;32:.tar=01;31:.tgz=01;31:.arc=01;31:.arj=01;31:.taz=01;31:.lha=01;31:.lz4=01;31:.lzh=01;31:.lzma=01;31:.tlz=01;31:.txz=01;31:.tzo=01;31:.t7z=01;31:.zip=01;31:.z=01;31:.Z=01;31:.dz=01;31:.gz=01;31:.lrz=01;31:.lz=01;31:.lzo=01;31:.xz=01;31:.zst=01;31:.tzst=01;31:.bz2=01;31:.bz=01;31:.tbz=01;31:.tbz2=01;31:.tz=01;31:.deb=01;31:.rpm=01;31:.jar=01;31:.war=01;31:.ear=01;31:.sar=01;31:.rar=01;31:.alz=01;31:.ace=01;31:.zoo=01;31:.cpio=01;31:.7z=01;31:.rz=01;31:.cab=01;31:.wim=01;31:.swm=01;31:.dwm=01;31:.esd=01;31:.jpg=01;35:.jpeg=01;35:.mjpg=01;35:.mjpeg=01;35:.gif=01;35:.bmp=01;35:.pbm=01;35:.pgm=01;35:.ppm=01;35:.tga=01;35:.xbm=01;35:.xpm=01;35:.tif=01;35:.tiff=01;35:.png=01;35:.svg=01;35:.svgz=01;35:.mng=01;35:.pcx=01;35:.mov=01;35:.mpg=01;35:.mpeg=01;35:.m2v=01;35:.mkv=01;35:.webm=01;35:.ogm=01;35:.mp4=01;35:.m4v=01;35:.mp4v=01;35:.vob=01;35:.qt=01;35:.nuv=01;35:.wmv=01;35:.asf=01;35:.rm=01;35:.rmvb=01;35:.flc=01;35:.avi=01;35:.fli=01;35:.flv=01;35:.gl=01;35:.dl=01;35:.xcf=01;35:.xwd=01;35:.yuv=01;35:.cgm=01;35:.emf=01;35:.ogv=01;35:.ogx=01;35:.aac=00;36:.au=00;36:.flac=00;36:.m4a=00;36:.mid=00;36:.midi=00;36:.mka=00;36:.mp3=00;36:.mpc=00;36:.ogg=00;36:.ra=00;36:.wav=00;36:.oga=00;36:.opus=00;36:.spx=00;36:.xspf=00;36:',

'OLDPWD': '/home/simon/Downloads',

'PATH': '/home/simon/.local/bin:/home/simon/miniconda3:/home/simon/miniconda3/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games',

'PWD': '/home/simon/Downloads/pytorch',

'SHELL': '/bin/bash',

'SHLVL': '1',

'SSH_AUTH_SOCK': '/tmp/dropbear-6acaa863/auth-74992dd7-6',

'SSH_CLIENT': '127.0.0.1 43280 2022',

'SSH_CONNECTION': '127.0.0.1 43280 127.0.0.1 2022',

'SSH_TTY': '/dev/pts/0',

'TERM': 'linux',

'USER': 'simon',

'XDG_DATA_DIRS': '/usr/local/share:/usr/share:/var/lib/snapd/desktop',

'_': '/usr/local/bin/python3'}

-- The CXX compiler identification is GNU 7.3.0

-- The C compiler identification is GNU 7.3.0

-- Check for working CXX compiler: /usr/bin/c++

-- Check for working CXX compiler: /usr/bin/c++ -- works

-- Detecting CXX compiler ABI info

-- Detecting CXX compiler ABI info - done

-- Detecting CXX compile features

-- Detecting CXX compile features - done

-- Check for working C compiler: /usr/bin/cc

-- Check for working C compiler: /usr/bin/cc -- works

-- Detecting C compiler ABI info

-- Detecting C compiler ABI info - done

-- Detecting C compile features

-- Detecting C compile features - done

-- Not forcing any particular BLAS to be found

-- Performing Test CAFFE2_EXCEPTION_PTR_SUPPORTED

-- Performing Test CAFFE2_EXCEPTION_PTR_SUPPORTED - Success

-- std::exception_ptr is supported.

-- NUMA is disabled

-- Performing Test CAFFE2_NEED_TO_TURN_OFF_DEPRECATION_WARNING

-- Performing Test CAFFE2_NEED_TO_TURN_OFF_DEPRECATION_WARNING - Failed

-- Turning off deprecation warning due to glog.

-- Performing Test CAFFE2_COMPILER_SUPPORTS_AVX2_EXTENSIONS

-- Performing Test CAFFE2_COMPILER_SUPPORTS_AVX2_EXTENSIONS - Failed

-- Performing Test CAFFE2_COMPILER_SUPPORTS_AVX512_EXTENSIONS

-- Performing Test CAFFE2_COMPILER_SUPPORTS_AVX512_EXTENSIONS - Failed

-- Performing Test COMPILER_SUPPORTS_HIDDEN_VISIBILITY

-- Performing Test COMPILER_SUPPORTS_HIDDEN_VISIBILITY - Success

-- Performing Test COMPILER_SUPPORTS_HIDDEN_INLINE_VISIBILITY

-- Performing Test COMPILER_SUPPORTS_HIDDEN_INLINE_VISIBILITY - Success

-- Performing Test COMPILER_SUPPORTS_RDYNAMIC

-- Performing Test COMPILER_SUPPORTS_RDYNAMIC - Success

-- Looking for pthread.h

-- Looking for pthread.h - found

-- Looking for pthread_create

-- Looking for pthread_create - not found

-- Looking for pthread_create in pthreads

-- Looking for pthread_create in pthreads - not found

-- Looking for pthread_create in pthread

-- Looking for pthread_create in pthread - found

-- Found Threads: TRUE

CMake Warning at cmake/public/protobuf.cmake:88 (message):

Protobuf cannot be found. Depending on whether you are building Caffe2 or

a Caffe2 dependent library, the next warning / error will give you more

info.

Call Stack (most recent call first):

cmake/ProtoBuf.cmake:97 (include)

cmake/Dependencies.cmake:40 (include)

CMakeLists.txt:224 (include)

CMake Warning at cmake/ProtoBuf.cmake:101 (message):

Protobuf cannot be found. Caffe2 will automatically switch to use own

protobuf under third_party. Note that this behavior may change in the

future, and you will need to specify -DBUILD_CUSTOM_PROTOBUF=ON explicitly.

Call Stack (most recent call first):

cmake/Dependencies.cmake:40 (include)

CMakeLists.txt:224 (include)

-- Use custom protobuf build.

-- Caffe2 protobuf include directory: $&lt;BUILD_INTERFACE:/home/simon/Downloads/pytorch/third_party/protobuf/src&gt;$&lt;INSTALL_INTERFACE:include>

-- Trying to find preferred BLAS backend of choice: Eigen

-- The ASM compiler identification is GNU

-- Found assembler: /usr/bin/cc

-- Check if compiler accepts -pthread

-- Check if compiler accepts -pthread - yes

CMake Error at third_party/QNNPACK/CMakeLists.txt:326 (ADD_SUBDIRECTORY):

The source directory

/home/simon/Downloads/pytorch/third_party/psimd

does not contain a CMakeLists.txt file.

CMake Error at third_party/QNNPACK/CMakeLists.txt:336 (ADD_SUBDIRECTORY):

The source directory

/home/simon/Downloads/pytorch/third_party/FP16

does not contain a CMakeLists.txt file.

-- Brace yourself, we are building NNPACK

CMake Error at cmake/External/nnpack.cmake:68 (add_subdirectory):

The source directory

/home/simon/Downloads/pytorch/third_party/NNPACK

does not contain a CMakeLists.txt file.

Call Stack (most recent call first):

cmake/Dependencies.cmake:251 (include)

CMakeLists.txt:224 (include)

CMake Error at cmake/External/nnpack.cmake:73 (set_property):

set_property could not find TARGET nnpack. Perhaps it has not yet been

created.

Call Stack (most recent call first):

cmake/Dependencies.cmake:251 (include)

CMakeLists.txt:224 (include)

-- Found PythonInterp: /usr/local/bin/python3 (found version "3.6.7")

-- Found Git: /usr/bin/git (found version "2.17.1")

-- git Version: v1.4.0-505be96a

-- Version: 1.4.0

-- Performing Test HAVE_CXX_FLAG_STD_CXX11

-- Performing Test HAVE_CXX_FLAG_STD_CXX11 - Success

-- Performing Test HAVE_CXX_FLAG_WALL

-- Performing Test HAVE_CXX_FLAG_WALL - Success

-- Performing Test HAVE_CXX_FLAG_WEXTRA

-- Performing Test HAVE_CXX_FLAG_WEXTRA - Success

-- Performing Test HAVE_CXX_FLAG_WSHADOW

-- Performing Test HAVE_CXX_FLAG_WSHADOW - Success

-- Performing Test HAVE_CXX_FLAG_WERROR

-- Performing Test HAVE_CXX_FLAG_WERROR - Success

-- Performing Test HAVE_CXX_FLAG_PEDANTIC

-- Performing Test HAVE_CXX_FLAG_PEDANTIC - Success

-- Performing Test HAVE_CXX_FLAG_PEDANTIC_ERRORS

-- Performing Test HAVE_CXX_FLAG_PEDANTIC_ERRORS - Success

-- Performing Test HAVE_CXX_FLAG_WSHORTEN_64_TO_32

-- Performing Test HAVE_CXX_FLAG_WSHORTEN_64_TO_32 - Failed

-- Performing Test HAVE_CXX_FLAG_WFLOAT_EQUAL

-- Performing Test HAVE_CXX_FLAG_WFLOAT_EQUAL - Success

-- Performing Test HAVE_CXX_FLAG_FSTRICT_ALIASING

-- Performing Test HAVE_CXX_FLAG_FSTRICT_ALIASING - Success

-- Performing Test HAVE_CXX_FLAG_WNO_DEPRECATED_DECLARATIONS-- Performing Test HAVE_CXX_FLAG_WNO_DEPRECATED_DECLARATIONS - Success

-- Performing Test HAVE_CXX_FLAG_WSTRICT_ALIASING

-- Performing Test HAVE_CXX_FLAG_WSTRICT_ALIASING - Success

-- Performing Test HAVE_CXX_FLAG_WD654

-- Performing Test HAVE_CXX_FLAG_WD654 - Failed

-- Performing Test HAVE_CXX_FLAG_WTHREAD_SAFETY

-- Performing Test HAVE_CXX_FLAG_WTHREAD_SAFETY - Failed

-- Performing Test HAVE_CXX_FLAG_COVERAGE

-- Performing Test HAVE_CXX_FLAG_COVERAGE - Success

-- Performing Test HAVE_STD_REGEX

-- Performing Test HAVE_STD_REGEX

-- Performing Test HAVE_STD_REGEX -- success

-- Performing Test HAVE_GNU_POSIX_REGEX

-- Performing Test HAVE_GNU_POSIX_REGEX

-- Performing Test HAVE_GNU_POSIX_REGEX -- failed to compile-- Performing Test HAVE_POSIX_REGEX

-- Performing Test HAVE_POSIX_REGEX

-- Performing Test HAVE_POSIX_REGEX -- success

-- Performing Test HAVE_STEADY_CLOCK

-- Performing Test HAVE_STEADY_CLOCK

-- Performing Test HAVE_STEADY_CLOCK -- success

CMake Warning at cmake/Dependencies.cmake:362 (message):

A compiler with AVX512 support is required for FBGEMM. Not compiling with

FBGEMM. Turn this warning off by USE_FBGEMM=OFF.

Call Stack (most recent call first):

CMakeLists.txt:224 (include)

CMake Error at cmake/Dependencies.cmake:520 (add_subdirectory):

The source directory

/home/simon/Downloads/pytorch/third_party/FP16

does not contain a CMakeLists.txt file.

Call Stack (most recent call first):

CMakeLists.txt:224 (include)

-- Using third party subdirectory Eigen.

Python 3.6.7

-- Found PythonInterp: /usr/local/bin/python3 (found suitable version "3.6.7", minimum required is "2.7")

-- Found PythonLibs: /usr/lib/libpython3.6m.so.1.0 (found suitable version "3.6.7", minimum required is "2.7")

-- Could NOT find pybind11 (missing: pybind11_DIR)

-- Could NOT find pybind11 (missing: pybind11_INCLUDE_DIR)

-- Using third_party/pybind11.

-- Could NOT find MPI_C (missing: MPI_C_LIB_NAMES MPI_C_HEADER_DIR MPI_C_WORKS)

-- Could NOT find MPI_CXX (missing: MPI_CXX_LIB_NAMES MPI_CXX_HEADER_DIR MPI_CXX_WORKS)

-- Could NOT find MPI (missing: MPI_C_FOUND MPI_CXX_FOUND)

CMake Warning at cmake/Dependencies.cmake:670 (message):

Not compiling with MPI. Suppress this warning with -DUSE_MPI=OFF

Call Stack (most recent call first):

CMakeLists.txt:224 (include)

--

-- ******** Summary ********

-- CMake version : 3.10.2

-- CMake command : /usr/bin/cmake

-- System : Linux

-- C++ compiler : /usr/bin/c++

-- C++ compiler version : 7.3.0

-- CXX flags : -Wno-deprecated -fvisibility-inlines-hidden -Wnon-virtual-dtor

-- Build type : Release

-- Compile definitions :

-- CMAKE_PREFIX_PATH : /usr/lib/python3/dist-packages

-- CMAKE_INSTALL_PREFIX : /home/simon/Downloads/pytorch/torch

-- CMAKE_MODULE_PATH : /home/simon/Downloads/pytorch/cmake/Modules

-- ONNX version : 1.4.1

-- ONNX NAMESPACE : onnx_torch

-- ONNX_BUILD_TESTS : OFF

-- ONNX_BUILD_BENCHMARKS : OFF

-- ONNX_USE_LITE_PROTO : OFF

-- ONNXIFI_DUMMY_BACKEND : OFF

-- ONNXIFI_ENABLE_EXT : OFF

-- Protobuf compiler : Protobuf_PROTOC_EXECUTABLE-NOTFOUND

-- Protobuf includes :

-- Protobuf libraries : Protobuf_LIBRARY-NOTFOUND;-lpthread

-- BUILD_ONNX_PYTHON : OFF

-- GCC 7.3.0: Adding gcc and gcc_s libs to link line

-- don't use NUMA

-- pytorch is compiling with OpenMP.

OpenMP CXX_FLAGS: -fopenmp.

OpenMP libraries: /usr/lib/gcc/aarch64-linux-gnu/7/libgomp.so;/usr/lib/aarch64-linux-gnu/libpthread.so.

-- /usr/bin/c++ /home/simon/Downloads/pytorch/torch/abi-check.cpp -o /home/simon/Downloads/pytorch/build/abi-check

-- Determined _GLIBCXX_USE_CXX11_ABI=1

-- Performing Test HAS_THREAD_LOCAL

-- Performing Test HAS_THREAD_LOCAL - Success

-- Could NOT find MPI_C (missing: MPI_C_LIB_NAMES MPI_C_HEADER_DIR MPI_C_WORKS)

-- Could NOT find MPI_CXX (missing: MPI_CXX_LIB_NAMES MPI_CXX_HEADER_DIR MPI_CXX_WORKS)

-- Could NOT find MPI (missing: MPI_C_FOUND MPI_CXX_FOUND)

-- ignoring CUDA

-- Building C10D without CUDA support

-- Could NOT find MPI_C (missing: MPI_C_LIB_NAMES MPI_C_HEADER_DIR MPI_C_WORKS)

-- Could NOT find MPI_CXX (missing: MPI_CXX_LIB_NAMES MPI_CXX_HEADER_DIR MPI_CXX_WORKS)

-- Could NOT find MPI (missing: MPI_C_FOUND MPI_CXX_FOUND)

-- Not able to find MPI, will compile c10d without MPI support

-- Looking for clock_gettime in rt

-- Looking for clock_gettime in rt - found

-- NCCL operators skipped due to no CUDA support

-- Excluding ideep operators as we are not using ideep

-- Excluding image processing operators due to no opencv

-- Excluding video processing operators due to no opencv

-- MPI operators skipped due to no MPI support

-- Include Observer library

-- Using lib/python3/dist-packages as python relative installation path

CMake Warning at CMakeLists.txt:421 (message):

Generated cmake files are only fully tested if one builds with system glog,

gflags, and protobuf. Other settings may generate files that are not well

tested.

--

-- ******** Summary ********

-- General:

-- CMake version : 3.10.2

-- CMake command : /usr/bin/cmake

-- System : Linux

-- C++ compiler : /usr/bin/c++

-- C++ compiler id : GNU

-- C++ compiler version : 7.3.0

-- BLAS : Eigen

-- CXX flags : -Wno-deprecated -fvisibility-inlines-hidden -O2 -fPIC -Wno-narrowing -Wall -Wextra -Wno-missing-field-initializers -Wno-type-limits -Wno-array-bounds -Wno-unknown-pragmas -Wno-sign-compare -Wno-unused-parameter -Wno-unused-variable -Wno-unused-function -Wno-unused-result -Wno-strict-overflow -Wno-strict-aliasing -Wno-error=deprecated-declarations -Wno-stringop-overflow -Wno-error=pedantic -Wno-error=redundant-decls -Wno-error=old-style-cast -faligned-new -Wno-unused-but-set-variable -Wno-maybe-uninitialized -Wno-stringop-overflow

-- Build type : Release

-- Compile definitions : ONNX_NAMESPACE=onnx_torch

-- CMAKE_PREFIX_PATH : /usr/lib/python3/dist-packages

-- CMAKE_INSTALL_PREFIX : /home/simon/Downloads/pytorch/torch

-- TORCH_VERSION : 1.1.0

-- CAFFE2_VERSION : 1.1.0

-- BUILD_ATEN_MOBILE : ON

-- BUILD_ATEN_ONLY : OFF

-- BUILD_BINARY : False

-- BUILD_CUSTOM_PROTOBUF : OFF

-- Protobuf compiler : Protobuf_PROTOC_EXECUTABLE-NOTFOUND

-- Protobuf includes :

-- Protobuf libraries : Protobuf_LIBRARY-NOTFOUND;-lpthread

-- BUILD_DOCS : OFF

-- BUILD_PYTHON : True

-- Python version : 3.6.7

-- Python executable : /usr/local/bin/python3

-- Pythonlibs version : 3.6.7

-- Python library : /usr/lib/libpython3.6m.so.1.0

-- Python includes : /usr/include/python3.6m

-- Python site-packages: lib/python3/dist-packages

-- BUILD_CAFFE2_OPS : True

-- BUILD_SHARED_LIBS : ON

-- BUILD_TEST : True

-- USE_ASAN : OFF

-- USE_CUDA : False

-- USE_ROCM : False

-- USE_EIGEN_FOR_BLAS : ON

-- USE_FBGEMM : OFF

-- USE_FFMPEG : False

-- USE_GFLAGS : OFF

-- USE_GLOG : OFF

-- USE_LEVELDB : False

-- USE_LITE_PROTO : OFF

-- USE_LMDB : False

-- USE_METAL : OFF

-- USE_MKL :

-- USE_MKLDNN :

-- USE_NCCL : False

-- USE_NNPACK : True

-- USE_NUMPY : ON

-- USE_OBSERVERS : ON

-- USE_OPENCL : OFF

-- USE_OPENCV : False

-- USE_OPENMP : OFF

-- USE_PROF : OFF

-- USE_QNNPACK : True

-- USE_REDIS : OFF

-- USE_ROCKSDB : OFF

-- USE_ZMQ : OFF

-- USE_DISTRIBUTED : True

-- USE_MPI : OFF

-- USE_GLOO : ON

-- USE_GLOO_IBVERBS : OFF

-- Public Dependencies : Threads::Threads

-- Private Dependencies : qnnpack;cpuinfo;fp16;gloo;onnxifi_loader;gcc_s;gcc;dl

-- Configuring incomplete, errors occurred!

See also "/home/simon/Downloads/pytorch/build/CMakeFiles/CMakeOutput.log".

See also "/home/simon/Downloads/pytorch/build/CMakeFiles/CMakeError.log".

Traceback (most recent call last):

File "setup.py", line 734, in

build_deps()

File "setup.py", line 281, in build_deps

build_dir='build')

File "/home/simon/Downloads/pytorch/tools/build_pytorch_libs.py", line 235, in build_caffe2

my_env)

File "/home/simon/Downloads/pytorch/tools/build_pytorch_libs.py", line 215, in run_cmake

check_call(cmake_args, cwd=build_dir, env=my_env)

File "/usr/lib/python3.6/subprocess.py", line 291, in check_call

raise CalledProcessError(retcode, cmd)

subprocess.CalledProcessError: Command '['cmake', '/home/simon/Downloads/pytorch', '-DBUILDING_WITH_TORCH_LIBS=ON', '-DBUILD_BINARY=False', '-DBUILD_CAFFE2_OPS=True', '-DBUILD_PYTHON=True', '-DBUILD_SHARED_LIBS=ON', '-DBUILD_TEST=True', '-DBUILD_TORCH=ON', '-DCAFFE2_STATIC_LINK_CUDA=False', '-DCMAKE_BUILD_TYPE=Release', '-DCMAKE_CXX_FLAGS= ', '-DCMAKE_C_FLAGS= ', '-DCMAKE_EXE_LINKER_FLAGS=', '-DCMAKE_INSTALL_PREFIX=/home/simon/Downloads/pytorch/torch', '-DCMAKE_PREFIX_PATH=/usr/lib/python3/dist-packages', '-DCMAKE_SHARED_LINKER_FLAGS=', '-DINSTALL_TEST=True', '-DNCCL_EXTERNAL=False', '-DNUMPY_INCLUDE_DIR=/usr/lib/python3/dist-packages/numpy/core/include', '-DONNX_ML=False', '-DONNX_NAMESPACE=onnx_torch', '-DPYTHON_EXECUTABLE=/usr/local/bin/python3', '-DPYTHON_INCLUDE_DIR=/usr/include/python3.6m', '-DPYTHON_LIBRARY=/usr/lib/libpython3.6m.so.1.0', '-DTHD_SO_VERSION=1', '-DTORCH_BUILD_VERSION=1.1.0a0+562fa55', '-DUSE_CUDA=False', '-DUSE_DISTRIBUTED=True', '-DUSE_FBGEMM=True', '-DUSE_FFMPEG=False', '-DUSE_LEVELDB=False', '-DUSE_LMDB=False', '-DUSE_MKLDNN=False', '-DUSE_NCCL=False', '-DUSE_NNPACK=True', '-DUSE_NUMPY=True', '-DUSE_OPENCV=False', '-DUSE_QNNPACK=True', '-DUSE_ROCM=False', '-DUSE_SYSTEM_EIGEN_INSTALL=OFF', '-DUSE_SYSTEM_NCCL=False', '-DUSE_TENSORRT=False']' returned non-zero exit status 1.

Issue 2:
🚀 Feature

Hey folks, I think the best path forward if you want to truly support mobile production environments is to make it easier to allow people to compile libtorch such that it can be used with Android Studio's NDK.

Right now, given the current state of things, I'm forced to fall back on the protobuf, caffe2 solution. I do understand that things are still unstable & a work in progress.

Motivation

Current shared/static libs offered in the docs are pre-built for specific architectures & thereby do not allow you to utilize libtorch on a robust set of production devices easily in the real-world.

For example, in my case, I can't run libtorch even a rooted Android phone because the architecture (aarch64) still has differences in compilation due to the OS/ABI I suspect. The NDK has invested in solving this for developers already via a fairly robust toolchain. It's not obvious how to build pytorch via it & then utilize those various static/shared libs to compile with the NDK.

Additionally, it's not simple to just compile libtorch on an arm64 machine and run the binary on the phone.

Pitch

NDK support will dramatically reduce the numerous pipeline of tools required for a mobile production environment.

This will also help people who do not have the priviledge of developing on a rooted phone & enable fast, client-side inference.

Alternatives

pytorch -> export to onnx -> caffe2 -> Write C++ w/ NDK -> Java