資源簡介
SLicerRT 源碼,通過該源碼閱讀可以了解slicer中如何處理DICOMRT圖像

代碼片段和文件信息
from?__future__?import?absolute_import?division?print_function?#?Makes?moving?python2?to?python3?much?easier?and?ensures?that?nasty?bugs?involving?integer?division?don‘t?creep?in
import?os
import?unittest
import?vtk?qt?ctk?slicer
from?slicer.scriptedLoadableModule?import?*
import?argparse
import?sys
import?logging
from?DICOMLib?import?DICOMUtils
#?------------------------------------------------------------------------------
#?BatchStructureSetConversion
#???Convert?structures?in?structure?set?to?labelmaps?and?save?them?to?disk
#
class?BatchStructureSetConversion(scriptedLoadableModule):
????def?__init__(self?parent):
????????scriptedLoadableModule.__init__(self?parent)
????????parent.title?=?“Batch?Structure?Set?Conversion“
????????parent.categories?=?[“Testing.SlicerRT?Tests“]
????????parent.dependencies?=?[“DicomRtImportExport“?“Segmentations“]
????????parent.contributors?=?[“Csaba?Pinter?(Queen‘s)“]
????????parent.helpText?=?“““
????This?is?a?module?for?converting?DICOM?structure?set?to?labelmaps?and?saving?them?to?disk.
????“““
????????parent.acknowledgementText?=?“““This?file?was?originally?developed?by?Csaba?Pinter?PerkLab?Queen‘s?University?and?was?supported?through?the?Applied?Cancer?Research?Unit?program?of?Cancer?Care?Ontario?with?funds?provided?by?the?Ontario?Ministry?of?Health?and?Long-Term?Care“““??#?replace?with?organization?grant?and?thanks.
????????self.parent?=?parent
????????#?Add?this?test?to?the?SelfTest?module‘s?list?for?discovery?when?the?module
????????#?is?created.??Since?this?module?may?be?discovered?before?SelfTests?itself
????????#?create?the?list?if?it?doesn‘t?already?exist.
????????try:
????????????slicer.selfTests
????????except?AttributeError:
????????????slicer.selfTests?=?{}
????????slicer.selfTests[‘BatchStructureSetConversion‘]?=?self.runTest
????def?runTest(self):
????????tester?=?BatchStructureSetConversionTest()
????????tester.runTest()
#?------------------------------------------------------------------------------
#?BatchStructureSetConversionWidget
#
class?BatchStructureSetConversionWidget(scriptedLoadableModuleWidget):
????def?setup(self):
????????self.developerMode?=?True
????????scriptedLoadableModuleWidget.setup(self)
#?------------------------------------------------------------------------------
#?BatchStructureSetConversionLogic
#
class?BatchStructureSetConversionLogic(scriptedLoadableModuleLogic):
????“““This?class?should?implement?all?the?actual
????computation?done?by?your?module.??The?interface
????should?be?such?that?other?python?code?can?import
????this?class?and?make?use?of?the?functionality?without
????requiring?an?instance?of?the?Widget
????“““
????def?__init__(self):
??????scriptedLoadableModuleLogic.__init__(self)
??????self.dataDir?=?slicer.app.temporaryPath?+?‘/BatchStructureSetConversion‘
??????if?not?os.access(self.dataDir?os.F_OK):
????????os.mkdir(self.dataDir)
????def?LoadFirstPatientIntoS
?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????目錄???????????0??2018-06-19?22:51??SlicerRT-master\
?????目錄???????????0??2018-06-19?22:51??SlicerRT-master\BatchProcessing\
?????文件???????14293??2018-06-19?22:51??SlicerRT-master\BatchProcessing\BatchStructureSetConversion.py
?????文件????????1197??2018-06-19?22:51??SlicerRT-master\BatchProcessing\CMakeLists.txt
?????文件????????1219??2018-06-19?22:51??SlicerRT-master\BatchProcessing\_readme.txt
?????目錄???????????0??2018-06-19?22:51??SlicerRT-master\Beams\
?????文件????????2372??2018-06-19?22:51??SlicerRT-master\Beams\CMakeLists.txt
?????目錄???????????0??2018-06-19?22:51??SlicerRT-master\Beams\Logic\
?????文件????????1137??2018-06-19?22:51??SlicerRT-master\Beams\Logic\CMakeLists.txt
?????文件????????7710??2018-06-19?22:51??SlicerRT-master\Beams\Logic\vtkSlicerBeamsModuleLogic.cxx
?????文件????????2683??2018-06-19?22:51??SlicerRT-master\Beams\Logic\vtkSlicerBeamsModuleLogic.h
?????文件???????14595??2018-06-19?22:51??SlicerRT-master\Beams\Logic\vtkSlicerIECTransformLogic.cxx
?????文件????????4899??2018-06-19?22:51??SlicerRT-master\Beams\Logic\vtkSlicerIECTransformLogic.h
?????目錄???????????0??2018-06-19?22:51??SlicerRT-master\Beams\MRML\
?????文件????????1486??2018-06-19?22:51??SlicerRT-master\Beams\MRML\CMakeLists.txt
?????文件???????20929??2018-06-19?22:51??SlicerRT-master\Beams\MRML\vtkMRMLRTBeamNode.cxx
?????文件????????7524??2018-06-19?22:51??SlicerRT-master\Beams\MRML\vtkMRMLRTBeamNode.h
?????文件???????29047??2018-06-19?22:51??SlicerRT-master\Beams\MRML\vtkMRMLRTPlanNode.cxx
?????文件????????7964??2018-06-19?22:51??SlicerRT-master\Beams\MRML\vtkMRMLRTPlanNode.h
?????目錄???????????0??2018-06-19?22:51??SlicerRT-master\Beams\Resources\
?????目錄???????????0??2018-06-19?22:51??SlicerRT-master\Beams\Resources\Icons\
?????文件?????????248??2018-06-19?22:51??SlicerRT-master\Beams\Resources\Icons\Beams.png
?????目錄???????????0??2018-06-19?22:51??SlicerRT-master\Beams\Resources\UI\
?????文件????????6731??2018-06-19?22:51??SlicerRT-master\Beams\Resources\UI\qSlicerBeamsModule.ui
?????文件?????????108??2018-06-19?22:51??SlicerRT-master\Beams\Resources\qSlicerBeamsModule.qrc
?????目錄???????????0??2018-06-19?22:51??SlicerRT-master\Beams\SubjectHierarchyPlugins\
?????文件????????1809??2018-06-19?22:51??SlicerRT-master\Beams\SubjectHierarchyPlugins\CMakeLists.txt
?????目錄???????????0??2018-06-19?22:51??SlicerRT-master\Beams\SubjectHierarchyPlugins\Resources\
?????目錄???????????0??2018-06-19?22:51??SlicerRT-master\Beams\SubjectHierarchyPlugins\Resources\Icons\
?????文件?????????248??2018-06-19?22:51??SlicerRT-master\Beams\SubjectHierarchyPlugins\Resources\Icons\Beam.png
?????文件?????????856??2018-06-19?22:51??SlicerRT-master\Beams\SubjectHierarchyPlugins\Resources\Icons\Isocenter.png
............此處省略614個文件信息
- 上一篇:FPGA實習題目-計算器.zip
- 下一篇:釘釘...rar
評論
共有 條評論