Output bigger then input

Get answers to your questions about color grading, editing and finishing with DaVinci Resolve.
  • Author
  • Message
Offline

Shea.gleadle

  • Posts: 12
  • Joined: Thu Mar 21, 2019 8:33 pm
  • Real Name: Shea Gleadle

Output bigger then input

PostThu Mar 21, 2019 8:39 pm

I'm trying to do some basic editing with Resolve. Take 3 clips, cut out the start and end, add simple transitions and render into a lossless output. My input filed are about 2-3 GB each (.moving from a phantom 4 pro shot in 4k) and my output in 33gb. My settings are h.264 MP4 2160 UHD resolution and best quality. Why does it increase in size? And how can I decrease the size significantly with as little perceivable decrease in quality as possible? Thanks a ton
Offline

Mike1938

  • Posts: 223
  • Joined: Sun Apr 15, 2018 4:44 pm
  • Real Name: Michael Stehly

Re: Output bigger then input

PostThu Mar 21, 2019 10:05 pm

Use Handbrake. It is a free program. It will reduce the file size significantly without any noticeable loss in quality.
Offline

Shea.gleadle

  • Posts: 12
  • Joined: Thu Mar 21, 2019 8:33 pm
  • Real Name: Shea Gleadle

Re: Output bigger then input

PostFri Mar 22, 2019 3:54 am

Does handbrake do anything resolve cannot? Why does resolve create a inflated output in the first place?
Offline

Tero Ahlfors

  • Posts: 640
  • Joined: Fri Apr 03, 2015 3:02 pm

Re: Output bigger then input

PostFri Mar 22, 2019 8:08 am

Shea.gleadle wrote:Why does resolve create a inflated output in the first place?


It's not a Resolve issue if the user exports to a lossless format. Lossless is lossless. There's no compression. That means it will take a lot of space. You could try using intermediate formats like DNxHR or Prores (if you're on a Mac) which are "visually lossless".
Offline

peterjackson

  • Posts: 1144
  • Joined: Sat Aug 18, 2018 7:12 pm
  • Real Name: Peter Jackson

Re: Output bigger then input

PostFri Mar 22, 2019 8:33 am

There is so much wrong in this thread, I'm not even sure where to start.

Lossless does not mean that there is no compression, it means the compression is mathematically lossless.

Handbreak is a frontend around a gazillion encoders with a gazillion presets and options. How could anyone say that using it without any details on encoders or options provides no visible loss?

H26x can both be as "visually lossless" as any intermediate codec, in fact at much lower bitrates.

Contrary to intermediate codecs both H264 and H265 can also be mathematically lossless. H265 blazing fast fully GPU accelerated all the way up 12 bit 4:4:4 using RTX cards. Resolve just doesn't support these options via NVENC.

All you get using intermediate codecs for final delivery is higher bitrates than H26x at any given visual quality metric.

People use intermediate codecs for editing as they employ much less advanced lossy compression, in particular no inter frame compression, and are therefor instant to seek as any frame can be decoded on its own.
5950x, 3090, 128GB.
Offline

Hendrik Proosa

  • Posts: 3053
  • Joined: Wed Aug 22, 2012 6:53 am
  • Location: Estonia

Re: Output bigger then input

PostFri Mar 22, 2019 10:34 am

What Peter said.

peterjackson wrote:Contrary to intermediate codecs both H264 and H265 can also be mathematically lossless.

At least in theory, any codec can be mathematically lossles. In practice, almost no software gives you options to use for example Prores or DNx in lossless form where no coeficcients are discarded.
I do stuff
Offline

Shea.gleadle

  • Posts: 12
  • Joined: Thu Mar 21, 2019 8:33 pm
  • Real Name: Shea Gleadle

Re: Output bigger then input

PostFri Mar 22, 2019 1:28 pm

How/why does my input of 6 GB get turned into an output of 33 gb when all I'm adding is a few transitions and exporting into the same resolution that my input was?
Offline

Jim Simon

  • Posts: 30311
  • Joined: Fri Dec 23, 2016 1:47 am

Re: Output bigger then input

PostFri Mar 22, 2019 2:20 pm

File size = bitrate x duration.

If you want a smaller file, you need a lower bitrate, shorter duration, or both.
My Biases:

You NEED training.
You NEED a desktop.
You NEED a calibrated (non-computer) display.
Offline

Andrew Kolakowski

  • Posts: 9212
  • Joined: Tue Sep 11, 2012 10:20 am
  • Location: Poland

Re: Output bigger then input

PostFri Mar 22, 2019 2:38 pm

Hendrik Proosa wrote:What Peter said.

peterjackson wrote:Contrary to intermediate codecs both H264 and H265 can also be mathematically lossless.

At least in theory, any codec can be mathematically lossles. In practice, almost no software gives you options to use for example Prores or DNx in lossless form where no coeficcients are discarded.


Those are not designed to give lossless output. There is quite a big difference between lossy codecs and lossless. They operate on rather different math and principles.
Offline

Shea.gleadle

  • Posts: 12
  • Joined: Thu Mar 21, 2019 8:33 pm
  • Real Name: Shea Gleadle

Re: Output bigger then input

PostFri Mar 22, 2019 5:05 pm

Jim Simon wrote:File size = bitrate x duration.

If you want a smaller file, you need a lower bitrate, shorter duration, or both.


Ok, so what you're saying is my input must be at a lower bitrate then what Im trying to output it as?
Offline

peterjackson

  • Posts: 1144
  • Joined: Sat Aug 18, 2018 7:12 pm
  • Real Name: Peter Jackson

Re: Output bigger then input

PostFri Mar 22, 2019 5:18 pm

What you probably want is to render Cineform YUV 12 bit preset best from Resolve, then use FFMPEG to encode H264 CRF 12-14 with preset slow, then delete the Cineform file. You can do it using handbreak as UI if you are not familiar with CLI tools.
5950x, 3090, 128GB.
Offline

Hendrik Proosa

  • Posts: 3053
  • Joined: Wed Aug 22, 2012 6:53 am
  • Location: Estonia

Re: Output bigger then input

PostFri Mar 22, 2019 5:35 pm

Andrew Kolakowski wrote:
Hendrik Proosa wrote:At least in theory, any codec can be mathematically lossles. In practice, almost no software gives you options to use for example Prores or DNx in lossless form where no coeficcients are discarded.

Those are not designed to give lossless output. There is quite a big difference between lossy codecs and lossless. They operate on rather different math and principles.

And what might that difference be? Virtually all codecs do some kind of transformation (lossless if done with enough precision) that pushes image data into domain where significant data is more easily separated from irrelevant. This separation is then done by discarding part of that transformed data (by some threshold) that is irrelevant for task at hand. If discarding is discarded, there is practically no loss, again, given that encoding and decoding are done with enough precision to prevent rounding errors.
I do stuff
Offline

George Dean

  • Posts: 19
  • Joined: Wed Mar 20, 2019 8:19 pm
  • Real Name: George Dean

Re: Output bigger then input

PostFri Mar 22, 2019 6:05 pm

Shea.gleadle wrote:......add simple transitions and render into a lossless output.

Shea.gleadle wrote:My settings are h.264 MP4 2160 UHD resolution and best quality.


Shea, I'm confused! You state you are rendering out to a lossless output, but also state you are using mp4, h264, UHD, best quality, format which is not lossless. Perhaps you can explain how you are referencing lossless, and check to confirm your render format selections.

I don't have source video like you have from your Phantom, but if I am correct the highest bit rate it is capable of is 100 Mb/s. When I render using your render settings of UHD DNxHR source (bit rate 698 Mb/s), I get 136 Mb/s bit rate and the size comparison is the source 1.03 GiB, and the rendered output is 204 Mib. Your results are not going to be the precise equivalent to mine, but should be pretty close.

Am I missing something?
Offline

Jim Simon

  • Posts: 30311
  • Joined: Fri Dec 23, 2016 1:47 am

Re: Output bigger then input

PostFri Mar 22, 2019 7:41 pm

Shea.gleadle wrote:so what you're saying is my input must be at a lower bitrate then what Im trying to output it as?


That's not even close.

I'm saying the size of the exported file is determined by the bitrate x duration. The size of the original file isn't relevant in any way.

If you want a smaller file than the current export, then you need to reexport using a lower bitrate, shorten the program, or both.
My Biases:

You NEED training.
You NEED a desktop.
You NEED a calibrated (non-computer) display.
Offline

Andrew Kolakowski

  • Posts: 9212
  • Joined: Tue Sep 11, 2012 10:20 am
  • Location: Poland

Re: Output bigger then input

PostFri Mar 22, 2019 11:12 pm

Hendrik Proosa wrote:
Andrew Kolakowski wrote:
Hendrik Proosa wrote:At least in theory, any codec can be mathematically lossles. In practice, almost no software gives you options to use for example Prores or DNx in lossless form where no coeficcients are discarded.

Those are not designed to give lossless output. There is quite a big difference between lossy codecs and lossless. They operate on rather different math and principles.

And what might that difference be? Virtually all codecs do some kind of transformation (lossless if done with enough precision) that pushes image data into domain where significant data is more easily separated from irrelevant. This separation is then done by discarding part of that transformed data (by some threshold) that is irrelevant for task at hand. If discarding is discarded, there is practically no loss, again, given that encoding and decoding are done with enough precision to prevent rounding errors.


Lossless codecs work like zip, rar etc. They don't necessarily need to understand incoming data as video. It's just bunch of 0 and 1 for them. They don't need to analyse motion, they don't need to apply any human vision modelling to judge what video part is not important (as they cannot remove anything). Lossy codecs are about removing not important part of the video, where lossless ones need to preserve everything. As far as I know math is quite different in both cases (I worked with MagicYUV developer, so he explained me some bits around lossless encoding). In case of complex codecs like h264/5 lossless modes are quite special parts of whole codec model.
Offline

Hendrik Proosa

  • Posts: 3053
  • Joined: Wed Aug 22, 2012 6:53 am
  • Location: Estonia

Re: Output bigger then input

PostMon Mar 25, 2019 9:56 am

Mhm, I was thinking about, lets say Prores or any other DCT based codec (or wavelet like Cineform, doesn't really matter) where image is basically put through DCT for fixed size macroblocks, then coeficcients that are below set threshold are discarded and remaining coefficient are compressed using huffman encoding or some other packing mechanism. If you don't zero out these coefficients, you basically get the lossless version of that codec, within limits of rounding and truncation errors. Unless I misunderstand DCT, it is losslessly invertible if coefficients are stored with enough precision relative to source data bit depth. For motion estimation this is all way more complicated ofcourse, can't argue that :)
I do stuff

Return to DaVinci Resolve

Who is online

Users browsing this forum: Google [Bot] and 220 guests