lisamelton / other_video_transcoding

Other tools to transcode videos.
MIT License
540 stars 24 forks source link

other-transcode no arguments fails - --nvenc fails but --hevc works #190

Open Gattung opened 11 months ago

Gattung commented 11 months ago

Thanks for this really interesting tool!

I am using an AMD system with a Nvidia RTX 3090. When using default other-transcode I get a fail

other-transcode h:\Video\encode\test\clip_001.mkv or if I use --nvenc it fails other-transcode --nvenc h:\Video\encode\test\clip_001.mkv

Here is the fail message I get

[h264_nvenc @ 000001592727f580] No capable devices found [vost#0:0/h264_nvenc @ 00000159264e1b00] Error while opening encoder - maybe incorrect parameters such as bit_rate, rate, width or height.

But if I use

other-transcode --hevc h:\Video\encode\test\clip_001.mkv

it is successful and pegs the GPU video encoder at 100% which is better then transcode-video's (handbrake) 80%

Any ideas on whats going on?

Also, if you have any examples of passing on quality arguments to ffmpeg that would be great, right now the quality of transcode-video --nvenc quality is a little better then ffmpeg --hevc in my testing, but ffmpeg is much faster and the file size is much smaller.

thanks again!

lisamelton commented 11 months ago

@Gattung My apologies for taking so long to respond.

This is very odd: For this command:

other-transcode --hevc h:\Video\encode\test\clip_001.mkv

Can you change that to:

other-transcode --dry-run --hevc h:\Video\encode\test\clip_001.mkv

... and copy the output of that command here.

Thanks.

Gattung commented 11 months ago

No worries! here's the output.

Verifying "ffprobe" availability... Verifying "ffmpeg" availability... Verifying "mkvpropedit" availability... Finding encoders... Trying "hevc_nvenc" video encoder... Scanning media... duration = 00:09:15.982 Stream mapping: 0 = hevc_nvenc / 8000 Kbps 1 = copy Command line: ffmpeg -loglevel error -stats -i h:\Video\encode\test\clip_001.mkv -map 0:0 -c:v hevc_nvenc -pix_fmt:v p010le -``b:v 8000k -maxrate:v 25000k -bufsize:v 25000k -color_primaries:v bt2020 -color_trc:v smpte2084 -colorspace:v ``bt2020nc -metadata:s:v title= -disposition:v default -map 0:1 -c:a:0 copy -metadata:s:a:0 title= -disposition:a:0`` default -sn -metadata:g title= -default_mode passthrough clip_001.mkv

lisamelton commented 11 months ago

@Gattung Thanks! OK, it's definitely using the Nvidia encoder then. Hmmmmm.

OK, just in case... What happens if you change this:

other-transcode --nvenc h:\Video\encode\test\clip_001.mkv

...to this:

other-transcode -dry-run --nvenc h:\Video\encode\test\clip_001.mkv
Gattung commented 11 months ago

Here is that output

Verifying "ffprobe" availability... Verifying "ffmpeg" availability... Verifying "mkvpropedit" availability... Finding encoders... Scanning media... duration = 00:09:15.982 Stream mapping: 0 = h264_nvenc / 6000 Kbps 1 = copy Command line: ffmpeg -loglevel error -stats -i h:\Video\encode\test\clip_001.mkv -map 0:0 -filter:v scale=1920:1080 -c:v ``h264_nvenc -b:v 6000k -maxrate:v 20000k -bufsize:v 20000k -profile:v high -color_primaries:v bt2020 -``color_trc:v smpte2084 -colorspace:v bt2020nc -metadata:s:v title= -disposition:v default -map 0:1 -c:a:0 copy -``metadata:s:a:0 title= -disposition:a:0 default -sn -metadata:g title= -default_mode passthrough clip_001.mkv

lisamelton commented 11 months ago

@Gattung OK, that looks perfectly normal. It's selected the correct encoder. Aaaaand... I have no idea why it would fail.

Honestly, I've never seen anything like that.

My only thought is that there's either something wrong with ffmpeg or with your video drivers.

Gattung commented 11 months ago

OK thanks! Will investigate further.

On Mon, Jul 17, 2023, 10:35 PM Don Melton @.***> wrote:

@Gattung https://github.com/Gattung OK, that looks perfectly normal. It's selected the correct encoder. Aaaaand... I have no idea why it would fail.

Honestly, I've never seen anything like that.

My only thought is that there's either something wrong with ffmpeg or with your video drivers.

— Reply to this email directly, view it on GitHub https://github.com/donmelton/other_video_transcoding/issues/190#issuecomment-1639516027, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAB3UAS4Z6E74PUVVNICF6DXQYOCJANCNFSM6AAAAAA2LNBYAY . You are receiving this because you were mentioned.Message ID: @.***>