[FFmpeg-user] Is there a bulk mode for ffprobe
eclipse7 at gmx.net
Sun Jan 19 15:26:22 EET 2020
On 2020-01-17 08:59 -0800, Carl Zwanzig wrote:
> On 1/17/2020 3:32 AM, Mike Martin wrote:
> > Thats what I am doing atm (via perl open3) and I am only getting about 4.7
> > files per second. (30160 in 105 minutes)
> > This is what I am passing
> > "ffprobe", '-hide_banner', '-loglevel','0','-show_format',
> > '-show_streams','-print_format','flat', '-sexagesimal', "$file"
> > Any ideas to speed this up
> I think you need to actually time some invocations of ffmpeg and possibly
> profile them (to know where the time is going).
> With that many files, are they on local disk or network storage (NFS or CIFS?)?
> Is it memory or processor constrained?
> How fast can anything open files on this system?
> Consider rolling up a program or script that simply opens a file, reads the
> first couple k bytes, and closes it. See how fast that can open all of those
> files. I'll guess it's not much faster than the 4.7/sec.
> (There are also other media analysis tools to try, I often use MediaInfo.)
> And please don't top-post on this mailing list.
You might also try parallizing the task by starting multiple ffprobe
processes at once. For some first experiments you could prepare a list
of files and use xargs:
time <files.txt xargs -P 6 -n 1 ffprobe -i
Well, best use the exact command line you use with your current program.
For finding the best number for -P you will have to experiment a bit on
your target machine.
More information about the ffmpeg-user