# pydicom.values.convert_UI

pydicom.values.convert_UI(byte_string: bytes, is_little_endian: bool, struct_format: Optional[str] = None) → Union[pydicom.uid.UID, MutableSequence[pydicom.uid.UID]]

  Return a decoded ‘UI’ value.

  Elements with VR of ‘UI’ may have a non-significant trailing null `0x00`.

  Parameters

    - byte_string (bytes) – The encoded ‘UI’ element value.

    - is_little_endian (bool) – `True` if the value is encoded as little endian, `False` otherwise.

    - struct_format (str, optional) – Not used.

  Returns

    The decoded ‘UI’ element value without trailing nulls or spaces.

  Return type

    uid.UID or list of uid.UID