Skip to content

Commit

Permalink
Merge branch 'RTKConsortium:master' into doc
Browse files Browse the repository at this point in the history
  • Loading branch information
axel-grc authored Feb 20, 2025
2 parents c992463 + 82f78c9 commit cae7d0b
Show file tree
Hide file tree
Showing 84 changed files with 339 additions and 187 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkadmmtotalvariation"
purpose "Performs an iterative 3D reconstruction with 3D TV regularization"

option "verbose" v "Verbose execution" flag off
Expand Down
1 change: 0 additions & 1 deletion applications/rtkadmmwavelets/rtkadmmwavelets.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkadmmwavelets"
purpose "Performs an iterative 3D reconstruction with Daubechies wavelets regularization"

option "verbose" v "Verbose execution" flag off
Expand Down
1 change: 0 additions & 1 deletion applications/rtkamsterdamshroud/rtkamsterdamshroud.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkamsterdamshroud"
purpose "Creates an Amsterdam Shroud image from a sequence of projections [Zijp et al, ICCR, 2004]."

option "verbose" v "Verbose execution" flag off
Expand Down
1 change: 0 additions & 1 deletion applications/rtkbackprojections/rtkbackprojections.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkbackprojections"
purpose "Backprojects a volume according to a geometry file."

option "verbose" v "Verbose execution" flag off
Expand Down
1 change: 0 additions & 1 deletion applications/rtkbioscangeometry/rtkbioscangeometry.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkbioscangeometry"
purpose "Creates an RTK geometry file from a sequence of x-ray projections of a Bioscan NanoSPECT/CT scanner."

option "verbose" v "Verbose execution" flag off
Expand Down
1 change: 0 additions & 1 deletion applications/rtkcheckimagequality/rtkcheckimagequality.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkcheckimagequality"
purpose "Checks the MSE of a reconstructed image against a reference."

option "verbose" v "Verbose execution" flag off
Expand Down
1 change: 0 additions & 1 deletion applications/rtkconjugategradient/rtkconjugategradient.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkconjugategradient"
purpose "Reconstructs a 3D volume from a sequence of projections with a conjugate gradient technique"

option "verbose" v "Verbose execution" flag off
Expand Down
1 change: 0 additions & 1 deletion applications/rtkdigisensgeometry/rtkdigisensgeometry.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkdigisensgeometry"
purpose "Creates an RTK geometry file from a Digisens geometry calibration."

option "verbose" v "Verbose execution" flag off
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkdrawgeometricphantom"
purpose "Computes a 3D voxelized phantom from a phantom description file"

option "verbose" v "Verbose execution" flag off
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkdrawshepploganphantom"
purpose "Computes a 3D voxelized Shepp & Logan phantom with noise [https://www.slaney.org/pct/pct-errata.html]"

option "verbose" v "Verbose execution" flag off
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ main(int argc, char * argv[])
using DualEnergyProjectionsType = itk::VectorImage<PixelValueType, Dimension>;
using DualEnergyProjectionWriterType = itk::ImageFileWriter<DualEnergyProjectionsType>;

using IncidentSpectrumImageType = itk::VectorImage<PixelValueType, Dimension - 1>;
using IncidentSpectrumImageType = itk::Image<PixelValueType, Dimension>;
using IncidentSpectrumReaderType = itk::ImageFileReader<IncidentSpectrumImageType>;

using DetectorResponseImageType = itk::Image<PixelValueType, Dimension - 1>;
Expand All @@ -66,6 +66,10 @@ main(int argc, char * argv[])
materialAttenuationsReader->SetFileName(args_info.attenuations_arg);
materialAttenuationsReader->Update();

// Get parameters from the images
const unsigned int MaximumEnergy =
incidentSpectrumReaderHighEnergy->GetOutput()->GetLargestPossibleRegion().GetSize(0);

// If the detector response is given by the user, use it. Otherwise, assume it is included in the
// incident spectrum, and fill the response with ones
DetectorResponseReaderType::Pointer detectorResponseReader = DetectorResponseReaderType::New();
Expand All @@ -82,16 +86,13 @@ main(int argc, char * argv[])
rtk::ConstantImageSource<DetectorResponseImageType>::New();
DetectorResponseImageType::SizeType sourceSize;
sourceSize[0] = 1;
sourceSize[1] = incidentSpectrumReaderHighEnergy->GetOutput()->GetVectorLength();
sourceSize[1] = MaximumEnergy;
detectorSource->SetSize(sourceSize);
detectorSource->SetConstant(1.0);
detectorSource->Update();
detectorImage = detectorSource->GetOutput();
}

// Get parameters from the images
const unsigned int MaximumEnergy = incidentSpectrumReaderHighEnergy->GetOutput()->GetVectorLength();

// Generate a set of zero-filled intensity projections
DualEnergyProjectionsType::Pointer dualEnergyProjections = DualEnergyProjectionsType::New();
dualEnergyProjections->CopyInformation(decomposedProjectionReader->GetOutput());
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkspectralforwardmodel"
purpose "Computes expected photon counts from incident spectrum, material attenuations, detector response and material-decomposed projections"

option "verbose" v "Verbose execution" flag off
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ main(int argc, char * argv[])
using DualEnergyProjectionsType = itk::VectorImage<PixelValueType, Dimension>;
using DualEnergyProjectionReaderType = itk::ImageFileReader<DualEnergyProjectionsType>;

using IncidentSpectrumImageType = itk::VectorImage<PixelValueType, Dimension - 1>;
using IncidentSpectrumImageType = itk::Image<PixelValueType, Dimension>;
using IncidentSpectrumReaderType = itk::ImageFileReader<IncidentSpectrumImageType>;

using DetectorResponseImageType = itk::Image<PixelValueType, Dimension - 1>;
Expand Down Expand Up @@ -71,6 +71,10 @@ main(int argc, char * argv[])
materialAttenuationsReader->SetFileName(args_info.attenuations_arg);
materialAttenuationsReader->Update();

// Get parameters from the images
const unsigned int MaximumEnergy =
incidentSpectrumReaderHighEnergy->GetOutput()->GetLargestPossibleRegion().GetSize(0);

// If the detector response is given by the user, use it. Otherwise, assume it is included in the
// incident spectrum, and fill the response with ones
DetectorResponseReaderType::Pointer detectorResponseReader = DetectorResponseReaderType::New();
Expand All @@ -87,23 +91,13 @@ main(int argc, char * argv[])
rtk::ConstantImageSource<DetectorResponseImageType>::New();
DetectorResponseImageType::SizeType sourceSize;
sourceSize[0] = 1;
sourceSize[1] = incidentSpectrumReaderHighEnergy->GetOutput()->GetVectorLength();
sourceSize[1] = MaximumEnergy;
detectorSource->SetSize(sourceSize);
detectorSource->SetConstant(1.0);
detectorSource->Update();
detectorImage = detectorSource->GetOutput();
}

// Get parameters from the images
const unsigned int MaximumEnergy = incidentSpectrumReaderHighEnergy->GetOutput()->GetVectorLength();

IncidentSpectrumImageType::IndexType indexIncident;
indexIncident.Fill(0);
if (incidentSpectrumReaderLowEnergy->GetOutput()->GetPixel(indexIncident).Size() != MaximumEnergy)
itkGenericExceptionMacro(<< "Low energy incident spectrum image has vector size "
<< incidentSpectrumReaderLowEnergy->GetOutput()->GetPixel(indexIncident).Size()
<< ", should be " << MaximumEnergy);

if (detectorImage->GetLargestPossibleRegion().GetSize()[1] != MaximumEnergy)
itkGenericExceptionMacro(<< "Detector response image has " << detectorImage->GetLargestPossibleRegion().GetSize()[1]
<< "energies, should have " << MaximumEnergy);
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkdualenergysimplexdecomposition"
purpose "Decomposes dual energy projections into materials"

option "verbose" v "Verbose execution" flag off
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkelektasynergygeometry"
purpose "Creates an RTK geometry file from an Elekta Synergy acquisition."

option "verbose" v "Verbose execution" flag off
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkextractshroudsignal"
purpose "Extracts the phase from a signal."

option "verbose" v "Verbose execution" flag off
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkextractshroudsignal"
purpose "Extracts the breathing signal from a shroud image."

option "verbose" v "Verbose execution" flag off
Expand Down
1 change: 0 additions & 1 deletion applications/rtkfdk/rtkfdk.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkfdk"
purpose "Reconstructs a 3D volume from a sequence of projections [Feldkamp, David, Kress, 1984]."

option "verbose" v "Verbose execution" flag off
Expand Down
1 change: 0 additions & 1 deletion applications/rtkfdktwodweights/rtkfdktwodweights.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkfdktwodweights"
purpose "Weights projection stack with 2D weights of Feldkamp cone-beam reconstruction algorithm."

option "verbose" v "Verbose execution" flag off
Expand Down
1 change: 0 additions & 1 deletion applications/rtkfieldofview/rtkfieldofview.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkfieldofview"
purpose "Computes the field of view of a reconstruction."

option "verbose" v "Verbose execution" flag off
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkforwardprojections"
purpose "Projects a volume according to a geometry file."

option "verbose" v "Verbose execution" flag off
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkfourdconjugategradient"
purpose "Reconstructs a 3D + time sequence of volumes from a projection stack and a respiratory/cardiac signal, with a conjugate gradient technique"

option "verbose" v "Verbose execution" flag off
Expand Down
1 change: 0 additions & 1 deletion applications/rtkfourdfdk/rtkfourdfdk.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkfourdfdk"
purpose "Reconstructs a 4D volume from a sequence of projections using FDK with one projection per respiratory cycle in each frame."

option "verbose" v "Verbose execution" flag off
Expand Down
1 change: 0 additions & 1 deletion applications/rtkfourdrooster/rtkfourdrooster.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkfourdrooster"
purpose "Reconstructs a 3D + time sequence of volumes from a projection stack and a respiratory/cardiac signal, applying TV regularization in space and time, and restricting motion to a region of interest"

option "verbose" v "Verbose execution" flag off
Expand Down
1 change: 0 additions & 1 deletion applications/rtkfourdsart/rtkfourdsart.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkfourdsart"
purpose "Reconstructs a 4D sequence of volumes from a sequence of projections with a 4D version of the Simulatenous Algebraic Reconstruction Technique [Andersen, 1984]."

option "verbose" v "Verbose execution" flag off
Expand Down
1 change: 0 additions & 1 deletion applications/rtkgaincorrection/rtkgaincorrection.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtk"
purpose "Polynomial gain correction projections"

option "config" - "Config file" string no
Expand Down
1 change: 0 additions & 1 deletion applications/rtki0estimation/rtki0estimation.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtki0estimation"
purpose "Reads projection images and estimates the I0 value for each of them"

option "verbose" v "Verbose execution" flag off
Expand Down
1 change: 0 additions & 1 deletion applications/rtkimagxgeometry/rtkimagxgeometry.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkimagxgeometry"
purpose "Creates an RTK geometry file from an iMagX acquisition."

option "config" - "Config file" string no
Expand Down
1 change: 0 additions & 1 deletion applications/rtkiterativefdk/rtkiterativefdk.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkiterativefdk"
purpose "Reconstructs a 3D volume from a sequence of projections [Feldkamp, David, Kress, 1984]."

option "verbose" v "Verbose execution" flag off
Expand Down
1 change: 0 additions & 1 deletion applications/rtklagcorrection/rtklagcorrection.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtklagcorrection"
purpose "4th order LTI Lag correction"

option "config" - "Config file" string no
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtklastdimensionl0gradientdenoising"
purpose "Performs denoising by minimizing the l0 norm of the gradient"

option "verbose" v "Verbose execution" flag off
Expand Down
1 change: 0 additions & 1 deletion applications/rtklut/rtklut.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtklut"
purpose "Converts pixel intensities of projection images according to lookup table"

option "verbose" v "Verbose execution" flag off
Expand Down
1 change: 0 additions & 1 deletion applications/rtkmaskcollimation/rtkmaskcollimation.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkmaskcollimation"
purpose "Masks out the collimator from the projections"

option "verbose" v "Verbose execution" flag off
Expand Down
1 change: 0 additions & 1 deletion applications/rtkmcrooster/rtkmcrooster.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkmcrooster"
purpose "Reconstructs a 3D + time sequence of volumes from a projection stack and a respiratory/cardiac signal, applying TV regularization in space and time, and restricting motion to a region of interest"

option "verbose" v "Verbose execution" flag off
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkmotioncompensatedfourdconjugategradient"
purpose "Performs a motion-compensated 4D reconstruction by the conjugate gradient method"

option "verbose" v "Verbose execution" flag off
Expand Down
1 change: 0 additions & 1 deletion applications/rtkorageometry/rtkorageometry.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkorageometry"
purpose "Creates an RTK geometry file from a sequence of ora.xml files (radART / medPhoton file format)."

option "verbose" v "Verbose execution" flag off
Expand Down
1 change: 0 additions & 1 deletion applications/rtkosem/rtkosem.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkosem"
purpose "Reconstructs a 3D volume from a sequence of projections with Ordered subset expectation maximization."

option "verbose" v "Verbose execution" flag off
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkoverlayphaseandshroud"
purpose "Generates an RGB image showing the phase peaks on top of the shroud"

option "verbose" v "Verbose execution" flag off
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkparkershortscanweighting"
purpose "Weights projection stack with parker weights for short scan with a divergent geometry."

option "verbose" v "Verbose execution" flag off
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkprojectgeometricphantom"
purpose "Computes projections through a 3D phantom described by a file, according to a geometry"

option "verbose" v "Verbose execution" flag off
Expand Down
1 change: 0 additions & 1 deletion applications/rtkprojectionmatrix/rtkprojectionmatrix.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkprojectionmatrix"
purpose "Saves the sparse system matrix of rtk::JosephForwardProjectionImageFilter in a file. Only works in 2D."

option "verbose" v "Verbose execution" flag off
Expand Down
1 change: 0 additions & 1 deletion applications/rtkprojections/rtkprojections.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkprojections"
purpose "Reads raw projection images, converts them to attenuation and stacks them into a single output image file"

option "verbose" v "Verbose execution" flag off
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkprojectshepploganphantom"
purpose "Computes projections through a 3D Shepp & Logan phantom, according to a geometry"

option "verbose" v "Verbose execution" flag off
Expand Down
1 change: 0 additions & 1 deletion applications/rtkramp/rtkramp.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkramp"
purpose "Reads raw projection images, converts to attenuation, ramp filters and stacks them into a single output image file"

option "verbose" v "Verbose execution" flag off
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkrayboxintersection"
purpose "Computes the intersection length between rays of 2D projections and a 3D volume."

option "verbose" v "Verbose execution" flag off
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkrayellipsoidintersection"
purpose "Computes the intersection length between rays of 2D projections and a 3D ellipsoid"

option "verbose" v "Verbose execution" flag off
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkrayquadricintersection"
purpose "Computes the intersection length between rays of 2D projections and a 3D quadric"

option "verbose" v "Verbose execution" flag off
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkregularizedconjugategradient"
purpose "Alternates between conjugate gradient reconstruction and regularization"

option "verbose" v "Verbose execution" flag off
Expand Down
1 change: 0 additions & 1 deletion applications/rtksart/rtksart.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtksart"
purpose "Reconstructs a 3D volume from a sequence of projections with Simulatenous Algebraic Reconstruction Technique [Andersen, 1984]."

option "verbose" v "Verbose execution" flag off
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkscatterglarecorrection"
purpose "Reads projection images and correct them for scatter glare"

option "verbose" v "Verbose execution" flag off
Expand Down
1 change: 0 additions & 1 deletion applications/rtksimulatedgeometry/rtksimulatedgeometry.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtksimulatedgeometry"
purpose "Creates an RTK geometry file from simulated/regular trajectory. See https://docs.openrtk.org/en/latest/documentation/docs/Geometry.html for more information."

option "verbose" v "Verbose execution" flag off
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkspectraldenoiseprojections"
purpose "Replaces aberrant pixels by the median in a small neighborhood around them. Pixels are aberrant if the difference between their value and the median is larger that threshold multiplier * the standard deviation in the neighborhood"

option "verbose" v "Verbose execution" flag off
Expand Down
10 changes: 2 additions & 8 deletions applications/rtkspectralforwardmodel/rtkspectralforwardmodel.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ main(int argc, char * argv[])
constexpr unsigned int Dimension = 3;
using DecomposedProjectionType = itk::VectorImage<PixelValueType, Dimension>;
using MeasuredProjectionsType = itk::VectorImage<PixelValueType, Dimension>;
using IncidentSpectrumImageType = itk::VectorImage<PixelValueType, Dimension - 1>;
using IncidentSpectrumImageType = itk::Image<PixelValueType, Dimension>;
using DetectorResponseImageType = itk::Image<PixelValueType, Dimension - 1>;
using MaterialAttenuationsImageType = itk::Image<PixelValueType, Dimension - 1>;

Expand All @@ -55,7 +55,7 @@ main(int argc, char * argv[])
// Get parameters from the images
const unsigned int NumberOfMaterials = materialAttenuations->GetLargestPossibleRegion().GetSize()[0];
const unsigned int NumberOfSpectralBins = args_info.thresholds_given;
const unsigned int MaximumEnergy = incidentSpectrum->GetVectorLength();
const unsigned int MaximumEnergy = incidentSpectrum->GetLargestPossibleRegion().GetSize()[0];

// Generate a set of zero-filled photon count projections
MeasuredProjectionsType::Pointer measuredProjections = MeasuredProjectionsType::New();
Expand Down Expand Up @@ -88,12 +88,6 @@ main(int argc, char * argv[])
<< measuredProjections->GetPixel(indexSpect).Size() << ", should be "
<< NumberOfSpectralBins);

IncidentSpectrumImageType::IndexType indexIncident;
indexIncident.Fill(0);
if (incidentSpectrum->GetPixel(indexIncident).Size() != MaximumEnergy)
itkGenericExceptionMacro(<< "Incident spectrum image has vector size "
<< incidentSpectrum->GetPixel(indexIncident).Size() << ", should be " << MaximumEnergy);

if (detectorResponse->GetLargestPossibleRegion().GetSize()[0] != MaximumEnergy)
itkGenericExceptionMacro(<< "Detector response image has "
<< detectorResponse->GetLargestPossibleRegion().GetSize()[0] << "energies, should have "
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkspectralforwardmodel"
purpose "Computes expected photon counts from incident spectrum, material attenuations, detector response and material-decomposed projections"

option "verbose" v "Verbose execution" flag off
Expand Down
1 change: 0 additions & 1 deletion applications/rtkspectralonestep/rtkspectralonestep.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkconjugategradient"
purpose "Reconstructs a set of 3D volumes from a set of photon counts projections, using the method described by Mechlem et al. in IEEE TMI in 2017"

option "verbose" v "Verbose execution" flag off
Expand Down
1 change: 0 additions & 1 deletion applications/rtkspectralrooster/rtkspectralrooster.ggo
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package "rtkspectralrooster"
purpose "Reconstructs a 3D + material vector volume from a vector projection stack, alternating between conjugate gradient optimization and regularization, including between materials"

option "verbose" v "Verbose execution" flag off
Expand Down
Loading

0 comments on commit cae7d0b

Please sign in to comment.