just curious, when you create a new version of Parallel are there any regression tests you run? Currently, I use parallel for a lot of my tasks just want to make sure it still behaves like the old way.
On Fri, May 6, 2011 at 6:06 AM, Hans Schou <[email protected]> wrote: > 2011/5/5 Ole Tange <[email protected]>: > > Are you making a video? Then I would start like... > > As example I will use the image manipulation program 'convert' from > the ImageMagick package. > A simple way of converting a file from .png to .jpg looks like: > convert foo.png foo.jpg > > With a for-loop do like this: > > time \ > for file in *.png; do > convert $file ${file%.png}.jpg > done > > With GNU Parallel it is: > time parallel convert {} {.}.jpg ::: *.png > > ...and then continue with more parameters. > >> This >> will convert foo.png to jpg with a size of 800 and JPEG-quality of 95. >> >> convert -size 800 -quality 95 foo.png foo_800_q95.jpg >> >> With a for-loop it can be done on a list of files: >> >> time \ >> for file in *.png ; do >> convert -size 800 -quality 95 $file ${file##.JPG}_800_q95.jpg > > The above does not work. Delete from the end is: > ${file%.png} > or > ${file%.*} > to delete from the last '.' to the end. > > I'll look at the rest later. > > > /hans > >
