Skip to main content

task

Prefect task for the GA metrics calculation step with fovea (v2).

Identical to v1 but for the lesion sizes of a scan with no GA. v1 reports its smallest and largest lesion sizes as nan, which a criterion reads as unknown, while the GA area beside them is a real 0.0: a scan measured and found clear of GA was unknown on a lesion-size bound and failed on the area bound. v2 reports both sizes as 0.0. A lesion that cannot be measured for want of a scale stays nan.

The version exists to move the task_hash: it does not cover the SDK's code, so without the bump every lesion size cached under v1 would keep being served. Moving the hash recomputes the GA metrics from the cached GA and fovea inferences, not by re-running either model. v1's partition survives, so pinning a template back to v1 is a complete rollback.

Module​

Functions​

ga_calculation_with_fovea_task_v2​

def ga_calculation_with_fovea_task_v2(    datasource: BaseSource,    config: GACalculationWithFoveaConfig,    ga_predictions: CacheAccessor,    fovea_predictions: CacheAccessor,    filenames: list[str],    cache: CacheProtocol,    task_hash: str,    project_id: str | None = None,    run_id: str | None = None,) ‑> GACalculationWithFoveaResult:

Compute GA metrics for each file and persist them to cache.

A scan with no GA reports lesion sizes of 0.0. See run_ga_calculation_with_fovea for the arguments.