A.1 Native DICOM Model

A.1.1 Usage

The Native DICOM Model defines a representation of binary-encoded DICOM SOP Instances as XML Infosets that allows a recipient of data to navigate through a binary DICOM data set using XML-based tools instead of relying on toolkits that understand the binary encoding of DICOM.

Note: It is not the intention that this form be utilized as the basis for other uses. This form does not take advantage of the self-validation features that could be possible with a pure XML representation of the data.

With the exception of padding, a data source that is creating a new instance of a native DICOM Model (e.g. the result from some analysis application) shall follow the DICOM encoding rules (e.g. the handling of character sets) in creating Values for the DicomAttributes within the instance of the DICOM Native Model.

A data recipient that converts data from an instance of the Native DICOM Model back into a binary encoded DICOM object shall adjust the padding as necessary to meet the encoding rules specified in DICOM PS3.5.

A.1.2 Identification

The ObjectDescriptors MIME content type for the Native DICOM Model shall be “application/x-dicom.native”.

The ObjectDescriptors class UID for the Native DICOM Model shall be “1.2.840.10008.7.1.1”.

A.1.3 Support

Support of the Native DICOM Model as both a data source and a data recipient shall be required of all Hosting Systems implementing the interface.

Support of the Native DICOM Model as either a data source or a data recipient shall be optional for all Hosted Applications implementing the interface.

A.1.4 Information Model

A diagram of the Native DICOM Model appears in Figure A.1.4-1.

[pic]

Figure A.1.4-1 Native DICOM Model

A.1.5 Description

Table A.1.5-1 Native DICOM Model

Name Optionality Cardinality Description
NativeDicomModel R 1 An Infoset (as defined in W3C Recommendation XML Information Set “http://www.w3.org/TR/xml-infoset/”) representing the content of a DICOM Data Set (as defined in PS3.5), which may be either: - the contents of an entire DICOM Composite Instance (as defined in PS3.3) in response to a native model request, or - the contents of part of a DICOM Composite Instance in response to a query on a native model, or - the contents of a Sequence Item (as defined in PS3.5), recursively included within an Infoset Value element. The directive xml:space=”preserve” shall be included.
Include ‘DICOM DataSet Macro’ Table A.1.5-2

Table A.1.5-2 DICOM Data Set Macro

Name Optionality Cardinality Description
DicomAttribute O 0-n An Infoset element corresponding to each DICOM Attribute.
>keyword C A The keyword as defined in PS3.6. Required unless the DICOM Data Element is unknown to the host.
>tag R A The four-digit zero-padded hexadecimal values of the Group and Element Numbers of the Data Element Tag, concatenated as a single string without a delimiter. E.g., Data Element (0010,0020) would have a tag of “00100020”. For Private Data Elements, the two most significant hexadecimal characters of the Element Number shall be 00, since the Private Creator is explicitly conveyed and the block used in the DICOM encoding shall not be sent (i.e., a Private Data Element has the form gggg00ee).
>vr O A The Value Representation of this element, represented as a two character uppercase string, as defined in PS3.5 and specified for this Data Element in PS3.6. Note: Implementations may utilize the Value Representation to validate data values, if desired.
>privateCreator C A The value of the Private Creator Data Element corresponding to the block in which this Private Data Element is used. Required for Private Data Elements. Shall not be present otherwise (i.e., for Data Elements defined by the DICOM Standard).
>Value C 1-n A Value from the Value Field of the DICOM Data Element. There is one Infoset Value element for each DICOM Value or Sequence Item. Required if the DICOM Data Element represented is not zero length and an Item, PersonName, or BulkData XML element is not present. Shall not be used if the VR of the enclosing Attribute is either SQ or PN.
>>number R A The order in which the Value occurs within the DICOM Value Field, as a number monotonically increasing starting from 1 by 1. Note: The Number XML Attribute is used to preserve the original order.
>>plain character data C 1 A single DICOM value encoded as plain character data. E.g., a DICOM Decimal String Value Field that contained two delimiter-separated values, e.g., “0.5\0.4” would be encoded as two Infoset Value elements: <Value number="1">0.5</Value> <Value number="2">0.4</Value> A Code String Value Field that containing three delimiter-separated values, the second of which was zero length, “MPG\\XR3”, would be encoded as: <Value number="1”>MPG</Value> <Value number=”2”></Value> <Value number=”3”>XR3</Value> Contrast the latter example with a zero length Value Field, in which case there would be no Infoset Value elements at all. The character encoding is that declared for the Infoset, regardless of any DICOM Specific Character Set, and any necessary translation from the DICOM Specific Character Set to the Infoset character encoding shall have been performed. Note: This translation might not be completely lossless, particularly with Asian character sets.
>Item C 1-n A DICOM sequence item, in other words a nested DICOM Data Set. Required if the DICOM Data Element represented is a Sequence (has a VR of “SQ”) and is not zero length. Not allowed otherwise.
>>number R A The order in which the Item occurs within a Sequence of Items, as a number monotonically increasing from 1 by 1. Note: The Number XML Attribute is used to preserve the original order.
>>Include Include ‘DICOM Data Set Macro’ Table A.1.5-2 R 1 Recursively includes the Data Set corresponding to a Sequence Item.
>PersonName C 1-n A parsed representation in XML of a DICOM Data Element containing a name (i.e., whose VR is PN). Note: Parsing Attributes with a VR of PN into an XML representation of the name groups and components simplifies the creation of XPath statements to pull only portions of names out of the DICOM data. Required if the DICOM Data Element represented has a VR of PN and is not zero length. Not allowed otherwise. The rules defined in DICOM PS3.5 on the usage of the Alphabetic, Ideographic, and Phonetic groups of name components within a DICOM Attribute with a Value Representation of PN apply.
>>number R A The order in which the PersonName occurs within the DICOM Value Field, as a number monotonically increasing from 1 by 1. Note: The Number XML Attribute is used to preserve the original order.
>>Alphabetic O 0-1 A group of name components that are represented in alphabetical characters. (See the definition for the Value Representation of PN in DICOM PS3.5.)
>>> Include ‘Person Name Component Macro’ Table 10.2-1
>>Ideographic O 0-1 A group of name components that are represented in ideographic characters. (See the definition for the Value Representation of PN in DICOM PS3.5.)
>>> Include ‘Person Name Component Macro’ Table 10.2-1
>>Phonetic O 0-1 A group of name components that are represented in phonetic characters. (See the definition for the Value Representation of PN in DICOM PS3.5.)
>>> Include ‘Person Name Component Macro’ Table 10.2-1
>BulkData C 1 A reference to a blob of data that the recipient may retrieve through use of the GetData() method. Required if the DICOM Data Element represented is not zero length and an XML Infoset Value, Item, or PersonName element is not present. The provider of the data may use a BulkData reference at its discretion to avoid encoding a large DICOM Value Field as text by value in the Infoset. For example, a provider may include large binary values such as pixel data or look up tables, which typically would be located in a file, as BulkData references. Note that there is a single BulkData Infoset element representing the entire Value Field, and not one per Value in the case where the Value Multiplicity is greater than one. E.g., a LUT with 4096 16 bit entries that may be encoded in DICOM with a Value Representation of OW, with a VL of 8192 and a VM of 1, or a US VR with a VL of 8192 and a VM of 4096 would both be represented as a single BulkData element. All rules (e.g. byte ordering and swapping) in DICOM PS3.5 apply. Note: Implementers should in particular pay attention the PS3.5 rules regarding the value representations of OW and OF. If the BulkData has a string or text Value Representation, the value(s) of the DICOM Specific Character Set Data Element, if present, might be necessary to determine its encoding.
>>UUID R A An identifier of this bulk data reference formatted as a UUID using the hexadecimal representation defined in ITU-T Recommendation X.667,..

A.1.6 Schema

The Normative version of the XML Schema for the Native DICOM Model follows:

default namespace="http://dicom.nema.org/PS3.19/models/NativeDICOM";

# This schema was created as an intermediary, a means of describing

# native binary encoded DICOM objects as XML Infosets, thus allowing

# one to manipulate binary DICOM objects using familiar XML tools.

# As such, the schema is designed to facilitate a simple, mechanical,

# bi-directional translation between binary encoded DICOM and XML-like

# constructs without constraints, and to simplify identifying portions

# of a DICOM object using XPath statements.

#

# Since this schema has minimal type checking, it is neither intended

# to be used for any operation that involves hand coding, nor to

# describe a definitive, fully validating encoding of DICOM concepts

# into XML, as what one might use, for example, in a robust XML

# database system or in XML-based forms, though it may be used

# as a means for translating binary DICOM Objects into such a form

# (e.g. through an XSLT script).

start = element NativeDicomModel { DicomDataSet }

# A DICOM Data Set is as defined in PS3.5. It does not appear

# as an XML Element, since it does not appear in the binary encoded

# DICOM objects. It exists here merely as a documentation aid.

DicomDataSet = DicomAttribute*

DicomAttribute = element DicomAttribute {

Tag, VR, Keyword?, PrivateCreator?,

( BulkData | Value+ | Item+ | PersonName+ )?

}

BulkData = element BulkData{ UUID }

Value = element Value { Number, xsd:string }

Item = element Item { Number, DicomDataSet }

PersonName = element PersonName {

Number,

element SingleByte { NameComponents }?,

element Ideographic { NameComponents }?,

element Phonetic { NameComponents }?

}

NameComponents =

element FamilyName {xsd:string}?,

element GivenName {xsd:string}?,

element MiddleName {xsd:string}?,

element NamePrefix {xsd:string}?,

element NameSuffix {xsd:string}?

# keyword is the attribute tag from PS3.6

# (derived from the DICOM Attribute's name)

Keyword = attribute keyword { xsd:token }

# canonical XML definition of Hex, with lowercase letters disallowed

Tag = attribute tag { xsd:string{ minLength="8" maxLength="8" pattern="[0-9A-F]{8}" } }

VR = attribute vr { "AE" | "AS" | "AT"| "CS" | "DA" | "DS" | "DT" | "FL" | "FD"

| "IS" | "LO" | "LT" | "OB" | "OF" | "OW" | "PN" | "SH" | "SL"

| "SQ" | "SS" | "ST" | "TM" | "UI" | "UL" | "UN" | "US" | "UT" }

PrivateCreator = attribute privateCreator{ xsd:string }

UUID = attribute uuid { xsd:string }

Number = attribute number { xsd:positiveInteger }

A.1.7 Examples

Here is an example XPath query to extract the code meaning of the first item in the View Code Sequence:

/DicomNativeModel/DicomAttribute[@keyword=”ViewCodeSequence”]/Item[@number=1]/ /DicomAttribute[@keyword=”CodeMeaning”]/Value[@number=1]