Changes between Initial Version and Version 1 of Tutorials/e0BTZG/Tutorial01


Ignore:
Timestamp:
02/09/18 17:51:52 (2 years ago)
Author:
nilanjan
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • Tutorials/e0BTZG/Tutorial01

    v1 v1  
     1== Example: Intel Movidius - Neural Computer ==
     2This tutorial will show how to get started with the Movidius NCS in the orbit environment. We'll go through downloading and installing the SDK, and then running a couple of the sample examples. This should provide a simple baseline for working with the Intel Movidius stick and SDK without getting into the details of neural networks.
     3
     4=== Hardware / Software Utilized ===
     5 * Nodes with the Movidius Neural Compute Stick - use the [https://www.orbit-lab.org/cPanel/status/template/index.html Inventory/Status page] find nodes with this device.
     6 * Node image with ubuntu 64-bit version 16.04 - for this example we'll use ubuntu-16-04-64bit-rzraven.ndz since it already has many of the prerequisites installed.
     7 * Intel Movidius Neural Network SDK - provides a set of tools to create and run applications on the NCS device from the node. Development can be done in C/C++ or Python. [https://movidius.github.io/ncsdk/install.html Click here for more info.]
     8
     9
     10=== Set up ===
     11To get started, please follow the instructions for creating a reservation and loading images on orbit-lab nodes under [wiki:Tutorials/a0Basic/Tutorial1 ORBIT Tutorial -> Basic Tutorials -> testbed operations] and use the [https://www.orbit-lab.org/cPanel/status/template/index.html Inventory/Status page] to find nodes with Movidius NCS.
     12In the example we'll use node1-1 on Sandbox1 imaged with ubuntu-16-04-64bit-rzraven.ndz.
     13
     14 * Once the node1-1 is imaged and turned on let's verify the system detected the device. Grep for "Movidius" in the driver messages.
     15{{{
     16root@node1-1:~# dmesg | grep Movidius
     17[    1.103633] usb 3-3: Product: Movidius MA2X5X
     18[    1.103634] usb 3-3: Manufacturer: Movidius Ltd.
     19}}}
     20
     21 * Install the SDK - download the SDK & examples from the git repository.
     22{{{
     23root@node1-1:~# git clone https://github.com/movidius/ncsdk.git
     24root@node1-1:~# cd ncsdk
     25root@node1-1:~# make install
     26}}}
     27
     28 At the end of the install you should see a message stating "Setup is complete" and Python environment variables updated in the .bashrc file, so make sure to source your .bashrc file before proceeding in the same terminal otherwise just open a new terminal.
     29{{{
     30root@node1-1:~# source ~/.bashrc
     31}}}
     32
     33
     34=== Run a simple example ===
     35
     36 * Let's run the ''hello_ncs'' example to check that the Neural Compute API is able to access the NCS device. This example will just open and close the device. There are two version of this example - one in Python and the other in C++. The source for both are very short and easy to match the output with the source code.
     37 Move to the directory ''ncsdk/examples/apps/hello_ncs_py'' and type ''make help'' for a list of possible options. Run the python example
     38{{{
     39 root@node1-1:~# cd ~/ncsdk/examples/apps/hello_ncs_py/
     40 root@node1-1:~# make all
     41 :
     42 :
     43 :
     44 root@node1-1:~# make run
     45python3 hello_ncs.py;
     46Hello NCS! Device opened normally.
     47Goodbye NCS! Device closed normally.
     48NCS device working.
     49}}}
     50
     51 To run the C++ example, move to the ''ncsdk/examples/apps/hello_ncs_cpp'' directory and do ''make all && make run''. The output should be similar to the Python version.
     52
     53 * Similarly we can run the other examples in ''ncsdk/examples''. The AlexNet example (image classification) is provided in ''ncsdk/examples/caffe/AlexNet''. Doing a ''make help'' will display all the options available. The makefile is used to download, profile, compile, check and run the network. The [https://github.com/movidius/ncsdk/tree/master/examples/caffe/AlexNet git repo has an outline] of all the make options, please refer to this before executing this example.
     54