git 地址:https://github.com/NVIDIA-AI-IOT/deepstream_python_apps

简介:

python通过pybindings访问deepstream的C库,pybindings使用的第三方库是pybind11。

pybind11 is a lightweight header-only library that exposes C++ types in Python。

环境搭建:

先安装编译各种库,参见:deepstream_python_apps/bindings at master · NVIDIA-AI-IOT/deepstream_python_apps · GitHub

binddings的编译:

deepstream_python_apps/bindings at master · NVIDIA-AI-IOT/deepstream_python_apps · GitHub

主要步骤是:

3.1.1 Quick build (x86-ubuntu-20.04 | python 3.8 | Deepstream 6.1)
cd deepstream_python_apps/bindings
mkdir build
cd build
cmake ..
make
4.1 Installing the pip wheel
apt install libgirepository1.0-dev libcairo2-dev
pip3 install ./pyds-1.1.2-py3-none*.whl
测试步骤:

python3 deepstream_test_1.py ../../../../samples/streams/sample_720p.h264

runtime_source_add_delete

This application demonstrates how to:
* Add and delete sources at runtime.
* Use a uridecodebin so that any type of input (e.g. RTSP/File), any GStreamersupported container format, and any codec can be used as input.
* Configure the stream-muxer to generate a batch of frames and infer on thebatch for better resource utilization.
* Configure the tracker (referred to as nvtracker in this sample) usingconfig file dstest_tracker_config.txt

add_sources{

#达到最大个数后,开始删source。

if (g_num_sources == MAX_NUM_SOURCES):

GObject.timeout_add_seconds(10, delete_sources, g_source_bin_list)

return False

}

main(){

GObject.timeout_add_seconds(10, add_sources, g_source_bin_list)  //每隔开10秒加source.

}

deepstream-imagedata-multistream

这个例子的目的:
* Access imagedata in a multistream source
* Modify the images in-place. Changes made to the buffer will reflect in the downstream but  
  color format, resolution and numpy transpose operations are not permitted.  
* Make a copy of the image, modify it and save to a file. These changes are made on the copy  
  of the image and will not be seen downstream.
* Extract the stream metadata, imagedata, which contains useful information about the
  frames in the batched buffer.
* Annotating detected objects within certain confidence interval
* Use OpenCV to draw bboxes on the image and save it to file.
* Use multiple sources in the pipeline.
* Use a uridecodebin so that any type of input (e.g. RTSP/File), any GStreamer
  supported container format, and any codec can be used as input.
* Configure the stream-muxer to generate a batch of frames and infer on the
  batch for better resource utilization.

标红的特色例子,其他的在其他例子都有出现。总结下来是:1.修改源buffer, 用opencv在上面画个图,但不能修改buffer的颜色格式,分辨率等。2. copy一份源buffer,并修改保存,不会影响源buffer。

deepstream python相关推荐

  1. Nvidia Deepstream极致细节:3. Deepstream Python RTSP视频输出显示

    Nvidia Deepstream极致细节:3. Deepstream Python RTSP视频输出显示 此章节将详细对官方案例:deepstream_test_1_rtsp_out.py作解读.d ...

  2. Nvidia Deepstream极致细节:2. Deepstream Python Meta数据解读

    Nvidia Deepstream极致细节:2. Deepstream Python Meta数据解读 这一章节中,我们将介绍如何使用Nvidia Deepstream内自定义的Metadata,包括 ...

  3. Nvidia Deepstream小细节系列:Deepstream python保存pipeline结构图

    Nvidia Deepstream小细节系列:Deepstream python保存pipeline结构图 提示:此章节我们将着重阐述如何在Deepstream Python运行的情况下保存pipel ...

  4. DeepStream python接口探索

    本文承接上文,记录对英伟达DeepStream python接口的初步探索. DeepStream-Python使用Gst-Python API操作构建操作管线(pipeline),并使用探针函数(p ...

  5. deepstream(deepstream python)

    新概念英语第三册生词适合哪个年级 个人觉得,新概念第一册学完,初中知识没问题.第二册学完,高中基本也能通过. 第三册我建议考大学英语4,6级时看就可以.里面课文较长,生词教多,不建议高中学习.我是高三 ...

  6. NVIDIA DeepStream 5.0构建智能视频分析应用程序

    NVIDIA DeepStream 5.0构建智能视频分析应用程序 无论是要平衡产品分配和优化流量的仓库,工厂流水线检查还是医院管理,要确保员工和护理人员在照顾病人的同时使用个人保护设备(PPE),就 ...

  7. NVIDIA相关资料(一)——Deepstream相关知识

    来源于官网翻译资料Welcome to the DeepStream Documentation - DeepStream 5.1 Release documentation 1.DeepStream ...

  8. 我的NVIDIA开发者之旅——利用NVIDIA TAO工具包3.0和Deepstream快速搭建车辆信息识别系统

    利用NVIDIA TAO工具包3.0和Deepstream快速搭建车辆信息识别系统 实现目标 部署工具:NVIDIA DeepStream SDK 简单设置参数 工作流程 注意事项 GPU深度学习推理 ...

  9. deepstream学习笔记(二):gstreamer与deepstream-test1说明

    Gstreamer介绍 gstreamer简介 gstreamer tools 相关工具介绍 gstreamer 组成说明 Element pad bin 与 pipeline Communicati ...

最新文章

  1. 值得收藏!基于激光雷达数据的深度学习目标检测方法大合集(上)
  2. swift iOS8 XIB 问题 ViewController.init() xib
  3. python-之基本语法
  4. 【Linux】【服务器】 CentOS7下安装Redis详细过程步骤
  5. callapplybind的js实现以及应用
  6. Flask基础知识点1
  7. 基于NEO的私链(Private Blockchain)
  8. pandas输出列名_pandas中的DataFrame按指定顺序输出所有列的方法
  9. Vue项目中如何设置动态的TDK
  10. koa --- mongoose连接mongoDB
  11. Swift开发图解入门
  12. Duration(2020多校第二场D)
  13. Pandas 基本文本数据处理
  14. 《信息存储与管理(第二版):数字信息的存储、管理和保护》—— 2.1 应用...
  15. 关于缓存穿透,缓存击穿,缓存雪崩,热点数据失效问题的解决方案
  16. plsql 存储过程 批量提交_浅谈PetShop之使用存储过程与PLSQL批量处理(附案例)
  17. 2.同步(Synchronization)
  18. 新版FMEA软件参数图(P图)免费申请试用(FMEAHunter)
  19. 全网首篇用人话讲清楚:光纤中的色散
  20. 【M24】了解虚方法、多继承、虚基类、RTTI的成本

热门文章

  1. 【SQL系列学习(五)】
  2. 英语中容易混淆的单词词意
  3. 天龙八部张家界聚贤庄服务器维护,【4月18日】4组服务器合服公告
  4. java是前端还是后端 对于java来讲那个以后发展的会更好
  5. php和Java哪个好?php和Java的对比
  6. 【Qt】实现波浪动画效果
  7. 需要很高的天赋才能成为天才程序员吗?
  8. 魂斗罗 归来 个人攻略经验总结
  9. 算法基础课:第一讲——基础算法
  10. LR和Jmeter的区别