Register
Login
Resources
Docs Blog Datasets Glossary Case Studies Tutorials & Webinars
Product
Data Engine LLMs Platform Enterprise
Pricing Explore
Connect to our Discord channel
zhliu 46bfd6b89c
Update to 1.0.2 release
3 years ago
..
46bfd6b89c
Update to 1.0.2 release
3 years ago
46bfd6b89c
Update to 1.0.2 release
3 years ago
46bfd6b89c
Update to 1.0.2 release
3 years ago
46bfd6b89c
Update to 1.0.2 release
3 years ago
46bfd6b89c
Update to 1.0.2 release
3 years ago
46bfd6b89c
Update to 1.0.2 release
3 years ago

README

You have to be logged in to leave a comment. Sign In
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
  1. ################################################################################
  2. # Copyright (c) 2019-2021, NVIDIA CORPORATION. All rights reserved.
  3. #
  4. # Permission is hereby granted, free of charge, to any person obtaining a
  5. # copy of this software and associated documentation files (the "Software"),
  6. # to deal in the Software without restriction, including without limitation
  7. # the rights to use, copy, modify, merge, publish, distribute, sublicense,
  8. # and/or sell copies of the Software, and to permit persons to whom the
  9. # Software is furnished to do so, subject to the following conditions:
  10. #
  11. # The above copyright notice and this permission notice shall be included in
  12. # all copies or substantial portions of the Software.
  13. #
  14. # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
  15. # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
  16. # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
  17. # THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
  18. # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
  19. # FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
  20. # DEALINGS IN THE SOFTWARE.
  21. ################################################################################
  22. Prerequisites:
  23. - DeepStreamSDK 5.1
  24. - Python 3.6
  25. - Gst-python
  26. To run:
  27. $ python3 deepstream_nvdsanalytics.py <uri1> [uri2] ... [uriN]
  28. e.g.
  29. $ python3 deepstream_nvdsanalytics.py file:///home/ubuntu/video1.mp4 file:///home/ubuntu/video2.mp4
  30. $ python3 deepstream_nvdsanalytics.py rtsp://127.0.0.1/video1 rtsp://127.0.0.1/video2
  31. This document describes the sample deepstream-nvdsanalytics application.
  32. This sample builds on top of the deepstream-test3 sample to demonstrate how to:
  33. * Use multiple sources in the pipeline.
  34. * Use a uridecodebin so that any type of input (e.g. RTSP/File), any GStreamer
  35. supported container format, and any codec can be used as input.
  36. * Configure the stream-muxer to generate a batch of frames and infer on the
  37. batch for better resource utilization.
  38. * Configure the tracker (referred to as nvtracker in this sample) uses
  39. config file dsnvanalytics_tracker_config.txt
  40. * Configure the nvdsanalytics plugin (referred to as nvanalytics in this sample)
  41. uses config file config_nvdsanalytics.txt
  42. * Extract the stream metadata, which contains useful information about the
  43. objects and frames in the batched buffer.
  44. This sample accepts one or more H.264/H.265 video streams as input. It creates
  45. a source bin for each input and connects the bins to an instance of the
  46. "nvstreammux" element, which forms the batch of frames. The batch of
  47. frames is fed to "nvinfer" for batched inferencing. The batched buffer is
  48. used as input for "nvtracker" which adds object tracking, which is then fed into
  49. "nvdsanalytics" element which runs analytics algorithms on these objects.
  50. This output is then composited into a 2D tile array using "nvmultistreamtiler."
  51. The rest of the pipeline is similar to the deepstream-test3 sample.
  52. The "width" and "height" properties must be set on the stream-muxer to set the
  53. output resolution. If the input frame resolution is different from
  54. stream-muxer's "width" and "height", the input frame will be scaled to muxer's
  55. output resolution.
  56. The stream-muxer waits for a user-defined timeout before forming the batch. The
  57. timeout is set using the "batched-push-timeout" property. If the complete batch
  58. is formed before the timeout is reached, the batch is pushed to the downstream
  59. element. If the timeout is reached before the complete batch can be formed
  60. (which can happen in case of rtsp sources), the batch is formed from the
  61. available input buffers and pushed. Ideally, the timeout of the stream-muxer
  62. should be set based on the framerate of the fastest source. It can also be set
  63. to -1 to make the stream-muxer wait infinitely.
  64. The "nvmultistreamtiler" composite streams based on their stream-ids in
  65. row-major order (starting from stream 0, left to right across the top row, then
  66. across the next row, etc.).
Tip!

Press p or to see the previous file or, n or to see the next file

Comments

Loading...