在file1.cc中在进行图片推理时,初始化调用了接口aclrtSetDevice和aclrtCreateContext;工程还在运行中,
然后调用file2.cc进行dvpp视频解码推理,又需要初始化,接口aclrtSetDevice和aclrtCreateContext是不是不能重复调用;
源码如下:

目前在file2.cc中重新调用aclrtCreateContext创建了context,
打开视频时,报错:Could not open video:rtsp://172.16.4.6/1920test.264, return :-1330794744, error info:Protocol not found,具体日志如图所示:

然后调用file2.cc进行dvpp视频解码推理,又需要初始化,接口aclrtSetDevice和aclrtCreateContext是不是不能重复调用;
源码如下:
目前在file2.cc中重新调用aclrtCreateContext创建了context,
打开视频时,报错:Could not open video:rtsp://172.16.4.6/1920test.264, return :-1330794744, error info:Protocol not found,具体日志如图所示: