Bio.SearchIO.HmmerIO.hmmer2_text module

Bio.SearchIO parser for HMMER 2 text output.

class Bio.SearchIO.HmmerIO.hmmer2_text.Hmmer2TextParser(handle)

Bases: object

Iterator for the HMMER 2.0 text output.

__init__(self, handle)

Initialize the class.


Iterate over Hmmer2TextParser, yields query results.

read_next(self, rstrip=True)

Return the next non-empty line, trailing whitespace removed.

push_back(self, line)

Un-read a line that should not be parsed yet.


Parse key-value pair separated by colon.


Parse HMMER2 preamble.


Parse a HMMER2 query block.


Parse a HMMER2 hit block, beginning with the hit table.

parse_hsps(self, hit_placeholders)

Parse a HMMER2 hsp block, beginning with the hsp table.


Parse a HMMER2 HSP alignment block.

class Bio.SearchIO.HmmerIO.hmmer2_text.Hmmer2TextIndexer(*args, **kwargs)

Bases: Bio.SearchIO.HmmerIO._base._BaseHmmerTextIndexer

Indexer for hmmer2-text format.

qresult_start = b'Query'
qresult_end = b'//'

Iterate over Hmmer2TextIndexer; yields query results’ key, offsets, 0.