DfmResult
Full DFM prediction result.
Returned by run_dfm(). Contains per-layer predictions, aggregate
statistics, and all violations. Use the passed attribute for a quick
pass/fail check when tolerances are configured.
result = run_dfm(cell, layers=[Layer(1)], config=config)
if result.passed:
print(f"DFM passed ({result.layers_processed} layers, {result.total_pixels} pixels)")
else:
print(f"DFM failed with {len(result.violations)} violations")
for v in result.violations:
print(f" {v.message}")
for lp in result.layers:
m = lp.metrics
if m:
print(f"Layer {lp.layer}: edge dev {m.max_edge_deviation:.3f} um")Attributes
attributelayerslist[LayerPrediction]Per-layer prediction results.
attributetotal_predicted_polygonsintTotal number of predicted polygons across all layers.
attributetotal_input_polygonsintTotal number of input (designed) polygons across all layers.
attributepassedboolTrue if no violations were found. Always True when no tolerances are
configured.
attributeviolationslist[DfmViolation]Aggregate list of all DFM violations across all layers.
attributelayers_processedintNumber of layers processed.
attributetotal_pixelsintTotal number of raster pixels computed across all layers.
attributeresolutionfloatRasterization resolution used (design units per pixel).
attributeelapsed_msfloatElapsed time in milliseconds.