-
Notifications
You must be signed in to change notification settings - Fork 487
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
update guidelines for the number of threads #1291
Conversation
Setting `OMP_NUM_THREADS` to 3 may be faster than 6. It needs to be confirmed.
Codecov Report
@@ Coverage Diff @@
## devel #1291 +/- ##
==========================================
- Coverage 75.97% 75.90% -0.08%
==========================================
Files 91 91
Lines 7406 7416 +10
==========================================
+ Hits 5627 5629 +2
- Misses 1779 1787 +8
Continue to review full report at Codecov.
|
if "OMP_NUM_THREADS" not in os.environ or \ | ||
"TF_INTRA_OP_PARALLELISM_THREADS" not in os.environ or \ | ||
"TF_INTER_OP_PARALLELISM_THREADS" not in os.environ: | ||
logging.warning( | ||
"To get the best performance, it is recommended to adjust " | ||
"the number of threads by setting the environment variables " | ||
"OMP_NUM_THREADS, TF_INTRA_OP_PARALLELISM_THREADS, and " | ||
"TF_INTER_OP_PARALLELISM_THREADS.") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it a good suggestion when the user train with GPU?
I think a user only need to adjust them when he/she uses CPU.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
#1284 is confirmed to be caused by improper configuration of threads.
close #1284.