From: Erik Valdes-Estrada on 17 May 2010 16:54 F=radon(LxL,theta), but iradon(F,theta) ----> (L+2)x(L+2) !!! HELLO THERE, I have a question, isn't iradon supposed to return an array of the same dimensions as the one given to radon? I have tried with all kinds of projections and sizes, the only difference is that when the original matrix is of odd side, the reconstructed by iradon is of odd+1. Before I used matlab's radon and iradon I constructed my own from scratch and I know there should be no reason for this bijection issue on matlab. I'm I missing something? -Regards Erik V.
From: Matt J on 17 May 2010 17:13 "Erik Valdes-Estrada" <vaee(a)yahoo.com> wrote in message <hssadc$cbq$1(a)fred.mathworks.com>... > F=radon(LxL,theta), but iradon(F,theta) ----> (L+2)x(L+2) !!! > > HELLO THERE, > > I have a question, isn't iradon supposed to return an array of the same dimensions as the one given to radon? ============== No, as is apparent from the following excerpt from "help iradon". Of course, you can force the array to be the same dimensions by passing a non-default OUTPUT_SIZE parameter. OUTPUT_SIZE is a scalar that specifies the number of rows and columns in the reconstructed image. If OUTPUT_SIZE is not specified, the size is determined from the length of the projections: OUTPUT_SIZE = 2*floor(size(R,1)/(2*sqrt(2))) If you specify OUTPUT_SIZE, IRADON reconstructs a smaller or larger portion of the image, but does not change the scaling of the data. If the projections were calculated with the RADON function, the reconstructed image may not be the same size as the original image.
From: Matt J on 17 May 2010 17:20 "Erik Valdes-Estrada" <vaee(a)yahoo.com> wrote in message <hssadc$cbq$1(a)fred.mathworks.com>... > > Before I used matlab's radon and iradon I constructed my own from scratch and I know there should be no reason for this bijection issue on matlab. ============== The reason is because radon must select a projection grid large enough to contain the forward projections of the given image. This will involve some ceil() and other rounding operations that are not bijective. It's hard to see why your home-brewed routines, which you used before iradon/radon had bijective behavior. Perhaps you always used odd or even sized arrays... We would have to know what rule you used for setting up the grid sizes of the target output.
From: Ez on 17 May 2010 18:17 Of course we can try to use: X1 sqare F=radon(X1,theta), then X2=iradon(F,theta, size(X1,2)) to obtain X2 of the same dimensions as the original X1, but the image from X2 is still shifted by one pixel compared whit the original, no matter how small or large its X1 dimension is :( I think this is because the length of the projection 'F' produced by matlab's radon has been inaccurately determined. One way I found to correct this issue is to "manually" cut the bottom row of the projection F obtained with radon -and so its dimension- , so the length iradon interprets now is closer to the actual value. [Note] This solution only works for L even. -regards
From: Matt J on 17 May 2010 18:48 "Ez " <vaee(a)yahoo.com> wrote in message <hssf90$rbg$1(a)fred.mathworks.com>... > Of course we can try to use: > X1 sqare > F=radon(X1,theta), > then > X2=iradon(F,theta, size(X1,2)) to obtain X2 of the same dimensions as the original X1, but the image from X2 is still shifted by one pixel compared whit the original, no matter how small or large its X1 dimension is :( ============== I think you mean X2=iradon(F,theta, ~, ~, ~,size(X1,2)) > I think this is because the length of the projection 'F' produced by matlab's radon has been inaccurately determined. ================ radon does not compute a projection length (see doc radon). It uses a cruder algorithm that is basically the transpose of iradon() after subdividing the pixels. Regarding the 1 pixel discrepancy, I tend to think iradon just uses different rules from radon to decide where the coordinate origin is, always rouding it to the nearest pixel or something... The bottom line is, if you specialize in tomographic imaging and already have your own home-cooked forward and back projection routines, you probably have a much better implementation than radon/iradon. I don't know anybody in this field who uses them, at any rate.
|
Next
|
Last
Pages: 1 2 Prev: find distance along complicated geometric surface Next: quasi monte carlo with sobol sequence |