File tree Expand file tree Collapse file tree 1 file changed +3
-5
lines changed Expand file tree Collapse file tree 1 file changed +3
-5
lines changed Original file line number Diff line number Diff line change @@ -203,9 +203,7 @@ def __init__(
203
203
if rank not in taxonomy .columns :
204
204
raise ValueError ("Missing the column `%s` from the taxonomy." % rank )
205
205
if "id" not in taxonomy .columns :
206
- taxonomy ["id" ] = taxonomy [rank ].str .replace (
207
- r"[^A-Za-z0-9_\s]+" , "_" , regex = True
208
- )
206
+ taxonomy ["id" ] = taxonomy [rank ]
209
207
keep_cols = [
210
208
r
211
209
for r in _ranks [0 : (_ranks .index (rank ) + 1 )]
@@ -225,7 +223,7 @@ def __init__(
225
223
)
226
224
logger .info (
227
225
"Matched %g%% of total abundance in model DB."
228
- % (100.0 * self .__db_metrics [3 ])
226
+ % (100.0 * self .__db_metrics . iloc [3 ])
229
227
)
230
228
if self .__db_metrics ["found_abundance_fraction" ] < 0.5 :
231
229
logger .warning (
@@ -236,7 +234,7 @@ def __init__(
236
234
taxonomy = merged
237
235
taxonomy ["abundance" ] /= taxonomy ["abundance" ].sum ()
238
236
239
- taxonomy .id = taxonomy .id .str .replace (r"[^A-Za-z0-9_\s ]+" , "_" , regex = True )
237
+ taxonomy .id = taxonomy .id .str .replace (r"[^A-Za-z0-9_]+" , "_" , regex = True )
240
238
241
239
self .__taxonomy = taxonomy
242
240
self .__taxonomy .index = self .__taxonomy .id
You can’t perform that action at this time.
0 commit comments