comparison TAXID_genusexpand_taxid2acc.py @ 11:3d116861e380 draft

Uploaded 14 03 23 def load_taxids fix bug chacking empty line
author p.lucas
date Tue, 14 Mar 2023 08:17:06 +0000
parents 5a4ac43fea68
children 19e175a84d0e
comparison
equal deleted inserted replaced
10:5a4ac43fea68 11:3d116861e380
190 " file does not exist, line "+ str(sys._getframe().f_lineno) ) 190 " file does not exist, line "+ str(sys._getframe().f_lineno) )
191 191
192 cmd = "cut -f 1,2 "+taxid_acc_tabular_f+" | sort | uniq " 192 cmd = "cut -f 1,2 "+taxid_acc_tabular_f+" | sort | uniq "
193 193
194 for line in os.popen(cmd).readlines(): 194 for line in os.popen(cmd).readlines():
195 if line != "": 195 if line.rstrip() != "":
196 k, v = line.rstrip().split() 196 k, v = line.rstrip().split()
197 taxidlist.append(k) 197 taxidlist.append(k)
198 accnrlist.append(v) 198 accnrlist.append(v)
199 199
200 return taxidlist 200 return taxidlist