parameters: (archive, name)
return_statement: return cv2.imdecode(imagefiledata, cv2.IMREAD_COLOR)
docstring: Load image PGM file from tar archive.
  
      Used for tarfile loading and unit test.
docstring_summary: Load image PGM file from tar archive.
docstring_tokens: Load image PGM file from tar archive .
function: def image_from_archive(archive, name):
      """
      Load image PGM file from tar archive.
  
      Used for tarfile loading and unit test.
      """
      member = archive.getmember(name)
      imagefiledata = numpy.fromstring(archive.extractfile(member).read(), numpy.uint8)
      imagefiledata.resize((1, imagefiledata.size))
      return cv2.imdecode(imagefiledata, cv2.IMREAD_COLOR)
function_tokens: def image_from_archive ( archive , name ) : member = archive . getmember ( name ) imagefiledata = numpy . fromstring ( archive . extractfile ( member ) . read ( ) , numpy . uint8 ) imagefiledata . resize ( ( 1 , imagefiledata . size ) ) return cv2 . imdecode ( imagefiledata , cv2 . IMREAD_COLOR )