Linux: batch nef to jpg

Discussion in 'Digital SLR' started by Mike -- Email Ignored, Mar 14, 2009.

  1. What Linux software is there to do batch
    conversions from nef to jpg?

    Thanks,
    Mike.
     
    Mike -- Email Ignored, Mar 14, 2009
    #1
    1. Advertisements

  2. Mike -- Email Ignored

    Bob Larter Guest

    Mike -- Email Ignored wrote:
    > What Linux software is there to do batch
    > conversions from nef to jpg?


    Something like the following command line should do the trick:

    for $IMAGE in (*.nef); do dcraw [my options] $IMAGE; done

    If you haven't already got a copy of DCRAW, you can get it at:
    <http://www.cybercom.net/~dcoffin/dcraw/>


    --
    W
    . | ,. w , "Some people are alive only because
    \|/ \|/ it is illegal to kill them." Perna condita delenda est
    ---^----^---------------------------------------------------------------
     
    Bob Larter, Mar 14, 2009
    #2
    1. Advertisements

  3. On Fri, 13 Mar 2009 18:36:03 -0800, Floyd L. Davidson wrote:

    > Mike -- Email Ignored <> wrote:
    >>What Linux software is there to do batch conversions from nef to jpg?

    >
    > Ufraw has /ufraw-batch/, which about as good as it gets. You can also
    > use /dcraw/, but it is not actually designed for production work.


    I just ran a quick test of both of these using mostly
    default parameters on a nef that gives a good image
    in Capture NX on WinXP with a calibrated screen. In
    each case I copied the image to the WinXP box and
    looked with Photoshop. The results:

    dcraw: bad color; much too much red; difficult
    or impossible to correct.

    ufraw-batch: good color, much too dark, correctable.

    My requirement is to get good results from good raw
    files without much diddling. On the face of it,
    neither of these really do it. It may be that if
    I fool around with one or the other, I can find a
    parameter set that would usually work.
    What do you think?

    Thanks for your advice.
    Mike.
     
    Mike -- Email Ignored, Mar 14, 2009
    #3
  4. Mike -- Email Ignored

    Bob Larter Guest

    Mike -- Email Ignored wrote:
    > I just ran a quick test of both of these using mostly
    > default parameters on a nef that gives a good image
    > in Capture NX on WinXP with a calibrated screen. In
    > each case I copied the image to the WinXP box and
    > looked with Photoshop. The results:
    >
    > dcraw: bad color; much too much red; difficult
    > or impossible to correct.


    Try using the "as shot" white balance option:

    dcraw $MYFILE -w

    You might also experiment with the '-p embed' or '-W' options.

    (DCRAW man page: <http://www.cybercom.net/~dcoffin/dcraw/dcraw.1.html>)

    > neither of these really do it. It may be that if
    > I fool around with one or the other, I can find a
    > parameter set that would usually work.
    > What do you think?


    If you need to batch convert a large numbers of NEFs, I think it'd
    definitely be worth experimenting to get the best results.

    > Thanks for your advice.


    My pleasure. Please keep us posted on the results.

    --
    W
    . | ,. w , "Some people are alive only because
    \|/ \|/ it is illegal to kill them." Perna condita delenda est
    ---^----^---------------------------------------------------------------
     
    Bob Larter, Mar 14, 2009
    #4
  5. On Sat, 14 Mar 2009 14:20:07 +1100, Bob Larter wrote:

    [...]
    >
    > Try using the "as shot" white balance option:
    >
    > dcraw $MYFILE -w
    >
    > You might also experiment with the '-p embed' or '-W' options.
    >
    > (DCRAW man page: <http://www.cybercom.net/~dcoffin/dcraw/dcraw.1.html>)
    >

    [...]
    >
    > If you need to batch convert a large numbers of NEFs, I think it'd
    > definitely be worth experimenting to get the best results.
    >
    >> Thanks for your advice.

    >
    > My pleasure. Please keep us posted on the results.


    Thanks, will do; but it is bedtime now at -0400.
    Mike.
     
    Mike -- Email Ignored, Mar 14, 2009
    #5
  6. Mike -- Email Ignored

    Guest

    On Sat, 14 Mar 2009 00:23:12 GMT, in rec.photo.digital.slr-systems Mike --
    Email Ignored <> wrote:

    >What Linux software is there to do batch
    >conversions from nef to jpg?


    Though I run the Windoze version, Bibble is available for Linux.

    http://www.bibblelabs.com/products/bibble/specs.html
     
    , Mar 14, 2009
    #6
  7. On Fri, 13 Mar 2009 19:53:22 -0800, Floyd L. Davidson wrote:

    >>dcraw: bad color; much too much red; difficult
    >> or impossible to correct.


    >It is not impossible to correct, though "difficult"
    >might well be accurate.


    I know others who would disagree. It depends on the
    residual bit depth of the colors that appear only
    at low level.

    [...]

    > If it is too dark, that is *your* fault, not a problem with /ufraw/!
    > (Keep in mind that the "default" settings are whatever it was you did
    > the last time you used it!)


    I never ran it before. Are you telling me that it "remembers"
    previous parameters? If so, is there any way to disable
    this "feature"? Blame is not relevant; the question is:
    "does it meet requirements, or can it be made to do so?".
    So far, the answer is not clear.

    > There is no "automatic adjustment" in batch
    > mode; you just need to make sure that the "defaults" that it uses are
    > what you want.
    >
    > Note that /ufraw/ (as do many of the third party raw conversion
    > programs) uses the same code as Dave Coffin's /dcraw/ program. Ufraw
    > does *not* provide a different option for raw conversions, it provides
    > exactly the same conversion but gives you a much more complete interface
    > and many other facilities. The practical effect is that there is no
    > point in using /dcraw/ directly.
    >

    Then are you telling me that with /ufraw/ I can do parameter settings
    that ate not possible with direct /dcraw/?

    >>My requirement is to get good results from good raw files without much
    >>diddling. On the face of it, neither of these really do it.

    >
    > That is because the face of anything that complex is not where you want
    > to make your judgment. :)


    ????

    [...]

    >
    > Use /ufraw/, and once you learn more about what it does and about what
    > it means to convert a raw data file into an image, you'll find that it
    > does do what you want... with a couple of potential exceptions.
    >
    > Ufraw is not an image editor, and makes no attempt to produce a final
    > product. It is almost a requirement to continue processing with some
    > other program. Specifically, if you want to do "sharpening" or "unsharp
    > mask", it must be done with another program. And /dcraw/ does not
    > produce a variety of different output image formats. On Linuxs that
    > generally means either with GIMP or with ImageMagick tools.
    >
    > There are two problems you'll encounter with using GIMP and/or
    > ImageMagick as the back end to /ufraw/. One is that those two programs
    > have entirely different algorithms for application of an unsharp mask,
    > and the parameters used for similar results are vastly different. Plus,
    > while GIMP can be used in batch mode, it requires considerably more than
    > a minimal amount of programming know how to do.


    The intended purpose is to get quick jpegs with no correction, like
    what Capture NX shows you when you first import the raw file. There
    should be a simple "direct conversion" that requires no choices.
    Serious image processing is done elsewhere, and is not part of
    this requirement.

    Mike.
     
    Mike -- Email Ignored, Mar 14, 2009
    #7
  8. Mike -- Email Ignored

    Paul Furman Guest

    Mike -- Email Ignored wrote:
    >
    > The intended purpose is to get quick jpegs with no correction, like
    > what Capture NX shows you when you first import the raw file. There
    > should be a simple "direct conversion" that requires no choices.
    > Serious image processing is done elsewhere, and is not part of
    > this requirement.


    I believe exiftool can extract the embedded jpgs from your NEF files.
    This gives the in-camera conversion which is going to most resemble what
    Capture would produce and what your histogram showed.

    --
    Paul Furman
    www.edgehill.net
    www.baynatives.com

    all google groups messages filtered due to spam
     
    Paul Furman, Mar 15, 2009
    #8
  9. On Sun, 15 Mar 2009 08:55:56 -0700, Paul Furman wrote:

    > Mike -- Email Ignored wrote:
    >>
    >> The intended purpose is to get quick jpegs with no correction, like
    >> what Capture NX shows you when you first import the raw file. There
    >> should be a simple "direct conversion" that requires no choices.
    >> Serious image processing is done elsewhere, and is not part of this
    >> requirement.

    >
    > I believe exiftool can extract the embedded jpgs from your NEF files.
    > This gives the in-camera conversion which is going to most resemble what
    > Capture would produce and what your histogram showed.


    I didn't know there is a jpeg embedded in the NEF files. Where
    can I read more about this?

    Mike.
     
    Mike -- Email Ignored, Mar 15, 2009
    #9
  10. On Sat, 14 Mar 2009 03:29:53 +0000, Mike -- Email Ignored wrote:

    > On Sat, 14 Mar 2009 14:20:07 +1100, Bob Larter wrote:
    >
    > [...]
    >>
    >> Try using the "as shot" white balance option:
    >>
    >> dcraw $MYFILE -w
    >>
    >> You might also experiment with the '-p embed' or '-W' options.
    >>
    >> (DCRAW man page: <http://www.cybercom.net/~dcoffin/dcraw/dcraw.1.html>)
    >>

    > [...]
    >>
    >> If you need to batch convert a large numbers of NEFs, I think it'd
    >> definitely be worth experimenting to get the best results.
    >>
    >>> Thanks for your advice.

    >>
    >> My pleasure. Please keep us posted on the results.

    >
    > Thanks, will do; but it is bedtime now at -0400. Mike.


    I just tried:

    dcraw -w -T : The result was reasonably good, but the histogram
    was different than the original. It appeared as if the
    brightness and contrast were adjusted so the low end remained
    in place, but the histogram was stretched in the high
    direction, so some of it ran off the top (losing some detail
    in the bright red and brightening highlights).

    dcraw -e : The result, including the histogram were
    indistinguishable from the original. The size was
    2832x4256 pixels which is more than enough for a 4"x6" print.
    I intend to run the result through convert with a maximum
    pixel size of 1800 before printing.

    I wonder if I can rely on the jpeg thumbnail always being
    large enough.

    Thanks again for your help.

    Mike.
     
    Mike -- Email Ignored, Mar 16, 2009
    #10
  11. Mike -- Email Ignored

    Bob Larter Guest

    Mike -- Email Ignored wrote:
    > dcraw -e : The result, including the histogram were
    > indistinguishable from the original. The size was
    > 2832x4256 pixels which is more than enough for a 4"x6" print.
    > I intend to run the result through convert with a maximum
    > pixel size of 1800 before printing.
    >
    > I wonder if I can rely on the jpeg thumbnail always being
    > large enough.


    I think you can safely assume that it'll always be the same size for the
    same camera.

    > Thanks again for your help.


    Glad I could help.

    --
    W
    . | ,. w , "Some people are alive only because
    \|/ \|/ it is illegal to kill them." Perna condita delenda est
    ---^----^---------------------------------------------------------------
     
    Bob Larter, Mar 16, 2009
    #11
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.