Add map QA evidence drilldown
This commit is contained in:
@@ -202,6 +202,7 @@ interface MapWorkspaceProps {
|
||||
mapSelectionQaRunning: boolean
|
||||
mapSelectionQaError: string | null
|
||||
mapSelectionQaResult: QaComparisonResult | null
|
||||
latestMapSelectionQualityCheckId: string | null
|
||||
availableMapDatasets: DatasetCreateResponse[]
|
||||
onSelectMapArea: (areaId: string) => void
|
||||
onOpenDatasetInMap: (dataset: DatasetCreateResponse) => void
|
||||
@@ -217,6 +218,7 @@ interface MapWorkspaceProps {
|
||||
onDeriveMapSelectionDataset: (bbox: VectorSelectionBBox) => void
|
||||
onSelectMapQaReferenceDataset: (datasetId: string) => void
|
||||
onRunMapSelectionQa: () => void
|
||||
onOpenMapSelectionQualityEvidence: () => void
|
||||
}
|
||||
|
||||
export function MapWorkspace({
|
||||
@@ -250,6 +252,7 @@ export function MapWorkspace({
|
||||
mapSelectionQaRunning,
|
||||
mapSelectionQaError,
|
||||
mapSelectionQaResult,
|
||||
latestMapSelectionQualityCheckId,
|
||||
availableMapDatasets,
|
||||
onSelectMapArea,
|
||||
onOpenDatasetInMap,
|
||||
@@ -265,6 +268,7 @@ export function MapWorkspace({
|
||||
onDeriveMapSelectionDataset,
|
||||
onSelectMapQaReferenceDataset,
|
||||
onRunMapSelectionQa,
|
||||
onOpenMapSelectionQualityEvidence,
|
||||
}: MapWorkspaceProps): JSX.Element {
|
||||
const [bboxSelectionMode, setBboxSelectionMode] = useState(false)
|
||||
const [firstSelectionCorner, setFirstSelectionCorner] = useState<[number, number] | null>(null)
|
||||
@@ -685,23 +689,65 @@ export function MapWorkspace({
|
||||
</button>
|
||||
{mapSelectionQaError ? <p className="error">{mapSelectionQaError}</p> : null}
|
||||
{mapSelectionQaResult ? (
|
||||
<div className="feature-extract-grid" aria-label="Map selection QA result">
|
||||
<div>
|
||||
<span>Precision</span>
|
||||
<strong>{mapSelectionQaResult.precision ?? 'n/a'}</strong>
|
||||
<div className="map-selection-qa-evidence" aria-label="Map selection QA result">
|
||||
<div className="panel-title-row">
|
||||
<div>
|
||||
<p className="eyebrow">QA evidence</p>
|
||||
<h4>Saved selection comparison</h4>
|
||||
</div>
|
||||
<button
|
||||
className="secondary-action"
|
||||
disabled={!latestMapSelectionQualityCheckId}
|
||||
type="button"
|
||||
onClick={onOpenMapSelectionQualityEvidence}
|
||||
>
|
||||
Open QA/QC evidence
|
||||
</button>
|
||||
</div>
|
||||
<div>
|
||||
<span>Recall</span>
|
||||
<strong>{mapSelectionQaResult.recall ?? 'n/a'}</strong>
|
||||
</div>
|
||||
<div>
|
||||
<span>F1</span>
|
||||
<strong>{mapSelectionQaResult.f1_score ?? 'n/a'}</strong>
|
||||
</div>
|
||||
<div>
|
||||
<span>Quality check</span>
|
||||
<strong>{mapSelectionQaResult.status}</strong>
|
||||
<div className="feature-extract-grid">
|
||||
<div>
|
||||
<span>Precision</span>
|
||||
<strong>{mapSelectionQaResult.precision ?? 'n/a'}</strong>
|
||||
</div>
|
||||
<div>
|
||||
<span>Recall</span>
|
||||
<strong>{mapSelectionQaResult.recall ?? 'n/a'}</strong>
|
||||
</div>
|
||||
<div>
|
||||
<span>F1</span>
|
||||
<strong>{mapSelectionQaResult.f1_score ?? 'n/a'}</strong>
|
||||
</div>
|
||||
<div>
|
||||
<span>Mean IoU</span>
|
||||
<strong>{mapSelectionQaResult.mean_iou ?? 'n/a'}</strong>
|
||||
</div>
|
||||
<div>
|
||||
<span>Matches</span>
|
||||
<strong>{mapSelectionQaResult.matches}</strong>
|
||||
</div>
|
||||
<div>
|
||||
<span>False positives</span>
|
||||
<strong>{mapSelectionQaResult.false_positives}</strong>
|
||||
</div>
|
||||
<div>
|
||||
<span>False negatives</span>
|
||||
<strong>{mapSelectionQaResult.false_negatives}</strong>
|
||||
</div>
|
||||
<div>
|
||||
<span>Quality check id</span>
|
||||
<strong>{latestMapSelectionQualityCheckId ?? 'not persisted'}</strong>
|
||||
</div>
|
||||
</div>
|
||||
{mapSelectionQaResult.warnings.length > 0 ? (
|
||||
<div className="map-selection-qa-warnings" aria-label="Map selection QA warnings">
|
||||
<span>Map selection QA warnings</span>
|
||||
<ul>
|
||||
{mapSelectionQaResult.warnings.map((warning) => (
|
||||
<li key={warning}>{warning}</li>
|
||||
))}
|
||||
</ul>
|
||||
</div>
|
||||
) : null}
|
||||
</div>
|
||||
) : null}
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user