Different results for "Save Video" and "Add to Batch" runs with same settings

ttfitz

Member
So I had a 3.75 GB TS file (704x480 MPEG2) that I wanted to reduce in size, so I loaded it into VRD TVSuite, hit "Save video" and did nothing but change the profile to MKV and the codec to HEVC. I was very surprised to get a 3.57 GB file from this. Messed around with the quality numbers a bit using the batch manager and got results more in line with expectations. It then occurred to me to do a batch run matching my first try. This time I got a 1.13 GB file.

I don't understand this, I thought there wasn't anything different with the batch processing except it being, you know, batch processing. So what's going on?
 

Dan203

Senior Developer
Staff member
The changes you made to the profile in batch are not permanent. They're like making changes in the save dialog and only apply to that single job. If you found settings that work you have to go to Tools->Manage output profiles and make them there to make them permanent.
 

Dan203

Senior Developer
Staff member
But I would like to know what changes you made as the default profile should produce a smaller file.
 

ttfitz

Member
You apparently didn't understand what I did. I loaded a TS-MPEG2 file, hit "save video", changed profile from TS to MKV, then clicked "Profile options" and changed to "HEVC". This shrunk my 3.75GB MPEG2 video to a 3.47GB HEVC one. Then, using the same TS-MPEG2 file, I instead hit "Save to batch", and repeated the same procedure as before (MKV and HEVC). Batch run produced a 1.3GB HEVC file.

Nothing else changed, both procedures were run with the same profile and same settings. The only difference was one ran in batch, the other "live".
 

ttfitz

Member
Okay, so this is weird, but maybe it will help in tracking things down. Did some more testing:

(1) Created a new profile with default codec being HEVC, changed the Quality Factor to 35. Ran small test TS file both batch and live, both files exactly the same. Hmmm.

(2) Changed (used Manage Profiles) the default codec on the built in MKV profile to HEVC from "match source." Ran small test file on both batch, and live, both files exactly the same. Hmmm. Perhaps I messed something up before?

(3) Changed the default codec on the built-in MKV profile back to "match source." Ran test file batch and live with this profile, only going in and changing codec on each run from "match source" to "HEVC". Only change made, and made each run. Back to "save" file being 4 times the size of the batch file.

I'm attaching MediaInfo exports for the two resulting files from test (3), in case that might help in some way.
 

Attachments

Dan203

Senior Developer
Staff member
That's basically impossible. "Save to Batch" is physically using the same dialog as Save just with some of the button labels changed via a flag passed into the constructor. When you save to batch it creates a special XML file that contains a project file (same as saving as VPRJ) and the profile XML which is exactly the same XML passed directly into VRD when you just save. When you run batch it essentially launches a hidden version of VideoReDo, loads the project and then send that profile XML over just like it was from the Save dialog. I mean literally the exact same functions are being called under the hood.

I'll run a test on my end to see if I can reproduce your results, but knowing how it works I just can't see how that would be possible. I'll get back to you when I get a chance to run the test.
 

ttfitz

Member
Look forward to hearing your results. While there is always a chance I messed up (I'm not perfect), but I've apparently done the impossible 3 times now, and I was very careful the 3rd time to do exactly the same thing on both batch and save, given the different results on the two tests with different profile setups.

As a software programmer myself, I can't tell you how many times my code did something I thought to be "impossible".

Anyway, looking forward to hearing back on this.
 

Dan203

Senior Developer
Staff member
The fact that it's not getting smaller without you messing with the values is concerning me more. The defaults should reduce the size automatically by nearly 1/4 from MPEG2 to HEVC.

Can you try the beta and see if that part works any better? Maybe this is something we've already fixed and just not released in a general build yet.
 

ttfitz

Member
Okay, so I installed the beta to try, and same behavior exhibited. Going to go thru it right now, switching back and forth between VRDTv and browser to write every step I take, Starting with a 30 second 1080 HD clip at 58.8 MB size.

RUN 1 - BATCH

Click Save Video.
Enter filename.
Select "Matroska MKV" profile.
Click "Profile Options." Change Output Codec from "Match source" to "HEVC", click Okay.
Click arrow beside "Save" and change to "Queue to batch."

Result - 14.5 MB HEVC file.

RUN 2 - SAVE

Click Save Video.
Enter filename.
Click "Profile Options." Change codec to "HEVC" from "Match source." Click okay.
Click "Save".

Result - 53.8 MB HEVC file.

Now HERE'S where it gets interesting (as in, a hint to where the problem lies). Just for fun, I tried a few variations on the RUN 2 SAVE scenario. Did the same as before, but this time, after changing to HEVC, I hit "Advanced Options" and changed the Quality Factor from 25 to 26. Got a 15.1 MB file - slightly bigger than the Batch run, which should fit.

Tried again, this time Advanced Options, changed 25 to 26, hit okay, then Advanced Options again, changed it back to 25. Identical size file to the 15.1 run above i.e. the "26" run.

Advanced Options, changed 25 to 26 and back to 25 without leaving and hit "Okay." Same result as RUN 2 SAVE, 53.8.

Advanced Options, changed 25 to 30, hit Okay, Advanced Options again, 30 to 25. Produced a 17.2 MB file - which, you guessed it, was identical in size to the file produced when I set QF to 30 and left it.

So, it seems like some of the changes being made in the dialog are not being saved/reflected in that XML file being created.

Hope you can follow that, and hope it helps.

PS - Just on a hunch, I ran one last time, changing the QF to 100. Got a file identical in size to the original problem one, 53.8 MB.
 

Danr

Administrator
Staff member
I think you're correct it's a setting that isn't being changed. If your output profile codec is set to "match source" and you change it in the file save dialog, it's not picking up the quality factor, but if you create an output profile with the desired codec it seems to work. Can you verify?

When you do a save to batch, then the output profile that's passed to the batch processor already has the output codec set which means the quality factor is being picked up properly.
 

ttfitz

Member
Yes, earlier I had created a new profile with MKV output, HEVC codec, and a higher quality factor and when using that profile, the save and batch both worked as expected, producing identical outputs. I also found if I changed the default on the MKV profile to be HEVC, that would also work correctly.

Glad to see we have moved away from impossible.
 
Top Bottom