def setUp(self): self.buf = open('data/ProtDNA.psl').read() self.buf = self.buf.replace("\r\n","\n") thisdir = os.path.abspath(os.path.dirname(__file__)) def thisfile(name): return os.path.join(thisdir, name) self.srcDB = seqdb.SequenceFileDB(thisfile('data/test_prot.fa')) self.destDB = seqdb.SequenceFileDB(thisfile('data/test_dna.fa')) self.db = seqdb.SequenceFileDB(thisfile('data/translatedDB.fa')) self.aln_type = 1 #protein-dna alignmet = 1, else - 0 self.matches, genome_names = blat_NLMSA.parse_blat(self.buf, self.aln_type) self.db = translationDB.get_translation_db(self.destDB) alignment = cnestedlist.NLMSA('test', mode='memory', pairwiseMode=True, bidirectional=False) self.temp_nlmsa = blat_NLMSA.create_NLMSA_blat(self.buf, alignment, aln_type = self.aln_type, srcDB = self.srcDB, destDB = self.db)
def setUp(self): self.buf = open('data/output.psl').read() self.buf = self.buf.replace("\r\n","\n") thisdir = os.path.abspath(os.path.dirname(__file__)) self.db = seqdb.SequenceFileDB(os.path.join(thisdir, 'data/test_genomes.fna')) self.aln_type = 0 #if protein-dna-1,else-0 matches, genome_names = blat_NLMSA.parse_blat(self.buf, self.aln_type) alignment = cnestedlist.NLMSA('test', mode='memory', seqDict=self.db, use_virtual_lpo=True) self.temp_nlmsa = blat_NLMSA.create_NLMSA_blat(self.buf, alignment, seqDB=self.db)
def setUp(self): self.buf = open('data/output.psl').read() self.buf = self.buf.replace("\r\n","\n") thisdir = os.path.abspath(os.path.dirname(__file__)) def thisfile(name): return os.path.join(thisdir, name) self.srcDB = seqdb.SequenceFileDB(thisfile('data/test_genomes.fna')) self.destDB = seqdb.SequenceFileDB(thisfile('data/test_genomes.fna')) self.protDNAaln = False #if protein-dna alignment - True,else- False matches, genome_names = blat_NLMSA.parse_blat(self.buf, self.protDNAaln) alignment = cnestedlist.NLMSA('test', mode='memory', seqDict=self.srcDB, use_virtual_lpo=True) #alignment = cnestedlist.NLMSA('test', mode='memory', pairwiseMode=True, #bidirectional=False)???????? self.temp_nlmsa = blat_NLMSA.create_NLMSA_blat(self.buf, alignment, self.srcDB, self.destDB, self.protDNAaln)