mirror of
https://github.com/facebookresearch/pytorch3d.git
synced 2025-08-02 03:42:50 +08:00
Cuda 10.2 for builds
Summary: cuda 10.2 location on linux. Also remove unused conda test dependencies. Reviewed By: nikhilaravi Differential Revision: D21176409 fbshipit-source-id: dd3f339a92233ff16877ba76506ddf8f4418715d
This commit is contained in:
parent
4bf30593ff
commit
faf0885811
@ -7,7 +7,7 @@
|
|||||||
# Setup CUDA environment variables, based on CU_VERSION
|
# Setup CUDA environment variables, based on CU_VERSION
|
||||||
#
|
#
|
||||||
# Inputs:
|
# Inputs:
|
||||||
# CU_VERSION (cu92, cu100, cu101)
|
# CU_VERSION (cu92, cu100, cu101, cu102)
|
||||||
# NO_CUDA_PACKAGE (bool)
|
# NO_CUDA_PACKAGE (bool)
|
||||||
# BUILD_TYPE (conda, wheel)
|
# BUILD_TYPE (conda, wheel)
|
||||||
#
|
#
|
||||||
@ -38,7 +38,7 @@ setup_cuda() {
|
|||||||
# Wheel builds need suffixes (but not if they're on OS X, which never has suffix)
|
# Wheel builds need suffixes (but not if they're on OS X, which never has suffix)
|
||||||
if [[ "$BUILD_TYPE" == "wheel" ]] && [[ "$(uname)" != Darwin ]]; then
|
if [[ "$BUILD_TYPE" == "wheel" ]] && [[ "$(uname)" != Darwin ]]; then
|
||||||
# The default CUDA has no suffix
|
# The default CUDA has no suffix
|
||||||
if [[ "$CU_VERSION" != "cu101" ]]; then
|
if [[ "$CU_VERSION" != "cu102" ]]; then
|
||||||
export PYTORCH_VERSION_SUFFIX="+$CU_VERSION"
|
export PYTORCH_VERSION_SUFFIX="+$CU_VERSION"
|
||||||
fi
|
fi
|
||||||
# Match the suffix scheme of pytorch, unless this package does not have
|
# Match the suffix scheme of pytorch, unless this package does not have
|
||||||
@ -51,6 +51,17 @@ setup_cuda() {
|
|||||||
|
|
||||||
# Now work out the CUDA settings
|
# Now work out the CUDA settings
|
||||||
case "$CU_VERSION" in
|
case "$CU_VERSION" in
|
||||||
|
cu102)
|
||||||
|
if [[ "$OSTYPE" == "msys" ]]; then
|
||||||
|
export CUDA_HOME="C:\\Program Files\\NVIDIA GPU Computing Toolkit\\CUDA\\v10.2"
|
||||||
|
else
|
||||||
|
export CUDA_HOME=/usr/local/cuda-10.2/
|
||||||
|
fi
|
||||||
|
export FORCE_CUDA=1
|
||||||
|
# Hard-coding gencode flags is temporary situation until
|
||||||
|
# https://github.com/pytorch/pytorch/pull/23408 lands
|
||||||
|
export NVCC_FLAGS="-gencode=arch=compute_35,code=sm_35 -gencode=arch=compute_50,code=sm_50 -gencode=arch=compute_60,code=sm_60 -gencode=arch=compute_70,code=sm_70 -gencode=arch=compute_75,code=sm_75 -gencode=arch=compute_50,code=compute_50"
|
||||||
|
;;
|
||||||
cu101)
|
cu101)
|
||||||
if [[ "$OSTYPE" == "msys" ]]; then
|
if [[ "$OSTYPE" == "msys" ]]; then
|
||||||
export CUDA_HOME="C:\\Program Files\\NVIDIA GPU Computing Toolkit\\CUDA\\v10.1"
|
export CUDA_HOME="C:\\Program Files\\NVIDIA GPU Computing Toolkit\\CUDA\\v10.1"
|
||||||
@ -233,6 +244,9 @@ setup_conda_cudatoolkit_constraint() {
|
|||||||
export CONDA_CUDATOOLKIT_CONSTRAINT=""
|
export CONDA_CUDATOOLKIT_CONSTRAINT=""
|
||||||
else
|
else
|
||||||
case "$CU_VERSION" in
|
case "$CU_VERSION" in
|
||||||
|
cu102)
|
||||||
|
export CONDA_CUDATOOLKIT_CONSTRAINT="- cudatoolkit >=10.2,<10.3 # [not osx]"
|
||||||
|
;;
|
||||||
cu101)
|
cu101)
|
||||||
export CONDA_CUDATOOLKIT_CONSTRAINT="- cudatoolkit >=10.1,<10.2 # [not osx]"
|
export CONDA_CUDATOOLKIT_CONSTRAINT="- cudatoolkit >=10.1,<10.2 # [not osx]"
|
||||||
;;
|
;;
|
||||||
|
@ -41,12 +41,7 @@ test:
|
|||||||
- tests
|
- tests
|
||||||
- docs
|
- docs
|
||||||
requires:
|
requires:
|
||||||
- pytest
|
|
||||||
- scipy
|
|
||||||
- mock
|
|
||||||
- av
|
|
||||||
- ca-certificates
|
- ca-certificates
|
||||||
- typing
|
|
||||||
commands:
|
commands:
|
||||||
#pytest .
|
#pytest .
|
||||||
python -m unittest discover -v -s tests
|
python -m unittest discover -v -s tests
|
||||||
|
Loading…
x
Reference in New Issue
Block a user