Replace ImageMath.eval with ImageMath.lambda_eval

This commit is contained in:
Andrew Murray 2024-04-09 07:34:52 +10:00
parent 33a73b5266
commit 3a92d4af01

View File

@ -139,7 +139,9 @@ def testimage() -> None:
In 1.1.6, you can use the ImageMath module to do image
calculations.
>>> im = ImageMath.eval("float(im + 20)", im=im.convert("L"))
>>> im = ImageMath.lambda_eval( \
lambda args: args["float"](args["im"] + 20), im=im.convert("L") \
)
>>> im.mode, im.size
('F', (128, 128))