With the createAtomCluster a atom cluster can be generated. The generated pictures smaller ~500x500 do converge fine, but for the version 3000x1500 it doesn't if the macro variable SCALE_EXAMPLE_IMAGE is set to 1.
_Reconstruction (#define SCALE_EXAMPLE_IMAGE 0)_
Note the cluster is barely visible in the upper and bottom left corners.
I'm not sure why this happens. I hope I do not embarrass myself, but my guess actually is on the algorithm itself. First tests have shown, that it is a problem with the creation of the initial mask. The initial mask uses a a threshold determined by the maximum of the auto-correlation map (Fourier transform of diffraction intensity). For some reason that mask creation is dependent on the image dimensions. For the scaled atom cluster too many pixels will be masked out. The shrink wrap basically is too strong and slips off the object too reconstruct.
_Initial Mask (#define SCALE_EXAMPLE_IMAGE 1)_
_Initial Mask (#define SCALE_EXAMPLE_IMAGE 0)_
Basically, after tweaking rIntensityCutOffAutoCorel it should also converge, but somehow this parameter should be chosen automatically, or another parameter should be used, e.g. to select the 50% top pixels to be masked out initially, where 50% is an adjustable parameter. (Note that on 100% and 0% the HIO algorithm may not advance).
The proposed method would need to make a histogram of the pixels though, which could be a quite expensive operation.
With the createAtomCluster a atom cluster can be generated. The generated pictures smaller ~500x500 do converge fine, but for the version 3000x1500 it doesn't if the macro variable
SCALE_EXAMPLE_IMAGE
is set to 1._Ground Truth (
#define SCALE_EXAMPLE_IMAGE 1
)__Diffraction Intensity (
#define SCALE_EXAMPLE_IMAGE 1
)_Reconstructed Image (
#define SCALE_EXAMPLE_IMAGE 1
) (aborted after 64 iterations)But if
SCALE_EXAMPLE_IMAGE
is set to 0 it actually does converge exactly as well as the smaller versions._Ground Truth (
#define SCALE_EXAMPLE_IMAGE 0
)__Diffraction Intensity (
#define SCALE_EXAMPLE_IMAGE 0
)__Reconstruction (
#define SCALE_EXAMPLE_IMAGE 0
)_ Note the cluster is barely visible in the upper and bottom left corners.I'm not sure why this happens. I hope I do not embarrass myself, but my guess actually is on the algorithm itself. First tests have shown, that it is a problem with the creation of the initial mask. The initial mask uses a a threshold determined by the maximum of the auto-correlation map (Fourier transform of diffraction intensity). For some reason that mask creation is dependent on the image dimensions. For the scaled atom cluster too many pixels will be masked out. The shrink wrap basically is too strong and slips off the object too reconstruct.
_Initial Mask (
#define SCALE_EXAMPLE_IMAGE 1
)__Initial Mask (
#define SCALE_EXAMPLE_IMAGE 0
)_Basically, after tweaking
rIntensityCutOffAutoCorel
it should also converge, but somehow this parameter should be chosen automatically, or another parameter should be used, e.g. to select the 50% top pixels to be masked out initially, where 50% is an adjustable parameter. (Note that on 100% and 0% the HIO algorithm may not advance).The proposed method would need to make a histogram of the pixels though, which could be a quite expensive operation.