diff --git a/Modules/Segmentation/Interactions/mitkMonaiLabelTool.cpp b/Modules/Segmentation/Interactions/mitkMonaiLabelTool.cpp new file mode 100644 index 0000000000..564c819d8f --- /dev/null +++ b/Modules/Segmentation/Interactions/mitkMonaiLabelTool.cpp @@ -0,0 +1,292 @@ +/*============================================================================ + +The Medical Imaging Interaction Toolkit (MITK) + +Copyright (c) German Cancer Research Center (DKFZ) +All rights reserved. + +Use of this source code is governed by a 3-clause BSD license that can be +found in the LICENSE file. + +============================================================================*/ + +// MITK +#include "mitkMonaiLabelTool.h" + +// us +#include "mitkIOUtil.h" +#include "mitkRESTUtil.h" +#include +#include +#include +#include +#include +#include +#include +#include +#include "cpprest/asyncrt_utils.h" +#include "cpprest/http_client.h" + +namespace mitk +{ + MITK_TOOL_MACRO(MITKSEGMENTATION_EXPORT, MonaiLabelTool, "MonaiLabel"); +} + +mitk::MonaiLabelTool::MonaiLabelTool() +{ + InitializeRESTManager(); +} + +void mitk::MonaiLabelTool::Activated() +{ + Superclass::Activated(); + this->SetLabelTransferMode(LabelTransferMode::AllLabels); +} + +const char **mitk::MonaiLabelTool::GetXPM() const +{ + return nullptr; +} + +us::ModuleResource mitk::MonaiLabelTool::GetIconResource() const +{ + us::Module *module = us::GetModuleContext()->GetModule(); + us::ModuleResource resource = module->GetResource("Otsu_48x48.png"); + return resource; +} + +const char *mitk::MonaiLabelTool::GetName() const +{ + return "MonaiLabel"; +} + +void mitk::MonaiLabelTool::DoUpdatePreview(const Image *inputAtTimeStep, + const Image * /*oldSegAtTimeStep*/, + LabelSetImage *previewImage, + TimeStepType timeStep) +{ + std::string outputImagePath = "Z:/dataset/Task05_Prostate/labelsTr/prostate_00.nii.gz"; + try + { + Image::Pointer outputImage = IOUtil::Load(outputImagePath); + previewImage->InitializeByLabeledImage(outputImage); + previewImage->SetGeometry(inputAtTimeStep->GetGeometry()); + } + catch (const mitk::Exception &e) + { + /* + Can't throw mitk exception to the caller. Refer: T28691 + */ + MITK_ERROR << e.GetDescription(); + return; + } +} + +void mitk::MonaiLabelTool::InitializeRESTManager() // Don't call from constructor --ashis +{ + auto serviceRef = us::GetModuleContext()->GetServiceReference(); + if (serviceRef) + { + m_RESTManager = us::GetModuleContext()->GetService(serviceRef); + } +} + +void mitk::MonaiLabelTool::GetOverallInfo(std::string url) +{ + if (m_RESTManager != nullptr) + { + PostSegmentationRequest(); + std::string jsonString; + bool fetched = false; + web::json::value result; + m_RESTManager->SendRequest(mitk::RESTUtil::convertToTString(url)) + .then( + [&](pplx::task resultTask) /*It is important to use task-based continuation*/ + { + try + { + result = resultTask.get(); + fetched = true; + } + catch (const mitk::Exception &exception) + { + MITK_ERROR << exception.what(); + return; + } + }) + .wait(); + if (fetched) + { + m_Parameters = DataMapper(result); + } + } +} + +std::unique_ptr mitk::MonaiLabelTool::DataMapper(web::json::value &result) +{ + auto object = std::make_unique(); + utility::string_t stringT = result.to_string(); + std::string jsonString(stringT.begin(), stringT.end()); + auto jsonObj = nlohmann::json::parse(jsonString); + if (jsonObj.is_discarded() || !jsonObj.is_object()) + { + MITK_ERROR << "Could not parse \"" << jsonString << "\" as JSON object!"; + } + //MITK_INFO << jsonString; + MITK_INFO << "ashis inside mapper " << jsonObj["name"].get(); // remove + object->name = jsonObj["name"].get(); + object->description = jsonObj["description"].get(); + object->labels = jsonObj["labels"].get>(); + + auto modelJsonMap = jsonObj["models"].get>(); + for (const auto &[_name, _jsonObj] : modelJsonMap) + { + if (_jsonObj.is_discarded() || !_jsonObj.is_object()) + { + MITK_ERROR << "Could not parse JSON object."; + } + MonaiModelInfo modelInfo; + modelInfo.name = _name; + try + { + auto labels = _jsonObj["labels"].get>(); + modelInfo.labels = labels; + } + catch (const std::exception &) + { + auto labels = _jsonObj["labels"].get>(); + for (const auto &label : labels) + { + modelInfo.labels[label] = -1; // Hardcode -1 as label id + } + } + modelInfo.type = _jsonObj["type"].get(); + modelInfo.dimension = _jsonObj["dimension"].get(); + modelInfo.description = _jsonObj["description"].get(); + + object->models.push_back(modelInfo); + } + return object; +} + + +std::vector mitk::MonaiLabelTool::GetAutoSegmentationModels() +{ + std::vector autoModels; + if (nullptr != m_Parameters) + { + for (mitk::MonaiModelInfo &model : m_Parameters->models) + { + if (m_AUTO_SEG_TYPE_NAME.find(model.type) != m_AUTO_SEG_TYPE_NAME.end()) + { + autoModels.push_back(model); + } + } + } + return autoModels; +} + +std::vector mitk::MonaiLabelTool::GetInteractiveSegmentationModels() +{ + std::vector interactiveModels; + if (nullptr != m_Parameters) + { + for (mitk::MonaiModelInfo &model : m_Parameters->models) + { + if (m_INTERACTIVE_SEG_TYPE_NAME.find(model.type) != m_INTERACTIVE_SEG_TYPE_NAME.end()) + { + interactiveModels.push_back(model); + } + } + } + return interactiveModels; +} + +std::vector mitk::MonaiLabelTool::GetScribbleSegmentationModels() +{ + std::vector scribbleModels; + if (nullptr != m_Parameters) + { + for (mitk::MonaiModelInfo &model : m_Parameters->models) + { + if (m_SCRIBBLE_SEG_TYPE_NAME.find(model.type) != m_SCRIBBLE_SEG_TYPE_NAME.end()) + { + scribbleModels.push_back(model); + } + } + } + return scribbleModels; +} + +void mitk::MonaiLabelTool::PostSegmentationRequest() // return LabelSetImage ?? +{ + // web::json::value result; + // web::json::value data; + + std::string url = "http://localhost:8000/infer/deepedit_seg"; // + m_ModelName; + std::string filePath = "//vmware-host//Shared Folders//Downloads//spleen_58.nii.gz"; + std::ifstream input(filePath, std::ios::binary); + if (!input) + { + MITK_WARN << "could not read file to POST"; + } + + std::vector result; + std::vector buffer; + + // Stop eating new lines in binary mode!!! + input.unsetf(std::ios::skipws); + + input.seekg(0, std::ios::end); + const std::streampos fileSize = input.tellg(); + input.seekg(0, std::ios::beg); + + MITK_INFO << fileSize << " bytes will be sent."; + buffer.reserve(fileSize); // file size + std::copy( + std::istream_iterator(input), std::istream_iterator(), std::back_inserter(buffer)); + + + mitk::RESTUtil::ParamMap headers; + headers.insert(mitk::RESTUtil::ParamMap::value_type(U("accept"), U("application/json"))); + // headers.insert(mitk::RESTUtil::ParamMap::value_type(U("Accept-Encoding"), U("gzip, deflate"))); + headers.insert(mitk::RESTUtil::ParamMap::value_type( + // U("Content-Type"), U("multipart/related; type=\"application/dicom\"; boundary=boundary"))); + U("Content-Type"), U("multipart/form-data; boundary=boundary"))); + + // in future more than one file should also be supported.. + std::string head = ""; + head += "\r\n--boundary"; + head += "\r\nContent-Disposition: form-data; name=\"params\"\r\n\r\n{}"; + head += "\r\n--boundary"; + head += "\r\nContent-Disposition: form-data; name=\"file\"; filename=\"spleen_58.nii.gz\"\r\n\r\n"; + + std::vector bodyVector(head.begin(), head.end()); + + std::string tail = ""; + tail += "\r\n--boundary"; + tail += "\r\nContent-Disposition: form-data; name=\"label\"\r\n\r\n"; + tail += "\r\n--boundary--\r\n"; + + result.insert(result.end(), bodyVector.begin(), bodyVector.end()); + result.insert(result.end(), buffer.begin(), buffer.end()); + result.insert(result.end(), tail.begin(), tail.end()); + + try + { + m_RESTManager + ->SendBinaryRequest(mitk::RESTUtil::convertToTString(url), mitk::IRESTManager::RequestType::Post, &result, headers) + .then( + [=](pplx::task result) /* (web::json::value result)*/ + { + MITK_INFO << "after send"; + //MITK_INFO << mitk::RESTUtil::convertToUtf8(result.serialize()); + //result.is_null(); + }) + .wait(); + } + catch (std::exception &e) + { + MITK_WARN << e.what(); + } +} \ No newline at end of file diff --git a/Modules/Segmentation/Interactions/mitkMonaiLabelTool.h b/Modules/Segmentation/Interactions/mitkMonaiLabelTool.h new file mode 100644 index 0000000000..b6fefa9e9c --- /dev/null +++ b/Modules/Segmentation/Interactions/mitkMonaiLabelTool.h @@ -0,0 +1,98 @@ +/*============================================================================ + +The Medical Imaging Interaction Toolkit (MITK) + +Copyright (c) German Cancer Research Center (DKFZ) +All rights reserved. + +Use of this source code is governed by a 3-clause BSD license that can be +found in the LICENSE file. + +============================================================================*/ +#ifndef MITKMONAILABELTOOL_H +#define MITKMONAILABELTOOL_H + +#include "mitkSegWithPreviewTool.h" +#include +#include +#include +#include +#include + +namespace us +{ + class ModuleResource; +} + +namespace mitk +{ + // class Image; + + struct MonaiModelInfo + { + std::string name; + std::string type; + std::unordered_map labels; + int dimension; + std::string description; + std::unordered_map config; //TODO: find the full extent + }; + + struct MonaiAppMetadata + { + std::string URL; + unsigned short port; + std::string origin; + std::string name; + std::string description; + std::string version; + std::vector labels; + std::vector models; + }; + + class MITKSEGMENTATION_EXPORT MonaiLabelTool : public SegWithPreviewTool + { + public: + mitkClassMacro(MonaiLabelTool, SegWithPreviewTool); + itkFactorylessNewMacro(Self); + itkCloneMacro(Self); + + const char *GetName() const override; + const char **GetXPM() const override; + us::ModuleResource GetIconResource() const override; + + void Activated() override; + void GetOverallInfo(std::string); + std::unique_ptr m_Parameters; //contains all parameters from Server to serve the GUI + std::vector GetAutoSegmentationModels(); + std::vector GetInteractiveSegmentationModels(); + std::vector GetScribbleSegmentationModels(); + void PostSegmentationRequest(); + + itkSetMacro(ModelName, std::string); + itkGetConstMacro(ModelName, std::string); + itkSetMacro(URL, std::string); + itkGetConstMacro(URL, std::string); + + + + protected: + MonaiLabelTool(); + ~MonaiLabelTool() = default; + + void DoUpdatePreview(const Image* inputAtTimeStep, const Image* oldSegAtTimeStep, LabelSetImage* previewImage, TimeStepType timeStep) override; + + + private: + void InitializeRESTManager(); + std::unique_ptr DataMapper(web::json::value&); + mitk::IRESTManager *m_RESTManager; + const std::set m_AUTO_SEG_TYPE_NAME = {"segmentation"}; + const std::set m_SCRIBBLE_SEG_TYPE_NAME = {"scribbles"}; + const std::set m_INTERACTIVE_SEG_TYPE_NAME = {"deepedit", "deepgrow"}; + std::string m_ModelName; + std::string m_URL; + + }; // class +} // namespace +#endif diff --git a/Modules/Segmentation/files.cmake b/Modules/Segmentation/files.cmake index 4520f0edc0..0bb7fc8182 100644 --- a/Modules/Segmentation/files.cmake +++ b/Modules/Segmentation/files.cmake @@ -1,117 +1,118 @@ set(CPP_FILES Algorithms/mitkCalculateSegmentationVolume.cpp Algorithms/mitkContourModelSetToImageFilter.cpp Algorithms/mitkContourSetToPointSetFilter.cpp Algorithms/mitkContourUtils.cpp Algorithms/mitkCorrectorAlgorithm.cpp Algorithms/mitkDiffImageApplier.cpp Algorithms/mitkDiffSliceOperation.cpp Algorithms/mitkDiffSliceOperationApplier.cpp Algorithms/mitkFeatureBasedEdgeDetectionFilter.cpp Algorithms/mitkGrowCutSegmentationFilter.cpp Algorithms/mitkImageLiveWireContourModelFilter.cpp Algorithms/mitkImageToContourFilter.cpp #Algorithms/mitkImageToContourModelFilter.cpp Algorithms/mitkImageToLiveWireContourFilter.cpp Algorithms/mitkManualSegmentationToSurfaceFilter.cpp Algorithms/mitkOtsuSegmentationFilter.cpp Algorithms/mitkSegmentationHelper.cpp Algorithms/mitkSegmentationObjectFactory.cpp Algorithms/mitkShapeBasedInterpolationAlgorithm.cpp Algorithms/mitkShowSegmentationAsSmoothedSurface.cpp Algorithms/mitkShowSegmentationAsSurface.cpp Algorithms/mitkVtkImageOverwrite.cpp Controllers/mitkSegmentationInterpolationController.cpp Controllers/mitkToolManager.cpp Controllers/mitkSegmentationModuleActivator.cpp Controllers/mitkToolManagerProvider.cpp DataManagement/mitkContour.cpp DataManagement/mitkContourSet.cpp DataManagement/mitkExtrudedContour.cpp Interactions/mitkAddContourTool.cpp Interactions/mitkAutoCropTool.cpp Interactions/mitkSegWithPreviewTool.cpp Interactions/mitkBinaryThresholdBaseTool.cpp Interactions/mitkBinaryThresholdTool.cpp Interactions/mitkBinaryThresholdULTool.cpp Interactions/mitkCloseRegionTool.cpp Interactions/mitkContourModelInteractor.cpp Interactions/mitkContourModelLiveWireInteractor.cpp Interactions/mitkEditableContourTool.cpp Interactions/mitkLiveWireTool2D.cpp Interactions/mitkLassoTool.cpp Interactions/mitkContourTool.cpp Interactions/mitkDrawPaintbrushTool.cpp Interactions/mitkErasePaintbrushTool.cpp Interactions/mitkEraseRegionTool.cpp Interactions/mitkFeedbackContourTool.cpp Interactions/mitkFillRegionBaseTool.cpp Interactions/mitkFillRegionTool.cpp Interactions/mitkGrowCutTool.cpp Interactions/mitkOtsuTool3D.cpp Interactions/mitkPaintbrushTool.cpp Interactions/mitkRegionGrowingTool.cpp Interactions/mitkSegmentationsProcessingTool.cpp Interactions/mitkSegTool2D.cpp Interactions/mitkSubtractContourTool.cpp Interactions/mitkTool.cpp Interactions/mitkToolCommand.cpp Interactions/mitkPickingTool.cpp Interactions/mitknnUnetTool.cpp Interactions/mitkSegmentationInteractor.cpp #SO Interactions/mitkProcessExecutor.cpp + Interactions/mitkMonaiLabelTool.cpp Rendering/mitkContourMapper2D.cpp Rendering/mitkContourSetMapper2D.cpp Rendering/mitkContourSetVtkMapper3D.cpp Rendering/mitkContourVtkMapper3D.cpp SegmentationUtilities/BooleanOperations/mitkBooleanOperation.cpp SegmentationUtilities/MorphologicalOperations/mitkMorphologicalOperations.cpp #Added from ML Controllers/mitkSliceBasedInterpolationController.cpp Algorithms/mitkSurfaceStampImageFilter.cpp ) set(RESOURCE_FILES Add.svg Add_Cursor.svg AI.svg AI_Cursor.svg Close.svg Close_Cursor.svg Erase.svg Erase_Cursor.svg Fill.svg Fill_Cursor.svg LiveWire.svg LiveWire_Cursor.svg Lasso.svg GrowCut.svg Lasso_Cursor.svg Otsu.svg Paint.svg Paint_Cursor.svg Picking.svg RegionGrowing.svg RegionGrowing_Cursor.svg Subtract.svg Subtract_Cursor.svg Threshold.svg ULThreshold.svg Wipe.svg Wipe_Cursor.svg Interactions/dummy.xml Interactions/EditableContourTool.xml Interactions/PickingTool.xml Interactions/MouseReleaseOnly.xml Interactions/PressMoveRelease.xml Interactions/PressMoveReleaseAndPointSetting.xml Interactions/PressMoveReleaseWithCTRLInversion.xml Interactions/PressMoveReleaseWithCTRLInversionAllMouseMoves.xml Interactions/SegmentationConfig.xml Interactions/SegmentationInteraction.xml Interactions/SegmentationToolsConfig.xml Interactions/ContourModelModificationConfig.xml Interactions/ContourModelModificationInteractor.xml ) diff --git a/Modules/SegmentationUI/Qmitk/QmitkMonaiLabelToolGUI.cpp b/Modules/SegmentationUI/Qmitk/QmitkMonaiLabelToolGUI.cpp new file mode 100644 index 0000000000..ecb3f78beb --- /dev/null +++ b/Modules/SegmentationUI/Qmitk/QmitkMonaiLabelToolGUI.cpp @@ -0,0 +1,92 @@ +#include "QmitkMonaiLabelToolGUI.h" +#include "mitkMonaiLabelTool.h" + +#include +#include +#include +#include "usServiceReference.h" +#include +#include +#include + + +MITK_TOOL_GUI_MACRO(MITKSEGMENTATIONUI_EXPORT, QmitkMonaiLabelToolGUI, "") + +QmitkMonaiLabelToolGUI::QmitkMonaiLabelToolGUI() + : QmitkMultiLabelSegWithPreviewToolGUIBase(), m_SuperclassEnableConfirmSegBtnFnc(m_EnableConfirmSegBtnFnc) +{ + m_EnableConfirmSegBtnFnc = [this](bool enabled) + { + return !m_FirstPreviewComputation ? m_SuperclassEnableConfirmSegBtnFnc(enabled) : false; + }; +} + +void QmitkMonaiLabelToolGUI::ConnectNewTool(mitk::SegWithPreviewTool* newTool) +{ + Superclass::ConnectNewTool(newTool); + newTool->IsTimePointChangeAwareOff(); + m_FirstPreviewComputation = true; +} + +void QmitkMonaiLabelToolGUI::InitializeUI(QBoxLayout* mainLayout) +{ + m_Controls.setupUi(this); + mainLayout->addLayout(m_Controls.verticalLayout); + + connect(m_Controls.previewButton, SIGNAL(clicked()), this, SLOT(OnPreviewBtnClicked())); + connect(m_Controls.fetchUrl, SIGNAL(clicked()), this, SLOT(OnFetchBtnClicked())); + + QIcon refreshIcon = QmitkStyleManager::ThemeIcon(QStringLiteral(":/org_mitk_icons/icons/awesome/scalable/actions/view-refresh.svg")); + m_Controls.fetchUrl->setIcon(refreshIcon); + + Superclass::InitializeUI(mainLayout); +} + +void QmitkMonaiLabelToolGUI::EnableWidgets(bool enabled) +{ + Superclass::EnableWidgets(enabled); +} + +void QmitkMonaiLabelToolGUI::OnFetchBtnClicked() +{ + auto tool = this->GetConnectedToolAs(); + if (nullptr != tool) + { + QString urlString = m_Controls.urlBox->text(); + QUrl url(urlString); + if (url.isValid() && !url.isLocalFile() && !url.hasFragment() && !url.hasQuery()) // sanity check + { + tool->GetOverallInfo(urlString.toStdString()); + // tool->GetOverallInfo("http://localhost:8000/info"); + if (nullptr != tool->m_Parameters) + { + std::string response = tool->m_Parameters->name; + std::vector autoModels = tool->GetAutoSegmentationModels(); + m_Controls.responseNote->setText(QString::fromStdString(response)); + m_Controls.appBox->addItem(QString::fromStdString(response)); + for (auto &model : autoModels) + { + m_Controls.modelBox->addItem(QString::fromStdString(model.name)); + } + } + } + else + { + MITK_ERROR << "Invalid URL entered: " << urlString.toStdString(); + } + } +} + +void QmitkMonaiLabelToolGUI::OnPreviewBtnClicked() +{ + auto tool = this->GetConnectedToolAs(); + if (nullptr != tool) + { + /* QString url = m_Controls.url->text(); + MITK_INFO << "tool found" << url.toStdString();*/ + + //tool->GetOverallInfo("https://httpbin.org/get"); + + } + //tool->UpdatePreview(); +} diff --git a/Modules/SegmentationUI/Qmitk/QmitkMonaiLabelToolGUI.h b/Modules/SegmentationUI/Qmitk/QmitkMonaiLabelToolGUI.h new file mode 100644 index 0000000000..87e9e766a2 --- /dev/null +++ b/Modules/SegmentationUI/Qmitk/QmitkMonaiLabelToolGUI.h @@ -0,0 +1,39 @@ +#ifndef QmitkMonaiLabelToolGUI_h_Included +#define QmitkMonaiLabelToolGUI_h_Included + +#include "QmitkMultiLabelSegWithPreviewToolGUIBase.h" +#include "ui_QmitkMonaiLabelToolGUIControls.h" +#include + +class MITKSEGMENTATIONUI_EXPORT QmitkMonaiLabelToolGUI : public QmitkMultiLabelSegWithPreviewToolGUIBase +{ + Q_OBJECT + +public: + mitkClassMacro(QmitkMonaiLabelToolGUI, QmitkMultiLabelSegWithPreviewToolGUIBase); + itkFactorylessNewMacro(Self); + itkCloneMacro(Self); + +protected slots : + + void OnPreviewBtnClicked(); + void OnFetchBtnClicked(); + + + +protected: + QmitkMonaiLabelToolGUI(); + ~QmitkMonaiLabelToolGUI() = default; + + void ConnectNewTool(mitk::SegWithPreviewTool* newTool) override; + void InitializeUI(QBoxLayout* mainLayout) override; + + void EnableWidgets(bool enabled) override; + + Ui_QmitkMonaiLabelToolGUIControls m_Controls; + + bool m_FirstPreviewComputation = true; + EnableConfirmSegBtnFunctionType m_SuperclassEnableConfirmSegBtnFnc; +}; + +#endif diff --git a/Modules/SegmentationUI/Qmitk/QmitkMonaiLabelToolGUIControls.ui b/Modules/SegmentationUI/Qmitk/QmitkMonaiLabelToolGUIControls.ui new file mode 100644 index 0000000000..28d745d832 --- /dev/null +++ b/Modules/SegmentationUI/Qmitk/QmitkMonaiLabelToolGUIControls.ui @@ -0,0 +1,186 @@ + + + QmitkMonaiLabelToolGUIControls + + + + 0 + 0 + 699 + 352 + + + + + 0 + 0 + + + + + 100 + 0 + + + + + 100000 + 100000 + + + + QmitkMonaiToolWidget + + + + 0 + + + 0 + + + 0 + + + 0 + + + 0 + + + + + + + + 0 + 0 + + + + <html><head/><body><p>Welcome to MONAI Label App in MITK. [Experimental]</p><p>Please note that this is only an interface to MONAI Label. MITK does not ship with any apps. Make sure to have a started a MONAI Label server beforehand. Provide the URL in the URL path to start the workflow. </p><p>Refer to <a href="https://github.com/MIC-DKFZ/nnUNet"><span style=" text-decoration: underline; color:#0000ff;">https://docs.monai.io/projects/label/en/latest/</span></a> to learn everything about the MONAI Label App.</p><p><br/></p></body></html> + + + Qt::RichText + + + true + + + + + + + + + 0 + 0 + + + + Monai Server URL: + + + + + + + + + + + + + + + 0 + 0 + + + + Available Apps: + + + + + + + + + + + + 0 + 0 + + + + Models: + + + + + + + + + + + + + 0 + 0 + + + + <html><head/><body><p>Welcome to Monai Label in MITK. [Experimental] + + + Qt::RichText + + + true + + + + + + + + + + + 0 + 0 + + + + + 100000 + 16777215 + + + + Preview + + + + + + + + + ctkExpandButton + QToolButton +
ctkExpandButton.h
+
+ + ctkComboBox + QComboBox +
ctkComboBox.h
+ 1 +
+
+ + +
diff --git a/Modules/SegmentationUI/files.cmake b/Modules/SegmentationUI/files.cmake index 5974d42e8d..5ebb388773 100644 --- a/Modules/SegmentationUI/files.cmake +++ b/Modules/SegmentationUI/files.cmake @@ -1,79 +1,81 @@ set( CPP_FILES Qmitk/QmitkSegWithPreviewToolGUIBase.cpp Qmitk/QmitkMultiLabelSegWithPreviewToolGUIBase.cpp Qmitk/QmitkBinaryThresholdToolGUIBase.cpp Qmitk/QmitkBinaryThresholdToolGUI.cpp Qmitk/QmitkBinaryThresholdULToolGUI.cpp Qmitk/QmitkConfirmSegmentationDialog.cpp Qmitk/QmitkCopyToClipBoardDialog.cpp Qmitk/QmitkDrawPaintbrushToolGUI.cpp Qmitk/QmitkErasePaintbrushToolGUI.cpp Qmitk/QmitkEditableContourToolGUIBase.cpp Qmitk/QmitkGrowCutToolGUI.cpp Qmitk/QmitkLiveWireTool2DGUI.cpp Qmitk/QmitkLassoToolGUI.cpp Qmitk/QmitkOtsuTool3DGUI.cpp Qmitk/QmitkPaintbrushToolGUI.cpp Qmitk/QmitkPickingToolGUI.cpp Qmitk/QmitkSlicesInterpolator.cpp Qmitk/QmitkToolGUI.cpp Qmitk/QmitkToolGUIArea.cpp Qmitk/QmitkToolSelectionBox.cpp Qmitk/QmitknnUNetFolderParser.cpp Qmitk/QmitknnUNetToolGUI.cpp Qmitk/QmitknnUNetWorker.cpp Qmitk/QmitknnUNetGPU.cpp +Qmitk/QmitkMonaiLabelToolGUI.cpp Qmitk/QmitkSurfaceStampWidget.cpp Qmitk/QmitkMaskStampWidget.cpp Qmitk/QmitkStaticDynamicSegmentationDialog.cpp Qmitk/QmitkSurfaceBasedInterpolatorWidget.cpp Qmitk/QmitkSimpleLabelSetListWidget.cpp ) set(MOC_H_FILES Qmitk/QmitkSegWithPreviewToolGUIBase.h Qmitk/QmitkMultiLabelSegWithPreviewToolGUIBase.h Qmitk/QmitkBinaryThresholdToolGUIBase.h Qmitk/QmitkBinaryThresholdToolGUI.h Qmitk/QmitkBinaryThresholdULToolGUI.h Qmitk/QmitkConfirmSegmentationDialog.h Qmitk/QmitkCopyToClipBoardDialog.h Qmitk/QmitkDrawPaintbrushToolGUI.h Qmitk/QmitkErasePaintbrushToolGUI.h Qmitk/QmitkEditableContourToolGUIBase.h Qmitk/QmitkGrowCutToolGUI.h Qmitk/QmitkLiveWireTool2DGUI.h Qmitk/QmitkLassoToolGUI.h Qmitk/QmitkOtsuTool3DGUI.h Qmitk/QmitkPaintbrushToolGUI.h Qmitk/QmitkPickingToolGUI.h Qmitk/QmitkSlicesInterpolator.h Qmitk/QmitkToolGUI.h Qmitk/QmitkToolGUIArea.h Qmitk/QmitkToolSelectionBox.h Qmitk/QmitknnUNetFolderParser.h Qmitk/QmitknnUNetToolGUI.h Qmitk/QmitknnUNetGPU.h Qmitk/QmitknnUNetWorker.h +Qmitk/QmitkMonaiLabelToolGUI.h Qmitk/QmitknnUNetEnsembleLayout.h Qmitk/QmitkSurfaceStampWidget.h Qmitk/QmitkMaskStampWidget.h Qmitk/QmitkStaticDynamicSegmentationDialog.h Qmitk/QmitkSurfaceBasedInterpolatorWidget.h Qmitk/QmitkSimpleLabelSetListWidget.h ) set(UI_FILES Qmitk/QmitkConfirmSegmentationDialog.ui Qmitk/QmitkGrowCutToolWidgetControls.ui Qmitk/QmitkOtsuToolWidgetControls.ui Qmitk/QmitkSurfaceStampWidgetGUIControls.ui Qmitk/QmitkMaskStampWidgetGUIControls.ui Qmitk/QmitkSurfaceBasedInterpolatorWidgetGUIControls.ui Qmitk/QmitknnUNetToolGUIControls.ui Qmitk/QmitkEditableContourToolGUIControls.ui ) set(QRC_FILES resources/SegmentationUI.qrc )