darsia.TracerAnalysis#
- class TracerAnalysis(baseline, config, update_setup=False)[source]#
Bases:
ABC,ConcentrationAnalysisBaseManager wiring a baseline plus config into a tracer-concentration pipeline.
Subclass and implement
define_tracer_analysisto specify the signal-to-concentration conversion.Constructor for TracerAnalysis.
- Parameters:
Methods
batch_analysis(images, **kwargs)Standard batch analysis.
The main purpose of this routine is to define self.tracer_analysis, which lies at the heart of this class.
determine_tracer([return_volume])Extract tracer from currently loaded image, based on a reference image.
load_and_process_image(path)Load image for further analysis.
single_image_analysis(img, **kwargs)Standard workflow to analyze CO2 phases.
Attributes
configConfig dict from file.
widthPhysical width of image.
heightPhysical height of image.
originPhysical origin of origin voxel.
processed_baseline_imagesList of corrected baseline images.
drift_correctionDrift correction wrt.
deformation_correctionLocal deformation correction wrt.
color_correctionColor correction based on reference colors.
translation_correctionTranslation correction based on fixed absolute translation.
curvature_correctionCurvature correction.
uncorrected_baseBaseline image stored as physical image but without corrections.
drift_corrected_baseBaseline image corrected for drift only.
- abstractmethod define_tracer_analysis()[source]#
The main purpose of this routine is to define self.tracer_analysis, which lies at the heart of this class. It is supposed to determine tracers from image differences. Since the choice of a suitable color channel etc. may heavily depend on the situation, this method is abstract and has to be overwritten in each specific situation.
- determine_tracer(return_volume=False)[source]#
Extract tracer from currently loaded image, based on a reference image.
- Parameters:
- return_volumebool
Flag controlling whether the volume of the fluid in the porous geometry is returned.
- Returns:
darsia.ImageImage array of spatial concentration map.
float,optionalOccupied volume by the fluid in porous geometry.