Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Section
Column
width50%
Panel
borderColor#CCCCCC
bgColor#FFFFFF
titleBGColor#F0F0F0
borderStylesolid
titleOn the page:

Table of Contents

Column

General information

It can take several minutes to launch neural analytics algorithms on NVIDIA GPU after server restart. At this time, the neural models are optimized for the current GPU type.

You can use the caching function to ensure that this operation is performed only once. Caching saves the optimization results on the hard drive and uses it for the subsequent analytics runs. 

Starting from Starting with DetectorPack 3.9, a utility was added to the Neuro Pack add-ons (see see Installing DetectorPack addonsadd-ons), which allows you to create GPU neural network caches without using using Axxon One. The presence of the cache speeds up the initialization and optimizes video memory consumption.

Optimizing the operation of neural analytics on GPU

To optimize the operation of the neural analytics on GPUTo create GPU network caches using the utility, do the following:

  1. Stop the

  2. Server
  3. server (see

  4. Shutting down a Server).
  5. Stop the server).

    Note
    titleAttention!

    If the system has the software running on GPU, it is necessary to stop its operation.

  6. In Windows OS, go to Settings System Display Graphics Settings. Turn off the Hardware-accelerated GPU scheduling toggle.This option increases the load on the server.
  7. Create the
  8. Create the 

  9. GPU_CACHE_DIR system variable (

  10. see Configuring the acceleration of GPU-based neuroanalytics)
  11. see Creating system variable) by specifying in the Variable value field the path to the cache location with an arbitrary folder name. For example, D:\GPU_cache. The specified directory will store the cache for all used detectors and neural networks.
    The cache size depends on the number of neural networks used and their type. The minimum size is 70 MB.

  12. Run the command prompt as administrator.
  13. To call the utility,

  14. open
  15. in the command

  16. line: C
  17. prompt, enter C:\Program Files\Common Files\AxxonSoft\DetectorPack\NeuroPackGpuCacheGenerator.exe

  18. and press
  19. .

  20. Press Enter.

  21. Specify the
  22. required NVIDIA GPU and press
  23. ID of the required Nvidia GPU (see Selecting Nvidia GPU when configuring detectors).
  24. Press Enter.

Creation of GPU network caches using the utility Optimizing the operation of the neural analytics on GPU is complete. The utility will create the caches of four neural networks included in the Neuro Pack add-ons:

  • GeneralNMHuman_v1.0GPU_onnx.ann
  • —human
  • (or GeneralNMHuman_v1.0_onnx.ann, starting with Detector Pack 3.16)—person;
  • smokeScanned_v1_onnx
  • .ann—smoke
  • .ann (or bestSmoke_v1.ann starting with Detector Pack 3.14)—smoke detection;
  • fireScanned_v1_onnx
  • .ann—fire
  • .ann (or bestFire_v1.ann starting with Detector Pack 3.14)—fire detection;
  • reid_15_0_256__osnetfpn_segmentation_noise_20_common_29_onnx.
  • ann—search
  • ann—search for the similar in the Neural
  • Tracker
  • tracker (see
  • Image Search
  • Similitude search).
  • Image Removed

...

Note
titleAttention!

The cache must be recreated in the following cases:

...

  • .

Creating GPU neural network caches using

...

parameters

  1. -p is a

  2. key
  3. parameter to create a cache for a particular neural network.
    Command example:

    Code Block
    C:\Program Files\Common Files\AxxonSoft\DetectorPack\NeuroPackGpuCacheGenerator.exe -p "<System disk>\
  4. <Network
  5. <Neural network location directory>\
  6. Network
  7. Neural_network_name.ann"

    To create a cache for multiple neural networks, list the paths to the selected neural networks, separated by a space.

  8. Command example
  9. Example of a command:

    Code Block
    C:\Program Files\Common Files\AxxonSoft\DetectorPack\NeuroPackGpuCacheGenerator.exe -p "<System disk>\
  10. <Network
  11. <Neural network location directory>\
  12. Network
  13. Neural_network_name.ann" "C:\Program Files\Common Files\AxxonSoft\DetectorPack\NeuroSDK\WaterLevelRuleNet_origin_onnx.ann"
  14. -v is a

  15. key
  16. parameter to output the procedure log to the console during cache generation.

  17. Command example
  18. Example of a command to automatically create caches of four neural networks included in the Neuro Pack add-ons with log output:

    Code Block
    C:\Program Files\Common Files\AxxonSoft\DetectorPack\NeuroPackGpuCacheGenerator.exe -v
  19. Command example
  20. Example of a command:

    Code Block
    C:\Program Files\Common Files\AxxonSoft\DetectorPack\NeuroPackGpuCacheGenerator.exe -p "<System disk>\
  21. <Network
  22. <Neural network location directory>\
  23. Network
  24. Neural_network_name.ann" -v
  25. --int8=1 is a

  26. key
  27. parameter to create a

  28. quantized version of the
  29. cache for those neural networks for which quantization is available. Neural networks for which the quantization mode is available are included in the Neuro Pack add-ons together with the *.info file. By default, the --int8=0

  30. key
  31. parameter is disabled.

  32. Command example
  33. Example of a command:

    Code Block
    C:\Program Files\Common Files\AxxonSoft\DetectorPack\NeuroPackGpuCacheGenerator.exe --int8=1
  34. Note
    titleAttention!

    The networks for which the quantization mode is available are included in the Neuro Pack add-ons together with the *.info file.

    The
  35. -f is a parameter to save logs of the caching procedure to files. It is available starting with DetectorPack 3.15. When you use the -v and -f parameters together, logs for each created cache are saved to: <Path to the cache folder created for the GPU_CACHE_DIR system variable>\caching-utility-log. A separate log file is created for each neural network. Log files created during previous runs of the utility are deleted.
    Example of a command for creating a cache with detailed logging to the console and saving logs to files:
    Code Block
    languageshell
    C:\Program Files\Common Files\AxxonSoft\DetectorPack\NeuroPackGpuCacheGenerator.exe -v -f

The neural networks for which the quantization mode is available (see Neural trackerStopped object detector, Neural counter):

  • GeneralNMCar_v1.0GPU_onnx.ann

...

  • (or GeneralNMCar_v1.0_onnx.ann,starting with Detector Pack 3.16)—Vehicle.
  • GeneralNMHuman_v1.0GPU_onnx.ann (or GeneralNMHuman_v1.0_onnx.ann

...

  • ,starting with Detector Pack 3.16)—Person.
  • GeneralNMHumanTopView_v0.8GPU_onnx.ann (or GeneralNMHumanTopView_v0.8_onnx.ann, starting with Detector Pack 3.16)—Person (top-down view).

Starting with DetectorPack 3.11, the following neural networks were added:

  • GeneralNMHumanAndVehicle_Nano_v1.0_GPU_onnx.ann—Person and vehicle (Nano).
  • GeneralNMHumanAndVehicle_Medium_v1.0_GPU_onnx.ann—Person and vehicle (Medium).
  • GeneralNMHumanAndVehicle_Large_v1.0_GPU_onnx

...

  • .ann—Person and vehicle (Large).

Starting with DetectorPack 3.12, the following neural networks were added:

  • GeneralNMHumanTopView_Nano_v1.0_GPU_onnx.ann—Person (top-down view Nano).
  • GeneralNMHumanTopView_Medium_v1.0_GPU_onnx.ann—Person (top-down view Medium).
  • GeneralNMHumanTopView_Large_v1.0_GPU_onnx.ann—Person (top-down view Large).