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

Running error #5

Open
hzlzldr opened this issue Feb 6, 2020 · 4 comments
Open

Running error #5

hzlzldr opened this issue Feb 6, 2020 · 4 comments

Comments

@hzlzldr
Copy link

hzlzldr commented Feb 6, 2020

hi,

I ran it according to your sample code in quick start, and the following error occurred. Have you run it by yourself?

Looking forward to your reply and code fixes!

genomedisco run_all --metadata_samples examples/metadata.samples --metadata_pairs examples/metadata.pairs --bins examples/Bins.w50000.bed.gz --outdir examples/output
Traceback (most recent call last):
File "/data5/huanglu/miniconda3/bin/genomedisco", line 11, in
load_entry_point('genomedisco', 'console_scripts', 'genomedisco')()
File "/data4/lzl/genomedisco/genomedisco/main.py", line 17, in main
command_methodscommand
File "/data4/lzl/genomedisco/genomedisco/concordance_utils.py", line 847, in run_all
preprocess(metadata_samples,bins,re_fragments,methods,outdir,running_mode,subset_chromosomes,parameters_file,timing)
File "/data4/lzl/genomedisco/genomedisco/concordance_utils.py", line 150, in preprocess
write_resolution(nodes,resolution_file)
File "/data4/lzl/genomedisco/genomedisco/concordance_utils.py", line 115, in write_resolution
items=line.strip().split('\t')
TypeError: a bytes-like object is required, not 'str'

@oursu
Copy link
Collaborator

oursu commented Feb 6, 2020

Hi! One suggestion I have is to make sure you are using python2, as recommended in the Readme. If that does not solve the issue, please let me know here and I am happy to continue helping to troubleshoot.

@hzlzldr hzlzldr closed this as completed Feb 7, 2020
@hzlzldr hzlzldr reopened this Feb 7, 2020
@hzlzldr
Copy link
Author

hzlzldr commented Feb 7, 2020

it does not work with py2


(base) huanglu 22:46:00 /data4/lzl/genomedisco
python --version
Python 2.7.15+

(base) huanglu 22:46:00 /data4/lzl/genomedisco
$ genomedisco run_all --metadata_samples examples/metadata.samples --metadata_pairs examples/metadata.pairs --bins examples/Bins.w50000.bed.gz --outdir examples/output
Traceback (most recent call last):
File "/data5/huanglu/miniconda3/bin/genomedisco", line 11, in
load_entry_point('genomedisco', 'console_scripts', 'genomedisco')()
File "/data4/lzl/genomedisco/genomedisco/main.py", line 17, in main
command_methodscommand
File "/data4/lzl/genomedisco/genomedisco/concordance_utils.py", line 847, in run_all
preprocess(metadata_samples,bins,re_fragments,methods,outdir,running_mode,subset_chromosomes,parameters_file,timing)
File "/data4/lzl/genomedisco/genomedisco/concordance_utils.py", line 150, in preprocess
write_resolution(nodes,resolution_file)
File "/data4/lzl/genomedisco/genomedisco/concordance_utils.py", line 115, in write_resolution
items=line.strip().split('\t')
TypeError: a bytes-like object is required, not 'str'

@oursu-broad
Copy link

I'm still worried it calls the python3 version because of /data5/huanglu/miniconda3/bin/genomedisco

@QichenFU
Copy link

Hi! One suggestion I have is to make sure you are using python2, as recommended in the Readme. If that does not solve the issue, please let me know here and I am happy to continue helping to troubleshoot.

May I ask how to run the command using python2 rather than python3 since it calls python3 by default?

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

4 participants