Metadata-Version: 2.4
Name: iatro-iac-adapters
Version: 0.1.0
Summary: Reusable domain adapters for IatroCache packs
License-Expression: MIT
Requires-Python: >=3.10
Description-Content-Type: text/markdown
Requires-Dist: iatro-base-iac[dicom]<0.2,>=0.1
Requires-Dist: imagecodecs
Requires-Dist: numpy
Requires-Dist: Pillow
Requires-Dist: pydicom<4,>=3
Requires-Dist: pyarrow
Requires-Dist: tqdm
Provides-Extra: dev
Requires-Dist: pytest; extra == "dev"

# iatro-iac-adapters

Concrete reusable data schemas for `iatro-base-iac`.

```bash
pip install iatro-iac-adapters
```

Installing this package also installs the matching IatroCache core. Schemas
are imported from their owning modules:

```python
from iatro.iac.adapters.text import ClinicalTextReader
from iatro.iac.adapters.tiles import TilePackageReader
from iatro.iac.adapters.dicom import (
    DicomPatientReader,
    build_dicom_patient_package,
    build_dicom_patient_package_from_files,
)
```

The DICOM builder accepts one directory containing a single patient's
``.dcm`` files and writes independently addressable lossless JPEG XL instance
records:

```python
build_dicom_patient_package("dicom-directory", "patient.iac")
# Paths, bytes, and one-shot binary streams are also accepted lazily:
build_dicom_patient_package_from_files(dicom_inputs, "patient.iac")
reader = DicomPatientReader("patient.iac")
pixels = reader.read_pixel_array(0)
reader.write_dicom(0, "restored.dcm")
```

The physical layout and reconstruction contract are documented in
[`docs/dicom-patient-schema.md`](../../docs/dicom-patient-schema.md).

The package contains reusable tile, fixed-feature, clinical-text, paired
clinical-text, and patient-level DICOM schemas. It defines no adapter base
class, protocol, or registry:
new schemas directly compose `VariableRecordPack` or `FixedRecordPack` with a
codec. Project-specific schemas remain in their owning projects.
