Skip to content

Commit f6aaacc

Browse files
committed
only cpu fix
1 parent 5f91370 commit f6aaacc

File tree

2 files changed

+10
-8
lines changed

2 files changed

+10
-8
lines changed

.travis.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ sudo: required
33
dist: trusty
44
matrix:
55
include:
6+
- python: 2.7
67
- python: 3.5
78
- python: 3.6
89
addons:
@@ -16,6 +17,7 @@ before_install:
1617
- export CC="gcc-4.9"
1718
- export CXX="g++-4.9"
1819
install:
20+
- if [[ $TRAVIS_PYTHON_VERSION == 2.7 ]]; then pip install https://download.pytorch.org/whl/cpu/torch-1.0.0-cp27-cp27mu-linux_x86_64.whl; fi
1921
- if [[ $TRAVIS_PYTHON_VERSION == 3.5 ]]; then pip install https://download.pytorch.org/whl/cpu/torch-1.0.0-cp35-cp35m-linux_x86_64.whl; fi
2022
- if [[ $TRAVIS_PYTHON_VERSION == 3.6 ]]; then pip install https://download.pytorch.org/whl/cpu/torch-1.0.0-cp36-cp36m-linux_x86_64.whl; fi
2123
- pip install pycodestyle

setup.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,8 @@
33
import torch
44
from torch.utils.cpp_extension import CppExtension, CUDAExtension, CUDA_HOME
55

6-
__version__ = '0.3.0'
7-
url = 'https://github.com/rusty1s/pytorch_sparse'
8-
9-
install_requires = ['scipy']
10-
setup_requires = ['pytest-runner']
11-
tests_require = ['pytest', 'pytest-cov']
126
ext_modules = [CppExtension('torch_sparse.spspmm_cpu', ['cpu/spspmm.cpp'])]
13-
cmdclass = {}
7+
cmdclass = {'build_ext': torch.utils.cpp_extension.BuildExtension}
148

159
if CUDA_HOME is not None:
1610
if platform.system() == 'Windows':
@@ -26,7 +20,13 @@
2620
CUDAExtension('torch_sparse.unique_cuda',
2721
['cuda/unique.cpp', 'cuda/unique_kernel.cu']),
2822
]
29-
cmdclass['build_ext'] = torch.utils.cpp_extension.BuildExtension
23+
24+
__version__ = '0.3.0'
25+
url = 'https://github.com/rusty1s/pytorch_sparse'
26+
27+
install_requires = ['scipy']
28+
setup_requires = ['pytest-runner']
29+
tests_require = ['pytest', 'pytest-cov']
3030

3131
setup(
3232
name='torch_sparse',

0 commit comments

Comments
 (0)