Page 1 of 1

Getting the most out of Dual 6-core Xeon 3.33Ghz & Handbrake

Posted: Wed May 22, 2013 10:55 am
by brobins
Hi there,

I have been a casual user of Handbrake for a few years, on and off and am fairly familiar with how it works and what I need to do to get what I want out of it. Saying that, I am by no means an expert.

Very recently I invested in a new media player (Mac Mini + Plex) & a decent NAS and I'm in the process of backing up my entire Blu-Ray and DVD collection. Obviously Handbrake is my preferred encoding choice, coupled with MakeMKV it seems to provide me the perfect work-flow.

I have a few questions regarding trying to get the most out of my system & Handbrake because I have a lot of movies / Tv shows to get through so anything I can do to streamline the process would be beneficial.

My workstation is a Dual 6-core Xeon 3.33Ghz (24 virtual-cores) + 48Gb Ram running Windows 7 pro. I have noticed that whilst encoding, Handbrake only utilises ~25% / ~35% CPU which is a bit of a shame. I started running two copies of Handbrake at the same time which worked really well (CPU usage was ~50% / ~70%) but I have started running into issues when I have 2 copies of Handbrake running through 2 separate Queues!

I am not sure of the exact error I get as I am at work but it one of the copies of Handbrake seems to complete the first job in the queue but then fail on the second. The second copy of Handbrake seems to continue through the queue although on my most recent attempt all the movies, (appart from the 1st), had no audio track! Very strange.

I set my workstation up this morning with a single copy of Handbrake running through a queue of 10 movies so will see the results of that this evening.

I will try and replicate the issue I have been having and post a log file but in the meantime I am hoping for a few tips on how to streamline my work-flow somewhat.

Up to now, all my Blu-Rays have been encoded with the High Profile pre-set with pass-through audio and look fantastic, so I plan to stick to using that.

Thanks in advance,
Ben.

Re: Getting the most out of Dual 6-core Xeon 3.33Ghz & Handb

Posted: Wed May 22, 2013 11:49 am
by Deleted User 11865
Encode log (for one of the encodes which only uses 25-35% CPU) please.

Re: Getting the most out of Dual 6-core Xeon 3.33Ghz & Handb

Posted: Wed May 22, 2013 11:55 am
by brobins
I'll post the encode log this evening. Thanks.

Re: Getting the most out of Dual 6-core Xeon 3.33Ghz & Handb

Posted: Wed May 22, 2013 6:18 pm
by brobins
Hey,

Ok, here is the log for a successful encode that utilized between ~25% / ~35~ CPU.

Code: Select all

HandBrake 0.9.8 2012071700
OS: Microsoft Windows NT 6.1.7601 Service Pack 1
CPU: Intel(R) Xeon(R) CPU           X5680  @ 3.33GHz
Ram: 49142 MB, Screen: 2560x1440
Temp Dir: C:\Users\BEN\AppData\Local\Temp\
Install Dir: C:\Program Files (x86)\Handbrake
Data Dir: C:\Users\BEN\AppData\Roaming\HandBrake\HandBrake\0.9.8.4861

-------------------------------------------

CLI Query:  -i "D:\Rips\WALL.E (2008)\WALL_E (2008)_BRip.mkv" -t 1 -c 1-32 -o "D:\Rips\WALL.E (2008)\WALL_E (2008).mkv"  -f mkv --decomb -w 1920 --loose-anamorphic  --modulus 2 -e x264 -q 20 --vfr  -a 1,1 -E copy:dts,ffac3 -B 0,640 -6 auto,dpl2 -R Auto,Auto -D 0,0 --gain=0,0 --audio-copy-mask none --audio-fallback ffac3 --markers="C:\Users\BEN\AppData\Local\Temp\WALL_E (2008)-1-chapters.csv" -x b-adapt=2:rc-lookahead=50 --verbose=1
User Query: False

[20:00:18] hb_init: starting libhb thread
HandBrake 0.9.8 (2012071700) - MinGW x86_64 - http://handbrake.fr
24 CPUs detected
Opening D:\Rips\WALL.E (2008)\WALL_E (2008)_BRip.mkv...
[20:00:18] hb_scan: path=D:\Rips\WALL.E (2008)\WALL_E (2008)_BRip.mkv, title_index=1
libbluray/bdnav/index_parse.c:157: indx_parse(): error opening D:\Rips\WALL.E (2008)\WALL_E (2008)_BRip.mkv/BDMV/index.bdmv
libbluray/bluray.c:1471: nav_get_title_list(D:\Rips\WALL.E (2008)\WALL_E (2008)_BRip.mkv) failed (0000000001E78870)
[20:00:18] bd: not a bd - trying as a stream/file instead
libdvdnav: Using dvdnav version 4.1.3
libdvdread: Encrypted DVD support unavailable.
libdvdnav:DVDOpenFileUDF:UDFFindFile /VIDEO_TS/VIDEO_TS.IFO failed
libdvdnav:DVDOpenFileUDF:UDFFindFile /VIDEO_TS/VIDEO_TS.BUP failed
libdvdread: Can't open file VIDEO_TS.IFO.
libdvdnav: vm: failed to read VIDEO_TS.IFO
[20:00:18] dvd: not a dvd - trying as a stream/file instead
Input #0, matroska,webm, from 'D:\Rips\WALL.E (2008)\WALL_E (2008)_BRip.mkv':
  Metadata:
    title           : Wall•E Disc 1
  Duration: 01:38:11.92, start: 0.000000, bitrate: 1536 kb/s
    Chapter #0.0: start 0.000000, end 216.299417
    Metadata:
      title           : Chapter 01
    Chapter #0.1: start 216.299417, end 349.682667
    Metadata:
      title           : Chapter 02
    Chapter #0.2: start 349.682667, end 558.766542
    Metadata:
      title           : Chapter 03
    Chapter #0.3: start 558.766542, end 723.431042
    Metadata:
      title           : Chapter 04
    Chapter #0.4: start 723.431042, end 1076.450375
    Metadata:
      title           : Chapter 05
    Chapter #0.5: start 1076.450375, end 1173.380542
    Metadata:
      title           : Chapter 06
    Chapter #0.6: start 1173.380542, end 1270.143875
    Metadata:
      title           : Chapter 07
    Chapter #0.7: start 1270.143875, end 1426.800375
    Metadata:
      title           : Chapter 08
    Chapter #0.8: start 1426.800375, end 1758.006250
    Metadata:
      title           : Chapter 09
    Chapter #0.9: start 1758.006250, end 1885.091542
    Metadata:
      title           : Chapter 10
    Chapter #0.10: start 1885.091542, end 2007.755750
    Metadata:
      title           : Chapter 11
    Chapter #0.11: start 2007.755750, end 2120.118000
    Metadata:
      title           : Chapter 12
    Chapter #0.12: start 2120.118000, end 2329.535542
    Metadata:
      title           : Chapter 13
    Chapter #0.13: start 2329.535542, end 2573.362458
    Metadata:
      title           : Chapter 14
    Chapter #0.14: start 2573.362458, end 2611.650708
    Metadata:
      title           : Chapter 15
    Chapter #0.15: start 2611.650708, end 3068.940875
    Metadata:
      title           : Chapter 16
    Chapter #0.16: start 3068.940875, end 3127.582792
    Metadata:
      title           : Chapter 17
    Chapter #0.17: start 3127.582792, end 3287.450833
    Metadata:
      title           : Chapter 18
    Chapter #0.18: start 3287.450833, end 3365.779083
    Metadata:
      title           : Chapter 19
    Chapter #0.19: start 3365.779083, end 3478.016208
    Metadata:
      title           : Chapter 20
    Chapter #0.20: start 3478.016208, end 3521.184333
    Metadata:
      title           : Chapter 21
    Chapter #0.21: start 3521.184333, end 3734.897833
    Metadata:
      title           : Chapter 22
    Chapter #0.22: start 3734.897833, end 3801.047250
    Metadata:
      title           : Chapter 23
    Chapter #0.23: start 3801.047250, end 3949.695750
    Metadata:
      title           : Chapter 24
    Chapter #0.24: start 3949.695750, end 4304.883917
    Metadata:
      title           : Chapter 25
    Chapter #0.25: start 4304.883917, end 4554.216333
    Metadata:
      title           : Chapter 26
    Chapter #0.26: start 4554.216333, end 4762.799708
    Metadata:
      title           : Chapter 27
    Chapter #0.27: start 4762.799708, end 4814.684875
    Metadata:
      title           : Chapter 28
    Chapter #0.28: start 4814.684875, end 5054.090708
    Metadata:
      title           : Chapter 29
    Chapter #0.29: start 5054.090708, end 5145.765625
    Metadata:
      title           : Chapter 30
    Chapter #0.30: start 5145.765625, end 5417.495417
    Metadata:
      title           : Chapter 31
    Chapter #0.31: start 5417.495417, end 5891.927708
    Metadata:
      title           : Chapter 32
    Stream #0.0(eng): Video: h264 (High), yuv420p, 1920x1080 [PAR 1:1 DAR 16:9], 23.98 fps, 23.98 tbr, 1k tbn, 47.95 tbc
    Stream #0.1(eng): Audio: dca (DTS), 48000 Hz, 5.1, s16, 1536 kb/s (default)
    Metadata:
      title           : 3/2+1
[20:00:18] scan: decoding previews for title 1
[20:00:18] scan: audio 0x1: DCA, rate=48000Hz, bitrate=1536000 English (DTS) (5.1 ch)
Scanning title 1...
Scanning title 1...
Scanning title 1...
Scanning title 1...
Scanning title 1...
Scanning title 1...
Scanning title 1...
[20:00:19] scan: 10 previews, 1920x1080, 23.976 fps, autocrop = 138/140/0/0, aspect 16:9, PAR 1:1
[20:00:19] scan: title (0) job->width:1920, job->height:800
[20:00:19] libhb: scan thread found 1 valid title(s)
+ title 1:
  + stream: D:\Rips\WALL.E (2008)\WALL_E (2008)_BRip.mkv
  + duration: 01:38:11
  + size: 1920x1080, pixel aspect: 1/1, display aspect: 1.78, 23.976 fps
  + autocrop: 138/140/0/0
  + chapters:
    + 1: cells 0->0, 0 blocks, duration 00:03:36
    + 2: cells 0->0, 0 blocks, duration 00:02:13
    + 3: cells 0->0, 0 blocks, duration 00:03:29
    + 4: cells 0->0, 0 blocks, duration 00:02:44
    + 5: cells 0->0, 0 blocks, duration 00:05:53
    + 6: cells 0->0, 0 blocks, duration 00:01:36
    + 7: cells 0->0, 0 blocks, duration 00:01:36
    + 8: cells 0->0, 0 blocks, duration 00:02:36
    + 9: cells 0->0, 0 blocks, duration 00:05:31
    + 10: cells 0->0, 0 blocks, duration 00:02:07
    + 11: cells 0->0, 0 blocks, duration 00:02:02
    + 12: cells 0->0, 0 blocks, duration 00:01:52
    + 13: cells 0->0, 0 blocks, duration 00:03:29
    + 14: cells 0->0, 0 blocks, duration 00:04:03
    + 15: cells 0->0, 0 blocks, duration 00:00:38
    + 16: cells 0->0, 0 blocks, duration 00:07:37
    + 17: cells 0->0, 0 blocks, duration 00:00:58
    + 18: cells 0->0, 0 blocks, duration 00:02:39
    + 19: cells 0->0, 0 blocks, duration 00:01:18
    + 20: cells 0->0, 0 blocks, duration 00:01:52
    + 21: cells 0->0, 0 blocks, duration 00:00:43
    + 22: cells 0->0, 0 blocks, duration 00:03:33
    + 23: cells 0->0, 0 blocks, duration 00:01:06
    + 24: cells 0->0, 0 blocks, duration 00:02:28
    + 25: cells 0->0, 0 blocks, duration 00:05:55
    + 26: cells 0->0, 0 blocks, duration 00:04:09
    + 27: cells 0->0, 0 blocks, duration 00:03:28
    + 28: cells 0->0, 0 blocks, duration 00:00:51
    + 29: cells 0->0, 0 blocks, duration 00:03:59
    + 30: cells 0->0, 0 blocks, duration 00:01:31
    + 31: cells 0->0, 0 blocks, duration 00:04:31
    + 32: cells 0->0, 0 blocks, duration 00:07:54
  + audio tracks:
    + 1, English (DTS) (5.1 ch) (iso639-2: eng), 48000Hz, 1536000bps
  + subtitle tracks:
Reading chapter markers from file C:\Users\BEN\AppData\Local\Temp\WALL_E (2008)-1-chapters.csv
[20:00:19] 1 job(s) to process
[20:00:19] starting job
[20:00:19] sync: expecting 141264 video frames
[20:00:19] job configuration:
[20:00:19]  * source
[20:00:19]    + D:\Rips\WALL.E (2008)\WALL_E (2008)_BRip.mkv
[20:00:19]    + title 1, chapter(s) 1 to 32
[20:00:19]    + container: matroska,webm
[20:00:19]    + data rate: 1536 kbps
[20:00:19]  * destination
[20:00:19]    + D:\Rips\WALL.E (2008)\WALL_E (2008).mkv
[20:00:19]    + container: Matroska (.mkv)
[20:00:19]      + chapter markers
[20:00:19]  * video track
[20:00:19]    + decoder: h264
[20:00:19]    + frame rate: same as source (around 23.976 fps)
[20:00:19]    + loose anamorphic
[20:00:19]      + storage dimensions: 1920 * 1080 -> 1920 * 802, crop 138/140/0/0, mod 2
[20:00:19]      + pixel aspect ratio: 1 / 1
[20:00:19]      + display dimensions: 1920 * 802
[20:00:19]    + filter
[20:00:19]      + Decomb (default settings)
[20:00:19]    + encoder: H.264 (x264)
[20:00:19]      + options: b-adapt=2:rc-lookahead=50
[20:00:19]      + quality: 20.00 (RF)
[20:00:19]  * audio track 1
[20:00:19]    + decoder: English (DTS) (5.1 ch) (track 1, id 0x1)
[20:00:19]      + bitrate: 1536 kbps, samplerate: 48000 Hz
[20:00:19]    + DTS Passthru
[20:00:19]  * audio track 2
[20:00:19]    + decoder: English (DTS) (5.1 ch) (track 1, id 0x1)
[20:00:19]      + bitrate: 1536 kbps, samplerate: 48000 Hz
[20:00:19]    + mixdown: Dolby Pro Logic II
[20:00:19]    + encoder: AC3 (ffmpeg)
[20:00:19]      + bitrate: 640 kbps, samplerate: 48000 Hz
[20:00:19] reader: first SCR 0 id 0x0 DTS 0
[20:00:19] yadif thread started for segment 0
[20:00:19] yadif thread started for segment 1
[20:00:19] yadif thread started for segment 2
[20:00:19] yadif thread started for segment 3
[20:00:19] yadif thread started for segment 4
[20:00:19] yadif thread started for segment 5
[20:00:19] yadif thread started for segment 6
[20:00:19] yadif thread started for segment 7
[20:00:19] yadif thread started for segment 8
[20:00:19] yadif thread started for segment 9
[20:00:19] yadif thread started for segment 10
[20:00:19] yadif thread started for segment 11
[20:00:19] yadif thread started for segment 12
[20:00:19] yadif thread started for segment 13
[20:00:19] yadif thread started for segment 14
[20:00:19] yadif thread started for segment 15
[20:00:19] yadif thread started for segment 16
[20:00:19] yadif thread started for segment 17
[20:00:19] yadif thread started for segment 18
[20:00:19] yadif thread started for segment 19
[20:00:19] yadif thread started for segment 20
[20:00:19] yadif thread started for segment 21
[20:00:19] yadif thread started for segment 22
[20:00:19] yadif thread started for segment 23
[20:00:19] decomb thread started for segment 0
[20:00:19] decomb thread started for segment 1
[20:00:19] decomb thread started for segment 2
[20:00:19] decomb thread started for segment 3
[20:00:19] decomb thread started for segment 4
[20:00:19] decomb thread started for segment 5
[20:00:19] decomb thread started for segment 6
[20:00:19] decomb thread started for segment 7
[20:00:19] decomb thread started for segment 8
[20:00:19] decomb thread started for segment 9
[20:00:19] decomb thread started for segment 10
[20:00:19] decomb thread started for segment 11
[20:00:19] decomb thread started for segment 12
[20:00:19] decomb thread started for segment 13
[20:00:19] decomb thread started for segment 14
[20:00:19] decomb thread started for segment 15
[20:00:19] decomb thread started for segment 16
[20:00:19] decomb thread started for segment 17
[20:00:19] decomb thread started for segment 18
[20:00:19] decomb thread started for segment 19
[20:00:19] decomb thread started for segment 20
[20:00:19] decomb thread started for segment 21
[20:00:19] decomb thread started for segment 22
[20:00:19] decomb thread started for segment 23
[20:00:19] encx264: min-keyint: 24, keyint: 240
[20:00:19] encx264: encoding with stored aspect 1/1
[20:00:19] encx264: Encoding at constant RF 20.000000
x264 [warning]: --psnr used with psy on: results will be invalid!
x264 [warning]: --tune psnr should be used if attempting to benchmark psnr!
x264 [info]: using SAR=1/1
x264 [info]: using cpu capabilities: MMX2 SSE2Fast SSSE3 FastShuffle SSE4.2
x264 [info]: profile High, level 4.0
Stream with high frequencies VQ coding
[20:04:02] h264: "Chapter 2" (2) at frame 5196 time 19474470
[20:06:21] h264: "Chapter 3" (3) at frame 8392 time 31471470
[20:09:55] h264: "Chapter 4" (4) at frame 13405 time 50289030
[20:12:44] h264: "Chapter 5" (5) at frame 17354 time 65112570
[20:18:48] h264: "Chapter 6" (6) at frame 25820 time 96891840
[20:20:27] h264: "Chapter 7" (7) at frame 28141 time 105604290
[20:22:07] h264: "Chapter 8" (8) at frame 30461 time 114312960
[20:24:49] h264: "Chapter 9" (9) at frame 34218 time 128415780
[20:30:29] h264: "Chapter 10" (10) at frame 42159 time 158224320
[20:32:40] h264: "Chapter 11" (11) at frame 45205 time 169658280
[20:34:47] h264: "Chapter 12" (12) at frame 48146 time 180698040
[20:36:44] h264: "Chapter 13" (13) at frame 50840 time 190810620
[20:40:19] h264: "Chapter 14" (14) at frame 55861 time 209658240
[20:44:32] h264: "Chapter 15" (15) at frame 61710 time 231613920
[20:45:12] h264: "Chapter 16" (16) at frame 62625 time 235048590
[20:53:01] h264: "Chapter 17" (17) at frame 73589 time 276204690
[20:54:01] h264: "Chapter 18" (18) at frame 74995 time 281482470
[20:56:47] h264: "Chapter 19" (19) at frame 78828 time 295870590
[20:58:08] h264: "Chapter 20" (20) at frame 80707 time 302923890
[21:00:04] h264: "Chapter 21" (21) at frame 83398 time 313025220
[21:00:49] h264: "Chapter 22" (22) at frame 84433 time 316910340
[21:04:30] h264: "Chapter 23" (23) at frame 89556 time 336140820
[21:05:39] h264: "Chapter 24" (24) at frame 91144 time 342101790
[21:08:11] h264: "Chapter 25" (25) at frame 94706 time 355472640
[21:14:15] h264: "Chapter 26" (26) at frame 103222 time 387439560
[21:18:32] h264: "Chapter 27" (27) at frame 109201 time 409883220
[21:22:07] h264: "Chapter 28" (28) at frame 114201 time 428652000
[21:23:01] h264: "Chapter 29" (29) at frame 115445 time 433321650
[21:27:08] h264: "Chapter 30" (30) at frame 121185 time 454868190
[21:28:42] h264: "Chapter 31" (31) at frame 123383 time 463118940
[21:33:21] h264: "Chapter 32" (32) at frame 129901 time 487585890
[21:41:24] reader: done. 1 scr changes
[21:41:28] work: average encoding speed for job is 23.286119 fps
[21:41:28] sync: got 141265 frames, 141264 expected
[21:41:29] h264-decoder done: 141265 frames, 0 decoder errors, 0 drops
[21:41:29] render: lost time: 0 (0 frames)
[21:41:29] render: gained time: 0 (0 frames) (0 not accounted for)
x264 [info]: frame I:1471  Avg QP:16.14  size:111296  PSNR Mean Y:49.74 U:50.23 V:50.22 Avg:49.78 Global:49.34
x264 [info]: frame P:46491 Avg QP:19.54  size: 28803  PSNR Mean Y:47.74 U:49.80 V:49.76 Avg:48.21 Global:47.33
x264 [info]: frame B:93302 Avg QP:21.56  size:  9153  PSNR Mean Y:46.92 U:49.42 V:49.31 Avg:47.49 Global:46.82
x264 [info]: consecutive B-frames:  5.2%  5.4% 44.7% 44.7%
x264 [info]: mb I  I16..4: 20.0% 59.8% 20.2%
x264 [info]: mb P  I16..4:  5.5% 10.6%  1.4%  P16..4: 36.7% 11.5%  7.5%  0.0%  0.0%    skip:26.8%
x264 [info]: mb B  I16..4:  0.7%  1.3%  0.2%  B16..8: 36.2%  3.2%  0.6%  direct: 2.7%  skip:55.2%  L0:41.7% L1:53.0% BI: 5.3%
x264 [info]: 8x8 transform intra:60.4% inter:83.9%
x264 [info]: coded y,uvDC,uvAC intra: 49.2% 69.2% 34.0% inter: 13.4% 17.9% 1.7%
x264 [info]: i16 v,h,dc,p: 28% 28%  5% 39%
x264 [info]: i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 21% 24% 17%  5%  7%  7%  8%  6%  7%
x264 [info]: i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 31% 24% 12%  4%  7%  6%  7%  4%  4%
x264 [info]: i8c dc,h,v,p: 48% 25% 18%  9%
x264 [info]: Weighted P-Frames: Y:5.2% UV:3.4%
x264 [info]: ref P L0: 61.8% 10.8% 18.9%  8.1%  0.5%
x264 [info]: ref B L0: 83.2% 13.5%  3.2%
x264 [info]: ref B L1: 92.1%  7.9%
x264 [info]: SSIM Mean Y:0.9892387 (19.681db)
x264 [info]: PSNR Mean Y:47.220 U:49.553 V:49.469 Avg:47.751 Global:47.000 kb/s:3200.02
[21:41:29] mux: track 0, 141264 frames, 2356709582 bytes, 3199.92 kbps, fifo 1024
[21:41:29] mux: track 1, 552369 frames, 1111366428 bytes, 1509.00 kbps, fifo 4096
[21:41:29] mux: track 2, 184123 frames, 471354880 bytes, 640.00 kbps, fifo 1024
[21:41:29] decomb: deinterlaced 0 | blended 358 | unfiltered 140906 | total 141264
[21:41:29] libhb: work result = 0
Encode done!
HandBrake has exited.

Appreciate the help.
Ben

Re: Getting the most out of Dual 6-core Xeon 3.33Ghz & Handb

Posted: Wed May 22, 2013 6:27 pm
by s55
If you know a source isn't interlaced, I'd turn of decomb, that'll help somewhat.

Also, update to 0.9.9, it may run a bit better.

Re: Getting the most out of Dual 6-core Xeon 3.33Ghz & Handb

Posted: Wed May 22, 2013 7:04 pm
by mduell
1) Upgrade to the latest release, as always.

2) Don't enable decomb or detelecine on sources that don't need them, i.e. entirely 24 fps content.

Re: Getting the most out of Dual 6-core Xeon 3.33Ghz & Handb

Posted: Wed May 22, 2013 7:29 pm
by Deleted User 11865
b-adapt 2 doesn't scale well at all. With as many cores as you have, I'd use bframes=16:b-adapt=1:trellis=0 in the advanced panel to maximize CPU usage. You'll lose some compression efficiency, but the increase in speed should probably allow you to compensate using other settings.

Plus, decomb does have a speed hit, so if you know that your source is progressive, better to leave it off as we pointed out.

Re: Getting the most out of Dual 6-core Xeon 3.33Ghz & Handb

Posted: Wed May 22, 2013 8:40 pm
by brobins
Amazing!

Updated to latest HB and disabled decomb and detelecine and am getting ~90% CPU, perfect!

Would it be worth me making a 'new' preset for myself which is essentially the High Profile preset with decomb and detelecine off, specifically for Blu-Ray's?

Thanks,
Ben.

Re: Getting the most out of Dual 6-core Xeon 3.33Ghz & Handb

Posted: Wed May 22, 2013 8:57 pm
by s55
Yes

Re: Getting the most out of Dual 6-core Xeon 3.33Ghz & Handb

Posted: Wed May 22, 2013 9:52 pm
by brobins
Great.

Thanks for all the help. Much appreciated.

Re: Getting the most out of Dual 6-core Xeon 3.33Ghz & Handb

Posted: Fri May 24, 2013 6:02 am
by grablife
My understanding is decomb and deinterlace is not multicore. In my test using a i5-3350p, encoding normal with decomb at default will run at about 90 fps. Simply turning off decomb will boost performance to 260 - 350 fps at 100% cpu on all cores. I used to care about decomb as nearly all Asian TV series are interlaced but all modern media players will deinterlace on playback. It's still a bit noticeable than decombing while encoding but it's passable.

Some have recommended running multiple instances of HB but that only resulted in errors for me.

Re: Getting the most out of Dual 6-core Xeon 3.33Ghz & Handb

Posted: Fri May 24, 2013 9:21 am
by Smithcraft
Unless you tell it to, Handbrake will not make an interlaced image, as by default it makes a progressive image.

SC

Re: Getting the most out of Dual 6-core Xeon 3.33Ghz & Handb

Posted: Fri May 24, 2013 11:01 am
by Deleted User 11865
Decomb and deinterlace are threaded, but it doesn't work that well in practice. Try the deblock filter, now that's not threaded! ;-)

P.S. if you're going to encode interlaced sources without decombing, be sure to add tff=1 to the advanced x264 settings (of bff=1 if the source is bottom field first)!

Re: Getting the most out of Dual 6-core Xeon 3.33Ghz & Handb

Posted: Sat May 25, 2013 2:18 pm
by grablife
What does tff=1 do and how will it impact encoding performance?

Re: Getting the most out of Dual 6-core Xeon 3.33Ghz & Handb

Posted: Sat May 25, 2013 2:21 pm
by Deleted User 11865
Enable interlaced encoding (with Top Field First) in x264. For interlaced, non-deinterlaced sources, this could improve compression efficiency, and more importantly, the source will be flagged as interlaced (so the playback device won't treat it as progressive and will deinterlace during playback if configured to do so).

Re: Getting the most out of Dual 6-core Xeon 3.33Ghz & Handb

Posted: Sun May 26, 2013 1:19 am
by grablife
Rodeo wrote:Enable interlaced encoding (with Top Field First) in x264. For interlaced, non-deinterlaced sources, this could improve compression efficiency, and more importantly, the source will be flagged as interlaced (so the playback device won't treat it as progressive and will deinterlace during playback if configured to do so).
I tried adding tff=1 in the Advanced Tab under x264 Encoder Options and it failed. Here's the log.

Code: Select all

HandBrake 0.9.9.5470 - 32bit Version
OS: Microsoft Windows NT 6.1.7601 Service Pack 1
CPU: AMD Athlon(tm) II X2 215 Processor 
Ram: 3582 MB, Screen: 1280x1024
Temp Dir: C:\Users\empc\AppData\Local\Temp\
Install Dir: C:\Program Files\Handbrake
Data Dir: C:\Users\empc\AppData\Roaming\HandBrake\HandBrake\0.9.9.5470

-------------------------------------------

CLI Query:  -i "D:\dvd\33 Safe Guards\01" -t 4 --angle 1 -c 1 -o "D:\Mom\33 Safe Guards\01-chp 1.m4v"  -f m4v  --denoise="medium" -w 720 --loose-anamorphic  --modulus 2 -e x264 -q 20 --vfr -a 1 -E faac -6 dpl2 -R Auto -B 160 -D 0 --gain 0 --audio-fallback ffac3 --subtitle scan,1,2,3 --markers="C:\Users\empc\AppData\Local\Temp\01-chp 1-4-chapters.csv" -x tff=1 --verbose=1
User Query: False

[18:10:13] hb_init: starting libhb thread
HandBrake 0.9.9 (2013051800) - MinGW i686 - http://handbrake.fr
2 CPUs detected
Opening D:\dvd\33 Safe Guards\01...
[18:10:13] hb_scan: path=D:\dvd\33 Safe Guards\01, title_index=4
libbluray/bdnav/index_parse.c:162: indx_parse(): error opening D:\dvd\33 Safe Guards\01/BDMV/index.bdmv
libbluray/bdnav/index_parse.c:162: indx_parse(): error opening D:\dvd\33 Safe Guards\01/BDMV/BACKUP/index.bdmv
libbluray/bluray.c:1725: nav_get_title_list(D:\dvd\33 Safe Guards\01) failed (01A83A48)
[18:10:13] bd: not a bd - trying as a stream/file instead
libdvdnav: Using dvdnav version 4.1.3
libdvdread: Encrypted DVD support unavailable.
libdvdread: Device (null) inaccessible, CSS authentication not available.
NAME OPEN FAILED
libdvdnav: Unable to find home directorylibdvdnav: DVD disk reports itself with Region mask 0x00000000. Regions: 1 2 3 4 5 6 7 8
libdvdread: Encrypted DVD support unavailable.
libdvdread: Device (null) inaccessible, CSS authentication not available.
[18:10:13] scan: DVD has 4 title(s)
[18:10:13] scan: scanning title 4
[18:10:13] scan: opening IFO for VTS 4
[18:10:13] scan: duration is 04:10:54 (15054220 ms)
[18:10:13] pgc_id: 1, pgn: 1: pgc: 01A87C58
[18:10:13] scan: vts=4, ttn=1, cells=0->6, blocks=0->3754778, 3754779 blocks
[18:10:13] scan: checking audio 1
[18:10:13] scan: id=0x80bd, lang=Chinese (AC3), 3cc=zho ext=0
[18:10:13] scan: checking audio 2
[18:10:13] scan: id=0x81bd, lang=Chinese (AC3), 3cc=zho ext=0
[18:10:13] scan: checking subtitle 1
[18:10:13] scan: id=0x20bd, lang=Chinese, 3cc=zho ext=0
[18:10:13] scan: checking subtitle 2
[18:10:13] scan: id=0x21bd, lang=Chinese, 3cc=zho ext=0
[18:10:13] scan: checking subtitle 3
[18:10:13] scan: id=0x22bd, lang=English, 3cc=eng ext=0
[18:10:13] scan: title 4 has 6 chapters
[18:10:13] scan: chap 1 c=0->0, b=0->643842 (643843), 2582486 ms
[18:10:13] scan: chap 2 c=1->1, b=643843->1268256 (624414), 2499475 ms
[18:10:13] scan: chap 3 c=2->3, b=1268257->1888440 (620184), 2485940 ms
[18:10:13] scan: chap 4 c=4->4, b=1888441->2508697 (620257), 2484363 ms
[18:10:13] scan: chap 5 c=5->5, b=2508698->3123492 (614795), 2467361 ms
[18:10:13] scan: chap 6 c=6->6, b=3123493->3754778 (631286), 2534592 ms
[18:10:13] scan: aspect = 1.33333
[18:10:13] scan: decoding previews for title 4
libdvdnav: DVD disk reports itself with Region mask 0x00000000. Regions: 1 2 3 4 5 6 7 8
[18:10:13] scan: title angle(s) 1
[18:10:13] scan: audio 0x80bd: AC-3, rate=48000Hz, bitrate=128000 Chinese (AC3) (2.0 ch)
[18:10:13] scan: audio 0x81bd: AC-3, rate=48000Hz, bitrate=128000 Chinese (AC3) (2.0 ch)
[18:10:13] scan: 10 previews, 720x480, 29.970 fps, autocrop = 0/0/6/4, aspect 4:3, PAR 8:9
[18:10:13] libhb: scan thread found 1 valid title(s)
+ title 4:
  + vts 4, ttn 1, cells 0->6 (3754779 blocks)
  + duration: 04:10:54
  + size: 720x480, pixel aspect: 8/9, display aspect: 1.33, 29.970 fps
  + autocrop: 0/0/6/4
  + chapters:
    + 1: cells 0->0, 643843 blocks, duration 00:43:02
    + 2: cells 1->1, 624414 blocks, duration 00:41:39
    + 3: cells 2->3, 620184 blocks, duration 00:41:26
    + 4: cells 4->4, 620257 blocks, duration 00:41:24
    + 5: cells 5->5, 614795 blocks, duration 00:41:07
    + 6: cells 6->6, 631286 blocks, duration 00:42:15
  + audio tracks:
    + 1, Chinese (AC3) (2.0 ch) (iso639-2: zho), 48000Hz, 128000bps
    + 2, Chinese (AC3) (2.0 ch) (iso639-2: zho), 48000Hz, 128000bps
  + subtitle tracks:
    + 1, Chinese (iso639-2: zho) (Bitmap)(VOBSUB)
    + 2, Chinese (iso639-2: zho) (Bitmap)(VOBSUB)
    + 3, English (iso639-2: eng) (Bitmap)(VOBSUB)
Reading chapter markers from file C:\Users\empc\AppData\Local\Temp\01-chp 1-4-chapters.csv
Subtitle Scan Enabled - enabling subtitles if found for foreign language segments
[18:10:13] 2 job(s) to process
[18:10:13] starting job
[18:10:14] sync: expecting 77397 video frames
[18:10:14] work: only 1 chapter, disabling chapter markers
[18:10:14] job configuration:
[18:10:14]  * source
[18:10:14]    + D:\dvd\33 Safe Guards\01
[18:10:14]    + title 4, chapter(s) 1 to 1
[18:10:14]  * destination
[18:10:14]    + D:\Mom\33 Safe Guards\01-chp 1.m4v
[18:10:14]    + container: MPEG-4 (.mp4 and .m4v)
[18:10:14]  * video track
[18:10:14]    + decoder: mpeg2
[18:10:14]      + bitrate 8000 kbps
[18:10:14]    + frame rate: same as source (around 29.970 fps)
[18:10:14]    + filters
[18:10:14]      + Framerate Shaper (0:27000000:900900)
[18:10:14]        + frame rate: same as source (around 29.970 fps)
[18:10:14]      + Denoise (hqdn3d) (3:2:2:3)
[18:10:14]      + Crop and Scale (720:486:0:0:6:4)
[18:10:14]        + source: 720 * 480, crop (0/0/6/4): 710 * 480, scale: 720 * 486
[18:10:14]    + loose anamorphic
[18:10:14]      + storage dimensions: 720 * 486, mod 2
[18:10:14]      + pixel aspect ratio: 71 / 80
[18:10:14]      + display dimensions: 639 * 486
[18:10:14]  * Foreign Audio Search: Passthrough
[18:10:14]    + subtitle, Chinese (track 1, id 0x20bd) Picture [VOBSUB]
[18:10:14]    + subtitle, Chinese (track 2, id 0x21bd) Picture [VOBSUB]
libdvdnav: Using dvdnav version 4.1.3
libdvdread: Encrypted DVD support unavailable.
libdvdread: Device (null) inaccessible, CSS authentication not available.
NAME OPEN FAILED
libdvdnav: Unable to find home directorylibdvdnav: DVD disk reports itself with Region mask 0x00000000. Regions: 1 2 3 4 5 6 7 8
libdvdread: Encrypted DVD support unavailable.
libdvdread: Device (null) inaccessible, CSS authentication not available.
libdvdnav: DVD disk reports itself with Region mask 0x00000000. Regions: 1 2 3 4 5 6 7 8
[18:10:35] reader: end of chapter 1 (media 1) reached at media chapter 2
[18:10:35] work: average encoding speed for job is 0.000000 fps
[18:10:35] render: lost time: 0 (0 frames)
[18:10:35] render: gained time: 0 (0 frames) (0 not accounted for)
[18:10:35] reader: done. 2 scr changes
[18:10:35] mpeg2 done: 0 frames
[18:10:35] Subtitle track 1 (id 0x20bd) 'Chinese': 657 hits (0 forced)
[18:10:35] Subtitle track 2 (id 0x21bd) 'Chinese': 657 hits (0 forced)
[18:10:35] No candidate detected during subtitle scan
[18:10:35] starting job
[18:10:35] work: sanitizing track 1 mixdown Dolby Pro Logic II to Stereo
[18:10:35] sync: expecting 77397 video frames
[18:10:35] work: only 1 chapter, disabling chapter markers
[18:10:35] job configuration:
[18:10:35]  * source
[18:10:35]    + D:\dvd\33 Safe Guards\01
[18:10:35]    + title 4, chapter(s) 1 to 1
[18:10:35]  * destination
[18:10:35]    + D:\Mom\33 Safe Guards\01-chp 1.m4v
[18:10:35]    + container: MPEG-4 (.mp4 and .m4v)
[18:10:35]  * video track
[18:10:35]    + decoder: mpeg2
[18:10:35]      + bitrate 8000 kbps
[18:10:35]    + frame rate: same as source (around 29.970 fps)
[18:10:35]    + filters
[18:10:35]      + Framerate Shaper (0:27000000:900900)
[18:10:35]        + frame rate: same as source (around 29.970 fps)
[18:10:35]      + Denoise (hqdn3d) (3:2:2:3)
[18:10:35]      + Crop and Scale (720:486:0:0:6:4)
[18:10:35]        + source: 720 * 480, crop (0/0/6/4): 710 * 480, scale: 720 * 486
[18:10:35]    + loose anamorphic
[18:10:35]      + storage dimensions: 720 * 486, mod 2
[18:10:35]      + pixel aspect ratio: 71 / 80
[18:10:35]      + display dimensions: 639 * 486
[18:10:35]    + encoder: H.264 (x264)
[18:10:35]      + options: tff=1
[18:10:35]      + quality: 20.00 (RF)
[18:10:35]  * subtitle track 1, Chinese (track 1, id 0x20bd) Picture [VOBSUB] -> Passthrough
[18:10:35]  * subtitle track 2, Chinese (track 2, id 0x21bd) Picture [VOBSUB] -> Passthrough
[18:10:35]  * subtitle track 3, English (track 3, id 0x22bd) Picture [VOBSUB] -> Passthrough
[18:10:35]  * audio track 1
[18:10:35]    + decoder: Chinese (AC3) (2.0 ch) (track 1, id 0x80bd)
[18:10:35]      + bitrate: 128 kbps, samplerate: 48000 Hz
[18:10:35]    + mixdown: Stereo
[18:10:35]    + encoder: AAC (faac)
[18:10:35]      + bitrate: 160 kbps, samplerate: 48000 Hz
libdvdnav: Using dvdnav version 4.1.3
libdvdread: Encrypted DVD support unavailable.
libdvdread: Device (null) inaccessible, CSS authentication not available.
NAME OPEN FAILED
libdvdnav: Unable to find home directorylibdvdnav: DVD disk reports itself with Region mask 0x00000000. Regions: 1 2 3 4 5 6 7 8
libdvdread: Encrypted DVD support unavailable.
libdvdread: Device (null) inaccessible, CSS authentication not available.
[18:10:35] encx264: min-keyint: 30, keyint: 300
[18:10:35] encx264: encoding with stored aspect 71/80
[18:10:35] encx264: Encoding at constant RF 20.000000
x264 [error]: height not divisible by 4 (720x486)
ERROR: encx264: x264_encoder_open failed.
ERROR: Failure to initialise thread 'H.264/AVC encoder (libx264)'
libdvdnav: DVD disk reports itself with Region mask 0x00000000. Regions: 1 2 3 4 5 6 7 8
[18:10:35] reader: done. 0 scr changes
[18:10:36] render: lost time: 0 (0 frames)
[18:10:36] render: gained time: 0 (0 frames) (0 not accounted for)
[18:10:36] mpeg2 done: 0 frames
[18:10:36] libhb: work result = 0
Encode done!
HandBrake has exited.

Re: Getting the most out of Dual 6-core Xeon 3.33Ghz & Handb

Posted: Sun May 26, 2013 5:41 am
by TedJ

Code: Select all

 x264 [error]: height not divisible by 4 (720x486)
Seems x264 insists on the frame height being mod4 for interlaced encodes. Are you attempting to rescale to 486i or is this happening spontaneously?

Re: Getting the most out of Dual 6-core Xeon 3.33Ghz & Handb

Posted: Sun May 26, 2013 1:12 pm
by grablife
Normal preset with denoise set to weak. Works without the tff parameter.

Re: Getting the most out of Dual 6-core Xeon 3.33Ghz & Handb

Posted: Wed May 29, 2013 5:04 pm
by Deleted User 11865
Set the modulus to 4 if you're going to do interlaced encoding.