CNStream is a streaming framework for building Cambricon machine learning pipelines

Cambricon CNStream

CNStream is a streaming framework with plug-ins. It is used to connect other modules, includes basic functionalities, libraries, and essential elements.

CNStream provides the following built-in modules:

  • source: Support RTSP, video file, images and elementary stream in memory (H.264, H.265, and JPEG decoding.)
  • inference: MLU-based inference accelerator for detection and classification.
  • inference2: Based on infer server to run inference, preprocess and postprocess.
  • osd (On-screen display): Module for highlighting objects and text overlay.
  • encode: Encode videos or images.
  • display: Display the video on screen.
  • tracker: Multi-object tracking.
  • rtsp_sink:Push RTSP stream to internet
  • ipc: Make pipeline across process

Cambricon Dependencies

CNStream depends on the CNCodec library and the CNRT library which are packed in Cambricon CNToolkit package. Therefore, the lastest Cambricon CNToolkit package is required. If you do not have one, please feel free to contact with us. Our mailbox: [email protected]

Install Cambricon CNToolkit package

Ubuntu

  dpkg -i cntoolkit-x.x.x_Ubuntuxx.xx_amd64.deb
  cd /var/cntoolkit-x.x.x
  dpkg -i cncodec-xxx.deb cnrt_xxx.deb

Centos

  yum -y install cntoolkit-x.x.x.el7.x86_64.rpm
  cd /var/cntoolkit-xxx-x.x.x
  yum -y install cncodec-xxx.rpm cnrt-xxx.rpm

After that, Cambricon dependencies that CNStream needed are installed at path '/usr/loacl/neuware'.

Please make sure you must not install cnstream_xxx.deb or cnstream-xxx.rpm.

Quick Start

This section introduces how to quickly build instructions on CNStream and how to develop your own applications based on CNStream. We strongly recommend you execute pre_required_helper.sh to prepare for the environment. If not, please follow the commands below.

Required environments

Before building instructions, you need to install the following software:

  • OpenCV 2.4.9+
  • GFlags 2.1.2
  • GLog 0.3.4
  • CMake 2.8.7+
  • SDL2 2.0.4+    // If build_display=ON
  • FFmpeg 2.8 3.4 4.2

Ubuntu

If you are using Ubuntu, run the following commands:

  OpenCV 2.4.9+  >>>>>>>>>   sudo apt-get install libopencv-dev
  GFlags 2.1.2   >>>>>>>>>   sudo apt-get install libgflags-dev
  GLog 0.3.4     >>>>>>>>>   sudo apt-get install libgoogle-glog-dev
  CMake 2.8.7+   >>>>>>>>>   sudo apt-get install cmake
  SDL2 2.0.4+    >>>>>>>>>   sudo apt-get install libsdl2-dev

Centos

If you are using Centos, run the following commands:

  OpenCV 2.4.9+  >>>>>>>>>   sudo yum install opencv-devel.x86_64
  GFlags 2.1.2   >>>>>>>>>   sudo yum install gflags.x86_64
  GLog 0.3.4     >>>>>>>>>   sudo yum install glog.x86_64
  CMake 2.8.7+   >>>>>>>>>   sudo yum install cmake3.x86_64
  SDL2 2.0.4+    >>>>>>>>>   sudo yum install SDL2_gfx-devel.x86_64

Build Instructions Using CMake

After finished prerequisites, you can build project with the following steps:

  1. clone submodule easydk with command as below

    git submodule  update  --init
  2. Run the following command to create a directory for saving the output.

    mkdir build       # Create a directory to save the output.

    A Makefile is generated in the build folder.

  3. Run the following command to generate a script for building instructions.

    cd build
    cmake ${CNSTREAM_DIR}  # Generate native build scripts.

    Cambricon CNStream provides a CMake script (CMakeLists.txt) to build instructions. You can download CMake for free from http://www.cmake.org/.

    ${CNSTREAM_DIR} specifies the directory where CNStream saves for.

    cmake option range default description
    build_display ON / OFF ON build display module
    build_ipc ON / OFF ON build ipc module
    build_encode ON / OFF ON build encode module
    build_inference ON / OFF ON build inference module
    build_osd ON / OFF ON build osd module
    build_rtsp_sink ON / OFF ON build rtsp_sink module
    build_source ON / OFF ON build source module
    build_track ON / OFF ON build track module
    build_modules_contrib ON / OFF ON build contributed modules
    build_tests ON / OFF ON build tests
    build_samples ON / OFF ON build samples
    RELEASE ON / OFF ON release / debug
    WITH_FFMPEG ON / OFF ON build with FFMPEG
    WITH_OPENCV ON / OFF ON build with OPENCV
    WITH_FREETYPE ON / OFF OFF build with FREETYPE
    WITH_RTSP ON / OFF ON build with RTSP
  4. If you want to build CNStream samples:

    a. Run the following command:

    cmake -Dbuild_samples=ON ${CNSTREAM_DIR}

    b. If wanna cross compile, please follow command to:

    cmake -DCMAKE_TOOLCHAIN_FILE=${CNSTREAM_DIR}/cmake/cross-compile.cmake ${CNSTREAM_DIR}

    Note: you need to configure toolchain by yourself in cross-compile.cmake and cross-compile gflags, glog, opencv, ffmpeg and install them into ${CNSTREAM_DIR}

    take MLU220EDGE as example:

    cmake ${CNSTREAM_DIR} -DCMAKE_TOOLCHAIN_FILE=${CNSTREAM_DIR}/cmake/cross-compile.cmake  -DCNIS_WITH_CURL=OFF -Dbuild_display=OFF -DMLU=MLU220EDGE
  5. Run the following command to build instructions:

    make
  6. If wanna install CNStream's head files and libraries to somewhere, please add CMAKE_INSTALL_PREFIX to cmake command as below:

    cmake {CNSTREAM_DIR} -DCMAKE_INSTALL_PREFIX=/path/to/install
    make
    make install

Samples

Classification Object Detection
Classification Object Detection
Object Tracking Secondary Classification
Object Tracking Secondary Classification

Demo Overview

This demo shows how to detect objects using CNStream. It includes the following plug-in modules:

  • source: Decodes video streams with MLU, such as local video files, RTMP stream, and RTSP stream.
  • detector: Neural Network inference with MLU.
  • osd: Draws inference results on images.
  • displayer: Displays inference results on the screen.

In the run.sh script, detection_config.json is set as the configuration file. In this configuration file, resnet34_ssd.cambricon is the offline model used for inference, which means, the data will be fed to an SSD model after decoding. And the results will be shown on the screen.

In addition, see the comments in cnstream/samples/demo/run.sh for details.

Also there are several demos as located under classification, detection, track, secondary, rtsp etc.

Run samples

To run the CNStream sample:

  1. Follow the steps above to build instructions.

  2. Run the demo using the list below:

    cd ${CNSTREAM_DIR}/samples/demo
    
    ./run.sh

Best Practices

How to create an application based on CNStream?

You should find a sample from samples/example/example.cpp that helps developers easily understand how to develop an application based on CNStream pipeline.

How to change the input video file?

Modify the files.list_video file, which is under the cnstream/samples/demo directory, to replace the video path. Each line represents one stream. It is recommended to use an absolute path or use a relative path relative to the executor path.

Documentation

Cambricon Forum Docs or CNStream Read-the-Docs

Check out the Examples page for tutorials on how to use CNStream. Concepts page for basic definitions

Community forum

Discuss - General community discussion around CNStream

Owner
Cambricon Technologies
Cambricon Technologies
Comments
  • 执行SSD 目标检测样例  ./run.sh出现报错

    执行SSD 目标检测样例 ./run.sh出现报错

    环境:docker 宿主机:centos 7.5

    错误日志: (* Note: Performance info of pipeline is slightly delayed compared to that of each stream.) Pipeline : -- [frame count]: 0, [processing time(s)]: 0.000000, [fps]: 0.0 [mjpeg @ 0x7fb7b8001d80] Changeing bps to 8 I1029 11:11:09.790115 54347 easy_infer.cpp:78] Init inference context, batch size: 1 device id: 0 I1029 11:11:09.817857 54347 easy_infer.cpp:96] Create MLU task queue from runtime context I1029 11:11:09.818697 54347 resize_and_colorcvt.cpp:178] Init ResizeAndConvert Operator, [batchsize: 16], [core_number: 16]. I1029 11:11:10.286540 54354 resize_and_colorcvt.cpp:278] MluTaskQueue has not been set, MluResizeConvertOp will create a new one 2020-10-29 11:11:10.287249: [cnrtError] [54354] [Card : 0] mluLaunchKernel fail. 2020-10-29 11:11:10.287352: [cnrtError] [54354] [Card : 0] fail to lanuch kernel. 2020-10-29 11:11:10.287449: [cnrtError] [54354] [Card : 0] for more information, please use core dump analysis tools. E1029 11:11:10.287614 54354 resize_and_colorcvt.cpp:339] Resize convert failed. Info: E1029 11:11:10.288530 54354 resize_and_colorcvt.cpp:340] dst w, dst h: 300300 E1029 11:11:10.288703 54354 resize_and_colorcvt.cpp:341] keep aspect ratio: 0 E1029 11:11:10.288830 54354 resize_and_colorcvt.cpp:342] batchsize: 16 E1029 11:11:10.288945 54354 resize_and_colorcvt.cpp:344] y plane attr: 0x200000ffcad00000 uv plane attr: 0x200000ffcad10000 src w: 256 src h: 256 src stride: 256 crop x: 0 crop y: 0 crop w: 256 crop h: 256 E1029 11:11:10.289341 54354 resize_and_colorcvt.cpp:344] y plane attr: 0x200000ffcad20000 uv plane attr: 0x200000ffcad30000 src w: 256 src h: 256 src stride: 256 crop x: 0 crop y: 0 crop w: 256 crop h: 256 E1029 11:11:10.289731 54354 resize_and_colorcvt.cpp:344] y plane attr: 0x200000ffcad40000 uv plane attr: 0x200000ffcad50000 src w: 256 src h: 256 src stride: 256 crop x: 0 crop y: 0 crop w: 256 crop h: 256 E1029 11:11:10.290042 54354 resize_and_colorcvt.cpp:344] y plane attr: 0x200000ffcad60000 uv plane attr: 0x200000ffcad70000 src w: 256 src h: 256 src stride: 256 crop x: 0 crop y: 0 crop w: 256 crop h: 256 E1029 11:11:10.290398 54354 resize_and_colorcvt.cpp:344] y plane attr: 0x200000ffcaf00000 uv plane attr: 0x200000ffcaf10000 src w: 256 src h: 256 src stride: 256 crop x: 0 crop y: 0 crop w: 256 crop h: 256 E1029 11:11:10.290792 54354 resize_and_colorcvt.cpp:344] y plane attr: 0x200000ffcaf20000 uv plane attr: 0x200000ffcaf30000 src w: 256 src h: 256 src stride: 256 crop x: 0 crop y: 0 crop w: 256 crop h: 256 E1029 11:11:10.291182 54354 resize_and_colorcvt.cpp:344] y plane attr: 0x200000ffcaf40000 uv plane attr: 0x200000ffcaf50000 src w: 256 src h: 256 src stride: 256 crop x: 0 crop y: 0 crop w: 256 crop h: 256 E1029 11:11:10.291554 54354 resize_and_colorcvt.cpp:344] y plane attr: 0x200000ffcaf60000 uv plane attr: 0x200000ffcaf70000 src w: 256 src h: 256 src stride: 256 crop x: 0 crop y: 0 crop w: 256 crop h: 256 E1029 11:11:10.291894 54354 resize_and_colorcvt.cpp:344] y plane attr: 0x200000ffd5b00000 uv plane attr: 0x200000ffd5b10000 src w: 256 src h: 256 src stride: 256 crop x: 0 crop y: 0 crop w: 256 crop h: 256 E1029 11:11:10.292261 54354 resize_and_colorcvt.cpp:344] y plane attr: 0x200000ffd5b20000 uv plane attr: 0x200000ffd5b30000 src w: 256 src h: 256 src stride: 256 crop x: 0 crop y: 0 crop w: 256 crop h: 256 E1029 11:11:10.292698 54354 resize_and_colorcvt.cpp:344] y plane attr: 0x200000ffd5b40000 uv plane attr: 0x200000ffd5b50000 src w: 256 src h: 256 src stride: 256 crop x: 0 crop y: 0 crop w: 256 crop h: 256 E1029 11:11:10.293067 54354 resize_and_colorcvt.cpp:344] y plane attr: 0x200000ffd5b60000 uv plane attr: 0x200000ffd5b70000 src w: 256 src h: 256 src stride: 256 crop x: 0 crop y: 0 crop w: 256 crop h: 256 E1029 11:11:10.293460 54354 resize_and_colorcvt.cpp:344] y plane attr: 0x200000ffccd00000 uv plane attr: 0x200000ffccd10000 src w: 256 src h: 256 src stride: 256 crop x: 0 crop y: 0 crop w: 256 crop h: 256 E1029 11:11:10.293900 54354 resize_and_colorcvt.cpp:344] y plane attr: 0x200000ffccd20000 uv plane attr: 0x200000ffccd30000 src w: 256 src h: 256 src stride: 256 crop x: 0 crop y: 0 crop w: 256 crop h: 256 E1029 11:11:10.294277 54354 resize_and_colorcvt.cpp:344] y plane attr: 0x200000ffccd40000 uv plane attr: 0x200000ffccd50000 src w: 256 src h: 256 src stride: 256 crop x: 0 crop y: 0 crop w: 256 crop h: 256 E1029 11:11:10.294665 54354 resize_and_colorcvt.cpp:344] y plane attr: 0x200000ffccd60000 uv plane attr: 0x200000ffccd70000 src w: 256 src h: 256 src stride: 256 crop x: 0 crop y: 0 crop w: 256 crop h: 256 I1029 11:11:10.296166 54354 mlu_context.cpp:50] Destroy MLU task queue E1029 11:11:10.296669 54354 inferencer.cpp:79] resize convert failed. 2020-10-29 11:11:10.297223: [cnrtError] [54405] [Card : 0] fail to lanuch kernel. 2020-10-29 11:11:10.297290: [cnrtError] [54405] [Card : 0] for more information, please use core dump analysis tools. 2020-10-29 11:11:10.297355: [cnrtError] [54405] [Card : 0] Invoke failed of index 0E1029 11:11:10.297410 54405 easy_infer.cpp:125] Invoke Runtime Context failed error code: 632028 terminate called after throwing an instance of 'edk::EasyInferError' what(): Invoke Runtime Context failed error code : 632028 *** Aborted at 1603969870 (unix time) try "date -d @1603969870" if you are using GNU date *** PC: @ 0x7fb83fb08387 __GI_raise *** SIGABRT (@0xd430) received by PID 54320 (TID 0x7fb7897d2700) from PID 54320; stack trace: *** @ 0x7fb841425630 (unknown) @ 0x7fb83fb08387 __GI_raise @ 0x7fb83fb09a78 __GI_abort @ 0x7fb8404187d5 (unknown) @ 0x7fb840416746 (unknown) @ 0x7fb840416773 (unknown) @ 0x7fb84046d105 (unknown) @ 0x7fb84141dea5 start_thread @ 0x7fb83fbd08dd __clone ./run.sh: line 35: 54320 Aborted (core dumped) $CURRENT_DIR/../bin/demo --data_path $CURRENT_DIR/files.list_image --src_frame_rate 30 --wait_time 0 --loop=false --raw_img_input=false --config_fname "$CURRENT_DIR/detection_config.json"

  • 运行 ./run.sh mlu270 kafka 出现kafka拒绝连接的错误

    运行 ./run.sh mlu270 kafka 出现kafka拒绝连接的错误

    在CNStream/samples/cns_launcher/object_detection路径下运行 # ./run.sh mlu270 kafka 出现以下报错 CNSTREAM Kafka E0112 08:09:16.067260 13903] FAIL: rdkafka#producer-1: [thrd:localhost:9092/bootstrap]: localhost:9092/bootstrap: Connect to ipv4#127.0.0.1:9092 failed: Connection refused CNSTREAM Kafka E0112 08:09:16.067299 13903] ERROR: rdkafka#producer-1: [thrd:localhost:9092/bootstrap]: localhost:9092/bootstrap: Connect to ipv4#127.0.0.1:9092 failed: Connection refused CNSTREAM Kafka E0112 08:09:16.067317 13903] ERROR: rdkafka#producer-1: [thrd:localhost:9092/bootstrap]: 1/1 brokers are down

    注:encode_jpeg/encode_video/display/rtsp/kafka 这几个选项中别的都试过,没有出现问题。

  • 运行generate_file_list.sh 文件报错

    运行generate_file_list.sh 文件报错

    在CNStream/samples目录下的运行如下命令: $ sh generate_file_list.sh 提示: generate_file_list.sh: 2: generate_file_list.sh: Bad substitution generate_file_list.sh: 6: generate_file_list.sh: Syntax error: Bad for loop variable 这是咋回事呢?

  • RTSP 推流访问

    RTSP 推流访问

    RTSP推流访问

    在运行CNStream/python/samples/python pycnstream_demo.py 例子,能够成功运行。但是现在想通过VLC播放器查看RTSP推流的视频,请问访问地址是多少? 我的访问地址是:rtsp://127.0.0.1:8554,在播放器上提示错误无法打开。 请问,rtsp的默认访问地址和访问方法是什么?

  • CMake create makefile failed

    CMake create makefile failed

    Hi CNSt. team,

    When I run "cmake -DCMAKE_TOOLCHAIN_FILE=${CNSTREAM_DIR}/cmake/cross-compile.cmake ${CNSTREAM_DIR}" , the error happens and output error message as below: CMake Error at CMakeLists.txt:227 (find_package): By not providing "FindSDL2.cmake" in CMAKE_MODULE_PATH this project has asked CMake to find a package configuration file provided by "SDL2", but CMake did not find one.

    Could not find a package configuration file provided by "SDL2" with any of the following names:

    SDL2Config.cmake
    sdl2-config.cmake
    

    Add the installation prefix of "SDL2" to CMAKE_PREFIX_PATH or set "SDL2_DIR" to a directory containing one of the above files. If "SDL2" provides a separate development package or SDK, be sure it has been installed.

    Could you help to check whether something wrong with cmake rule or something missing in my environment?

    Thanks

  • Bump numpy from 1.18.4 to 1.22.0 in /python

    Bump numpy from 1.18.4 to 1.22.0 in /python

    Bumps numpy from 1.18.4 to 1.22.0.

    Release notes

    Sourced from numpy's releases.

    v1.22.0

    NumPy 1.22.0 Release Notes

    NumPy 1.22.0 is a big release featuring the work of 153 contributors spread over 609 pull requests. There have been many improvements, highlights are:

    • Annotations of the main namespace are essentially complete. Upstream is a moving target, so there will likely be further improvements, but the major work is done. This is probably the most user visible enhancement in this release.
    • A preliminary version of the proposed Array-API is provided. This is a step in creating a standard collection of functions that can be used across application such as CuPy and JAX.
    • NumPy now has a DLPack backend. DLPack provides a common interchange format for array (tensor) data.
    • New methods for quantile, percentile, and related functions. The new methods provide a complete set of the methods commonly found in the literature.
    • A new configurable allocator for use by downstream projects.

    These are in addition to the ongoing work to provide SIMD support for commonly used functions, improvements to F2PY, and better documentation.

    The Python versions supported in this release are 3.8-3.10, Python 3.7 has been dropped. Note that 32 bit wheels are only provided for Python 3.8 and 3.9 on Windows, all other wheels are 64 bits on account of Ubuntu, Fedora, and other Linux distributions dropping 32 bit support. All 64 bit wheels are also linked with 64 bit integer OpenBLAS, which should fix the occasional problems encountered by folks using truly huge arrays.

    Expired deprecations

    Deprecated numeric style dtype strings have been removed

    Using the strings "Bytes0", "Datetime64", "Str0", "Uint32", and "Uint64" as a dtype will now raise a TypeError.

    (gh-19539)

    Expired deprecations for loads, ndfromtxt, and mafromtxt in npyio

    numpy.loads was deprecated in v1.15, with the recommendation that users use pickle.loads instead. ndfromtxt and mafromtxt were both deprecated in v1.17 - users should use numpy.genfromtxt instead with the appropriate value for the usemask parameter.

    (gh-19615)

    ... (truncated)

    Commits

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
    • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
    • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
    • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language

    You can disable automated security fix PRs for this repo from the Security Alerts page.

  • Bump numpy from 1.18.4 to 1.22.0 in /tools/web_visualize

    Bump numpy from 1.18.4 to 1.22.0 in /tools/web_visualize

    Bumps numpy from 1.18.4 to 1.22.0.

    Release notes

    Sourced from numpy's releases.

    v1.22.0

    NumPy 1.22.0 Release Notes

    NumPy 1.22.0 is a big release featuring the work of 153 contributors spread over 609 pull requests. There have been many improvements, highlights are:

    • Annotations of the main namespace are essentially complete. Upstream is a moving target, so there will likely be further improvements, but the major work is done. This is probably the most user visible enhancement in this release.
    • A preliminary version of the proposed Array-API is provided. This is a step in creating a standard collection of functions that can be used across application such as CuPy and JAX.
    • NumPy now has a DLPack backend. DLPack provides a common interchange format for array (tensor) data.
    • New methods for quantile, percentile, and related functions. The new methods provide a complete set of the methods commonly found in the literature.
    • A new configurable allocator for use by downstream projects.

    These are in addition to the ongoing work to provide SIMD support for commonly used functions, improvements to F2PY, and better documentation.

    The Python versions supported in this release are 3.8-3.10, Python 3.7 has been dropped. Note that 32 bit wheels are only provided for Python 3.8 and 3.9 on Windows, all other wheels are 64 bits on account of Ubuntu, Fedora, and other Linux distributions dropping 32 bit support. All 64 bit wheels are also linked with 64 bit integer OpenBLAS, which should fix the occasional problems encountered by folks using truly huge arrays.

    Expired deprecations

    Deprecated numeric style dtype strings have been removed

    Using the strings "Bytes0", "Datetime64", "Str0", "Uint32", and "Uint64" as a dtype will now raise a TypeError.

    (gh-19539)

    Expired deprecations for loads, ndfromtxt, and mafromtxt in npyio

    numpy.loads was deprecated in v1.15, with the recommendation that users use pickle.loads instead. ndfromtxt and mafromtxt were both deprecated in v1.17 - users should use numpy.genfromtxt instead with the appropriate value for the usemask parameter.

    (gh-19615)

    ... (truncated)

    Commits

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
    • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
    • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
    • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language

    You can disable automated security fix PRs for this repo from the Security Alerts page.

  • Bump numpy from 1.18.4 to 1.21.0 in /python

    Bump numpy from 1.18.4 to 1.21.0 in /python

    Bumps numpy from 1.18.4 to 1.21.0.

    Release notes

    Sourced from numpy's releases.

    v1.21.0

    NumPy 1.21.0 Release Notes

    The NumPy 1.21.0 release highlights are

    • continued SIMD work covering more functions and platforms,
    • initial work on the new dtype infrastructure and casting,
    • universal2 wheels for Python 3.8 and Python 3.9 on Mac,
    • improved documentation,
    • improved annotations,
    • new PCG64DXSM bitgenerator for random numbers.

    In addition there are the usual large number of bug fixes and other improvements.

    The Python versions supported for this release are 3.7-3.9. Official support for Python 3.10 will be added when it is released.

    :warning: Warning: there are unresolved problems compiling NumPy 1.21.0 with gcc-11.1 .

    • Optimization level -O3 results in many wrong warnings when running the tests.
    • On some hardware NumPy will hang in an infinite loop.

    New functions

    Add PCG64DXSM BitGenerator

    Uses of the PCG64 BitGenerator in a massively-parallel context have been shown to have statistical weaknesses that were not apparent at the first release in numpy 1.17. Most users will never observe this weakness and are safe to continue to use PCG64. We have introduced a new PCG64DXSM BitGenerator that will eventually become the new default BitGenerator implementation used by default_rng in future releases. PCG64DXSM solves the statistical weakness while preserving the performance and the features of PCG64.

    See upgrading-pcg64 for more details.

    (gh-18906)

    Expired deprecations

    • The shape argument numpy.unravel_index cannot be passed as dims keyword argument anymore. (Was deprecated in NumPy 1.16.)

    ... (truncated)

    Commits
    • b235f9e Merge pull request #19283 from charris/prepare-1.21.0-release
    • 34aebc2 MAINT: Update 1.21.0-notes.rst
    • 493b64b MAINT: Update 1.21.0-changelog.rst
    • 07d7e72 MAINT: Remove accidentally created directory.
    • 032fca5 Merge pull request #19280 from charris/backport-19277
    • 7d25b81 BUG: Fix refcount leak in ResultType
    • fa5754e BUG: Add missing DECREF in new path
    • 61127bb Merge pull request #19268 from charris/backport-19264
    • 143d45f Merge pull request #19269 from charris/backport-19228
    • d80e473 BUG: Removed typing for == and != in dtypes
    • Additional commits viewable in compare view

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
    • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
    • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
    • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language

    You can disable automated security fix PRs for this repo from the Security Alerts page.

  • Bump opencv-python from 4.0.0.21 to 4.2.0.32 in /python

    Bump opencv-python from 4.0.0.21 to 4.2.0.32 in /python

    Bumps opencv-python from 4.0.0.21 to 4.2.0.32.

    Release notes

    Sourced from opencv-python's releases.

    4.2.0.32

    OpenCV version 4.2.0.

    Changes:

    • macOS environment updated from xcode8.3 to xcode 9.4
    • macOS uses now Qt 5 instead of Qt 4
    • Nasm version updated to Docker containers
    • multibuild updated

    Fixes:

    • don't use deprecated brew tap-pin, instead refer to the full package name when installing #267
    • replace get_config_var() with get_config_vars() in setup.py #274
    • add workaround for DLL errors in Windows Server #264

    4.1.2.30

    OpenCV version 4.1.2.

    Changes:

    • Python 3.8 builds added to the build matrix
    • Support for Python 3.4 builds dropped (Python 3.4 is in EOL)
    • multibuild updated
    • minor build logic changes
    • Docker images rebuilt

    Notes:

    Please note that Python 2.7 enters into EOL phase in January 2020. opencv-python Python 2.7 wheels won't be provided after that.

    4.1.1.26

    OpenCV version 4.1.1.

    Changes:

    ... (truncated)

    Commits

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
    • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
    • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
    • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language

    You can disable automated security fix PRs for this repo from the Security Alerts page.

  • Bump numpy from 1.18.4 to 1.21.0 in /tools/web_visualize

    Bump numpy from 1.18.4 to 1.21.0 in /tools/web_visualize

    Bumps numpy from 1.18.4 to 1.21.0.

    Release notes

    Sourced from numpy's releases.

    v1.21.0

    NumPy 1.21.0 Release Notes

    The NumPy 1.21.0 release highlights are

    • continued SIMD work covering more functions and platforms,
    • initial work on the new dtype infrastructure and casting,
    • universal2 wheels for Python 3.8 and Python 3.9 on Mac,
    • improved documentation,
    • improved annotations,
    • new PCG64DXSM bitgenerator for random numbers.

    In addition there are the usual large number of bug fixes and other improvements.

    The Python versions supported for this release are 3.7-3.9. Official support for Python 3.10 will be added when it is released.

    :warning: Warning: there are unresolved problems compiling NumPy 1.21.0 with gcc-11.1 .

    • Optimization level -O3 results in many wrong warnings when running the tests.
    • On some hardware NumPy will hang in an infinite loop.

    New functions

    Add PCG64DXSM BitGenerator

    Uses of the PCG64 BitGenerator in a massively-parallel context have been shown to have statistical weaknesses that were not apparent at the first release in numpy 1.17. Most users will never observe this weakness and are safe to continue to use PCG64. We have introduced a new PCG64DXSM BitGenerator that will eventually become the new default BitGenerator implementation used by default_rng in future releases. PCG64DXSM solves the statistical weakness while preserving the performance and the features of PCG64.

    See upgrading-pcg64 for more details.

    (gh-18906)

    Expired deprecations

    • The shape argument numpy.unravel_index cannot be passed as dims keyword argument anymore. (Was deprecated in NumPy 1.16.)

    ... (truncated)

    Commits
    • b235f9e Merge pull request #19283 from charris/prepare-1.21.0-release
    • 34aebc2 MAINT: Update 1.21.0-notes.rst
    • 493b64b MAINT: Update 1.21.0-changelog.rst
    • 07d7e72 MAINT: Remove accidentally created directory.
    • 032fca5 Merge pull request #19280 from charris/backport-19277
    • 7d25b81 BUG: Fix refcount leak in ResultType
    • fa5754e BUG: Add missing DECREF in new path
    • 61127bb Merge pull request #19268 from charris/backport-19264
    • 143d45f Merge pull request #19269 from charris/backport-19228
    • d80e473 BUG: Removed typing for == and != in dtypes
    • Additional commits viewable in compare view

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
    • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
    • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
    • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language

    You can disable automated security fix PRs for this repo from the Security Alerts page.

  • Bump opencv-python from 4.0.0.21 to 4.2.0.32 in /tools/web_visualize

    Bump opencv-python from 4.0.0.21 to 4.2.0.32 in /tools/web_visualize

    Bumps opencv-python from 4.0.0.21 to 4.2.0.32.

    Release notes

    Sourced from opencv-python's releases.

    4.2.0.32

    OpenCV version 4.2.0.

    Changes:

    • macOS environment updated from xcode8.3 to xcode 9.4
    • macOS uses now Qt 5 instead of Qt 4
    • Nasm version updated to Docker containers
    • multibuild updated

    Fixes:

    • don't use deprecated brew tap-pin, instead refer to the full package name when installing #267
    • replace get_config_var() with get_config_vars() in setup.py #274
    • add workaround for DLL errors in Windows Server #264

    4.1.2.30

    OpenCV version 4.1.2.

    Changes:

    • Python 3.8 builds added to the build matrix
    • Support for Python 3.4 builds dropped (Python 3.4 is in EOL)
    • multibuild updated
    • minor build logic changes
    • Docker images rebuilt

    Notes:

    Please note that Python 2.7 enters into EOL phase in January 2020. opencv-python Python 2.7 wheels won't be provided after that.

    4.1.1.26

    OpenCV version 4.1.1.

    Changes:

    ... (truncated)

    Commits

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
    • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
    • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
    • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language

    You can disable automated security fix PRs for this repo from the Security Alerts page.

  • cpu 利用率低

    cpu 利用率低

    在mlu220-som上使用cnstream,模型的预处理与推理均在MLU上,而后处理在CPU上。 得到的MLU利用率只有74%,CPU利用率只有53%左右,4个核心没有跑满。 测试过如果将后处理省略掉的话,MLU就可以跑到100%利用率。也就是说性能瓶颈在CPU端的后处理上。 请问如何才能使得CPU的4个核心都跑满呢?

Vowpal Wabbit is a machine learning system which pushes the frontier of machine learning with techniques such as online, hashing, allreduce, reductions, learning2search, active, and interactive learning.
Vowpal Wabbit is a machine learning system which pushes the frontier of machine learning with techniques such as online, hashing, allreduce, reductions, learning2search, active, and interactive learning.

This is the Vowpal Wabbit fast online learning code. Why Vowpal Wabbit? Vowpal Wabbit is a machine learning system which pushes the frontier of machin

Dec 30, 2022
Deep Scalable Sparse Tensor Network Engine (DSSTNE) is an Amazon developed library for building Deep Learning (DL) machine learning (ML) models

Amazon DSSTNE: Deep Scalable Sparse Tensor Network Engine DSSTNE (pronounced "Destiny") is an open source software library for training and deploying

Dec 30, 2022
A library for creating Artificial Neural Networks, for use in Machine Learning and Deep Learning algorithms.
A library for creating Artificial Neural Networks, for use in Machine Learning and Deep Learning algorithms.

iNeural A library for creating Artificial Neural Networks, for use in Machine Learning and Deep Learning algorithms. What is a Neural Network? Work on

Apr 5, 2022
An Open Source Machine Learning Framework for Everyone
An Open Source Machine Learning Framework for Everyone

Documentation TensorFlow is an end-to-end open source platform for machine learning. It has a comprehensive, flexible ecosystem of tools, libraries, a

Jan 7, 2023
A fast, distributed, high performance gradient boosting (GBT, GBDT, GBRT, GBM or MART) framework based on decision tree algorithms, used for ranking, classification and many other machine learning tasks.

Light Gradient Boosting Machine LightGBM is a gradient boosting framework that uses tree based learning algorithms. It is designed to be distributed a

Jan 5, 2023
SecMML: Secure MPC(multi-party computation) Machine Learning Framework
SecMML: Secure MPC(multi-party computation) Machine Learning Framework

SecMML 介绍 SecMML是FudanMPL(Multi-Party Computation + Machine Learning)的一个分支,是用于训练机器学习模型的高效可扩展的安全多方计算(MPC)框架,基于BGW协议实现。此框架可以应用到三个及以上参与方联合训练的场景中。目前,SecMM

Dec 27, 2022
Distributed machine learning platform

Veles Distributed platform for rapid Deep learning application development Consists of: Platform - https://github.com/Samsung/veles Znicz Plugin - Neu

Dec 5, 2022
An open source machine learning library for performing regression tasks using RVM technique.

Introduction neonrvm is an open source machine learning library for performing regression tasks using RVM technique. It is written in C programming la

May 31, 2022
A fast, scalable, high performance Gradient Boosting on Decision Trees library, used for ranking, classification, regression and other machine learning tasks for Python, R, Java, C++. Supports computation on CPU and GPU.
A fast, scalable, high performance Gradient Boosting on Decision Trees library, used for ranking, classification, regression and other machine learning tasks for Python, R, Java, C++. Supports computation on CPU and GPU.

Website | Documentation | Tutorials | Installation | Release Notes CatBoost is a machine learning method based on gradient boosting over decision tree

Dec 31, 2022
A lightweight C++ machine learning library for embedded electronics and robotics.

Fido Fido is an lightweight, highly modular C++ machine learning library for embedded electronics and robotics. Fido is especially suited for robotic

Dec 17, 2022
High performance, easy-to-use, and scalable machine learning (ML) package, including linear model (LR), factorization machines (FM), and field-aware factorization machines (FFM) for Python and CLI interface.
High performance, easy-to-use, and scalable machine learning (ML) package, including linear model (LR), factorization machines (FM), and field-aware factorization machines (FFM) for Python and CLI interface.

What is xLearn? xLearn is a high performance, easy-to-use, and scalable machine learning package that contains linear model (LR), factorization machin

Dec 23, 2022
Feature Store for Machine Learning
Feature Store for Machine Learning

Overview Feast (Feature Store) is an operational data system for managing and serving machine learning features to models in production. Please see ou

Jan 4, 2023
Machine Learning Platform for Kubernetes
Machine Learning Platform for Kubernetes

Reproduce, Automate, Scale your data science. Welcome to Polyaxon, a platform for building, training, and monitoring large scale deep learning applica

Jan 1, 2023
In-situ data analyses and machine learning with OpenFOAM and Python

PythonFOAM: In-situ data analyses with OpenFOAM and Python Using Python modules for in-situ data analytics with OpenFOAM 8. NOTE that this is NOT PyFO

Dec 29, 2022
In this tutorial, we will use machine learning to build a gesture recognition system that runs on a tiny microcontroller, the RP2040.
In this tutorial, we will use machine learning to build a gesture recognition system that runs on a tiny microcontroller, the RP2040.

Pico-Motion-Recognition This Repository has the code used on the 2 parts tutorial TinyML - Motion Recognition Using Raspberry Pi Pico The first part i

Nov 3, 2022
Edge ML Library - High-performance Compute Library for On-device Machine Learning Inference
 Edge ML Library - High-performance Compute Library for On-device Machine Learning Inference

Edge ML Library (EMLL) offers optimized basic routines like general matrix multiplications (GEMM) and quantizations, to speed up machine learning (ML) inference on ARM-based devices. EMLL supports fp32, fp16 and int8 data types. EMLL accelerates on-device NMT, ASR and OCR engines of Youdao, Inc.

Dec 20, 2022
A flexible, high-performance serving system for machine learning models

XGBoost Serving This is a fork of TensorFlow Serving, extended with the support for XGBoost, alphaFM and alphaFM_softmax frameworks. For more informat

Nov 18, 2022
Examples for using ONNX Runtime for machine learning inferencing.
Examples for using ONNX Runtime for machine learning inferencing.

Examples for using ONNX Runtime for machine learning inferencing.

Jan 3, 2023
Provide sample code of efficient operator implementation based on the Cambrian Machine Learning Unit (MLU) .

Cambricon CNNL-Example CNNL-Example 提供基于寒武纪机器学习单元(Machine Learning Unit,MLU)开发高性能算子、C 接口封装的示例代码。 依赖条件 操作系统: 目前只支持 Ubuntu 16.04 x86_64 寒武纪 MLU SDK: 编译和

Mar 7, 2022