phenotypic.sdk_.write_metadata_table#

phenotypic.sdk_.write_metadata_table(store_part: Path, tables: PreparedImageTables) Path[source]#

Write tables/metadata/pht-metadata.parquet and its Zarr v3 group.

The metadata analogue of write_embedded_measurement_table(), and called from the same place: the store’s own .part, before the root zarr.json. That is what makes D-A’s backfill step unnecessary – no path writes into a store that already carries a content proof.

The payload is self-describing from the file alone (spec §7.2): its Parquet key/value metadata names the join keys, the join kind, and the metadata snapshot it was projected from, so a third party who opens only this Parquet can still say what it is and how it attaches.

Parameters:
  • store_part (Path) – An unpromoted *.ome.zarr.part directory.

  • tables (PreparedImageTables) – The split payload. tables.metadata must not be None.

Returns:

The written Parquet path.

Raises:

ValueError – If tables carries no metadata frame.

Return type:

Path