Return to directory of Todd's CASA extensions

Compares two pngs images using the ImageMagick compare command. Returns 0 if identical, or positive integer if not.


au.comparePngs(png1, png2, compare='compare', metric='AE', cleanup=True):
  • compare: the path to the compare command
  • cleanup: if True, remove the difference image


Demonstration of output when comparing the same file:
CASA <2>: au.comparePngs('regression00.spw00.t00.task.png','regression00.spw00.t00.png')
  Out[2]: 0

Demonstration of output when comparing different files:
CASA <3>: au.comparePngs('regression00.spw00.t00.task.png','regression/regression01.spw00.t00.png', cleanup=False)
Wrote image:  regression00.spw00.t00.task.diff.png
  Out[4]: 65535

-- ToddHunter - 2014-04-08
  • regression00.spw00.t00.task.diff.png:
Topic revision: r1 - 2014-04-08, ToddHunter
This site is powered by FoswikiCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding NRAO Public Wiki? Send feedback