|
Medical Imaging Interaction Toolkit
2026.06.00
Medical Imaging Interaction Toolkit
|
Base class for data generators that accept image and ROI nodes as vectors. More...
#include <QmitkImageAndRoiDataGeneratorBase.h>


Public Types | |
| using | Superclass = QmitkDataGeneratorBase |
| Superclass typedef. More... | |
| using | ConstNodeVectorType = std::vector< mitk::DataNode::ConstPointer > |
| Vector of const data node pointers. More... | |
| using | NodeVectorType = std::vector< mitk::DataNode::Pointer > |
| Vector of mutable data node pointers. More... | |
Public Types inherited from QmitkDataGeneratorBase | |
| using | JobResultMapType = QmitkDataGenerationJobBase::ResultMapType |
| Alias for the result map type produced by generation jobs. More... | |
Public Slots | |
| void | SetImageNodes (const ConstNodeVectorType &imageNodes) |
| Sets the image nodes for data generation. More... | |
| void | SetImageNodes (const NodeVectorType &imageNodes) |
| Convenience overload accepting mutable node pointers. More... | |
| void | SetROINodes (const ConstNodeVectorType &roiNodes) |
| Sets the ROI nodes for data generation. More... | |
| void | SetROINodes (const NodeVectorType &roiNodes) |
| Convenience overload accepting mutable node pointers. More... | |
Public Slots inherited from QmitkDataGeneratorBase | |
| void | SetDataStorage (mitk::DataStorage *storage) |
| Sets the data storage for monitoring, storing WIP placeholders, and final results. More... | |
| void | SetAutoUpdate (bool autoUpdate) |
| Enables or disables automatic update on data changes. More... | |
Public Member Functions | |
| ConstNodeVectorType | GetImageNodes () const |
| Returns the currently set image nodes. More... | |
| ConstNodeVectorType | GetROINodes () const |
| Returns the currently set ROI nodes. More... | |
Public Member Functions inherited from QmitkDataGeneratorBase | |
| QmitkDataGeneratorBase (const QmitkDataGeneratorBase &other)=delete | |
| QmitkDataGeneratorBase & | operator= (const QmitkDataGeneratorBase &other)=delete |
| virtual | ~QmitkDataGeneratorBase () |
| mitk::DataStorage::Pointer | GetDataStorage () const |
| Returns the data storage used by this generator. More... | |
| bool | GetAutoUpdate () const |
| Returns whether automatic updates are enabled. More... | |
| bool | IsGenerating () const |
| Returns whether data generation jobs are currently running or pending. More... | |
| bool | Generate () const |
| Checks data validity and triggers generation of missing or outdated data. More... | |
| virtual bool | IsValidResultAvailable (const mitk::DataNode *imageNode, const mitk::DataNode *roiNode) const =0 |
| Checks whether a valid final result exists for the given image and ROI. More... | |
Protected Types | |
| using | InputPairVectorType = Superclass::InputPairVectorType |
Protected Types inherited from QmitkDataGeneratorBase | |
| using | InputPairVectorType = std::vector< std::pair< mitk::DataNode::ConstPointer, mitk::DataNode::ConstPointer > > |
| Vector of image/ROI node pairs used as input for generation. More... | |
Protected Member Functions | |
| QmitkImageAndRoiDataGeneratorBase (mitk::DataStorage::Pointer storage, QObject *parent=nullptr) | |
| QmitkImageAndRoiDataGeneratorBase (QObject *parent=nullptr) | |
| bool | ChangedNodeIsRelevant (const mitk::DataNode *changedNode) const override |
| Determines whether a changed data node is relevant and should trigger a regeneration. More... | |
| InputPairVectorType | GetAllImageROICombinations () const override |
| Returns all image/ROI pairs for which data generation is needed. More... | |
| QmitkImageAndRoiDataGeneratorBase (const QmitkImageAndRoiDataGeneratorBase &)=delete | |
| QmitkImageAndRoiDataGeneratorBase & | operator= (const QmitkImageAndRoiDataGeneratorBase &)=delete |
Protected Member Functions inherited from QmitkDataGeneratorBase | |
| QmitkDataGeneratorBase (mitk::DataStorage::Pointer storage, QObject *parent=nullptr) | |
| Constructs a generator with the given data storage. More... | |
| QmitkDataGeneratorBase (QObject *parent=nullptr) | |
| Constructs a generator without an initial data storage. More... | |
| virtual void | IndicateFutureResults (const mitk::DataNode *imageNode, const mitk::DataNode *roiNode) const =0 |
| Adds placeholder nodes and WIP dummy data to the data storage for missing or outdated results. More... | |
| virtual std::pair< QmitkDataGenerationJobBase *, mitk::DataNode::Pointer > | GetNextMissingGenerationJob (const mitk::DataNode *imageNode, const mitk::DataNode *roiNode) const =0 |
| Returns the next generation job and its associated placeholder node. More... | |
| virtual void | RemoveObsoleteDataNodes (const mitk::DataNode *imageNode, const mitk::DataNode *roiNode) const =0 |
| Removes obsolete result nodes for the given image/ROI pair from the data storage. More... | |
| virtual mitk::DataNode::Pointer | PrepareResultForStorage (const std::string &label, mitk::BaseData *result, const QmitkDataGenerationJobBase *job) const =0 |
| Wraps a generation result in a data node suitable for storage. More... | |
| InputPairVectorType | FilterImageROICombinations (InputPairVectorType &&imageROICombinations) const |
| Filters image/ROI pairs to only include those whose nodes exist in the data storage. More... | |
| std::string | GetPairDescription (const InputPairVectorType::value_type &imageAndSeg) const |
| Returns a human-readable description of an image/ROI pair for debug logging. More... | |
| bool | DoGenerate () const |
| Core generation loop that checks validity and launches jobs for all image/ROI pairs. More... | |
| void | EnsureRecheckingAndGeneration () const |
| Ensures generation is (re)started, either immediately or by flagging a restart if already running. More... | |
Protected Attributes | |
| ConstNodeVectorType | m_ImageNodes |
| ConstNodeVectorType | m_ROINodes |
Protected Attributes inherited from QmitkDataGeneratorBase | |
| mitk::WeakPointer< mitk::DataStorage > | m_Storage |
| bool | m_AutoUpdate |
| std::mutex | m_DataMutex |
| itk::TimeStamp | m_GenerationTime |
Additional Inherited Members | |
Signals inherited from QmitkDataGeneratorBase | |
| void | DataGenerationStarted (const mitk::DataNode *imageNode, const mitk::DataNode *roiNode, const QmitkDataGenerationJobBase *job) const |
| Emitted when a data generation job is started for outdated or missing data. More... | |
| void | NewDataAvailable (mitk::DataStorage::SetOfObjects::ConstPointer data) const |
| Emitted when new final result data has been produced and added to the data storage. More... | |
| void | GenerationFinished () const |
| Emitted when all generation jobs have finished and all results are up to date. More... | |
| void | JobError (QString error, const QmitkDataGenerationJobBase *failedJob) const |
| Emitted when a generation job encounters an error. More... | |
Protected Slots inherited from QmitkDataGeneratorBase | |
| void | OnJobError (QString error, const QmitkDataGenerationJobBase *failedJob) const |
| Handles error signals from generation jobs and re-emits JobError. More... | |
| void | OnFinalResultsAvailable (JobResultMapType results, const QmitkDataGenerationJobBase *job) const |
| Handles completed job results, adds them to the data storage, and emits NewDataAvailable. More... | |
Static Protected Member Functions inherited from QmitkDataGeneratorBase | |
| static mitk::DataNode::Pointer | CreateWIPDataNode (mitk::BaseData *dataDummy, const std::string &nodeName) |
| Creates a WIP placeholder data node for future results. More... | |
Base class for data generators that accept image and ROI nodes as vectors.
Extends QmitkDataGeneratorBase to accept separate vectors of image nodes and ROI nodes (as typically provided by node selection widgets). This class computes the Cartesian product of all image/ROI combinations, ensuring that data is generated for every pairing. If no ROI nodes are set, each image is processed without a mask.
Definition at line 30 of file QmitkImageAndRoiDataGeneratorBase.h.
| using QmitkImageAndRoiDataGeneratorBase::ConstNodeVectorType = std::vector<mitk::DataNode::ConstPointer> |
Vector of const data node pointers.
Definition at line 37 of file QmitkImageAndRoiDataGeneratorBase.h.
|
protected |
Definition at line 91 of file QmitkImageAndRoiDataGeneratorBase.h.
| using QmitkImageAndRoiDataGeneratorBase::NodeVectorType = std::vector<mitk::DataNode::Pointer> |
Vector of mutable data node pointers.
Definition at line 39 of file QmitkImageAndRoiDataGeneratorBase.h.
Superclass typedef.
Definition at line 34 of file QmitkImageAndRoiDataGeneratorBase.h.
|
inlineprotected |
Definition at line 88 of file QmitkImageAndRoiDataGeneratorBase.h.
|
inlineprotected |
Definition at line 89 of file QmitkImageAndRoiDataGeneratorBase.h.
|
protecteddelete |
|
overrideprotectedvirtual |
Determines whether a changed data node is relevant and should trigger a regeneration.
| [in] | changedNode | The node that was changed in the data storage. |
Implements QmitkDataGeneratorBase.
Reimplemented in QmitkImageStatisticsDataGenerator.
|
overrideprotectedvirtual |
Returns all image/ROI pairs for which data generation is needed.
The ROI element of a pair may be nullptr if no ROI is required.
Implements QmitkDataGeneratorBase.
| ConstNodeVectorType QmitkImageAndRoiDataGeneratorBase::GetImageNodes | ( | ) | const |
Returns the currently set image nodes.
| ConstNodeVectorType QmitkImageAndRoiDataGeneratorBase::GetROINodes | ( | ) | const |
Returns the currently set ROI nodes.
|
protecteddelete |
|
slot |
Sets the image nodes for data generation.
If auto-update is enabled and the nodes differ from the current set, generation is automatically re-triggered.
| [in] | imageNodes | The vector of image data nodes. |
|
slot |
Convenience overload accepting mutable node pointers.
| [in] | imageNodes | The vector of image data nodes. |
|
slot |
Sets the ROI nodes for data generation.
If auto-update is enabled and the nodes differ from the current set, generation is automatically re-triggered.
| [in] | roiNodes | The vector of ROI data nodes. |
|
slot |
Convenience overload accepting mutable node pointers.
| [in] | roiNodes | The vector of ROI data nodes. |
|
protected |
Definition at line 96 of file QmitkImageAndRoiDataGeneratorBase.h.
|
protected |
Definition at line 97 of file QmitkImageAndRoiDataGeneratorBase.h.