Dear DeepStream community,
When I run DeepStream3.0 with different sources like video/RTSP-format:hevc/yuv420/8k(7680x4320)/10bits
the output seems not to decode correctly, but sources with hevc/yuv420/8k(7680x4320)/8bits works fine,
and show the correct output as I expected, the issue is only with 10bits
output on screen and config.txt are as attached
GPU : RTX TITAN
Any suggestions how to avoid ?
test.txt (3.28 KB)
RTX TITAN is Turning GPU which should support hevc 4:2:0 12 bits.
https://developer.nvidia.com/nvidia-video-codec-sdk
Can you download our latest video codec sdk 9.0 from this link to test this stream and give the result?
I downloaded the latest video codec sdk 9.0, but there is compile error like somebody in the below link have reported, and I have made the changes suggested.
https://devtalk.nvidia.com/default/topic/1038691/video-codec-and-optical-flow-sdk/video-codec-samples-giving-ffmpeg-errors-while-trying-to-build/
make -C AppDecode/AppDec
make[1]: Entering directory '/home/xkd/Video_Codec_SDK_9.0.20/Samples/AppDecode/AppDec'
g++ -std=c++11 -I/usr/local/cuda/include -I../../NvCodec -I../../NvCodec/NvDecoder -I../../NvCodec/NvEncoder -I../../NvCodec/Common -I../../../include -I/usr/include/x86_64-linux-gnu -I/usr/include/x86_64-linux-gnu -o AppDec.o -c AppDec.cpp
In file included from AppDec.cpp:18:0:
../../NvCodec/../Utils/FFmpegDemuxer.h:25:5: error: ‘AVBSFContext’ does not name a type
AVBSFContext *bsfc = NULL;
^
../../NvCodec/../Utils/FFmpegDemuxer.h: In constructor ‘FFmpegDemuxer::FFmpegDemuxer(AVFormatContext*)’:
../../NvCodec/../Utils/FFmpegDemuxer.h:57:52: error: ‘AVStream {aka struct AVStream}’ has no member named ‘codecpar’
eVideoCodec = fmtc->streams[iVideoStream]->codecpar->codec_id
^
../../NvCodec/../Utils/FFmpegDemuxer.h:58:47: error: ‘AVStream {aka struct AVStream}’ has no member named ‘codecpar’
nWidth = fmtc->streams[iVideoStream]->codecpar->width;
^
../../NvCodec/../Utils/FFmpegDemuxer.h:59:48: error: ‘AVStream {aka struct AVStream}’ has no member named ‘codecpar’
nHeight = fmtc->streams[iVideoStream]->codecpar->height;
^
../../NvCodec/../Utils/FFmpegDemuxer.h:60:69: error: ‘AVStream {aka struct AVStream}’ has no member named ‘codecpar’
hromaFormat = (AVPixelFormat)fmtc->streams[iVideoStream]->codecpar->f
^
../../NvCodec/../Utils/FFmpegDemuxer.h:122:81: error: ‘av_bsf_get_by_name’ was not declared in this scope
nst AVBitStreamFilter *bsf = av_bsf_get_by_name("h264_mp4toannexb");
^
In file included from AppDec.cpp:17:0:
../../NvCodec/../Utils/FFmpegDemuxer.h:127:35: error: ‘bsfc’ was not declared in this scope
ck(av_bsf_alloc(bsf, &bsfc));
^
../../NvCodec/../Utils/NvCodecUtils.h:112:24: note: in definition of macro ‘ck’
#define ck(call) check(call, __LINE__, __FILE__)
^
../../NvCodec/../Utils/FFmpegDemuxer.h:127:39: error: ‘av_bsf_alloc’ was not declared in this scope
ck(av_bsf_alloc(bsf, &bsfc));
^
../../NvCodec/../Utils/NvCodecUtils.h:112:24: note: in definition of macro ‘ck’
#define ck(call) check(call, __LINE__, __FILE__)
^
In file included from AppDec.cpp:18:0:
../../NvCodec/../Utils/FFmpegDemuxer.h:128:80: error: ‘AVStream {aka struct AVStream}’ has no member named ‘codecpar’
arameters_copy(bsfc->par_in, fmtc->streams[iVideoStream]->codecpar);
^
../../NvCodec/../Utils/FFmpegDemuxer.h:128:88: error: ‘avcodec_parameters_copy’ was not declared in this scope
arameters_copy(bsfc->par_in, fmtc->streams[iVideoStream]->codecpar);
^
In file included from AppDec.cpp:17:0:
../../NvCodec/../Utils/FFmpegDemuxer.h:129:32: error: ‘av_bsf_init’ was not declared in this scope
ck(av_bsf_init(bsfc));
^
../../NvCodec/../Utils/NvCodecUtils.h:112:24: note: in definition of macro ‘ck’
#define ck(call) check(call, __LINE__, __FILE__)
^
In file included from AppDec.cpp:18:0:
../../NvCodec/../Utils/FFmpegDemuxer.h:132:81: error: ‘av_bsf_get_by_name’ was not declared in this scope
nst AVBitStreamFilter *bsf = av_bsf_get_by_name("hevc_mp4toannexb");
^
In file included from AppDec.cpp:17:0:
../../NvCodec/../Utils/FFmpegDemuxer.h:137:35: error: ‘bsfc’ was not declared in this scope
ck(av_bsf_alloc(bsf, &bsfc));
^
../../NvCodec/../Utils/NvCodecUtils.h:112:24: note: in definition of macro ‘ck’
#define ck(call) check(call, __LINE__, __FILE__)
^
../../NvCodec/../Utils/FFmpegDemuxer.h:137:39: error: ‘av_bsf_alloc’ was not declared in this scope
ck(av_bsf_alloc(bsf, &bsfc));
^
../../NvCodec/../Utils/NvCodecUtils.h:112:24: note: in definition of macro ‘ck’
#define ck(call) check(call, __LINE__, __FILE__)
^
In file included from AppDec.cpp:18:0:
../../NvCodec/../Utils/FFmpegDemuxer.h:138:80: error: ‘AVStream {aka struct AVStream}’ has no member named ‘codecpar’
arameters_copy(bsfc->par_in, fmtc->streams[iVideoStream]->codecpar);
^
../../NvCodec/../Utils/FFmpegDemuxer.h:138:88: error: ‘avcodec_parameters_copy’ was not declared in this scope
arameters_copy(bsfc->par_in, fmtc->streams[iVideoStream]->codecpar);
^
In file included from AppDec.cpp:17:0:
../../NvCodec/../Utils/FFmpegDemuxer.h:139:32: error: ‘av_bsf_init’ was not declared in this scope
ck(av_bsf_init(bsfc));
^
../../NvCodec/../Utils/NvCodecUtils.h:112:24: note: in definition of macro ‘ck’
#define ck(call) check(call, __LINE__, __FILE__)
^
In file included from AppDec.cpp:18:0:
../../NvCodec/../Utils/FFmpegDemuxer.h: In destructor ‘FFmpegDemuxer::~FFmpegDemuxer()’:
../../NvCodec/../Utils/FFmpegDemuxer.h:189:13: error: ‘bsfc’ was not declared in this scope
if (bsfc) {
^
../../NvCodec/../Utils/FFmpegDemuxer.h:190:30: error: ‘av_bsf_free’ was not declared in this scope
av_bsf_free(&bsfc);
^
In file included from AppDec.cpp:17:0:
../../NvCodec/../Utils/FFmpegDemuxer.h: In member function ‘bool FFmpegDemuxer::Demux(uint8_t**, int*)’:
../../NvCodec/../Utils/FFmpegDemuxer.h:241:35: error: ‘bsfc’ was not declared in this scope
ck(av_bsf_send_packet(bsfc, &pkt));
^
../../NvCodec/../Utils/NvCodecUtils.h:112:24: note: in definition of macro ‘ck’
#define ck(call) check(call, __LINE__, __FILE__)
^
../../NvCodec/../Utils/FFmpegDemuxer.h:241:45: error: ‘av_bsf_send_packet’ was not declared in this scope
ck(av_bsf_send_packet(bsfc, &pkt));
^
../../NvCodec/../Utils/NvCodecUtils.h:112:24: note: in definition of macro ‘ck’
#define ck(call) check(call, __LINE__, __FILE__)
^
../../NvCodec/../Utils/FFmpegDemuxer.h:242:56: error: ‘av_bsf_receive_packet’ was not declared in this scope
ck(av_bsf_receive_packet(bsfc, &pktFiltered));
^
../../NvCodec/../Utils/NvCodecUtils.h:112:24: note: in definition of macro ‘ck’
#define ck(call) check(call, __LINE__, __FILE__)
^
Makefile:30: recipe for target 'AppDec.o' failed
make[1]: *** [AppDec.o] Error 1
make[1]: Leaving directory '/home/xkd/Video_Codec_SDK_9.0.20/Samples/AppDecode/AppDec'
Makefile:34: recipe for target 'AppDecode/AppDec' failed
make: *** [AppDecode/AppDec] Error 2
Software versions: cuda-10.0, latest video coded 9.0, ffmpeg 3.4.4-1
Thanks
This is my ffmpeg installation. Can you try it?
sudo apt-get install build-essential yasm cmake libtool libc6 libc6-dev unzip wget libnuma1 libnuma-dev
mkdir ffmpeg_28_3_2018
cd ffmpeg_28_3_2018
git clone https://git.ffmpeg.org/ffmpeg.git
git clone https://git.videolan.org/git/ffmpeg/nv-codec-headers.git
cd nv-codec-headers/
sudo make install
cd ..
cd ffmpeg_28_3_2018/
./configure --enable-nonfree --enable-cuda-sdk --shared --disable-optimizations --extra-cflags=-I/usr/local/cuda/include --extra-ldflags=-L/usr/local/cuda/lib64
make -j 10
sudo make install
Here is Video_Codec_SDK_9.0/Samples/AppDecode/AppDecGL result
The result is correct
Decode with NvDecoder.
[INFO ][17:34:05] Media format: QuickTime / MOV (mov,mp4,m4a,3gp,3g2,mj2)
Session Initialization Time: 348 ms
[INFO ][17:34:06] Video Input Information
Codec : H.265/HEVC
Frame rate : 60/1 = 60 fps
Sequence : Progressive
Coded size : [7680, 4352]
Display area : [0, 0, 7680, 4336]
Chroma : YUV 420
Bit depth : 10
Video Decoding Params:
Num Surfaces : 10
Crop : [0, 0, 0, 0]
Resize : 7680x4352
Deinterlace : Weave
Total frame decoded: 3960
Session Deinitialization Time: 44 ms
The result of Video Codec SDK is fine.
I also tried NGC Deepstream with yuv420/10bits/7680x4320 video still got the error result as I mentioned.
Can I modify somewhere in the DeepStreams or Gstreamer source code to fix this problem?
Thanks
What’s the error? Is there error log?
The output error means not decode correctly like the output.jpg
10bits video in NGC DeepStream meets the same problem.
Maybe there is bug in the high resolution decoding. Can you wait our Deepstream 4.0 GA release. It will be available in this month.
DS 3.0 and DS 4.0 do not support 10-bit decoding feature. Hardware supports 10-bit decoding feature but DS SDK only supports 8-bit decoding.
Need to convert the input bit-stream from 10-bit to 8-bit before running the DS application in this case.
Sorry. 10bits is not supported in 3.0 and will not be supported in 4.0 either.