Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AttributeError: 'float' object has no attribute 'split' #2

Open
wenyuhaokikika opened this issue Nov 23, 2022 · 0 comments
Open

AttributeError: 'float' object has no attribute 'split' #2

wenyuhaokikika opened this issue Nov 23, 2022 · 0 comments

Comments

@wenyuhaokikika
Copy link

when i run

In [4]: fp = 'data-raw/cellline2pubtatorcentral.gz'
   ...: fc = 'data-raw/cellosaurus.txt'
   ...: fh = 'data-raw/HIPPIE.mitab'

In [5]: ppictx.process_raw_data(fh, fp, fc)

it raise Exception

  ~ [PID -> CLA]
  ~ [CLA -> CID]
  ~ [PPI -> PID -> CLA -> CID]
---------------------------------------------------------------------------
AttributeError                            Traceback (most recent call last)
Cell In [5], line 1
----> 1 ppictx.process_raw_data(fh, fp, fc)

File ~/code/someProject/ppi-context/ppictx/routine.py:66, in process_raw_data(fh, fp, fc)
     64 pid_cla = ppictx.process_pid_cla(fp)
     65 cla_cid = ppictx.process_cla_cid(fc)
---> 66 df, logs = process_ppi_cid(ppi, pid_cla, cla_cid)
     67 ppictx.logging_ppi_cid(df, logs)

File ~/code/someProject/ppi-context/ppictx/routine.py:22, in process_ppi_cid(ppi, pid_cla, cla_cid)
     18 # Check if publications exist
     19 if ids != '-':
     20 
     21     # For each publication reporting this interaction
---> 22     pids = ppictx.split_ids(ids)
     23     for pid in pids:
     24         log[pid] = {}

File ~/code/someProject/ppi-context/ppictx/utils.py:13, in split_ids(ids)
     12 def split_ids(ids):
---> 13     pids = [j.lstrip('pubmed:') for j in ids.split('|')]
     14     return pids

AttributeError: 'float' object has no attribute 'split'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant