From 0c1bf811a12d83436ae8acdfd1345d5294ba3606 Mon Sep 17 00:00:00 2001 From: Luis Pedro Coelho Date: Thu, 25 Apr 2024 17:21:50 +1000 Subject: [PATCH] ENH Update data load in api.py --- website/api.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/website/api.py b/website/api.py index 51cf271..62c5f9c 100644 --- a/website/api.py +++ b/website/api.py @@ -37,10 +37,8 @@ def predict(): try: subprocess.check_call(args) tfile = path.join(tdir, 'macrel.out', 'macrel.out.prediction.gz') - data = pd.read_table(tfile) - data.rename(inplace=True, columns={ - 'Unnamed: 0': 'access', - 'group': 'amp_family',}) + data = pd.read_table(tfile, comment='#') + # is_AMP is a boolean, but is of type bool_ which is not JSON # serializable. Since it's redundant with AMP_probability, we can