Commit a683d4d1 authored by Pierre Paleo's avatar Pierre Paleo
Browse files

Downgrade links to APIdoc: linking to rst APIdoc header is not supported anymore

parent c2356b92
......@@ -16,7 +16,7 @@ Usually, several "flats" images are acquired. Nabu automatically determines whic
Configuration file: section `[preproc]`: `flatfield_enabled = 1`.
API: [FlatField](apidoc/nabu.preproc.ccd.rst#nabu.preproc.ccd.FlatField) and [CudaFlatField](apidoc/nabu.preproc.ccd_cuda.rst#nabu.preproc.ccd_cuda.CudaFlatField)
API: [FlatField](apidoc/nabu.preproc.ccd) and [CudaFlatField](apidoc/nabu.preproc.ccd_cuda)
### CCD hotspots removal
......@@ -25,7 +25,7 @@ Some pixels might have unusually high values. These are called "hotspots". A sim
Configuration file: section `[preproc]`: `ccd_filter_enabled = 1` and `ccd_filter_threshold = 0.04`.
API: [CCDCorrection](apidoc/nabu.preproc.ccd.rst#nabu.preproc.ccd.CCDCorrection) and [CudaCCDCorrection](apidoc/nabu.preproc.ccd_cuda.rst#nabu.preproc.ccd_cuda.CudaCCDCorrection)
API: [CCDCorrection](apidoc/nabu.preproc.ccd) and [CudaCCDCorrection](apidoc/nabu.preproc.ccd_cuda)
### Double flat-field
......@@ -42,7 +42,9 @@ This method assumes that when averaging all the radios, the genuine feature will
Configuration file key: section `[preproc]`: `double_flatfield_enabled = 1`.
API: [DoubleFlatField](apidoc/nabu.preproc.double_flatfield.rst#nabu.preproc.double_flatfield.DoubleFlatField) and [CudaDoubleFlatField](apidoc/nabu.preproc.double_flatfield_cuda.rst#nabu.preproc.double_flatfield_cuda.CudaDoubleFlatField)
API: [DoubleFlatField](apidoc/nabu.preproc.double_flatfield) and [CudaDoubleFlatField](apidoc/nabu.preproc.double_flatfield_cuda)
You can pre-compute the double flatfield and provide it to the nabu configuration file, in order to avoid recomputing it each time. To this end, a CLI tool `nabu-double-flatfield` is available. Once you generated a double flat-field file, eg. `dff.h5`, you can provide `processes_file = dff.h5` in `[preproc]`.
### Logarithm
......@@ -54,7 +56,25 @@ Numerical issues might occur when performing this step. For this reason, the pro
Configuration file: section `[preproc]`: `take_logarithm = 1`, `log_min_clip = 1e-6`, `log_max_clip = 10.0`.
API: [CCDProcessing.Log](apidoc/nabu.preproc.ccd.rst#nabu.preproc.ccd.Log) and [CudaLog](apidoc/nabu.preproc.ccd_cuda.rst#nabu.preproc.ccd_cuda.CudaLog)
API: [CCDProcessing.Log](apidoc/nabu.preproc.ccd) and [CudaLog](apidoc/nabu.preproc.ccd_cuda)
### Projections rotation and detector tilt auto-detection
Each rotation can be rotated by a user-defined angle. This can be useful to correct the effects of a detector tilt, or rotation axis tilt in some cases.
A command-line interface tool `nabu-rotate` is also available.
Configuration file: `[preproc]`: `rotate_projections` (value in degrees).
API: [Rotation](apidoc/nabu.misc.rotation) and [CudaRotation](apidoc/nabu.misc.rotation_cuda)
Nabu can also attempt at estimating the detector tilt, if any. If a tilt is detected, then the projection images will be rotated by the found angle value.
Configuration file: `[preproc]`: `tilt_correction` and `autotilt_options`.
Parameter `tilt_correction` can be the following:
- A scalar value: tilt correction angle in degrees. It is equivalent to `rotate_projections` parameter.
- `1d-correlation`: auto-detect tilt with the 1D correlation method (fastest, but works best for small tilts)
- `fft-polar`: auto-detect tilt with polar FFT method (slower, but works well on all ranges of tilts)
### Sinogram normalization
......@@ -65,7 +85,26 @@ Mind that you probably lose quantativeness by using this additional normalizatio
Configuration file: `[preproc]` : `sino_normalization = chebyshev`.
API: [SinoNormalization](apidoc/nabu.preproc.sinogram.rst#nabu.preproc.sinogram.SinoNormalization)
API: [SinoNormalization](apidoc/nabu.preproc.sinogram)
### Sinogram-based rings artefacts removal
A new rings artefacts removal technique has been added. It is the implementation of Munch Et Al. Fourier-Wavelets destripping method.
Configuration file: `[preproc]`: `sino_rings_correction` and `sino_rings_options`.
API: [MunchDeringer](apidoc/nabu.preproc.rings) and [CudaMunchDeringer](apidoc/nabu.preproc.rings_cuda)
### Flats distortion correction
A flats distortion estimation/correction is available. If activated, each radio is correlated with its corresponding flat, in order to determine and correct the flat distortion.
```warning:: This is currently quite slow (many correlations), and only supported by the "full radios pipeline"
```
Configuration file: `[preproc]`: `flat_distortion_params` and `flat_distortion_correction_enabled`
API: [estimate_flat_distortion](apidoc/nabu.estimation.distortion)
## Phase retrieval
......@@ -85,7 +124,18 @@ It depends on the δ/β ratio (assumed to be constant in all the image) and the
Configuration file: section `[phase]`: `method = Paganin`, `delta_beta = 1000.0`
API : [PaganinPhaseRetrieval](apidoc/nabu.preproc.phase.rst#nabu.preproc.phase.PaganinPhaseRetrieval) and [CudaPaganinPhaseRetrieval](apidoc/nabu.preproc.phase_cuda.rst#nabu.preproc.phase_cuda.CudaPaganinPhaseRetrieval)
API : [PaganinPhaseRetrieval](apidoc/nabu.preproc.phase) and [CudaPaganinPhaseRetrieval](apidoc/nabu.preproc.phase_cuda)
### Contrast Transfer Function (CTF) phase retrieval
A single distance CTF retrieval method is also available.
``` warning:: Using this phase retrieval method triggrers the use of a new pipeline, which is less tested that the ones already available. Also, this new pipeline is currently only available with the CPU backend, meaning the overall process will be relatively slor.
```
Configuration file: `[phase]`: `method = CTF`, `delta_beta`, `ctf_geometry`, `ctf_translations_file` and `ctf_advanced_params`.
API: [CTFPhaseRetrieval](apidoc/nabu.preproc.ctf)
### Unsharp Mask
......@@ -114,7 +164,7 @@ This is the Filtered Back Projection reconstruction method.
### Reconstructor
This utility can only be used from the API ([Reconstructor](apidoc/nabu.reconstruction.reconstructor.rst#nabu.reconstruction.reconstructor.Reconstructor) and [CudaReconstructor](apidoc/nabu.reconstruction.reconstructor_cuda.rst#nabu.reconstruction.reconstructor_cuda.CudaReconstructor)).
This utility can only be used from the API ([Reconstructor](apidoc/nabu.reconstruction.reconstructor) and [CudaReconstructor](apidoc/nabu.reconstruction.reconstructor_cuda)).
The purpose of this class is to quickly reconstruct slices over the three main axes, possibly in a Region Of Interest. For example: "I want to reconstruct 50 vertical slices along the Y axis", or "I want to reconstruct 10 vertical slices along the X axis, with each slice in the subregion (1000-1200, 2000-2200)".
......@@ -128,7 +178,7 @@ Nabu can compute the histogram of the reconstucted (sub-) volume. As the volume
Configuration file: section `[postproc]`: `output_histogram = 1`, `histogram_bins = 1000000`.
API : [PartialHistogram](apidoc/nabu.misc.histogram.rst#nabu.misc.histogram.PartialHistogram) and [VolumeHistogram](apidoc/nabu.misc.histogram.rst#nabu.misc.histogram.VolumeHistogram)
API : [PartialHistogram](apidoc/nabu.misc.histogram) and [VolumeHistogram](apidoc/nabu.misc.histogram)
## File formats
......@@ -146,6 +196,10 @@ Mind that tiff support currently has the following limitations:
- Data is saved as `float32` data type, no normalization
- No metadata (configuration used to obtain the reconstruction, date, version,...)
### EDF
Reconstruction can be saved as tiff files by specifying `file_format = edf` in the configuration `[output]` section.
### Jpeg2000
Reconstruction can be saved as jpeg2000 files by specifying `file_format = jpeg2000` in the configuration `[output]` section.
......@@ -155,79 +209,16 @@ Mind that jpeg2000 support currently has the following limitations:
- No metadata (configuration used to obtain the reconstruction, date, version,...)
## Parameters estimation
### Center of Rotation
Nabu provides a method to find the half-shift between two images. The center of axial vertical rotation is obtained when the fist image is a radiography at the rotation angle 0 and the second image is given by the radiography at the rotation angle 180 after flipping the image horizontally. The rotation axis position is the center of the image plus the found shift.
## Save/resume from processing steps
Configuration file: section `[reconstruction]`, key `rotation_axis_position`. Values can be:
It is possible to save arbitrary processing steps, and to resume the processing pipeline from a saved step. It speeds up the process of "reconstructing - editing configuration - reconstructing - etc".
In the section `[pipeline]`, there are two corresponding options `save_steps` and `resume_from_step`.
For example, to set a check point to the "sinogram" generation, set `save_steps = sinogram`.
- Empty (default): the CoR is set to the middle of the detector: `(detector_width - 1)/2.0`
- A number (known CoR)
- `centered`: a fast and simple auto-CoR method. It only works when the CoR is not far from the middle of the detector. It does not work for half-tomography.
- `global`: a slow but robust auto-CoR.
- `sliding-window`: semi-automatically find the CoR with a sliding window. You have to specify on which side the CoR is (left, center, right).
- `growing-window` : automatically find the CoR with a sliding-and-growing window. You can tune the option with the parameter 'cor_options'.
Both `save_steps` and `resume_from_step` can be specified at the same time. If the file is not found, then all the processing is done in normal mode, and the steps are saved to the file. Otherwise, the pipeline resumes from the step. The file where data is dumped can be specified with the parameter `steps_file`.
API: [CenterOfRotation](apidoc/nabu.preproc.alignment.rst#nabu.preproc.alignment.CenterOfRotation)
#### Advanced parameters in configuration file
Advanced parameters can be provided in the configuration file, by the means of key `cor_options`. The parameters are separated by commas and passed as 'name=value'. For example:
```ini
cor_options = low_pass=1; high_pass=20
```
Mind the semicolon separator (;).
These advanced parameters corrrespond to the arguments of function [find_shift](apidoc/nabu.preproc.alignment.rst#nabu.preproc.alignment.CenterOfRotation.find_shift).
### Tilt angle
Nabu provides methods for detecting the detector tilt angle, or, equivalently, the rotation axis tilt in the plane parallel to the detector plane. When such a tilt occurs, the columns of the detector are not parallel to the rotation axis.
Configuration file: section `[preproc]`, key `tilt_correction`. Values can be:
- Empty (default): no tilt detection/correction.
- A scalar value: user-provided tilt angle in degrees.
- `1d-correlation`: auto-detect tilt with the 1D correlation method (fastest, but works best for small tilts)
- `fft-polar`: auto-detect tilt with polar FFT method (slower, but works well on all ranges of tilts)
When a tilt is detected or provided by the user, each projection image is rotated to correct for this angle.
API: [CameraTilt](apidoc/nabu.preproc.alignment.rst#nabu.preproc.alignment.CameraTilt)
#### Advanced parameters in configuration file
Advanced parameters can be provided in the configuration file, by the means of key `autotilt_options`. The parameters are separated by commas and passed as 'name=value'. For example:
```ini
autotilt_options = median_filt_shape(3,3); threshold=0.5
```
Mind the semicolon separator (;).
These advanced parameters corrrespond to the arguments of function [compute_angle](apidoc/nabu.preproc.alignment.rst#nabu.preproc.alignment.CameraTilt.compute_angle).
The parameter `threshold` indicates the value, in pixels, below which the effect of tilt is ignored. Given a tilt angle `a`, the maximum effect on a detector of width `N` is `N/2 * sin(a)`. If `N/2 * sin(a) < threshold`, then the tilt is considered too small for being corrected and is subsequently ignored. For example, on a detector of width `2560` pixels, a tilt of `0.05` degree induces a shift of 1.12 pixel at most. The default threshold is 0.25 pixel.
### Detector Translation Along the Beam
When moving the detector along the longitudinal translation axis the beam shape image, recorded on the detector, can be seen moving if the translation is not parallel to the beam. The occurring shifts can be found, and the beam tilt respect to the translation axis ca be inferred.
The vertical and horizontal shifts are returned in pixels-per-unit-translation.
To compute the vertical and horizontal tilt angles from the obtained `shift_pix`:
```python
tilt_deg = np.rad2deg(np.arctan(shift_pix_per_unit_translation * pixel_size))
```
where `pixel_size` and and the input parameter `img_pos` have to be
expressed in the same units.
API: [DetectorTranslationAlongBeam](apidoc/nabu.preproc.alignment.rst#nabu.preproc.alignment.DetectorTranslationAlongBeam)
## Parameters estimation
Nabu provides some parameter estimation tools. Please see the [dedicated page](apidoc/nabu.estimation.md).
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment