Skip to content

rs_rich.art.imagediff

Generated from the type stubs by scripts/gen_python_api.py; do not edit.

rich_art::imagediff: perceptual image diffs.

diff module-attribute

diff = image_diff

DiffRegion

x instance-attribute

x: int

y instance-attribute

y: int

width instance-attribute

width: int

height instance-attribute

height: int

area_px instance-attribute

area_px: int

share_of_change instance-attribute

share_of_change: float

mean_delta_e instance-attribute

mean_delta_e: float

DiffReport

width property

width: int

height property

height: int

changed_fraction property

changed_fraction: float

naive_changed_fraction property

naive_changed_fraction: float

mean_delta_e property

mean_delta_e: float

max_delta_e property

max_delta_e: float

regions property

regions: List[DiffRegion]

delta_e property

delta_e: List[float]

heatmap

heatmap() -> ArtImage

highlight

highlight(after: Any) -> ArtImage

DiffSettings

blur instance-attribute

blur: float

threshold instance-attribute

threshold: float

open_kernel instance-attribute

open_kernel: int

min_region instance-attribute

min_region: int

top instance-attribute

top: int

ImageDiffError

Bases: ArtError

Two images cannot be compared; kind says why.

kind instance-attribute

kind: str

image_diff

image_diff(before: Any, after: Any, settings: Optional[DiffSettings] = None, *, blur: Optional[float] = None, threshold: Optional[float] = None, open_kernel: Optional[int] = None, min_region: Optional[int] = None, top: Optional[int] = None) -> DiffReport