WEMDicomSave

MacroModule
genre DICOM
author MeVis Medical Solutions AG
package MeVisLab/Standard
definition WEMDicomSave.def
see also WEMDicomLoad, WEMSave, WEMLoad
keywords save, store, write, mesh, surface, segmentation, object, sso

Purpose

This module saves a WEM object as DICOM Surface Segmentation Object.

Usage

Connect a WEM to inWEM and some reference DICOM tree to inRefTree, fill in the required fields and press Save.

Details

The module will copy a bunch of required tags from inRefTree. Each WEM patch will be put into its own segment. If you require something different, you need to copy this module (or use the wrapper used in this module directly) and modify the use of addSurface and addSegment accordingly.

Windows

Default Panel

../../../Modules/Macros/WEMDicomStorage/mhelp/Images/Screenshots/WEMDicomSave._default.png

Input Fields

inWEM

name: inWEM, type: WEM(MLBase)

Connect a WEM object to this input.

For accessing this object via scripting see the Scripting Reference: MLWEMWrapper.

inRefTree

name: inRefTree, type: DicomTree(MLBase)

Connect a reference Dicom tree to this input. If you only have a reference image, you can use GetDicomTreeFromImage to extract the Dicom information.

For accessing this object via scripting see the Scripting Reference: MLABDicomTree.

Parameter Fields

Field Index

Algorithm Name: String Copy Equipment Tags From Reference: Bool Save: Trigger
Algorithm Type: Enum Device Serial Number: String Scheme: String
Algorithm Version: String Filename: String segmentationPropertyMappingJSON: String
Code: String Instance Number: Integer Series Number: Integer
Content Creators Name: String Manufacturer: String Set Now: Trigger
Content Date: String Manufacturers Model Name: String Software Versions: String
Content Description: String Meaning: String Status: String
Content Label: String Ok: Bool  
Content Time: String referenceReferenceTree: Bool  

Visible Fields

Filename

name: filename, type: String

The filename to save the resulting Dicom file under.

Save

name: save, type: Trigger

Triggers generation and saving of the Dicom file.

Status

name: status, type: String, persistent: no

This field will contain error reasons is Ok is not true, otherwise it will just read “Ok”.

Ok

name: ok, type: Bool, persistent: no

This field indicates if the last save operation performed without problems.

Copy Equipment Tags From Reference

name: copyEquipmentTagsFromReference, type: Bool, default: TRUE

If true, copies the equipment tags from inRefTree, otherwise the equipment tag values must be filled.

Manufacturer

name: manufacturer, type: String

Value of the Manufacturer (0008,0070) tag.

Manufacturers Model Name

name: manufacturersModelName, type: String

Value of the ManufacturersModelName (0008,1090) tag.

Device Serial Number

name: deviceSerialNumber, type: String

Value of the DeviceSerialNumber (0008,1000) tag.

Software Versions

name: softwareVersions, type: String

Value of the SoftwareVersions (0008,1020) tag.

Set Now

name: setContentDateTimeToNow, type: Trigger

Set the value of Content Date and Content Time to the current time.

Content Date

name: contentDate, type: String

Value of the ContentDate (0008,0023) tag.

Content Time

name: contentTime, type: String

Value of the ContentTime (0008,0033) tag.

Content Label

name: contentLabel, type: String

Value of the ContentLabel (0070,0080) tag.

Content Description

name: contentDescription, type: String

Value of the ContentDescription (0070,0081) tag.

Content Creators Name

name: contentCreatorsName, type: String

Value of the ContentCreatorsName (0070,0084) tag.

Series Number

name: seriesNumber, type: Integer, default: 1, minimum: 1

Value of the SeriesNumber (0020,0011) tag. This should be the number of the (generated) series in the study given by inRefTree. To be correct one would need to know how many series have been generated for the study already, but probably one can get away with an incorrect number (there is always the SeriesInstanceUID, which is guaranteed to be unique).

Instance Number

name: instanceNumber, type: Integer, default: 1, minimum: 1

Value of the InstanceNumber (0020,0013) tag. The number of the generated instance in the current (generated) series. 1 should always be correct.

Algorithm Type

name: algorithmType, type: Enum, default: AUTOMATIC

Value of the SegmentAlgorithmType (0062,0008) tag in the SegmentSequence (0062,0002) sequence.

Values:

Title Name
Automatic AUTOMATIC
Semiautomatic SEMIAUTOMATIC
Manual MANUAL

Algorithm Name

name: algorithmName, type: String

Value of the AlgorithmName (0066,0036) tag in the SegmentSurfaceGenerationAlgorithmIdentificationSequence (0066,002D) sequence in the ReferencedSurfaceSequence (0066,002B) sequence in the SegmentSequence (0062,0002) sequence. This should be the user defined name of the algorithm used to generate the surface.

Algorithm Version

name: algorithmVersion, type: String

Value of the AlgorithmVersion (0066,0031) tag in the SegmentSurfaceGenerationAlgorithmIdentificationSequence (0066,002D) sequence in the ReferencedSurfaceSequence (0066,002B) sequence in the SegmentSequence (0062,0002) sequence. This should be the user defined version string of the algorithm used to generate the surface.

Code

name: algorithmCode, type: String

Value of the CodeValue (0008,0100) tag (or LongCodeValue (0008,0119) tag) in the AlgorithmFamilyCodeSequence (0066,002F) sequence in the SegmentSurfaceGenerationAlgorithmIdentificationSequence (0066,002D) sequence in the ReferencedSurfaceSequence (0066,002B) sequence in the SegmentSequence (0062,0002) sequence. This identifies the principal type of algorithm employed. This will be automatically set if the user selects one of the predefined values offered for Meaning.

Scheme

name: algorithmScheme, type: String

Value of the CodingSchemeDesignator (0008,0102) tag in the AlgorithmFamilyCodeSequence (0066,002F) sequence in the SegmentSurfaceGenerationAlgorithmIdentificationSequence (0066,002D) sequence in the ReferencedSurfaceSequence (0066,002B) sequence in the SegmentSequence (0062,0002) sequence. This is kind of a namespace for Code value. This will be automatically set if the user selects one of the predefined values offered for Meaning.

Meaning

name: algorithmMeaning, type: String

Value of the CodeMeaning (0008,0104) tag in the AlgorithmFamilyCodeSequence (0066,002F) sequence in the SegmentSurfaceGenerationAlgorithmIdentificationSequence (0066,002D) sequence in the ReferencedSurfaceSequence (0066,002B) sequence in the SegmentSequence (0062,0002) sequence. This is the user readable description for Code. There is a list of pre-defined values. Selecting one of these will also set Code and Scheme.

Hidden Fields

referenceReferenceTree

name: referenceReferenceTree, type: Bool, default: FALSE

If set all SOPInstanceUIDs contained in the inRefTree will be referenced in the ReferencedSeriesSequence (0008,1115) tag.

segmentationPropertyMappingJSON

name: segmentationPropertyMappingJSON, type: String

This field stores the JSON representation of a map that will map WEM patch labels to SegmentedPropertyCategoryCodeSequence (0062,0003) and SegmentedPropertyTypeCodeSequence (0062,000F) values. These will tell what is represented by these surfaces. The user interface for this will have selection lists for the category meaning and category type columns that will automatically fill the code and scheme columns for the user.