TMHMM is a program to predict the location of transmembrane helices in proteins, directly from sequence. ssbio provides a wrapper to execute and parse the “long” output format of TMHMM.

Installation instructions (Unix)


These instructions were created on an Ubuntu 17.04 system.

  1. Register for the software (academic license only) at the TMHMM download page

  2. Receive instructions to download the software at your email address

  3. Download the file tmhmm-2.0c.Linux.tar.gz

  4. Extract it to a place where you store software

  5. Install it according to the TMHMM installation instructions, repeated and annotated below…

    1. Insert the correct path for perl 5.x in the first line of the scripts bin/tmhmm and bin/ (if not /usr/local/bin/perl). Use which perl and perl -v in the terminal to help find the correct path.
    2. Make sure you have an executable version of decodeanhmm in the bin directory.
    3. Include the directory containing tmhmm in your path (how do I add something to my Path?)
    4. Read the

Program execution

In the shell

To run the program on its own, execute the following command with your protein sequences contained in a FASTA file:

tmhmm my_sequences.fasta

With ssbio

To run the program using the ssbio Python wrapper, see:


  • How do I cite TMHMM?

    • Krogh A, Larsson B, von Heijne G & Sonnhammer EL (2001) Predicting transmembrane protein topology with a hidden Markov model: application to complete genomes. J. Mol. Biol. 305: 567–580 Available at:
  • I’m having issues running TMHMM…

    • See the ssbio wiki for (hopefully) some solutions - or add yours in when you find the answer!


Determine the residue numbers of the TM-helix residues that cross the membrane and label them by leaflet.

Parameters:tmhmm_seq – g.protein.representative_sequence.seq_record.letter_annotations[‘TM-tmhmm’]
Returns:a dictionary with leaflet_variable : [residue list] where the variable is inside or outside TM_boundary dict: outputs a dictionar with : TM helix number : [TM helix residue start , TM helix residue end]
Return type:leaflet_dict


untested method!