[Play Raw] First foss processing - panorama

This is my first attempt to fully process an image using foss, from shooting (CHDK) to developing (Hugin/Luminance HDR, Photoflow),
It was aimed to be an hdr panorama, following the steps in this post, but since I did the shots hand held, I had aligning issues.
So I gave up the hdr workflow and took the 0 EV frames, aligned them with align_stack, then I created two images from that one, under and over exposed by 1 step.
Then I used Photo Flow to merge them together (ground and sky).
This is the result:

The raws:
CRW_3486.DNG (17.8 MB)
CRW_3487.DNG (17.8 MB)
CRW_3488.DNG (17.8 MB)
CRW_3489.DNG (17.8 MB)
CRW_3490.DNG (17.8 MB)
CRW_3491.DNG (17.8 MB)
CRW_3492.DNG (17.8 MB)
CRW_3493.DNG (17.8 MB)
CRW_3494.DNG (17.8 MB)

And Photoflow pfi file: stackf_v4.pfi (195.4 KB)

As I don’t have a calibrated monitor, I really don’t know how others will see this. I hope it’s not too bad.

These files are licensed Creative Commons, By-Attribution, Share-Alike
(Creative Commons, By-Attribution, Share-Alike)


@gadolf I am glad that you posted this. As I said in the other thread, it is a nice photo. Nice to look at and probably nice to play with. One thing to improve is actually drop the raws into the post itself instead of using filebin, which will expire. Then future visitors or users won’t be able to play :cry:. If you have trouble with that, please @ any of the mods.

1 Like

@afre Thanks. I guess I’ll need help, tried to upload the nine dng’s but no success.
Whom should I ask help for?

If the files were zipped and exceeded 100MB, they were to big. You should be able to upload them individually.

I gave this pano a quick go, and merged the brackets before even checking what they were, before checking whether it was worth merging them. Since there was little difference between the brackets in each bracketed set there was very little to gain, and the resulting merged file, after automatic alignment, suffered from some issues.

There were merging artifacts in the clouds:

Furthermore, each source raw file was riddled with dead pixels, so the merged file had as many dead pixels if not more - the extra ones would appear in transition zones where the source images blended one into another.

The lesson is that there is little to gain, and in fact time and quality to lose, by merging shots where the difference between the darkest and brightest image is only 1EV, as is the case here. As such, I would recommend uploading only the darkest shot of each bracketed stack: CRW_3488.DNG, CRW_3491.DNG and CRW_3494.DNG.


It was fun to see what could be squeezed out from raw files from such a tiny compact camera.

I did this in two steps.

  1. The first step was to squash the dynamic range. I suppose I did this more out of habit than necessity. The first reason for squashing before stitching was that some programs don’t handle high precision (floating-point TIFF or EXR) images well, so you can avoid the issues by stitching 16-bit TIFFs which were already compressed (tone-mapped, fused, manually blended, whatever). The second reason is that some tools requires much RAM, and when dealing with high resolution panoramas (hundreds of megapixels) you might not be able to run certain tools on the whole stitched pano. Neither of these reasons apply here, since this is a small panorama. Here is one of the compressed images before stitching:
  2. The three tiles were then stitched in Hugin, and the final pano got a curves treatment in RawTherapee with a little wavelet edge sharpness and TM for pop:

Resulting overcooked pano:


P.S. Try Retinex on these images, it really shines here.

1 Like

Thanks for sharing!
Here’s my route: hdrmerge → RT → hugin
I’m not a huge fan of the “HDR look” so I tried to keep this somehow natural looking (whatever that means :slight_smile: There are some halos visible if you look at the image scaled down, but I find them acceptable if you look at the pic in full size (think about printing big).


@agriggio Wow, amazing! How have you managed to aligned them so well? I lost a week or so just to have them fit and gave up…
If you could post the hdrmerge command you used it would be great.
Also, I don’t understand quite well the idea behind your work flow. Have you used hdrmerge only to align the images, then you processed them individually on RT and only stitched them in the end?

Thanks to CHDK (I believe), since it allows me to grab raw files (beside many other functions not available in the original Canon firmware)

And thanks for your thoughts and time.

Wouldn’t a previous development on individual images solve that?

As for selecting the under exposed ones, I assume you’ve done so because you decided to prioritize the sky, right?

When you do that, aren’t you eliminating data and detail?

@gadolf I used auto-align and auto-crop in HDRMerge, didn’t manually touch the mask.

HDRMerge doesn’t only-align, it’s all or nothing, meaning if you align, you must save the aligned and merged HDR DNG, not the individual frames. However! You could, if you wanted to, then export bracketed TIFFs from the HDR DNG using RawTherapee. So, for example, bracket -4EV, -2EV, 0EV, +2EV, +4EV, merge them using HDRMerge (with auto-align if needed), open the HDR DNG in RawTherapee, then set exposure compensation to -4EV (and enable chromatic aberration correction, dead pixel correction, etc.), save a TIFF, set EC to -2EV, save, 0EV, save, +2EV, save +4EV, save. Now you have 5 aligned TIFFs which you could for example use in Luminance HDR. Why would you do this, instead of just opening the HDR DNG in that program, or instead of exporting a single 32-bit TIFF or EXR from RT? Several reasons. Storing one losslessly compressed HDR DNG takes up far less disk space than storing five usually uncompressed or poorly compressed original raw files - people who stitch panoramas may find that significant. Another reason could be that some software doesn’t support HDR DNG files, nor does it support 32-bit TIFF or EXR files. And yet another that some software doesn’t align well, and doesn’t prevent ghosting well.


Nope. Unless you consider a 16-bit TIFF to be insufficient to store the data and detail, but that’s not the case here.

@Morgan_Hardwood Actually I was referring to @agriggio’s alignment, since he seem to have used all frames. When I tried that, I always ended with alignment issues. That’s why I ended up using only one EV step set.
Anyway, thanks for the elaboration on your hdr workflow. I’ll try that (not sure when :disappointed:) and get back with results.

As did I. Which was a mistake, since there was nothing to gain by doing that, but I didn’t check beforehand.

As did I. Which was a mistake, since there was nothing to gain by doing that, but I didn’t check beforehand.

Oh, ok.
But aren’t you too radical in saying that “there was nothing to gain”?
I mean, I agree that three bracketed, one step images won’t add too much to the dynamic range, but doesn’t it, still, add something?
Do you usually take hdr’s with that range (-4,-2, 0, +2, +4)?

I didn’t check either. I simply used (a recent version from git of) hdrmerge with auto align and auto crop, as Morgan said. Nothing fancy really. Then developed the 3 frames in RT (or better, I only worked on the central one, and then copied the settings to the other two), exported, and quickly stitched with hugin.

1 Like

It adds merging artifacts and it adds time to the workflow. I’d say the reduction in noise as opposed to just using the brightest-but-not-clipped images is not worth it.

Yes, when needed, which is usually “always” when shooting a 360 panorama. Otherwise just -2EV, 0, +2EV.

@agriggio Thanks.
I’ll try that and see what happens.
I like the result you’ve got, but I would boost a little bit the ground.

Issue opened

  1. I opened DNG at Darktable

  2. Adjust to all:CRW_3494.DNG.xmp (3.5 KB)

  3. Export Tif16

  4. I opened Tifs to Hugin

  5. Normal stich in Hugin (Exposure fused from stacks)–>Tif

  6. I opened Tif to Darktable

  7. Adjust:CRW_3486 - CRW_3494_fused.tif.xmp (8.8 KB)

  8. Export jpg

Second sample:

  1. I opened DNG at Darktable
  2. Export all Tif32
  3. Normal stich in Hugin (Exposure fused from stacks)–>Tif
  4. I opened Tif to Darktable
  5. Adjust CRW_3486 - CRW_3494_fused.tif.xmp (3.6 KB)
    6.Export jpg
1 Like

I used @partha’s GIMP 2.9.8 Std’s panorama stitcher (well, actually it is the free panorama stitcher from Microsoft) after doing preliminary processing in RT 5.4. Tried to anchor viewer’s attention to the yellow building at the bottom of the hill by making it prominent!


Here my try with only CRW_3486.dng :slight_smile:

CRW_3486.pfi (33.9 KB)