docs: def _get_hmm_from_alignment(self, alignment, hmm_filename, output_alignment_filename):
          '''Return a HMM file and alignment of sequences to that HMM
  
          Parameters
          ----------
          alignment: str
              path to aligned proteins
          hmm_filename: str
              write the hmm to this file path
          output_alignment_filename: str
              write the output alignment to this file path
  
          Returns
          -------
          Return the pipeline type of the HMM.
          '''
          logging.info("Building HMM from alignment")
  
          with tempfile.NamedTemporaryFile(suffix='.fasta',prefix='graftm') as tempaln:
              cmd = "hmmbuild -O /dev/stdout -o /dev/stderr '%s' '%s'" % (
                  hmm_filename, alignment)
              process = subprocess.Popen(["bash", "-c", cmd],
                                         stdout=subprocess.PIPE,
                                         stderr=subprocess.PIPE)
              output, error = process.communicate()
              logging.debug("Got STDERR from hmmbuild: %s" % error)
              if process.returncode != 0:
                  logging.error(
                      "hmmbuild exitstatus was non-zero, likely indicating an error of "
                      "some description")
                  logging.error("Got STDERR from hmmbuild: %s" % error)
  
              SeqIO.write(SeqIO.parse(StringIO(output), 'stockholm'), tempaln, 'fasta')
              tempaln.flush()
  
              ptype, _ = self._pipe_type(hmm_filename)
              SequenceSearcher(hmm_filename).alignment_correcter([tempaln.name],
                                                      output_alignment_filename)
              return ptype