other_gbk_folder =os.path.abspath('data/input/other/') exp_name = datetime.datetime.now().strftime('%Y%m%d%H%M') mongo_init(exp_name) reset_database(exp_name) new_folder = 'data/output/{0}/'.format(exp_name) if not os.path.isdir(new_folder): os.makedirs(new_folder) os.chdir(new_folder) print 'Checking and importing core genomes...' for the_file in os.listdir(core_gbk_folder): path_to_file = '{0}/{1}'.format(core_gbk_folder, the_file) DataImport.import_file(path_to_file, 'core') print 'Checking and importing other genomes...' for the_file in os.listdir(other_gbk_folder): path_to_file = '{0}/{1}'.format(other_gbk_folder, the_file) DataImport.import_file(path_to_file, 'other') KvasirBlast.make_blast_db('core') KvasirBlast.make_blast_db('other') KvasirBlast.core_hgt_blast(perc_identity='90') # KvasirBlast.core_hgt_blast(perc_identity='95') # KvasirBlast.core_hgt_blast(perc_identity='99') KvasirBlast.blast_to_db(perc_identity='90') # KvasirBlast.blast_to_db(perc_identity='95')