You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: public_dropin_environments/python3_xgboost/Dockerfile
+6Lines changed: 6 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -59,6 +59,12 @@ ENV ADDRESS=0.0.0.0:8080
59
59
ENV WITH_ERROR_SERVER=0 \
60
60
PYTHONUNBUFFERED=1
61
61
62
+
# OMP_NUM_THREADS is an environment variable that controls the maximum number of threads used by programs that rely on OpenMP for parallel processing.
63
+
# In libraries like XGBoost, it limits the number of CPU threads used for computation, helping to prevent resource contention and hangs in multi-worker environments.
64
+
# Setting OMP_NUM_THREADS=1 forces XGBoost to use only one thread per process.
65
+
# If we need to use wekzeug max_workers > 1 in DRUM, we must set OMP_NUM_THREADS=1 to avoid potential hangs.
66
+
# Maybe the same would apply to gunicorn, when we test.
0 commit comments