ef METHOD_NAME(self):
  lastIter=self.opt.niter
  doesExist=os.system("test -s {}/alignments_iter{}.db".format(self.opt.outputdir, lastIter))
  while (doesExist != 0):
     lastIter -= 1
     if lastIter < 0:
        break
     doesExist=os.system("test -s {}/alignments_iter{}.db".format(self.opt.outputdir, lastIter))
  return lastIter