frame

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Sign In

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Neural Compute SDK version 2.04 is now available! The NCAPPZOO has also been updated for NCSDK 2!

What’s new in NCSDK 2.04?

Multiple graph allocations on a single NCS device is now possible! This feature allows for users to use multiple graph files from multiple models and queue them up for inference in a sequential manner.

NCSDK 1 can still be found on the master branch of the NCSDK repository, although NCSDK 1 will likely be replaced by NCSDK 2 in the near future. At the moment, NCSDK version 2.xx will be on the ncsdk2 branch of the github repo. To install NCSDK version 2.xx, you can use the following command:
git clone -b ncsdk2 https://github.com/movidius/ncsdk.git

More details and information on the differences between NCSDK 1 and NCSDK 2 can be found at https://movidius.github.io/ncsdk/ncapi/readme.html. Additionally NCSDK version 2.04.00.06 release notes can be found at https://movidius.github.io/ncsdk/release_notes.html.

The NCAPPZOO has also been updated for NCSDK 2!
To view the NCAPPZOO examples for NCSDK 2, please visit https://github.com/movidius/ncappzoo/ and switch to the ncsdk2 branch of the repository. The NCSDK v 1.12 version of the NCAPPZOO will stay in the master branch of the NCAPPZOO.

Comments

  • 18 Comments sorted by Votes Date Added
  • @Tome_at_Intel , does Neural Compute SDK version 2.04 support 16 bit floating point?
    I tried to generate graph by mvNCCompile tool from tensorflow model(.pb, file which is 32bit), and I did not find the there is a parameter which could specify 16bit or 32bit floating point. And the output graph works well. And before I used same .pb file to generate graph by NCSDK 1.2, the output is 16bit floating point, and it works as well.
    So my question is whether 2.04 still supports 16bit float point, maybe according to the input model(.pb) or with specific parameter? Or it only supports 32bit floating point now?
    Thanks for your answer in advance.

  • @minnowspirit Yes the NCSDK does support fp16. But now it takes fp32 and does the conversion internally now. You can read more about it at https://movidius.github.io/ncsdk/ncapi/python_api_migration.html. Scroll down to the input/output data types section.

  • I have install the NCSDK 1. , how could I upgrade to the NCSDK 2. I use the uninstall commant to uninstall the NCSDK1 and then install the NCSDK2. But I meet error and I don't know how to fix it. Could you pls give a help .Thanks!@Tome_at_Intel

  • @ideallyworld What is the error you are seeing?

  • The log info is just as follow(install error 131):

    root@ubuntu:~/workspace# cd ncsdk
    root@ubuntu:~/workspace/ncsdk# ls
    api examples install.sh Makefile requirements_apt_raspbian.txt uninstall-opencv.sh
    ATTRIBUTIONS extras install-utilities.sh ncsdk.conf requirements_apt.txt uninstall.sh
    docs install-opencv.sh LICENSE README.md requirements.txt version.txt
    root@ubuntu:~/workspace/ncsdk# make install
    ./uninstall-opencv.sh
    OpenCV uninstall starting
    Reading installer configuration variables from ./ncsdk.conf
    You are using pip version 8.1.1, however version 10.0.1 is available.
    You should consider upgrading via the 'pip install --upgrade pip' command.
    OpenCV uninstall finished

    make install starting.
    ./install.sh
    Movidius Neural Compute Toolkit Installation
    Installer NCSDK version: 2.04.00.06

    Reading installer configuration variables from ./ncsdk.conf
    Installing on Ubuntu 16.04

    print_ncsdk_config()
    INSTALL_DIR - Main installation directory
    INSTALL_CAFFE - Flag to install TensorFlow
    CAFFE_FLAVOR - Specific 'flavor' of caffe to install
    CAFFE_USE_CUDA - Use CUDA enabled version of caffe
    INSTALL_TENSORFLOW - Flag to install TensorFlow
    INSTALL_TOOLKIT - Flag to install Neural Compute Toolkit
    PIP_SYSTEM_INSTALL - Globally install pip packages via sudo -H
    VERBOSE - Flag to enable more verbose installation
    USE_VIRTUALENV - Flag to enable python virtualenv
    MAKE_NJOBS - Number of processes to use for parallel build (i.e. make -j MAKE_NJOBS)

    INSTALL_DIR=/opt/movidius
    INSTALL_CAFFE=yes
    CAFFE_FLAVOR=ssd
    CAFFE_USE_CUDA=no
    INSTALL_TENSORFLOW=yes
    INSTALL_TOOLKIT=yes
    PIP_SYSTEM_INSTALL=yes
    VERBOSE=yes
    USE_VIRTUALENV=no
    MAKE_NJOBS=2

    Didn't find a valid NCSDK installation
    Searching and removing previous NCSDK installation from the system
    Searching and removing NCS python API...You are using pip version 8.1.1, however version 10.0.1 is available.
    You should consider upgrading via the 'pip install --upgrade pip' command.
    Uninstalling mvnc-1.12.0.1:
    Successfully uninstalled mvnc-1.12.0.1
    You are using pip version 8.1.1, however version 10.0.1 is available.
    You should consider upgrading via the 'pip install --upgrade pip' command.
    Uninstalling mvnc-1.12.0.1:
    Successfully uninstalled mvnc-1.12.0.1
    done
    Searching and removing udev rules...done
    Running ldconfig...done
    Updating udev rules...done
    Successfully uninstalled NCSDK from the system
    Downloading NCSDK-2.04.00.06.tar.gz
    --2018-06-12 21:11:38-- https://downloadmirror.intel.com/27738/eng/NCSDK-2.04.00.06.tar.gz
    Resolving downloadmirror.intel.com (downloadmirror.intel.com)... 23.48.22.30
    Connecting to downloadmirror.intel.com (downloadmirror.intel.com)|23.48.22.30|:443... connected.
    HTTP request sent, awaiting response... 200 OK
    Length: 1383386 (1.3M) [application/x-gzip]
    Saving to: ‘NCSDK-2.04.00.06.tar.gz’

    。。。。。。

    http://ppa.launchpad.net/fcitx-team/nightly/ubuntu xenial/main DEP-11 64x64 Icons
    Err:9 http://ppa.launchpad.net/fcitx-team/nightly/ubuntu xenial/main Sources
    404 Not Found
    Ign:12 http://ppa.launchpad.net/fcitx-team/nightly/ubuntu xenial/main amd64 Packages
    Ign:15 http://ppa.launchpad.net/fcitx-team/nightly/ubuntu xenial/main i386 Packages
    Ign:16 http://ppa.launchpad.net/fcitx-team/nightly/ubuntu xenial/main all Packages
    Ign:17 http://ppa.launchpad.net/fcitx-team/nightly/ubuntu xenial/main Translation-en_US
    Ign:18 http://ppa.launchpad.net/fcitx-team/nightly/ubuntu xenial/main Translation-en
    Ign:19 http://ppa.launchpad.net/fcitx-team/nightly/ubuntu xenial/main amd64 DEP-11 Metadata
    Ign:22 http://ppa.launchpad.net/fcitx-team/nightly/ubuntu xenial/main DEP-11 64x64 Icons
    Fetched 4,610 kB in 46s (99.7 kB/s)
    Reading package lists...
    W: The repository 'http://ppa.launchpad.net/fcitx-team/nightly/ubuntu xenial Release' does not have a Release file.
    E: Failed to fetch http://ppa.launchpad.net/fcitx-team/nightly/ubuntu/dists/xenial/main/source/Sources 404 Not Found
    E: Some index files failed to download. They have been ignored, or old ones used instead.
    Installation failed: Command ' apt-get update' return code=100. Error on line 308 in ./install-utilities.sh. Will exit
    Makefile:47: recipe for target 'install' failed
    make: *** [install] Error 131@Tome_at_Intel

  • edited July 18 Vote Up0Vote Down

    Facing the exact same issue with installation of NCSDK 2 as mentioned by @ideallyworld in the above post.
    Could someone please help in resolving this issue?

    Thanks in advance.

  • @ideallyworld , @abhi
    I do not know if it will work or not.
    Various packages seem to be old.

    $ sudo apt update
    $ sudo apt upgrade
    $ cd <new ncsdk downloaded path>
    $ make install
    
  • I need some help, since I cannot find the repository for NCSDK 2
    http://github.com/Movidius/ncsdk

  • Is there an example about how to load multi model in on stick device?Such as MTCNN,there are three model for three stages,how can this be done in version 2.0?

  • Is there an example about how to load multi model in on stick device?Such as MTCNN,there are three model for three stages,how can this be done in version 2.0?

  • Is there an example about how to load multi model in on stick device?Such as MTCNN,there are three model for three stages,how can this be done in version 2.0?

  • edited November 1 Vote Up0Vote Down

    @shartoo
    I do not know if it will be helpful, but it is the repository I created.
    I am implementing Multi Graph.
    Load two or three graphs simultaneously.
    Because it is logic based on Multi Stick, the part of "Try ~ Except ~" may be a bit confusing.
    https://github.com/PINTO0309/MobileNet-SSD-RealSense.git
    MultiStickSSDwithRealSense.py

        # 1:= Enabled MobileNet-SSD Model
        if ssd_detection_mode == 1:
            with open(join(graph_folder, "graph"), mode="rb") as f:
                graph_buffers.append(f.read())
            graphs.append(mvnc.Graph('MobileNet-SSD'))
    
        # 1:= Enabled Fullweight FaceDetection Model
        if face_detection_mode == 1:
            with open(join(graph_folder, "graph.fullfacedetection"), mode="rb") as f:
                graph_buffers.append(f.read())
            graphs.append(mvnc.Graph('FullFaceDetection'))
    
        # 2:= Enabled Lightweight FaceDetection Model
        if face_detection_mode == 2:
            with open(join(graph_folder, "graph.shortfacedetection"), mode="rb") as f:
                graph_buffers.append(f.read())
            graphs.append(mvnc.Graph('ShortFaceDetection'))
    
        devopen = False
        for device in devices:
            try:
                device = mvnc.Device(device)
                device.open()
                for (graph, graph_buffer) in zip(graphs, graph_buffers):
                    graphHandles.append(graph.allocate_with_fifos(device, graph_buffer))
                devopen = True
                break
            except:
                continue
    

    By the way, MTCNN has multiple output problems, it is impossible to smartly implement with NCSDK v2.

  • Hi @PINTO i have tried loading three model of MTCNN's three stage in one stick but failed.Here is what i did:

    def load_graph(graph_file1,graph_file2,graph_file3):
        #mvnc.SetGlobalOption(mvnc.GlobalOption.LOG_LEVEL, 0)
        devices = mvnc2.enumerate_devices()
        if len(devices) == 0:
            print('No devices found')
            return 1
        device = mvnc2.Device(devices[0])
        device.open()
        # Load graph from disk and allocate graph via API
        with open(graph_file1, mode='rb') as f:
            graph_from_disk1 = f.read()
        graph1 = mvnc2.Graph("graph1")
        fifo_in1, fifo_out1 = graph1.allocate_with_fifos(device, graph_from_disk1)
    
        with open(graph_file2, mode='rb') as f:
            graph_from_disk2 = f.read()
        graph2 = mvnc2.Graph("graph2")
        fifo_in2, fifo_out2 = graph2.allocate_with_fifos(device, graph_from_disk2)
    
        with open(graph_file3, mode='rb') as f:
            graph_from_disk3 = f.read()
        graph3 = mvnc2.Graph("graph3")
        fifo_in3, fifo_out3 = graph3.allocate_with_fifos(device, graph_from_disk3)
    
        return graph1,fifo_in1, fifo_out1,graph2,fifo_in2, fifo_out2,graph3,fifo_in3, fifo_out3
    

    error is below

    ...
    I1102 10:19:38.878919  3190 net.cpp:157] Top shape: 1 2 (2)
    I1102 10:19:38.878955  3190 net.cpp:165] Memory required for data: 940680
    I1102 10:19:38.879007  3190 layer_factory.hpp:77] Creating layer conv6-2
    I1102 10:19:38.879052  3190 net.cpp:100] Creating Layer conv6-2
    I1102 10:19:38.879079  3190 net.cpp:434] conv6-2 <- conv5_prelu5_0_split_1
    I1102 10:19:38.879118  3190 net.cpp:408] conv6-2 -> conv6-2
    I1102 10:19:38.879233  3190 net.cpp:150] Setting up conv6-2
    I1102 10:19:38.879261  3190 net.cpp:157] Top shape: 1 4 (4)
    I1102 10:19:38.879293  3190 net.cpp:165] Memory required for data: 940696
    I1102 10:19:38.879334  3190 layer_factory.hpp:77] Creating layer conv6-3
    I1102 10:19:38.879374  3190 net.cpp:100] Creating Layer conv6-3
    I1102 10:19:38.879400  3190 net.cpp:434] conv6-3 <- conv5_prelu5_0_split_2
    I1102 10:19:38.879444  3190 net.cpp:408] conv6-3 -> conv6-3
    I1102 10:19:38.879634  3190 net.cpp:150] Setting up conv6-3
    I1102 10:19:38.879663  3190 net.cpp:157] Top shape: 1 10 (10)
    I1102 10:19:38.879696  3190 net.cpp:165] Memory required for data: 940736
    I1102 10:19:38.879737  3190 layer_factory.hpp:77] Creating layer prob1
    I1102 10:19:38.879772  3190 net.cpp:100] Creating Layer prob1
    I1102 10:19:38.879798  3190 net.cpp:434] prob1 <- conv6-1
    I1102 10:19:38.879837  3190 net.cpp:408] prob1 -> prob1
    I1102 10:19:38.879884  3190 net.cpp:150] Setting up prob1
    I1102 10:19:38.879909  3190 net.cpp:157] Top shape: 1 2 (2)
    I1102 10:19:38.879940  3190 net.cpp:165] Memory required for data: 940744
    I1102 10:19:38.879966  3190 net.cpp:228] prob1 does not need backward computation.
    I1102 10:19:38.879994  3190 net.cpp:228] conv6-3 does not need backward computation.
    I1102 10:19:38.880022  3190 net.cpp:228] conv6-2 does not need backward computation.
    I1102 10:19:38.880049  3190 net.cpp:228] conv6-1 does not need backward computation.
    I1102 10:19:38.880079  3190 net.cpp:228] conv5_prelu5_0_split does not need backward computation.
    I1102 10:19:38.880105  3190 net.cpp:228] prelu5 does not need backward computation.
    I1102 10:19:38.880131  3190 net.cpp:228] drop5 does not need backward computation.
    I1102 10:19:38.880157  3190 net.cpp:228] conv5 does not need backward computation.
    I1102 10:19:38.880185  3190 net.cpp:228] prelu4 does not need backward computation.
    I1102 10:19:38.880211  3190 net.cpp:228] conv4 does not need backward computation.
    I1102 10:19:38.880239  3190 net.cpp:228] pool3 does not need backward computation.
    I1102 10:19:38.880266  3190 net.cpp:228] prelu3 does not need backward computation.
    I1102 10:19:38.880292  3190 net.cpp:228] conv3 does not need backward computation.
    I1102 10:19:38.880321  3190 net.cpp:228] pool2 does not need backward computation.
    I1102 10:19:38.880347  3190 net.cpp:228] prelu2 does not need backward computation.
    I1102 10:19:38.880374  3190 net.cpp:228] conv2 does not need backward computation.
    I1102 10:19:38.880401  3190 net.cpp:228] pool1 does not need backward computation.
    I1102 10:19:38.880429  3190 net.cpp:228] prelu1 does not need backward computation.
    I1102 10:19:38.880455  3190 net.cpp:228] conv1 does not need backward computation.
    I1102 10:19:38.880482  3190 net.cpp:228] input does not need backward computation.
    I1102 10:19:38.880508  3190 net.cpp:270] This network produces output conv6-2
    I1102 10:19:38.880535  3190 net.cpp:270] This network produces output conv6-3
    I1102 10:19:38.880564  3190 net.cpp:270] This network produces output prob1
    I1102 10:19:38.880630  3190 net.cpp:283] Network initialization done.
    I1102 10:19:38.886859  3190 net.cpp:761] Ignoring source layer data48
    I1102 10:19:38.886955  3190 net.cpp:761] Ignoring source layer slicer_label
    I1102 10:19:38.886981  3190 net.cpp:761] Ignoring source layer label1_slicer_label_0_split
    I1102 10:19:38.888417  3190 net.cpp:761] Ignoring source layer conv6-1_conv6-1_0_split
    I1102 10:19:38.888537  3190 net.cpp:761] Ignoring source layer loss1
    I1102 10:19:38.888568  3190 net.cpp:761] Ignoring source layer accuracy1
    I1102 10:19:38.888595  3190 net.cpp:761] Ignoring source layer loss2
    I1102 10:19:38.888620  3190 net.cpp:761] Ignoring source layer loss3
    E: [         0] XLinkOpenStream:1035    Max streamId reached deaddead!
    W: [         0] ncGraphAllocate:1008    can't open stream for graphBuffer transmission
    Traceback (most recent call last):
      File "/home/pi/workspace/test/mtcnn/mtcnn_caffe/demo/test.py", line 223, in <module>
        main()
      File "/home/pi/workspace/test/mtcnn/mtcnn_caffe/demo/test.py", line 207, in main
        graph1, fifo_in1, fifo_out1, graph2, fifo_in2, fifo_out2, graph3, fifo_in3, fifo_out3 = load_graph(graph_file1, graph_file2, graph_file3)
      File "/home/pi/workspace/test/mtcnn/mtcnn_caffe/demo/test.py", line 197, in load_graph
        fifo_in3, fifo_out3 = graph3.allocate_with_fifos(device, graph_from_disk3)
      File "/usr/local/lib/python3.5/dist-packages/mvnc/mvncapi.py", line 613, in allocate_with_fifos
        raise Exception(Status(status))
    Exception: Status.ERROR
    

    It seems that load two graph is ok,while fail when loading a third graph.

  • There is a caffe version of MTCNN here caffe-mtcnn github,what i did above was cloned the caffe-mtcnn and compiled the caffe model using nvccCompile of ncsdk for using accelerator of ncsdk

  • edited November 2 Vote Up0Vote Down

    @shartoo
    I used the repository you suggested and tried to implement it in cooperation with other engineers, but it did not succeed.
    https://ncsforum.movidius.com/discussion/comment/3391/
    https://ncsforum.movidius.com/discussion/comment/3441/
    https://ncsforum.movidius.com/discussion/comment/3729/
    https://ncsforum.movidius.com/discussion/comment/3815/

    Please show below.
    Unfortunately, Intel's engineers say it is a bug in NCSDK.
    https://ncsforum.movidius.com/discussion/1259/cant-load-more-than-two-models#latest

    I think your question is not appropriate for this topic.
    (Because it is hard to touch the eyes of other expert engineers.)
    I think it would be better to create a new topic yourself.

  • @PINTO Thank you for your advice .Now i have to quit this solution ,the nvccCompile seems work for only few model provide by intel official

Sign In or Register to comment.