pydicom序列class的目的是什么?

What is the purpose of pydicom Sequence class?

我无法理解 pydicom 中 class 序列的用途。

我阅读了 pydicom 文档页面上提供的示例:https://pydicom.github.io/pydicom/stable/auto_examples/metadata_processing/plot_sequences.html#sphx-glr-auto-examples-metadata-processing-plot-sequences-py

好像无非就是一个Dataset的列表。

另外,示例中将其描述为数据集的一个元素class,我不知道是否需要。

有人用过吗?

谢谢

来自https://pydicom.github.io/pydicom/stable/base_element.html#sequence

Sequence is derived from Python’s list. The only added functionality is to make string representations prettier. Otherwise all the usual methods of list like item selection, append, etc. are available.

所以它基本上只是一个 python 列表。

Furthermore, it is described in the example as an element of the Dataset class, and I do not understand if it required or not.

序列是数据集中数据元素的一个可能值 - 那些具有 'SQ' 值表示 (VR) 的数据元素。

我不完全同意所写的内容。序列应被视为结构列表。序列由(列表)项组成,每个项都具有相同的结构(ure),即属性。

我也不同意序列在图像对象中的相关性较低。新的增强型 (CT-/MR-/XA-/US-/..) 图像 SOP 类 大量使用序列来编码每帧属性。参见 here