CERN / TIGRE

TIGRE: Tomographic Iterative GPU-based Reconstruction Toolbox
BSD 3-Clause "New" or "Revised" License
581 stars 190 forks source link

'OS_ASD_POCS' reconstruction results in visible streaks #607

Open COCOPOLLY opened 2 weeks ago

COCOPOLLY commented 2 weeks ago

Obviously see a clear streak in the reconfiguration result, I don't know where the parameter is set incorrectly

image FDK image OS_ASD_POCS

Code to reproduce the problem (If applicable)

%% Demo 4: Simple Image reconstruction
%
%
% This demo will show how a simple image reconstruction can be performed,
% by using OS-SART and FDK
%
%--------------------------------------------------------------------------
%--------------------------------------------------------------------------
% This file is part of the TIGRE Toolbox
% 
% Copyright (c) 2015, University of Bath and 
%                     CERN-European Organization for Nuclear Research
%                     All rights reserved.
%
% License:            Open Source under BSD. 
%                     See the full license at
%                     https://github.com/CERN/TIGRE/blob/master/LICENSE
%
% Contact:            tigre.toolbox@gmail.com
% Codes:              https://github.com/CERN/TIGRE/
% Coded by:           Ander Biguri 
%--------------------------------------------------------------------------
%% Initialize

clear;
close all;
%% Geometry
geo=defaultGeometry('nVoxel',[128;128;128]);                     

%% Load data and generate projections 
% define angles
angles=linspace(0,2*pi,100);
% Load thorax phantom data
head=headPhantom(geo.nVoxel);
% generate projections
projections=Ax(head,geo,angles,'interpolated');
% add noise
noise_projections=addCTnoise(projections);

%% Reconstruct image using OS-SART and FDK

% FDK
imgFDK=FDK(noise_projections,geo,angles);
% OS-SART

niter=50;
imgOSSART=OS_ASD_POCS(noise_projections,geo,angles,niter);

% Show the results
plotImg([imgFDK,imgOSSART],'Dim','Z');

Specifications

AnderBiguri commented 2 weeks ago

I supect the error in OS-ASD-POCS (the upper/lower differences) are related to #594 , which I am trying to fix.

COCOPOLLY commented 2 weeks ago

Thank you for your prompt reply, after testing I have no ghosts or streaks using small size projections and the method can be well applied in STEM-ET

COCOPOLLY commented 1 week ago

Hi, I tested your latest code #609 and found that the OS-ASD-POCS reconstruction results still show a lot of artifacts at the boundaries. image image And the results using the SART-TV reconstruction method are normal. image

AnderBiguri commented 1 week ago

@COCOPOLLY thanks for the report. Both of those algorithms use a different TV minimization code and I think that I only fixed one of them. Will try to work in the other one soon.

COCOPOLLY commented 6 days ago

Thank you for your attention. I sincerely hope that TIGRE continues to excel.

zezisme commented 3 days ago

hello @COCOPOLLY @AnderBiguri , maybe we need add a new line in https://github.com/CERN/TIGRE/blob/d63ad04740e58f3523458d8e31bec8e725e9fdf4/Common/CUDA/POCS_TV.cu#L464 the new line is:

cudaMemsetAsync(d_image[dev], 0, mem_img_each_GPU,stream[dev*nStream_device+1]); 

here is the new codes example image

And after complite, we can get a correct OS-ASD-POCS result, here is the results: The old code result(have streaks artifact) image The new code result (no artifact) image

COCOPOLLY commented 3 days ago

Oh, thanks so much, I'll try it!