First time focus stacking. How to get rid of artefacts.

A forum to ask questions, post setups, and generally discuss anything having to do with photomacrography and photomicroscopy.

Moderators: rjlittlefield, ChrisR, Chris S., Pau

sapstar
Posts: 15
Joined: Sat Feb 13, 2021 5:01 pm
Location: London

First time focus stacking. How to get rid of artefacts.

Post by sapstar »

I was trying out some focus stacking at 2.24x magnification today with some dry leaves. The first one is a stack of 9 photos, Second one is a stack of 20 photos and third one is a stack of 52 photos.
None of them are great, but the first one atleast doesn't have many artefacts. But the remaining 2 photos have a lot of halos throughout the photos. Am I doing something wrong or these artefacts are common with stacking?
A7RIII_1635_20210321_Stacked.jpg
A7RIII_1644_20210321_Stacked.jpg
A7RIII_1667_20210321_Stacked.jpg

rjlittlefield
Site Admin
Posts: 23562
Joined: Tue Aug 01, 2006 8:34 am
Location: Richland, Washington State, USA
Contact:

Re: First time focus stacking. How to get rid of artefacts.

Post by rjlittlefield »

sapstar wrote:
Sun Mar 21, 2021 4:29 pm
...a lot of halos throughout the photos. Am I doing something wrong or these artefacts are common with stacking?
Yes to both. Halos are very common, but there are standard ways of dealing with them, which you are not yet using.

To my eye, the most obvious artifacts that are really halos occur in image #3, where there are loss-of-detail halos around the bright vein and hairs in the upper right corner of the image.

In image #2, there is a different type of artifact that manifests as blurred areas that form wavy bands stretching clear across the image. That effect is called "focus banding", and it's due to using a step size that is a little too big. This type is easily avoided by using a smaller step size.

For loss-of-detail halos, the usual attack is to process the stack twice, once using a depth map method and once using a pyramid method, then use retouching to combine the best bits of each result. The pyramid method will not have loss-of-detail halos, but it may alter colors and contrasts and accumulate noise. The depth map method may have loss-of-detail halos, but it will retain accurate colors and contrasts and will not accumulate noise. So usually you start with the depth map result, then use the retouching brush to retrieve details from the pyramid result, only in places where details were lost by depth map. In Zerene Stacker, this means retouching DMap (depth map) from PMax (pyramid). In Helicon Focus, it means retouching Method B (depth map) from Method C (pyramid).

--Rik

sapstar
Posts: 15
Joined: Sat Feb 13, 2021 5:01 pm
Location: London

Re: First time focus stacking. How to get rid of artefacts.

Post by sapstar »

rjlittlefield wrote:
Sun Mar 21, 2021 5:30 pm
sapstar wrote:
Sun Mar 21, 2021 4:29 pm
...a lot of halos throughout the photos. Am I doing something wrong or these artefacts are common with stacking?
Yes to both. Halos are very common, but there are standard ways of dealing with them, which you are not yet using.

To my eye, the most obvious artifacts that are really halos occur in image #3, where there are loss-of-detail halos around the bright vein and hairs in the upper right corner of the image.

In image #2, there is a different type of artifact that manifests as blurred areas that form wavy bands stretching clear across the image. That effect is called "focus banding", and it's due to using a step size that is a little too big. This type is easily avoided by using a smaller step size.

For loss-of-detail halos, the usual attack is to process the stack twice, once using a depth map method and once using a pyramid method, then use retouching to combine the best bits of each result. The pyramid method will not have loss-of-detail halos, but it may alter colors and contrasts and accumulate noise. The depth map method may have loss-of-detail halos, but it will retain accurate colors and contrasts and will not accumulate noise. So usually you start with the depth map result, then use the retouching brush to retrieve details from the pyramid result, only in places where details were lost by depth map. In Zerene Stacker, this means retouching DMap (depth map) from PMax (pyramid). In Helicon Focus, it means retouching Method B (depth map) from Method C (pyramid).

--Rik
Thank you very much for the quick reply. I have noticed that I have used a step size larger. I am using the below focus rail for the steps. The movement is quite smooth, but there are no markings on it. I think I will need a bit more practice and get used to it. Is there a recommended focus slider which can help with the step sizes to be more accurate?
https://www.amazon.co.uk/gp/product/B07WK11QKW/

Regarding the focus stack methods you suggested, I will need to figure out how to do this. I am currently using Affinity Photo for focus merge. It doesn't really provide me any options during the merge.

rjlittlefield
Site Admin
Posts: 23562
Joined: Tue Aug 01, 2006 8:34 am
Location: Richland, Washington State, USA
Contact:

Re: First time focus stacking. How to get rid of artefacts.

Post by rjlittlefield »

sapstar wrote:
Sun Mar 21, 2021 6:56 pm
I am currently using Affinity Photo for focus merge. It doesn't really provide me any options during the merge.
You may have to switch to one of the dedicated focus stacking programs. Both Helicon Focus and Zerene Stacker (which I wrote) have 30-day free trials.
Is there a recommended focus slider which can help with the step sizes to be more accurate?
https://www.amazon.co.uk/gp/product/B07WK11QKW/
From product review videos, it looks to me like the two axes of that Neewer rail have quite different movements. It looks like the upper slide, the long axis, is a direct pinion drive, while the lower slide, the short axis, is a screw drive that provides much finer control. Are you already using the screw drive? If not, you should switch. If so, then you might consider adding a larger plate on the knob, to allow for smaller movements, something like shown HERE for a different rail. There's a lot of other options, but the Neewer rail looks pretty reasonable for where you are in the learning curve.

--Rik

sapstar
Posts: 15
Joined: Sat Feb 13, 2021 5:01 pm
Location: London

Re: First time focus stacking. How to get rid of artefacts.

Post by sapstar »

rjlittlefield wrote:
Sun Mar 21, 2021 9:39 pm
You may have to switch to one of the dedicated focus stacking programs. Both Helicon Focus and Zerene Stacker (which I wrote) have 30-day free trials.
I will give this a try. Thought the Helicon was too expensive for my occasional macro photography :(.
rjlittlefield wrote:
Sun Mar 21, 2021 9:39 pm
From product review videos, it looks to me like the two axes of that Neewer rail have quite different movements. It looks like the upper slide, the long axis, is a direct pinion drive, while the lower slide, the short axis, is a screw drive that provides much finer control. Are you already using the screw drive? If not, you should switch. If so, then you might consider adding a larger plate on the knob, to allow for smaller movements, something like shown HERE for a different rail. There's a lot of other options, but the Neewer rail looks pretty reasonable for where you are in the learning curve.
--Rik
The drive on both axes is the same for the focus slider I have. Please take a look at the picture below. I think it is a screw drive. While operating, I don't feel any difference between the 2. There are multiple Neewer macro sliders, but this not the widely reviewed one on youtube. This has only 2 reviews on youtube. https://www.youtube.com/watch?v=WsFeevpwVx4
Screenshot 2021-03-22 at 08.53.23.png
I also ordered a set of contax bellows which comes with a focus slider attached. That one seems to be a pinion drive which I thought was smoother to operate than the Neewer. This one doesn't have any markings too. I will also give this a try.
s-l300.jpg

rjlittlefield
Site Admin
Posts: 23562
Joined: Tue Aug 01, 2006 8:34 am
Location: Richland, Washington State, USA
Contact:

Re: First time focus stacking. How to get rid of artefacts.

Post by rjlittlefield »

sapstar wrote:
Mon Mar 22, 2021 2:19 am
Thought the Helicon was too expensive for my occasional macro photography :(.
For what you need, Zerene Stacker Personal Edition would be less than half the price in the long run. That's because Helicon Focus does not provide retouching in its Lite version, only in Pro or Premium. Zerene Stacker provides retouching at all price points. If you're into free stuff, you might try PicoLay. It's been several years since I last used that, but some of the current videos look promising.
rjlittlefield wrote:
Sun Mar 21, 2021 9:39 pm
The drive on both axes is the same for the focus slider I have. ... While operating, I don't feel any difference between the 2. There are multiple Neewer macro sliders, but this not the widely reviewed one on youtube. This has only 2 reviews on youtube. https://www.youtube.com/watch?v=WsFeevpwVx4
The video that you reference is the one that I watched. At 1:35 the inset shows that the knob on the backside has its axis running perpendicular to the axis of movement, which is typical of pinion drives. The knob on the frontside has its axis running parallel to the axis of movement, which is typical of screw drives. But when I slow the video down, I see that the mm/turn does look similar on both axes, so maybe they have the pinion drive geared down.

In any case, at 2X you'll be needing to make focus steps someplace around 0.2-0.1 mm, better on the short end of that. The usual low price solution to that problem is a screw-driven rail with a screw pitch around 1 mm, something like the iShoot Macro Focusing Rail 150 that I modified as shown at the link I provided earlier, HERE. The stack at viewtopic.php?t=35024 was shot using that rail, 2X at 0.1 mm step size.

--Rik

sapstar
Posts: 15
Joined: Sat Feb 13, 2021 5:01 pm
Location: London

Re: First time focus stacking. How to get rid of artefacts.

Post by sapstar »

Thanks very much for all your help @rjlittlefield. I have now installed both Zerene and Picolay. Did the stacking yesterday, but wasn't very sure how the retouching works. Will watch some youtube videos and learn to fix the artefacts.

In terms of the gear I will first try and get better with the 2 different focus sliders I have and if these definitely are not fit for purpose, then I will look into other options.

rjlittlefield
Site Admin
Posts: 23562
Joined: Tue Aug 01, 2006 8:34 am
Location: Richland, Washington State, USA
Contact:

Re: First time focus stacking. How to get rid of artefacts.

Post by rjlittlefield »

sapstar wrote:
Tue Mar 23, 2021 8:08 am
Did the stacking yesterday, but wasn't very sure how the retouching works. Will watch some youtube videos and learn to fix the artefacts.
For Zerene Stacker, the "official" videos about retouching are the ones linked on its own Tutorials index page, at https://zerenesystems.com/cms/stacker/d ... rialsindex . They are not on YouTube so YouTube won't find them.

While you're on the Tutorials page, I always recommend that new users study at least the first 7 bullets, down to "Tips for Retouching".

Happy stacking!

--Rik

sapstar
Posts: 15
Joined: Sat Feb 13, 2021 5:01 pm
Location: London

Re: First time focus stacking. How to get rid of artefacts.

Post by sapstar »

@rjlittlefield, thanks for your guidance. I have been practicing the last couple of days. Wanted to share the results. I think I am able to shoot without focus banding now. Also learning to use both Zerene and Affinity photo for stacking.
These were shot around 3:1 roughly, using some old bellows and a El-Nikkor 50mm 2.8 Enlarger lens. As per Zerene stacker help, I see it is recommended to use the rear of the bellows rather than the focus slider. Previously I was using the focus slider.

Actual Subject:
Image

Output from Zerene Stacker - Pmax and edited to remove halos and some trails caused by sensor dust.
Image

Output from Affinity photo - Similar edits to above, but less control as dmap wasn't available. But was able to produce more pixels around the corners. I actually cropped some of the area at the bottom here.
Image

rjlittlefield
Site Admin
Posts: 23562
Joined: Tue Aug 01, 2006 8:34 am
Location: Richland, Washington State, USA
Contact:

Re: First time focus stacking. How to get rid of artefacts.

Post by rjlittlefield »

sapstar wrote:
Thu Mar 25, 2021 1:35 pm
I have been practicing the last couple of days
These are looking good.
Affinity photo ... was able to produce more pixels around the corners.
By default, Zerene Stacker starts at the narrow end of the stack and adjusts all the other frames to fit the first frame on the narrow end. The purpose is to restrict the final field of view to just those areas that are represented in all frames and thus will not have any out-of-frame artifacts.

Some other tools, especially ones that also provide panorama stitching, will produce an output that includes all areas covered by any frame. Photoshop will do that, and I'm guessing that Affinity is doing it also. That can be a useful feature, particularly for people who have not yet gotten used to the idea that the frame size does change from one end of the stack to the other. But it can also be a bit of a trap, because not getting used to that idea means that in some stacks, edge regions that you would otherwise like to have will never get captured in focus.

In Zerene Stacker, if you do want to recover those edge regions then there are options that will let you start at the wide end of the stack. See https://zerenesystems.com/cms/stacker/d ... _my_images and https://zerenesystems.com/cms/stacker/d ... _processed . If you do start at the wide end, then you'll be vulnerable to an artifact called "edge streaks", which are caused by Zerene Stacker's default way of handling out-of-frame regions of the image. There are options that can avoid that also, but see the discussion at https://zerenesystems.com/cms/stacker/d ... hy_is_that .

--Rik

sapstar
Posts: 15
Joined: Sat Feb 13, 2021 5:01 pm
Location: London

Re: First time focus stacking. How to get rid of artefacts.

Post by sapstar »

Thanks for all the information Rik. Also would it matter if I shoot starting focussing the subject closer to lens and move further or the other way round?

rjlittlefield
Site Admin
Posts: 23562
Joined: Tue Aug 01, 2006 8:34 am
Location: Richland, Washington State, USA
Contact:

Re: First time focus stacking. How to get rid of artefacts.

Post by rjlittlefield »

sapstar wrote:
Thu Mar 25, 2021 3:04 pm
Thanks for all the information Rik. Also would it matter if I shoot starting focussing the subject closer to lens and move further or the other way round?
See https://zerenesystems.com/cms/stacker/docs/faqlist#does_it_matter_if_i_shoot_the_stack_in_order

In addition to the Tutorials, it's often helpful to proactively read through the FAQs. Many people find issues mentioned there that they haven't even thought to ask yet.

--Rik

Post Reply Previous topicNext topic