Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
seminar-breakout
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Shashank Suhas
seminar-breakout
Commits
e9326105
Commit
e9326105
authored
Jul 31, 2017
by
Yuxin Wu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix build
parent
7ae014f1
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
6 deletions
+4
-6
tensorpack/libinfo.py
tensorpack/libinfo.py
+4
-6
No files found.
tensorpack/libinfo.py
View file @
e9326105
import
os
import
os
from
.utils
import
logger
# issue#7378 may happen with custom opencv. It doesn't hurt to disable opencl
# issue#7378 may happen with custom opencv. It doesn't hurt to disable opencl
os
.
environ
[
'OPENCV_OPENCL_RUNTIME'
]
=
''
os
.
environ
[
'OPENCV_OPENCL_RUNTIME'
]
=
''
try
:
try
:
# issue#1924 may happen on old systems
# issue#1924 may happen on old systems
import
cv2
# noqa
import
cv2
# noqa
except
ImportError
:
pass
else
:
if
int
(
cv2
.
__version__
.
split
(
'.'
)[
0
])
==
3
:
if
int
(
cv2
.
__version__
.
split
(
'.'
)[
0
])
==
3
:
cv2
.
ocl
.
setUseOpenCL
(
False
)
cv2
.
ocl
.
setUseOpenCL
(
False
)
# check if cv is built with cuda
# check if cv is built with cuda
...
@@ -19,9 +15,11 @@ else:
...
@@ -19,9 +15,11 @@ else:
answer
=
line
.
split
()[
-
1
]
.
lower
()
answer
=
line
.
split
()[
-
1
]
.
lower
()
if
answer
==
'yes'
:
if
answer
==
'yes'
:
# issue#1197
# issue#1197
logger
.
warn
(
"OpenCV is built with CUDA support. "
print
(
"OpenCV is built with CUDA support. "
"This may cause slow initialization or sometimes segfault with TensorFlow."
)
"This may cause slow initialization or sometimes segfault with TensorFlow."
)
break
break
except
ImportError
,
TypeError
:
pass
os
.
environ
[
'TF_ENABLE_WINOGRAD_NONFUSED'
]
=
'1'
# issue#9339
os
.
environ
[
'TF_ENABLE_WINOGRAD_NONFUSED'
]
=
'1'
# issue#9339
os
.
environ
[
'TF_AUTOTUNE_THRESHOLD'
]
=
'3'
# use more warm-up
os
.
environ
[
'TF_AUTOTUNE_THRESHOLD'
]
=
'3'
# use more warm-up
...
...
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