Issue 1:
🐛 Bug

[1331/2730] Building CXX object caffe2\CMakeFiles\torch_cpu.dir\core\blob_serialization.cc.obj

FAILED: caffe2/CMakeFiles/torch_cpu.dir/core/blob_serialization.cc.obj

C:\PROGRA2\MICROS4\2019\COMMUN1\VC\Tools\MSVC\14241.283\bin\Hostx64\x64\cl.exe /nologo /TP -DAT_PARALLEL_OPENMP=1 -DCPUINFO_SUPPORTED_PLATFORM=1 -DONNX_ML=1 -DONNX_NAMESPACE=onnx_torch -DWIN32_LEAN_AND_MEAN -D_CRT_SECURE_NO_DEPRECATE=1 -Dtorch_cpu_EXPORTS -Iaten\src -I..\aten\src -I. -I..\ -I..\cmake..\third_party\benchmark\include -Icaffe2\contrib\aten -I..\third_party\onnx -Ithird_party\onnx -I..\third_party\foxi -Ithird_party\foxi -I..\caffe2..\torch\csrc\api -I..\caffe2..\torch\csrc\api\include -I..\caffe2\aten\src\TH -Icaffe2\aten\src\TH -I..\caffe2..\torch..\aten\src -Icaffe2\aten\src -Icaffe2..\aten\src -Icaffe2..\aten\src\ATen -I..\caffe2..\torch\csrc -I..\caffe2..\torch..\third_party\miniz-2.0.8 -I..\aten\src\TH -I..\aten..\third_party\catch\single_include -I..\aten\src\ATen.. -Icaffe2\aten\src\ATen -I..\third_party\miniz-2.0.8 -I..\caffe2\core\nomnigraph\include -I..\c10.. -I..\third_party\cpuinfo\include -I..\third_party\FP16\include -I..\cmake..\third_party\googletest\googlemock\include -I..\cmake..\third_party\googletest\googletest\include -I..\third_party\protobuf\src -I..\cmake..\third_party\eigen -ID:\Aanaconda3\include -ID:\Aanaconda3\lib\site-packages\numpy\core\include -I..\cmake..\third_party\pybind11\include -I\opt\rocm\hip\include -I\include -I..\cmake..\third_party\cub -I"C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.1\include" -I..\caffe2 /DWIN32 /D_WINDOWS /GR /w /EHa /MP /bigobj -openmp:experimental -DHAVE_AVX_CPU_DEFINITION -DHAVE_AVX2_CPU_DEFINITION /MD /O2 /Ob2 /w /EHa /MP /bigobj -DCUDA_HAS_FP16=1 -DUSE_GCC_GET_CPUID -DUSE_AVX -DUSE_AVX2 -DTH_HAVE_THREAD /Z7 /EHa /DNOMINMAX /wd4267 /wd4251 /wd4522 /wd4838 /wd4305 /wd4244 /wd4190 /wd4101 /wd4996 /wd4275 /bigobj -O2 -DCAFFE2_BUILD_MAIN_LIB -DONNX_BUILD_MAIN_LIB -std:c++14 /showIncludes /Focaffe2\CMakeFiles\torch_cpu.dir\core\blob_serialization.cc.obj /Fdcaffe2\CMakeFiles\torch_cpu.dir\ /FS -c ..\caffe2\core\blob_serialization.cc

D:\code\Obj_tracking\pytorch\caffe2/core/context_base.h(92): error C2338: CopyToCPU requires fundamental types

..\caffe2\core\blob_serialization.cc(602): note: 查看对正在编译的函数 模板 实例化“void at::BaseContext::CopyToCPUc10::Half(size_t,const T *,T *)”的引用

with

[

T=c10::Half

]

ninja: build stopped: subcommand failed.

-- Building version 1.4.0a0+190dac1

cmake -GNinja -DBUILD_PYTHON=True -DBUILD_TEST=True -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=D:\code\Obj_tracking\pytorch\torch -DCMAKE_PREFIX_PATH=D:\Aanaconda3\Lib\site-packages -DNUMPY_INCLUDE_DIR=D:\Aanaconda3\lib\site-packages\numpy\core\include -DPYTHON_EXECUTABLE=D:\Aanaconda3\python.exe -DPYTHON_INCLUDE_DIR=D:\Aanaconda3\include -DPYTHON_LIBRARY=D:\Aanaconda3/libs/python37.lib -DTORCH_BUILD_VERSION=1.4.0a0+190dac1 -DUSE_NUMPY=True D:\code\Obj_tracking\pytorch

cmake --build . --target install --config Release -- -j 32

Traceback (most recent call last):

File "setup.py", line 755, in

build_deps()

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

cmake=cmake)

File "D:\code\Obj_tracking\pytorch\tools\build_pytorch_libs.py", line 62, in build_caffe2

cmake.build(my_env)

File "D:\code\Obj_tracking\pytorch\tools\setup_helpers\cmake.py", line 337, in build

self.run(build_args, my_env)

File "D:\code\Obj_tracking\pytorch\tools\setup_helpers\cmake.py", line 141, in run

check_call(command, cwd=self.build_dir, env=env)

File "D:\Aanaconda3\lib\subprocess.py", line 347, in check_call

raise CalledProcessError(retcode, cmd)

subprocess.CalledProcessError: Command '['cmake', '--build', '.', '--target', 'install', '--config', 'Release', '--', '-j', '32']' returned non-zero exit status 1.

Here is the build.log

To Reproduce

Steps to reproduce the behavior:

1.git clone --recursive https://github.com/pytorch/pytorch

2.cd pytorch

3.python setup.py install

Expected

behavior

Environment

Collecting environment information...

PyTorch version: N/A

Is debug build: N/A

CUDA used to build PyTorch: N/A

OS: Microsoft Windows 10

GCC version: (MinGW.org GCC-8.2.0-5) 8.2.0

CMake version: version 3.16.0

Python version: 3.7

Is CUDA available: N/A

CUDA runtime version: 10.1.243

GPU models and configuration: GPU 0: GeForce GTX TITAN X

Nvidia driver version: 426.00

cuDNN version: C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.1\bin\cudnn64_7.dll

Versions of relevant libraries:

[pip] numpy==1.16.5

[pip] numpydoc==0.9.1

[conda] blas 1.0 mkl

[conda] mkl 2019.4 245

[conda] mkl-include 2019.4 245

[conda] mkl-service 2.3.0 py37hb782905_0

[conda] mkl_fft 1.0.14 py37h14836fe_0

[conda] mkl_random 1.1.0 py37h675688f_0

Additional context

Issue 2:
🐛 Bug

For some days, I have a broken build on Windows (cf. appended error message)

To Reproduce

Steps to reproduce the behavior:

Pull master, submodules etc.

(Opt.) clear build directory

Build pytorch

Expected behavior

A finishing build

Environment

PyTorch version: N/A

Is debug build: N/A

CUDA used to build PyTorch: N/A

OS: Microsoft Windows 10 Pro

GCC version: Could not collect

CMake version: version 3.16.0

Python version: 3.7

Is CUDA available: N/A

CUDA runtime version: 10.2.89

GPU models and configuration: GPU 0: Quadro M1200

Nvidia driver version: 441.28

cuDNN version: C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.2\bin\cudnn64_7.dll

Versions of relevant libraries:

[pip3] msgpack-numpy==0.4.4.3

[pip3] numpy==1.17.4+mkl

[pip3] numpydoc==0.9.1

[pip3] torch==1.3.1 # I don't know, what this means - my pip call lists the same development version as conda

[pip3] torchvision==0.4.2

[conda] blas 1.0 mkl

[conda] libblas 3.8.0 14_mkl conda-forge

[conda] libcblas 3.8.0 14_mkl conda-forge

[conda] liblapack 3.8.0 14_mkl conda-forge

[conda] liblapacke 3.8.0 14_mkl conda-forge

[conda] mkl 2019.4 245

[conda] mkl-include 2019.4 245

[conda] mkl-service 2.3.0 py37hfa6e2cd_0 conda-forge

[conda] pytorch-sphinx-theme 0.0.24 dev_0

[conda] torch 1.4.0a0+6e145b4 pypi_0 pypi

[conda] torchvision 0.5.0a0+95131de pypi_0 pypi

Additional context

MS Visual Studio got an update lately - maybe the used C++ compiler is worth a check:

Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.24.28314\bin\Hostx64\x64\cl.exe

Error message from build:

[95/995] Building CXX object caffe2\CMakeFiles\torch_cpu.dir\core\blob_serialization.cc.obj
FAILED: caffe2/CMakeFiles/torch_cpu.dir/core/blob_serialization.cc.obj
C:\PROGRA~2\MICROS~2\2019\COMMUN~1\VC\Tools\MSVC\1424~1.283\bin\Hostx64\x64\cl.exe /nologo /TP -DAT_PARALLEL_OPENMP=1 -DCPUINFO_SUPPORTED_PLATFORM=1 -DONNX_ML=1 -DONNX_NAMESPACE=onnx_torch -DTH_BLAS_MK
L -DWIN32_LEAN_AND_MEAN -D_CRT_SECURE_NO_DEPRECATE=1 -D_OPENMP_NOFORCE_MANIFEST -Dtorch_cpu_EXPORTS -Iaten\src -I..\aten\src -I. -I..\ -I..\cmake\..\third_party\benchmark\include -I..\third_party\onnx -
Ithird_party\onnx -I..\third_party\foxi -Ithird_party\foxi -I..\caffe2\..\torch\csrc\api -I..\caffe2\..\torch\csrc\api\include -I..\caffe2\aten\src\TH -Icaffe2\aten\src\TH -I..\caffe2\..\torch\..\aten\s
rc -Icaffe2\aten\src -Icaffe2\..\aten\src -Icaffe2\..\aten\src\ATen -I..\caffe2\..\torch\csrc -I..\caffe2\..\torch\..\third_party\miniz-2.0.8 -I..\aten\src\TH -I..\aten\..\third_party\catch\single_inclu
de -I..\aten\src\ATen\.. -Icaffe2\aten\src\ATen -I..\third_party\miniz-2.0.8 -I..\caffe2\core\nomnigraph\include -I..\c10\.. -I..\third_party\cpuinfo\include -I..\third_party\FP16\include -I..\cmake\..\
third_party\googletest\googlemock\include -I..\cmake\..\third_party\googletest\googletest\include -I..\third_party\protobuf\src -I"C:\Program Files (x86)\IntelSWTools\compilers_and_libraries\windows\mkl
\include" -IV:\bin\scripting\python\conda\envs\pytorch\Library\include -I..\cmake\..\third_party\eigen -IV:\bin\scripting\python\conda\envs\pytorch\include -Iv:\bin\scripting\python\conda\envs\pytorch\l
ib\site-packages\numpy\core\include -I..\torch\include -I..\cmake\..\third_party\cub -I"C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.2\include" -I..\caffe2 /DWIN32 /D_WINDOWS /GR /w /EHa /MP
/bigobj -openmp:experimental -DHAVE_AVX_CPU_DEFINITION -DHAVE_AVX2_CPU_DEFINITION /MD /O2 /Ob2 /w /EHa /MP /bigobj -DCUDA_HAS_FP16=1 -DUSE_GCC_GET_CPUID -DUSE_AVX -DUSE_AVX2 -DTH_HAVE_THREAD /Z7 /EHa
/DNOMINMAX /wd4267 /wd4251 /wd4522 /wd4838 /wd4305 /wd4244 /wd4190 /wd4101 /wd4996 /wd4275 /bigobj -O2 -DCAFFE2_BUILD_MAIN_LIB -DONNX_BUILD_MAIN_LIB -std:c++14 /showIncludes /Focaffe2\CMakeFiles\torch_
cpu.dir\core\blob_serialization.cc.obj /Fdcaffe2\CMakeFiles\torch_cpu.dir\ /FS -c ..\caffe2\core\blob_serialization.cc
V:\src\git\pytorch\src\pytorch\caffe2/core/context_base.h(92): error C2338: CopyToCPU requires fundamental types
..\caffe2\core\blob_serialization.cc(602): note: see reference to function template instantiation 'void at::BaseContext::CopyToCPU<c10::Half>(size_t,const T *,T *)' being compiled
with
[
T=c10::Half
]
[102/995] Building CXX object caffe2\CMakeFiles\torch_cpu.dir\opt\onnxifi_op.cc.obj
ninja: build stopped: subcommand failed.
Traceback (most recent call last):
File "setup.py", line 755, in <module>
build_deps()
File "setup.py", line 316, in build_deps
cmake=cmake)
File "v:\src\git\pytorch\src\pytorch\tools\build_pytorch_libs.py", line 62, in build_caffe2
cmake.build(my_env)
File "v:\src\git\pytorch\src\pytorch\tools\setup_helpers\cmake.py", line 337, in build
self.run(build_args, my_env)
File "v:\src\git\pytorch\src\pytorch\tools\setup_helpers\cmake.py", line 141, in run
check_call(command, cwd=self.build_dir, env=env)
File "v:\bin\scripting\python\conda\envs\pytorch\lib\subprocess.py", line 347, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['cmake', '--build', '.', '--target', 'install', '--config', 'Release', '--', '-j', '8']' returned non-zero exit status 1.
``` `

cc @peterjc123