Skip to content

Commit

Permalink
RFCT Slightly better function name
Browse files Browse the repository at this point in the history
  • Loading branch information
luispedro committed Aug 7, 2023
1 parent 6baac44 commit 19793d0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions argnorm/normalizers.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

_ROOT = os.path.abspath(os.path.dirname(__file__))

def get_data(path):
def get_data_path(path):
return os.path.join(_ROOT, 'data', path)


Expand Down Expand Up @@ -72,7 +72,7 @@ def get_aro_mapping_table(self):
"""
Don't customize this unless you're using your own (not package built-in) reference data.
"""
df = pd.read_csv(get_data(f'{self.tool}_{self.database}_{self.mode}_ARO_mapping.tsv'), sep='\t', index_col=0)
df = pd.read_csv(get_data_path(f'{self.tool}_{self.database}_{self.mode}_ARO_mapping.tsv'), sep='\t', index_col=0)
if self.tool != 'argsoap' or self.mode != 'orfs':
df[TARGET_ARO_COL] = df[TARGET_ARO_COL].map(lambda a: f'ARO:{int(a) if a == a else "nan"}') # a == a checks that a is not nan
return df
Expand Down

0 comments on commit 19793d0

Please sign in to comment.