You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mxnet.apache.org by GitBox <gi...@apache.org> on 2017/12/13 03:03:12 UTC

[GitHub] rahul003 opened a new pull request #9049: Allow user to pass specific environment variables for server/worker/both through launch.py

rahul003 opened a new pull request #9049: Allow user to pass specific environment variables for server/worker/both through launch.py
URL: https://github.com/apache/incubator-mxnet/pull/9049
 
 
   ## Description ##
   Sometimes user might want to pass a specific environment variable when launching a distributed training job using launch.py. I have found it very helpful to set variables like PYTHONPATH or one of the [many MXNet environment variables](https://mxnet.incubator.apache.org/how_to/env_var.html). 
   Also we might sometimes want to set a variable like OMP_NUM_THREADS or MXNET_CPU_WORKER_NTHREADS only for server processes. And others for worker processes only.
   
   This PR allows user to pass such variables easily
   
   - For both server and worker processes
   ```... --env VARIABLE1```
   Picks value of the environment variable which is set when launch.py is called. If a variable passed doesn't have value set, raises an error to ensure user isn't making a mistake.
   
   - For server processes only
   ```... --env-server VARIABLE:VALUE```
   
   - For worker processes only
   ```... --env-worker VARIABLE:VALUE```
   
   Passing multiple such arguments is allowed
   For example ```--env VARIABLE1 --env VARIABLE2```
   
   Supports cluster types of `local` and `ssh`
   
   Requires this PR in dmlc-core to be merged https://github.com/dmlc/dmlc-core/pull/346
   
   @anirudh2290 This is a better version of something I had sent earlier that you had reviewed
   
   ## Checklist ##
   ### Essentials ###
   - [x] Passed code style checking (`make lint`)
   - [x] Changes are complete (i.e. I finished coding on this PR)
   - [ ] All changes have test coverage:
   - Unit tests are added for small changes to verify correctness (e.g. adding a new operator)
   - Nightly tests are added for complicated/long-running ones (e.g. changing distributed kvstore)
   - Build tests will be added for build configuration changes (e.g. adding a new build option with NCCL)
   - [x] Code is well-documented: 
   - For user-facing API changes, API doc string has been updated. 
   - For new C++ functions in header files, their functionalities and arguments are documented. 
   - For new examples, README.md is added to explain the what the example does, the source of the dataset, expected performance on test set and reference to the original paper if applicable
   - [x] To the my best knowledge, examples are either not affected by this change, or have been fixed to be compatible with this change
   
   ### Changes ###
   Refer description
   
   ## Comments ##
   This doesn't break anything which is already there. 
   If someone doesn't want to use it, it doesn't affect them. But I believe this would be very useful

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services