ConeBeamReconstructionSettings
Settings for cone beam reconstruction.
Import
import ScriptingApi as api
# Access the class
# ConeBeamReconstructionSettings is available via api.ConeBeamReconstructionSettings
Properties
invert_x
Mirror the input projections horizontally (flip along the X axis).
Type: bool
invert_y
Mirror the input projections vertically (flip along the Y axis).
Type: bool
invert_z
Reverse the order of input projections (invert the Z direction). Rarely used.
Type: bool
invert_intensity
Invert the intensity values of the input projections. Use if projections appear as negative images.
Type: bool
source_to_detector_distance
Distance from the X-ray source to the detector plane (in millimeters). This affects the magnification and geometry of the scan.
Type: float
source_to_isocenter_distance
Distance from the X-ray source to the object isocenter (in millimeters). This is the radius of the scan trajectory.
Type: float
detector_pixel_size_x
Physical size of a detector pixel along the X (horizontal) axis (in millimeters).
Type: float
detector_pixel_size_y
Physical size of a detector pixel along the Y (vertical) axis (in millimeters).
Type: float
xray_scan_start_angle
The starting angle of the X-ray scan (in degrees). Defines the initial gantry position.
Type: float
xray_scan_total_angle
Total angular range covered by the scan (in degrees). 360° for a full scan, less for a short scan.
Type: float
is_clockwise
Scan rotation direction.
Type: bool
projection_offset_x
Horizontal offset of the detector center relative to the rotation axis (in millimeters). Use to correct for detector misalignment.
Type: float
projection_offset_y
Vertical offset of the detector center relative to the rotation axis (in millimeters). Use to correct for detector misalignment.
Type: float
source_offset_x
Horizontal offset of the X-ray source relative to the rotation axis (in millimeters).
Type: float
source_offset_y
Vertical offset of the X-ray source relative to the rotation axis (in millimeters).
Type: float
out_of_plane_angle
Rotation of the detector around the X axis (out-of-plane tilt, in degrees). Use to correct for detector tilt.
Type: float
in_plane_angle
Rotation of the detector around the Z axis (in-plane tilt, in degrees). Use to correct for detector tilt.
Type: float
enable_displaced_detector
Enable special handling for off-centered (displaced) detector panels. Useful for short scans or non-standard geometries.
Type: bool
angular_gap_threshold
Angular gap threshold (in degrees) for detecting short scans. Above this value, Parker short scan weighting is applied.
Type: float
enable_auto_detector_offset_x
Automatically estimate the horizontal detector offset (center-of-rotation correction) from the scan data by registering opposing projections (180 degrees apart). Requires a scan arc of at least 180 degrees. When enabled and the estimation succeeds, the estimated value replaces projectionOffsetX; on failure the manual value is kept. Enabled by default: an uncorrected rotation axis blurs every voxel onto a ring in the axial plane, which reverses the contrast of small features. Disable it only when projectionOffsetX is known from a scanner calibration.
Type: bool
projection_skip
Skip projections to reduce computation time. 0 uses all, 1 uses every 2nd, 2 uses every 3rd, etc. Note: Increasing this reduces computation and data size but also lowers angular sampling and may degrade reconstruction quality.
Type: int
projection_smoothing_level
Projection smoothing level. Low/Medium provide increasing noise reduction; higher settings reduce fine details. Choose Low or Medium for a balanced result. Use api.CBR_ProjectionSmoothingLevel.Low, api.CBR_ProjectionSmoothingLevel.Medium, api.CBR_ProjectionSmoothingLevel.High
Type: CBR_ProjectionSmoothingLevel
intensity_normalization_mode
Intensity normalization mode. Use api.CBR_IntensityNormalizationMode.AirPeak, api.CBR_IntensityNormalizationMode.Maximum, api.CBR_IntensityNormalizationMode.Fixed, api.CBR_IntensityNormalizationMode.Off
Type: CBR_IntensityNormalizationMode
speckle_removal_mode
Speckle removal mode. Use to remove isolated hot/dead pixels while preserving overall sharpness. Use api.CBR_SpeckleRemovalMode.MultiPixel, api.CBR_SpeckleRemovalMode.SinglePixel, api.CBR_SpeckleRemovalMode.Off
Type: CBR_SpeckleRemovalMode
ring_artifact_reduction_level
Ring artifact reduction level. Higher levels increase stripe suppression but may slightly smooth features; start with Low or Medium. Use api.CBR_RingArtifactReductionLevel.Off, api.CBR_RingArtifactReductionLevel.Low, api.CBR_RingArtifactReductionLevel.Medium, api.CBR_RingArtifactReductionLevel.High
Type: CBR_RingArtifactReductionLevel
beam_hardening_preset
Beam hardening correction preset. Presets increase correction strength from mild to strong. Use api.CBR_BeamHardeningPreset.Off, api.CBR_BeamHardeningPreset.Low, api.CBR_BeamHardeningPreset.Medium, api.CBR_BeamHardeningPreset.High
Type: CBR_BeamHardeningPreset
enable_intensity_offset_correction
Enable intensity offset/bias correction. When True, subtracts a constant percentage (intensityOffsetBias) from projection intensities when no valid dark/bright calibration is applied. A valid dark field replaces this manual correction so the detector offset is not subtracted twice. Higher values may produce negative intensities and cause streak artifacts; increase gradually and inspect results.
Type: bool
intensity_offset_bias
Intensity offset bias value to subtract from projections (percentage of maximum intensity). Range: 0.0–100.0 (%). Typical: 0.5–5.0 (%). Use small values to avoid artifacts.
Type: float
enable_logarithm_conversion
Convert raw detector intensities to attenuation values using logarithmic transformation. Enable when input projections are raw transmission/intensity measurements (I). A successfully applied dark/bright calibration enables this conversion automatically because flat-field correction produces transmission data.
Type: bool
enable_scatter_correction
Enable scatter radiation correction. Apply when working with raw intensities to reduce scatter-induced background; requires tuning of related parameters.
Type: bool
scatter_air_threshold
Detector value threshold for identifying air regions (for scatter correction). Typical values for 16-bit detectors: 30000–40000; tune according to detector and acquisition.
Type: float
scatter_to_primary_ratio
Estimated ratio of scatter to primary radiation. Typical values 0.02–0.15.
Type: float
dark_field_image_file_name
Path to dark field calibration image for flat-field correction. Set it only for raw, uncorrected projections: when a scanner already applies the detector calibration while exporting, correcting such projections again causes shading and ring artifacts. May cover the full detector panel even when the projections use a smaller read-out window. Leave empty to disable flat-field correction.
Type: str
bright_field_image_file_name
Path to bright field calibration image for flat-field correction. Both this and the dark field path must be set for the correction to run. Files holding several gain maps for different exposure settings are supported when the projections contain enough free beam to identify the matching map. Leave empty to disable flat-field correction.
Type: str
truncation_correction
Fraction of the detector width feathered for truncation correction (0.0 to 1.0). 0 disables correction; larger values correct a wider region when the object extends beyond the detector.
Type: float
reconstruction_filter
Reconstruction (ramp apodization) filter. Shepp-Logan, Hann, and Hamming apply their window even when filterCutFrequency is 0; Ram-Lak with 0 uses the pure ramp when the legacy Hann frequency is also 0. Use api.CBR_ReconstructionFilter.RamLak, api.CBR_ReconstructionFilter.SheppLogan, api.CBR_ReconstructionFilter.Hann, api.CBR_ReconstructionFilter.Hamming
Type: CBR_ReructionFilter
filter_cut_frequency
Cut frequency of the selected reconstruction filter (0.0 to 1.0). Higher values allow more high-frequency detail, lower values increase smoothing. 0 applies the selected window across the full frequency band without an additional band limit; with Ram-Lak, it uses the pure ramp when the legacy Hann frequency is also 0.
Type: float
hann_cut_frequency
Hann cut frequency (0.0 to 1.0). Higher values allow more high-frequency detail, lower values increase smoothing. Legacy parameter: prefer reconstructionFilter = api.CBR_ReconstructionFilter.Hann together with filterCutFrequency. Only used when reconstructionFilter is RamLak and filterCutFrequency is 0.
Type: float
auto_invert_intensity
Automatically invert the intensity of the reconstructed image. Useful if the reconstructed object appears with reversed contrast.
Type: bool
auto_crop
Automatically crop the reconstructed image to the object. Removes empty background for a tighter result.
Type: bool
crop_margin
Margin (in pixels) to add around the cropped object. Only used if autoCrop is enabled.
Type: int
enable_low_clamping
Enable low intensity clamping (clamp values below threshold).
Type: bool
low_clamping_type
Low clamping type. Use api.CBR_ClampingType.Absolute, api.CBR_ClampingType.Percental
Type: CBR_ClampingType
low_clamping_value
Low clamping threshold value. In Absolute mode this is the intensity cutoff; in Percental mode this is the percentage of the darkest voxels to clamp (e.g. 0.001 raises the darkest 0.001% of voxels).
Type: float
enable_high_clamping
Enable high intensity clamping (clamp values above threshold).
Type: bool
high_clamping_type
High clamping type. Use api.CBR_ClampingType.Absolute, api.CBR_ClampingType.Percental
Type: CBR_ClampingType
high_clamping_value
High clamping threshold value. In Absolute mode this is the intensity cutoff; in Percental mode this is the percentage of the brightest voxels to clamp (e.g. 0.001 clamps the brightest 0.001% of voxels).
Type: float
noise_reduction_mode
Noise reduction filter applied to the reconstructed volume. Use api.CBR_NoiseReductionMode.Off, api.CBR_NoiseReductionMode.Median, api.CBR_NoiseReductionMode.Gaussian, api.CBR_NoiseReductionMode.EdgePreserving
Type: CBR_NoiseReductionMode
noise_reduction_level
Strength of the noise reduction filter. Use api.CBR_NoiseReductionLevel.Low, api.CBR_NoiseReductionLevel.Medium, api.CBR_NoiseReductionLevel.High
Type: CBR_NoiseReductionLevel
enable_histogram_windowing
Clip extreme outlier intensities (percentile-based) and stretch the remaining histogram over the full output range for a better contrast distribution. Disable to preserve the unstretched gray value relations.
Type: bool
histogram_windowing_margin_percent
Margin added on both sides of the contrast window, as a percentage of the window width (0-50). Prevents the histogram windowing clip from cutting tightly at the percentile bounds. Typical values: 2-10.
Type: float
enable_sharpening
Enable Unsharp Mask (USM) sharpening on the reconstructed volume. Sharpening can enhance edge contrast and local detail but may amplify noise.
Type: bool
sharpening_iterations
Number of times the sharpening operation is applied. More iterations increase sharpening strength; typical values: 1-5.
Type: int
sharpening_radius
Radius (in pixels) of the local neighborhood used for sharpening. Larger radius affects broader features; typical values: 1-5.
Type: int
sharpening_contrast
Sharpening amount expressed as a percentage. Typical values: 10-200.
Type: int