InstallationWin.rst 6.86 KB
Newer Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
Install on Windows
==================

Prerequires
-----------


* 
  Python 3.6 (or above) 64-bit. `Anaconda <https://www.anaconda.com/products/individual>`__ or `Miniconda <https://docs.conda.io/en/latest/miniconda.html>`__ is highly recommended to manage multiple Python environments on Windows.

* 
  If it's a newly installed Python environment, it needs to install `Microsoft C++ Build Tools <https://visualstudio.microsoft.com/visual-cpp-build-tools/>`__ to support build NNI dependencies like ``scikit-learn``.

  .. code-block:: bat

       pip install cython wheel

* 
  git for verifying installation.

Install NNI
-----------

In most cases, you can install and upgrade NNI from pip package. It's easy and fast.

If you are interested in special or the latest code versions, you can install NNI through source code.

If you want to contribute to NNI, refer to `setup development environment <SetupNniDeveloperEnvironment.rst>`__.


* 
  From pip package

  .. code-block:: bat

       python -m pip install --upgrade nni

* 
  From source code

  .. code-block:: bat

43
       git clone -b v2.6 https://github.com/Microsoft/nni.git
44
       cd nni
45
46
       python -m pip install -U -r dependencies/setup.txt
       python -m pip install -r dependencies/develop.txt
47
       python setup.py develop
48
49
50
51
52
53
54
55
56

Verify installation
-------------------

* 
  Clone examples within source code.

  .. code-block:: bat

57
       git clone -b v2.6 https://github.com/Microsoft/nni.git
58
59
60
61
62
63

* 
  Run the MNIST example.

  .. code-block:: bat

64
       nnictl create --config nni\examples\trials\mnist-pytorch\config_windows.yml
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183

    Note:  If you are familiar with other frameworks, you can choose corresponding example under ``examples\trials``. It needs to change trial command ``python3`` to ``python`` in each example YAML, since default installation has ``python.exe``\ , not ``python3.exe`` executable.

* 
  Wait for the message ``INFO: Successfully started experiment!`` in the command line. This message indicates that your experiment has been successfully started. You can explore the experiment using the ``Web UI url``.

.. code-block:: text

   INFO: Starting restful server...
   INFO: Successfully started Restful server!
   INFO: Setting local config...
   INFO: Successfully set local config!
   INFO: Starting experiment...
   INFO: Successfully started experiment!
   -----------------------------------------------------------------------
   The experiment id is egchD4qy
   The Web UI urls are: http://223.255.255.1:8080   http://127.0.0.1:8080
   -----------------------------------------------------------------------

   You can use these commands to get more information about the experiment
   -----------------------------------------------------------------------
            commands                       description
   1. nnictl experiment show        show the information of experiments
   2. nnictl trial ls               list all of trial jobs
   3. nnictl top                    monitor the status of running experiments
   4. nnictl log stderr             show stderr log content
   5. nnictl log stdout             show stdout log content
   6. nnictl stop                   stop an experiment
   7. nnictl trial kill             kill a trial job by id
   8. nnictl --help                 get help information about nnictl
   -----------------------------------------------------------------------


* Open the ``Web UI url`` in your browser, you can view detailed information about the experiment and all the submitted trial jobs as shown below. `Here <../Tutorial/WebUI.rst>`__ are more Web UI pages.


.. image:: ../../img/webui_overview_page.png
   :target: ../../img/webui_overview_page.png
   :alt: overview



.. image:: ../../img/webui_trialdetail_page.png
   :target: ../../img/webui_trialdetail_page.png
   :alt: detail


System requirements
-------------------

Below are the minimum system requirements for NNI on Windows, Windows 10.1809 is well tested and recommend. Due to potential programming changes, the minimum system requirements for NNI may change over time.

.. list-table::
   :header-rows: 1
   :widths: auto

   * -
     - Recommended
     - Minimum
   * - **Operating System**
     - Windows 10 1809 or above
     - 
   * - **CPU**
     - Intel® Core™ i5 or AMD Phenom™ II X3 or better
     - Intel® Core™ i3 or AMD Phenom™ X3 8650
   * - **GPU**
     - NVIDIA® GeForce® GTX 660 or better
     - NVIDIA® GeForce® GTX 460
   * - **Memory**
     - 6 GB RAM
     - 4 GB RAM
   * - **Storage**
     - 30 GB available hare drive space
     - 
   * - **Internet**
     - Boardband internet connection
     - 
   * - **Resolution**
     - 1024 x 768 minimum display resolution
     - 


FAQ
---

simplejson failed when installing NNI
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Make sure a C++ 14.0 compiler is installed.

..

   building 'simplejson._speedups' extension error: [WinError 3] The system cannot find the path specified


Trial failed with missing DLL in command line or PowerShell
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

This error is caused by missing LIBIFCOREMD.DLL and LIBMMD.DLL and failure to install SciPy. Using Anaconda or Miniconda with Python(64-bit) can solve it.

..

   ImportError: DLL load failed


Trial failed on webUI
^^^^^^^^^^^^^^^^^^^^^

Please check the trial log file stderr for more details.

If there is a stderr file, please check it. Two possible cases are:


* forgetting to change the trial command ``python3`` to ``python`` in each experiment YAML.
* forgetting to install experiment dependencies such as TensorFlow, Keras and so on.

Fail to use BOHB on Windows
^^^^^^^^^^^^^^^^^^^^^^^^^^^

184
Make sure a C++ 14.0 compiler is installed when trying to run ``pip install nni[BOHB]`` to install the dependencies.
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214

Not supported tuner on Windows
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

SMAC is not supported currently; for the specific reason refer to this `GitHub issue <https://github.com/automl/SMAC3/issues/483>`__.

Use Windows as a remote worker
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Refer to `Remote Machine mode <../TrainingService/RemoteMachineMode.rst>`__.

Segmentation fault (core dumped) when installing
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Refer to `FAQ <FAQ.rst>`__.

Further reading
---------------


* `Overview <../Overview.rst>`__
* `Use command line tool nnictl <Nnictl.rst>`__
* `Use NNIBoard <WebUI.rst>`__
* `Define search space <SearchSpaceSpec.rst>`__
* `Config an experiment <ExperimentConfig.rst>`__
* `How to run an experiment on local (with multiple GPUs)? <../TrainingService/LocalMode.rst>`__
* `How to run an experiment on multiple machines? <../TrainingService/RemoteMachineMode.rst>`__
* `How to run an experiment on OpenPAI? <../TrainingService/PaiMode.rst>`__
* `How to run an experiment on Kubernetes through Kubeflow? <../TrainingService/KubeflowMode.rst>`__
* `How to run an experiment on Kubernetes through FrameworkController? <../TrainingService/FrameworkControllerMode.rst>`__