Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
vision
Commits
60e2fdc1
Unverified
Commit
60e2fdc1
authored
Oct 25, 2021
by
Prabhat Roy
Committed by
GitHub
Oct 25, 2021
Browse files
Removed unnecessary if from setup.py (#4739)
* Removed unnecessary if from setup.py * Removed empty line
parent
dc113995
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
2 deletions
+1
-2
setup.py
setup.py
+1
-2
No files found.
setup.py
View file @
60e2fdc1
...
@@ -143,7 +143,7 @@ def get_extensions():
...
@@ -143,7 +143,7 @@ def get_extensions():
if
torch
.
__version__
>=
"1.5"
:
if
torch
.
__version__
>=
"1.5"
:
from
torch.utils.cpp_extension
import
ROCM_HOME
from
torch.utils.cpp_extension
import
ROCM_HOME
is_rocm_pytorch
=
True
if
(
(
torch
.
version
.
hip
is
not
None
)
and
(
ROCM_HOME
is
not
None
)
)
else
False
is_rocm_pytorch
=
(
torch
.
version
.
hip
is
not
None
)
and
(
ROCM_HOME
is
not
None
)
if
is_rocm_pytorch
:
if
is_rocm_pytorch
:
from
torch.utils.hipify
import
hipify_python
from
torch.utils.hipify
import
hipify_python
...
@@ -159,7 +159,6 @@ def get_extensions():
...
@@ -159,7 +159,6 @@ def get_extensions():
# Copy over additional files
# Copy over additional files
for
file
in
glob
.
glob
(
r
"torchvision/csrc/ops/cuda/*.h"
):
for
file
in
glob
.
glob
(
r
"torchvision/csrc/ops/cuda/*.h"
):
shutil
.
copy
(
file
,
"torchvision/csrc/ops/hip"
)
shutil
.
copy
(
file
,
"torchvision/csrc/ops/hip"
)
else
:
else
:
source_cuda
=
glob
.
glob
(
os
.
path
.
join
(
extensions_dir
,
"ops"
,
"cuda"
,
"*.cu"
))
source_cuda
=
glob
.
glob
(
os
.
path
.
join
(
extensions_dir
,
"ops"
,
"cuda"
,
"*.cu"
))
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment