pynetdicom._config.STORE_SEND_CHUNKED_DATASET

pynetdicom._config.STORE_SEND_CHUNKED_DATASET: bool = False

Chunk a dataset file when sending it to minimise memory usage.

Added in version 2.0.

If True, then when using send_c_store() with a file path to a DICOM dataset, don’t decode the dataset and instead send the raw encoded data (without the File Meta Information) in chunks of no larger than maximum PDU size allowed by the peer. This should minimise the amount of memory required when:

  • Sending large datasets

  • Sending many datasets concurrently

As it’s not possible to change the dataset encoding without loading it into memory, an exact matching accepted presentation context will be required.

Default: False

Examples

>>> from pynetdicom import _config
>>> _config.STORE_SEND_CHUNKED_DATASET = True