[mythtv-users] Mythexport sssssllllllloooooooowwwwww

John Baab john.baab at gmail.com
Thu Sep 2 18:18:36 UTC 2010


On Wed, Sep 1, 2010 at 4:14 AM, Diego Torres <torres.diego at ttcpl.com.au> wrote:
> Thanks mate, that was it... sort of.
> I added '-threads 0'  and that made all four cores to be utilized.
> At first I realized that there is a "multiple threading" checkbox on myth
> export and used
> that . But it adds '-threads 2' to the command so it only uses two cores.
> With '-threads 0' on both passes it only took 1.5 hours for the first pass
> and 1 hour to for the second pass.
> Still not as fast as Airvideo but a heck of a lot faster than before.
> The only things I noticed are:
> - The 1 GB RAM was being used with the SWAP going to 200MB or so. I upped
> the memory to 2GB and it still used it all but did not use swap.
> - Even though all 4 cores are being used, none are used more than 80% and
> there is always one that
> oscillates between 30 and 80%. With Airvideo all 4 cores are pretty much
> pegged at 80% the whole time.
> - I am  guessing that the CPU does not go to 100% because of I/O
> bottlenecks. It could be that the 500GB IDE HDD /controller combo
> just can't keep up with ffmpeg using all four cores.
> - The output file is twice as big as Airvideo's so there is definetely a
> mismatch on the settings. I need to investigate that.
> - I realized that myth export uses a two pass approach whilst Airvideo uses
> a one pass approach
> (because the output file starts to fill up immediately).  Doing some reading
> on the ffmpeg lit it says that a two pass
> approach is required with a Variable Bit Rate and in general is recommended
> for quality output.
> I reckon the quality from airvideo's one pass is more than good for the ipad
> so I will try hacking the script (time permittiing) to do a one pass only
> and compare the conversion time.
>
> Cheers and thanks again.
> Diego
> On 01/09/2010, at 2:41 AM, John Baab wrote:
>
> On Tue, Aug 31, 2010 at 4:36 AM, Diego Torres <torres.diego at ttcpl.com.au>
> wrote:
>
> Video conversion is a slow process in general, especially if you are
> using h.264.  You can try adding "-threads 0" to your ffmpeg line in
> the config, which should make ffmpeg attempt to automagically detect
> cpu settings.
> _______________________________________________
> mythtv-users mailing list
> mythtv-users at mythtv.org
> http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users
>
>
> _______________________________________________
> mythtv-users mailing list
> mythtv-users at mythtv.org
> http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users
>
>

You can adjust the ffmpeg lines for mythexport all you want, just
modify the config.  Feel free to mess around with single pass vs two
pass, and constant vs variable bitrates.  Report back what you like
best in the end and I'll consider that as a new default.  You may want
to look at the new default I am using in the next release:
http://bazaar.launchpad.net/~mythbuntu/mythexport/trunk/annotate/head:/usr/share/mythexport/configs/PortableH264HighRes.pm
It utilizes ffmpeg's presets, and should run fine on your system as
long as you transform it to fit in the existing config structure (ie
rip out the ffmpeg from the beginning, etc).  In the end you have all
the power in the world to use whatever ffmpeg options you want, don't
feel you have to stick to the presets at all.  This should be useful
to you as well:
http://rob.opendot.cl/index.php/useful-stuff/ipod-video-guide/

As far as your 80% cpu issue, that is most likely caused by running as
nice -19, which is by design.  We don't want mythexport eating all
your cpu and causing a recording issue.


More information about the mythtv-users mailing list