I noticed in my own work that the pyhmmer HMMFile loading interface is not particularly performant. It's a hacky fix, but:
import io
with open(hmmfile, 'rb') as fh:
with HMMFile(io.BytesIO(fh.read()) as hmm_file:
...
Is about 20-50x faster than using the HMMFile parser directly on the file path on my platform. I'm on WSL - it could be wierdness that way.
I noticed in my own work that the pyhmmer HMMFile loading interface is not particularly performant. It's a hacky fix, but:
import io
with open(hmmfile, 'rb') as fh:
with HMMFile(io.BytesIO(fh.read()) as hmm_file:
...
Is about 20-50x faster than using the HMMFile parser directly on the file path on my platform. I'm on WSL - it could be wierdness that way.