pydicom.filewriter.write_sequence_item

pydicom.filewriter.write_sequence_item(fp: DicomIO, dataset: Dataset, encodings: list[str]) None[source]

Write a dataset in a sequence to the file-like fp.

This is similar to writing a data_element, but with a specific tag for Sequence Item.

See DICOM Standard, Part 5, Section 7.5.

Parameters:
  • fp (file-like) – The file-like to write the encoded data to.

  • dataset (Dataset) – The Dataset to write to fp.

  • encodings (list of str) – The character encodings to use on text values.