From a4f9f698dd1b5d838480c309010e6d4484f73b05 Mon Sep 17 00:00:00 2001 From: David Sarrut Date: Fri, 29 Jul 2011 15:17:54 +0200 Subject: [PATCH] Finish first step of S3A. --- segmentation/clitkExtractLymphStation_3A.txx | 78 +++++++------------- 1 file changed, 27 insertions(+), 51 deletions(-) diff --git a/segmentation/clitkExtractLymphStation_3A.txx b/segmentation/clitkExtractLymphStation_3A.txx index 4b1d3c2..8bcabc5 100644 --- a/segmentation/clitkExtractLymphStation_3A.txx +++ b/segmentation/clitkExtractLymphStation_3A.txx @@ -43,10 +43,11 @@ ExtractStation_3A() ExtractStation_3A_PostToBones(); - - - // ExtractStation_3A_Ant_Limits(); --> No, already in support; to remove - // ExtractStation_3A_Post_Limits(); --> No, more complex, see Vessels etc + // Keep a single CCL + m_ListOfStations["3A"] = + clitk::SliceBySliceKeepMainCCL(m_ListOfStations["3A"], + GetBackgroundValue(), + GetForegroundValue()); // Store image filenames into AFDB writeImage(m_ListOfStations["3A"], "seg/Station3A.mhd"); @@ -57,53 +58,6 @@ ExtractStation_3A() //-------------------------------------------------------------------- -//-------------------------------------------------------------------- -template -void -clitk::ExtractLymphStationsFilter:: -ExtractStation_3A_Ant_Limits() -{ - StartNewStep("[Station 3A] Ant limits with Sternum"); - - // Get Sternum, keep posterior part. - MaskImagePointer Sternum = GetAFDB()->template GetImage("Sternum"); - m_Working_Support = - clitk::SliceBySliceRelativePosition(m_Working_Support, Sternum, 2, - GetFuzzyThreshold("3A", "Sternum"), "PostTo", - false, 3, true, false); - StopCurrentStep(m_Working_Support); - m_ListOfStations["3A"] = m_Working_Support; -} -//-------------------------------------------------------------------- - - -//-------------------------------------------------------------------- -template -void -clitk::ExtractLymphStationsFilter:: -ExtractStation_3A_Post_Limits() -{ - StartNewStep("[Station 3A] Post limits with SubclavianArtery"); - - // Get Sternum, keep posterior part. - MaskImagePointer SubclavianArteryLeft = - GetAFDB()->template GetImage("SubclavianArteryLeft"); - MaskImagePointer SubclavianArteryRight = - GetAFDB()->template GetImage("SubclavianArteryRight"); - - m_Working_Support = - clitk::SliceBySliceRelativePosition(m_Working_Support, SubclavianArteryLeft, 2, - GetFuzzyThreshold("3A", "SubclavianArtery"), "AntTo", - false, 3, true, false); - m_Working_Support = - clitk::SliceBySliceRelativePosition(m_Working_Support, SubclavianArteryRight, 2, - GetFuzzyThreshold("3A", "SubclavianArtery"), "AntTo", - false, 3, true, false); - StopCurrentStep(m_Working_Support); - m_ListOfStations["3A"] = m_Working_Support; -} -//-------------------------------------------------------------------- - //-------------------------------------------------------------------- template @@ -341,3 +295,25 @@ ExtractStation_3A_Remove_Structures() m_ListOfStations["3A"] = m_Working_Support; } //-------------------------------------------------------------------- + + +//-------------------------------------------------------------------- +template +void +clitk::ExtractLymphStationsFilter:: +ExtractStation_3A_PostToBones() +{ + StartNewStep("[Station 3A] Post limits with bones"); + + // limits with bones + MaskImagePointer Bones = GetAFDB()->template GetImage("Bones"); + m_Working_Support = + clitk::SliceBySliceRelativePosition(m_Working_Support, Bones, 2, + GetFuzzyThreshold("3A", "Bones"), "NotAntTo", + false, 3, true, false); + + StopCurrentStep(m_Working_Support); + m_ListOfStations["3A"] = m_Working_Support; +} +//-------------------------------------------------------------------- + -- 2.47.1