Defaults to "info" or "debug", depending on ``debug`` option. When debug mode is enabled, Loglevel is set to "debug", otherwise, Loglevel is set to "info".
When debug mode is enabled, Loglevel is set to "debug", otherwise, Loglevel is set to "info".
Most modules of NNI will be affected by this value, including NNI manager, tuner, training service, etc.
Most modules of NNI will be affected by this value, including NNI manager, tuner, training service, etc.
The exception is trial, whose logging level is directly managed by trial code.
The exception is trial, whose logging level is directly managed by trial code.
For Python modules, "trace" acts as logging level 0 and "fatal" acts as ``logging.CRITICAL``.
For Python modules, "trace" acts as logging level 0 and "fatal" acts as ``logging.CRITICAL``.
* - experimentWorkingDirectory
* - experimentWorkingDirectory
- ``Optional[str]``
- ``str``, optional
- Specify the :ref:`directory <path>` to place log, checkpoint, metadata, and other run-time stuff.
- Default: ``~/nni-experiments``.
By default uses ``~/nni-experiments``.
Specify the :ref:`directory <path>` to place log, checkpoint, metadata, and other run-time stuff.
NNI will create a subdirectory named by experiment ID, so it is safe to use the same directory for multiple experiments.
NNI will create a subdirectory named by experiment ID, so it is safe to use the same directory for multiple experiments.
* - tunerGpuIndices
* - tunerGpuIndices
- ``Optional[list[int] | str | int]``
- ``list[int]`` or ``str`` or ``int``, optional
- Limit the GPUs visible to tuner, assessor, and advisor.
- Limit the GPUs visible to tuner, assessor, and advisor.
This will be the ``CUDA_VISIBLE_DEVICES`` environment variable of tuner process.
This will be the ``CUDA_VISIBLE_DEVICES`` environment variable of tuner process.
Because tuner, assessor, and advisor run in the same process, this option will affect them all.
Because tuner, assessor, and advisor run in the same process, this option will affect them all.
* - tuner
* - tuner
- ``Optional[AlgorithmConfig]``
- ``AlgorithmConfig``, optional
- Specify the tuner.
- Specify the tuner.
The built-in tuners can be found `here <../builtin_tuner.rst>`__ and you can follow `this tutorial <../Tuner/CustomizeTuner.rst>`__ to customize a new tuner.
The built-in tuners can be found `here <../builtin_tuner.rst>`__ and you can follow `this tutorial <../Tuner/CustomizeTuner.rst>`__ to customize a new tuner.
* - assessor
* - assessor
- ``Optional[AlgorithmConfig]``
- ``AlgorithmConfig``, optional
- Specify the assessor.
- Specify the assessor.
The built-in assessors can be found `here <../builtin_assessor.rst>`__ and you can follow `this tutorial <../Assessor/CustomizeAssessor.rst>`__ to customize a new assessor.
The built-in assessors can be found `here <../builtin_assessor.rst>`__ and you can follow `this tutorial <../Assessor/CustomizeAssessor.rst>`__ to customize a new assessor.
* - advisor
* - advisor
- ``Optional[AlgorithmConfig]``
- ``AlgorithmConfig``, optional
- Specify the advisor.
- Specify the advisor.
NNI provides two built-in advisors: `BOHB <../Tuner/BohbAdvisor.rst>`__ and `Hyperband <../Tuner/HyperbandAdvisor.rst>`__, and you can follow `this tutorial <../Tuner/CustomizeAdvisor.rst>`__ to customize a new advisor.
NNI provides two built-in advisors: `BOHB <../Tuner/BohbAdvisor.rst>`__ and `Hyperband <../Tuner/HyperbandAdvisor.rst>`__, and you can follow `this tutorial <../Tuner/CustomizeAdvisor.rst>`__ to customize a new advisor.
...
@@ -236,7 +232,7 @@ ExperimentConfig
...
@@ -236,7 +232,7 @@ ExperimentConfig
- Specify the `training service <../TrainingService/Overview.rst>`__.
- Specify the `training service <../TrainingService/Overview.rst>`__.
* - sharedStorage
* - sharedStorage
- ``Optional[SharedStorageConfig]``
- ``SharedStorageConfig``, optional
- Configure the shared storage, detailed usage can be found `here <../Tutorial/HowToUseSharedStorage.rst>`__.
- Configure the shared storage, detailed usage can be found `here <../Tutorial/HowToUseSharedStorage.rst>`__.
AlgorithmConfig
AlgorithmConfig
...
@@ -259,23 +255,23 @@ For customized algorithms, there are two ways to describe them:
...
@@ -259,23 +255,23 @@ For customized algorithms, there are two ways to describe them:
- Description
- Description
* - name
* - name
- ``Optional[str]``
- ``str`` or ``None``, optional
- Name of the built-in or registered algorithm.
- Default: None. Name of the built-in or registered algorithm.
``str`` for the built-in and registered algorithm, ``None`` for other customized algorithms.
``str`` for the built-in and registered algorithm, ``None`` for other customized algorithms.
* - className
* - className
- ``Optional[str]``
- ``str`` or ``None``, optional
- Qualified class name of not registered customized algorithm.
- Default: None. Qualified class name of not registered customized algorithm.
``None`` for the built-in and registered algorithm, ``str`` for other customized algorithms.
``None`` for the built-in and registered algorithm, ``str`` for other customized algorithms.
example: ``"my_tuner.MyTuner"``
example: ``"my_tuner.MyTuner"``
* - codeDirectory
* - codeDirectory
- ``Optional[str]``
- ``str`` or ``None``, optional
- `Path`_ to the directory containing the customized algorithm class.
- Default: None. Path_ to the directory containing the customized algorithm class.
``None`` for the built-in and registered algorithm, ``str`` for other customized algorithms.
``None`` for the built-in and registered algorithm, ``str`` for other customized algorithms.
* - classArgs
* - classArgs
- ``Optional[dict[str, Any]]``
- ``dict[str, Any]``, optional
- Keyword arguments passed to algorithm class' constructor.
- Keyword arguments passed to algorithm class' constructor.
See algorithm's document for supported value.
See algorithm's document for supported value.
...
@@ -311,8 +307,8 @@ Detailed usage can be found `here <../TrainingService/LocalMode.rst>`__.
...
@@ -311,8 +307,8 @@ Detailed usage can be found `here <../TrainingService/LocalMode.rst>`__.
-
-
* - useActiveGpu
* - useActiveGpu
- ``Optional[bool]``
- ``bool``, optional
- Specify whether NNI should submit trials to GPUs occupied by other tasks.
- Default: ``False``. Specify whether NNI should submit trials to GPUs occupied by other tasks.
Must be set when ``trialGpuNumber`` greater than zero.
Must be set when ``trialGpuNumber`` greater than zero.
Following processes can make GPU "active":
Following processes can make GPU "active":
...
@@ -325,12 +321,11 @@ Detailed usage can be found `here <../TrainingService/LocalMode.rst>`__.
...
@@ -325,12 +321,11 @@ Detailed usage can be found `here <../TrainingService/LocalMode.rst>`__.
When you create multiple NNI experiments and ``useActiveGpu`` is set to ``True``, they will submit multiple trials to the same GPU(s) simultaneously.
When you create multiple NNI experiments and ``useActiveGpu`` is set to ``True``, they will submit multiple trials to the same GPU(s) simultaneously.
* - maxTrialNumberPerGpu
* - maxTrialNumberPerGpu
- ``int``
- ``int``, optional
- Specify how many trials can share one GPU.
- Default: ``1``. Specify how many trials can share one GPU.
default: ``1``
* - gpuIndices
* - gpuIndices
- ``Optional[list[int] | str | int]``
- ``list[int]`` or ``str`` or ``int``, optional
- Limit the GPUs visible to trial processes.
- Limit the GPUs visible to trial processes.
If ``trialGpuNumber`` is less than the length of this value, only a subset will be visible to each trial.
If ``trialGpuNumber`` is less than the length of this value, only a subset will be visible to each trial.
This will be used as ``CUDA_VISIBLE_DEVICES`` environment variable.
This will be used as ``CUDA_VISIBLE_DEVICES`` environment variable.
...
@@ -357,8 +352,8 @@ Detailed usage can be found `here <../TrainingService/RemoteMachineMode.rst>`__.
...
@@ -357,8 +352,8 @@ Detailed usage can be found `here <../TrainingService/RemoteMachineMode.rst>`__.
- If not specified, ``sshKeyFile`` will be used instead.
- If not specified, ``sshKeyFile`` will be used instead.
* - sshKeyFile
* - sshKeyFile
- ``Optional[str]``
- ``str``, optional
- `Path`_ to ``sshKeyFile`` (identity file).
- `Path`_ to ``sshKeyFile`` (identity file).
Only used when ``password`` is not specified.
Only used when ``password`` is not specified.
* - sshPassphrase
* - sshPassphrase
- ``Optional[str]``
- ``str``, optional
- Passphrase of SSH identity file.
- Passphrase of SSH identity file.
* - useActiveGpu
* - useActiveGpu
- ``bool``
- ``bool``, optional
- Specify whether NNI should submit trials to GPUs occupied by other tasks.
- Default: ``False``. Specify whether NNI should submit trials to GPUs occupied by other tasks.
default: ``False``
Must be set when ``trialGpuNumber`` greater than zero.
Must be set when ``trialGpuNumber`` greater than zero.
Following processes can make GPU "active":
Following processes can make GPU "active":
...
@@ -413,18 +406,17 @@ RemoteMachineConfig
...
@@ -413,18 +406,17 @@ RemoteMachineConfig
When you create multiple NNI experiments and ``useActiveGpu`` is set to ``True``, they will submit multiple trials to the same GPU(s) simultaneously.
When you create multiple NNI experiments and ``useActiveGpu`` is set to ``True``, they will submit multiple trials to the same GPU(s) simultaneously.
* - maxTrialNumberPerGpu
* - maxTrialNumberPerGpu
- ``int``
- ``int``, optional
- Specify how many trials can share one GPU.
- Default: ``1``. Specify how many trials can share one GPU.
default: ``1``
* - gpuIndices
* - gpuIndices
- ``Optional[list[int] | str | int]``
- ``list[int]`` or ``str`` or ``int``, optional
- Limit the GPUs visible to trial processes.
- Limit the GPUs visible to trial processes.
If ``trialGpuNumber`` is less than the length of this value, only a subset will be visible to each trial.
If ``trialGpuNumber`` is less than the length of this value, only a subset will be visible to each trial.
This will be used as ``CUDA_VISIBLE_DEVICES`` environment variable.
This will be used as ``CUDA_VISIBLE_DEVICES`` environment variable.
* - pythonPath
* - pythonPath
- ``Optional[str]``
- ``str``, optional
- Specify a Python environment.
- Specify a Python environment.
This path will be inserted at the front of PATH. Here are some examples:
This path will be inserted at the front of PATH. Here are some examples:
...
@@ -434,7 +426,7 @@ RemoteMachineConfig
...
@@ -434,7 +426,7 @@ RemoteMachineConfig
If you are working on Anaconda, there is some difference. On Windows, you also have to add ``../script`` and ``../Library/bin`` separated by ``;``. Examples are as below:
If you are working on Anaconda, there is some difference. On Windows, you also have to add ``../script`` and ``../Library/bin`` separated by ``;``. Examples are as below: