parameters: (self)
docstring: Adam7 interlace reading.
          Specifically, test that for images in the PngSuite that
          have both an interlaced and straightlaced pair that both
          images from the pair produce the same array of pixels.
docstring_summary: Adam7 interlace reading.
          Specifically, test that for images in the PngSuite that
          have both an interlaced and straightlaced pair that both
          images from the pair produce the same array of pixels.
docstring_tokens: Adam7 interlace reading . Specifically test that for images in the PngSuite that have both an interlaced and straightlaced pair that both images from the pair produce the same array of pixels .
function: def testAdam7read(self):
          """Adam7 interlace reading.
          Specifically, test that for images in the PngSuite that
          have both an interlaced and straightlaced pair that both
          images from the pair produce the same array of pixels."""
          for candidate in _pngsuite:
              if not candidate.startswith('basn'):
                  continue
              candi = candidate.replace('n', 'i')
              if candi not in _pngsuite:
                  continue
              print 'adam7 read', candidate
              straight = Reader(bytes=_pngsuite[candidate])
              adam7 = Reader(bytes=_pngsuite[candi])
              # Just compare the pixels.  Ignore x,y (because they're
              # likely to be correct?); metadata is ignored because the
              # "interlace" member differs.  Lame.
              straight = straight.read()[2]
              adam7 = adam7.read()[2]
              self.assertEqual(map(list, straight), map(list, adam7))
function_tokens: def testAdam7read ( self ) : for candidate in _pngsuite : if not candidate . startswith ( 'basn' ) : continue candi = candidate . replace ( 'n' , 'i' ) if candi not in _pngsuite : continue print 'adam7 read' , candidate straight = Reader ( bytes = _pngsuite [ candidate ] ) adam7 = Reader ( bytes = _pngsuite [ candi ] ) # Just compare the pixels.  Ignore x,y (because they're # likely to be correct?); metadata is ignored because the # "interlace" member differs.  Lame. straight = straight . read ( ) [ 2 ] adam7 = adam7 . read ( ) [ 2 ] self . assertEqual ( map ( list , straight ) , map ( list , adam7 ) )