Re: [galaxy-dev] wolfpsort
Hello again, I cannot launch it manually neither. It gives me the same error… :
runWolfPsortSummary animal test.fasta
Can't locate fastafmt/GetOptWarnHandler.pm in @INC (you may need to install the fastafmt::GetOptWarnHandler module) (@INC contains: /etc/perl /usr/local/lib/perl/5.18.2 /usr/local/share/perl/5.18.2 /usr/lib/perl5 /usr/share/perl5 /usr/lib/perl/5.18 /usr/share/perl/5.18 /usr/local/lib/site_perl . /bin) at /bin/runWolfPsortSummary line 37.
BEGIN failed--compilation aborted at /bin/runWolfPsortSummary line 37. I think i missed something somewhere. Any lead? thanks De : Peter Cock [mailto:p.j.a.cock@googlemail.com] Envoyé : mercredi 2 décembre 2015 18:59 À : Olivier CLAUDE <o.claude@outlook.fr> Cc : galaxy-dev@lists.galaxyproject.org; Björn Grüning <bjoern.gruening@gmail.com> Objet : Re: [galaxy-dev] 3 questions On Wed, Dec 2, 2015 at 5:07 PM, Olivier CLAUDE < <mailto:o.claude@outlook.fr> o.claude@outlook.fr> wrote: Hello again, 1/ I managed to find WolfPsort on github. You mean <https://github.com/fmaguire/WoLFPSort> https://github.com/fmaguire/WoLFPSort ? I can see why Finlay Maguire did that although I'm not 100% sure that is within the licence. In other news, it looks like someone else has bought the domain <http://wolfpsort.org/> http://wolfpsort.org/ and is holding it to random (for sale, offers over $1190). Oh dear. :( I followed the readme file and it work with the command line but when I tried to run it on galaxy with the one included in the package “tmhmm and signal” from peterjc, it gave me an error: “can’t locate fastafmt/GetOptWarnHandler.pm” I put in my .bashrc the path of the file. I tried to put it directly in the /bin directory but it didn’t change anything. Any idea anyone? Have you followed the INSTALL file instructions? Have you been able to run WolfPsort at the command line? Note it only has precompiled binaries under bin/binByPlatform for i386 and sparc, however we could use the 32bit binaries on our 64bit Linux machine. According to my old comment inside the Python wrapper script for Galaxy, I had trouble running the tool from outside its home directory and so used a simple (second) wrapper script to change directory before running the real binary. See: <https://github.com/peterjc/pico_galaxy/blob/master/tools/protein_analysis/wolf_psort.py#L43> https://github.com/peterjc/pico_galaxy/blob/master/tools/protein_analysis/wo... 2/in the python script I can see: Num_thread = thread_count(sys.argv[2], default=4) Does it means that it will use at the maximum 4 threads? Can I assume it will use 4 core in parallel? This means my Python wrapper script will default to 4 threads if not specified via the command line. When called via Galaxy, the XML wrapper will use the $GALAXY_SLOTS environment variable (if set). See the job runner settings taken from job_conf.xml for details. This means unless you've setup something special in Galaxy for the number of slots/threads to use, the tool will default to four threads. This means it will break up the input file into chunks and run four copies of the single threaded tool runWolfPsortSummary at once. 3/I use blast + from the devteam is there any possibility to use more than 1 core? If yes where? Thanks ! Again, the BLAST+ wrappers will use the $GALAXY_SLOTS environment variable (if set), although here they default to using calling BLAST+ with 8 threads. Peter
Hi Olivier, First of all, let's double check what kind of machine you are running, in case that gives us some clues: $ arch $ uname -a Let's double check which Perl you have, $ which perl $ perl -v $ /usr/bin/perl -v NOTE: You have to pipe the input file into this tool, it does not take the input argument as a filename: $ runWolfPsortSummary animal test.fasta Command Line Parsing Error; Do not know what to do with argument "test.fasta" Usage: runWolfPsortSummary [*OPTIONS*] *organismType* runWolfPsortSummary (--usage|--help|--man) Pipe sequences in from standard in. In your case it seems to be failing to even give this error message, apparently due to not finding one of the Perl files it comes with, line 37 is: use fastafmt::GetOptWarnHandler; Question: Where did you put the tool? Is there a .../bin/fastafmt/ folder? Is there are .../bin/fastafmt/GetOptWarnHandler.pm file? What happens if you try to do this: $ cd /path/you/put/wolfpsort $ ./runWolfPsortSummary OrganismType should be one of {"fungi", "plant", "animal"} pipe fasta query sequences in from standard in Usage: runWolfPsortSummary [*OPTIONS*] *organismType* runWolfPsortSummary (--usage|--help|--man) Pipe sequences in from standard in. Or, with a real test - for example using one of the test files I often use: $ cd /path/you/put/wolfpsort $ ./runWolfPsortSummary animal < ~/repositories/pico_galaxy/test-data/four_human_proteins.fasta # k used for kNN is: 32 sp|Q9BS26|ERP44_HUMAN extr 18, E.R. 5, plas 3, mito 2, lyso 2 sp|Q9NSY1|BMP2K_HUMAN nucl 25, cyto_nucl 17, cyto 7 sp|P06213|INSR_HUMAN extr_plas 11.5, plas 10.5, extr 9.5, pero 5, E.R. 4 sp|P08100|OPSD_HUMAN plas 32 Regards, Peter On Fri, Dec 4, 2015 at 9:13 AM, Olivier CLAUDE <o.claude@outlook.fr> wrote:
Hello again,
I cannot launch it manually neither. It gives me the same error… :
runWolfPsortSummary animal test.fasta
Can't locate fastafmt/GetOptWarnHandler.pm in @INC (you may need to install the fastafmt::GetOptWarnHandler module) (@INC contains: /etc/perl /usr/local/lib/perl/5.18.2 /usr/local/share/perl/5.18.2 /usr/lib/perl5 /usr/share/perl5 /usr/lib/perl/5.18 /usr/share/perl/5.18 /usr/local/lib/site_perl . /bin) at /bin/runWolfPsortSummary line 37.
BEGIN failed--compilation aborted at /bin/runWolfPsortSummary line 37.
I think i missed something somewhere. Any lead?
thanks
Hi Peter, Thanks for all. $ arch
x86_64
$ uname -a >Linux LM1166 3.16.0-38-generic #52~14.04.1-Ubuntu SMP Fri May 8 09:43:57 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux $ which perl >/usr/bin/perl $ perl -v > This is perl 5, version 18, subversion 2 (v5.18.2) built for x86_64-linux-gnu-thread-multi (with 41 registered patches, see perl -V for more detail) (...) $ /usr/bin/perl -v > This is perl 5, version 18, subversion 2 (v5.18.2) built for x86_64-linux-gnu-thread-multi (with 41 registered patches, see perl -V for more detail) (...) NOTE: You have to pipe the input file into this tool, it does not take the input argument as a filename: $ runWolfPsortSummary animal test.fasta Command Line Parsing Error; Do not know what to do with argument "test.fasta" Usage: runWolfPsortSummary [*OPTIONS*] *organismType* runWolfPsortSummary (--usage|--help|--man) Pipe sequences in from standard in. In your case it seems to be failing to even give this error message, apparently due to not finding one of the Perl files it comes with, line 37 is: use fastafmt::GetOptWarnHandler; Question: Where did you put the tool? Is there a .../bin/fastafmt/ folder? Is there are .../bin/fastafmt/GetOptWarnHandler.pm file? I did not changed the structure of the tools as you recommanded it in the python script. olivier@LM1166 ~/galaxy/CBS/WoLFPSort-master/bin $ ls binByPlatform psortModifiedForWolfFiles runWolfPsortSummary.py checkFastaInput.pl README test.fasta fastafmt runAddAlignmentToHtml testQuery.fasta GetOptWarnHandler.pm runWolfPsortHtmlTables wolfPredict pod runWolfPsortSummary WoLFPSORTpredictAndAlign olivier@LM1166 ~/galaxy/CBS/WoLFPSort-master/bin/fastafmt $ ls GetOptWarnHandler.pm What happens if you try to do this: $ cd /path/you/put/wolfpsort $ ./runWolfPsortSummary animal <~/repositories/pico_galaxy/test-data/four_human_proteins.fasta It gives me : olivier@LM1166 ~/galaxy/CBS/WoLFPSort-master/bin $ runWolfPsortSummary animal <~/galaxy/test-data/four_human_proteins.fasta sh: 1: /bin/checkFastaInput.pl: not found sh: 1: /bin/psortModifiedForWolfFiles/psortModifiedForWoLF: not found /home/paulh/cbrcRepos/C++/utils/argvParsing/ArgvParser.hh:291 Error opening file: "/bin/../data//animal.wolfw" Usage: /bin/wolfPredict [OPTIONS] weightFile trainingDataFile utilityMatrixFile I tried with different options : olivier@LM1166 ~/galaxy/CBS/WoLFPSort-master/bin $ runWolfPsortSummary --print-neighbors animal <~/galaxy/test-data/four_human_proteins.fasta sh: 1: /bin/checkFastaInput.pl: not found sh: 1: /bin/psortModifiedForWolfFiles/psortModifiedForWoLF: not found /home/paulh/cbrcRepos/C++/utils/argvParsing/ArgvParser.hh:291 Error opening file: "/bin/../data//animal.wolfw" Usage: /bin/wolfPredict [OPTIONS] weightFile trainingDataFile utilityMatrixFile Or olivier@LM1166 ~/galaxy/CBS/WoLFPSort-master/bin $ runWolfPsortSummary --print-all-score animal <~/galaxy/test-data/four_human_proteins.fasta Error in parsing command line. Perhaps problem with "--print-all-score" Usage: runWolfPsortSummary [*OPTIONS*] *organismType* runWolfPsortSummary (--usage|--help|--man) Pipe sequences in from standard in Regards, Olivier -----Message d'origine----- De : Peter Cock [mailto:p.j.a.cock@googlemail.com] Envoyé : vendredi 4 décembre 2015 11:16 À : Olivier CLAUDE <o.claude@outlook.fr> Cc : galaxy-dev@lists.galaxyproject.org Objet : Re: [galaxy-dev] wolfpsort Hi Olivier, First of all, let's double check what kind of machine you are running, in case that gives us some clues: $ arch $ uname -a Let's double check which Perl you have, $ which perl $ perl -v $ /usr/bin/perl -v NOTE: You have to pipe the input file into this tool, it does not take the input argument as a filename: $ runWolfPsortSummary animal test.fasta Command Line Parsing Error; Do not know what to do with argument "test.fasta" Usage: runWolfPsortSummary [*OPTIONS*] *organismType* runWolfPsortSummary (--usage|--help|--man) Pipe sequences in from standard in. In your case it seems to be failing to even give this error message, apparently due to not finding one of the Perl files it comes with, line 37 is: use fastafmt::GetOptWarnHandler; Question: Where did you put the tool? Is there a .../bin/fastafmt/ folder? Is there are .../bin/fastafmt/GetOptWarnHandler.pm file? What happens if you try to do this: $ cd /path/you/put/wolfpsort $ ./runWolfPsortSummary OrganismType should be one of {"fungi", "plant", "animal"} pipe fasta query sequences in from standard in Usage: runWolfPsortSummary [*OPTIONS*] *organismType* runWolfPsortSummary (--usage|--help|--man) Pipe sequences in from standard in. Or, with a real test - for example using one of the test files I often use: $ cd /path/you/put/wolfpsort $ ./runWolfPsortSummary animal < ~/repositories/pico_galaxy/test-data/four_human_proteins.fasta # k used for kNN is: 32 sp|Q9BS26|ERP44_HUMAN extr 18, E.R. 5, plas 3, mito 2, lyso 2 sp|Q9NSY1|BMP2K_HUMAN nucl 25, cyto_nucl 17, cyto 7 sp|P06213|INSR_HUMAN extr_plas 11.5, plas 10.5, extr 9.5, pero 5, E.R. 4 sp|P08100|OPSD_HUMAN plas 32 Regards, Peter On Fri, Dec 4, 2015 at 9:13 AM, Olivier CLAUDE <o.claude@outlook.fr> wrote:
Hello again,
I cannot launch it manually neither. It gives me the same error… :
runWolfPsortSummary animal test.fasta
Can't locate fastafmt/GetOptWarnHandler.pm in @INC (you may need to install the fastafmt::GetOptWarnHandler module) (@INC contains: /etc/perl /usr/local/lib/perl/5.18.2 /usr/local/share/perl/5.18.2 /usr/lib/perl5 /usr/share/perl5 /usr/lib/perl/5.18 /usr/share/perl/5.18 /usr/local/lib/site_perl . /bin) at /bin/runWolfPsortSummary line 37.
BEGIN failed--compilation aborted at /bin/runWolfPsortSummary line 37.
I think i missed something somewhere. Any lead?
thanks
On Fri, Dec 4, 2015 at 11:19 AM, Olivier CLAUDE <o.claude@outlook.fr> wrote:
Hi Peter, Thanks for all.
...
What happens if you try to do this:
$ cd /path/you/put/wolfpsort $ ./runWolfPsortSummary animal <~/repositories/pico_galaxy/test-data/four_human_proteins.fasta
It gives me :
olivier@LM1166 ~/galaxy/CBS/WoLFPSort-master/bin $ runWolfPsortSummary animal <~/galaxy/test-data/four_human_proteins.fasta sh: 1: /bin/checkFastaInput.pl: not found sh: 1: /bin/psortModifiedForWolfFiles/psortModifiedForWoLF: not found /home/paulh/cbrcRepos/C++/utils/argvParsing/ArgvParser.hh:291 Error opening file: "/bin/../data//animal.wolfw" Usage: /bin/wolfPredict [OPTIONS] weightFile trainingDataFile utilityMatrixFile
That's not what I meant, there is a small but important difference. Just runWolfPsortSummary will search the $PATH for runWolfPsortSummary script. I wanted you to use ./runWolfPsortSummary with a dot slash at the start which means look in the current director for the runWolfPsortSummary script. Please try: $ cd ~/galaxy/CBS/WoLFPSort-master/bin $ ./runWolfPsortSummary animal <~/galaxy/test-data/four_human_proteins.fasta Peter
Ok i did not saw it. I runned it with ./ and it worked fine. It gave me the same answer you gave me earlier. Olivier -----Message d'origine----- De : Peter Cock [mailto:p.j.a.cock@googlemail.com] Envoyé : vendredi 4 décembre 2015 12:40 À : Olivier CLAUDE <o.claude@outlook.fr> Cc : galaxy-dev@lists.galaxyproject.org Objet : Re: [galaxy-dev] wolfpsort On Fri, Dec 4, 2015 at 11:19 AM, Olivier CLAUDE <o.claude@outlook.fr> wrote:
Hi Peter, Thanks for all.
...
What happens if you try to do this:
$ cd /path/you/put/wolfpsort $ ./runWolfPsortSummary animal <~/repositories/pico_galaxy/test-data/four_human_proteins.fasta
It gives me :
olivier@LM1166 ~/galaxy/CBS/WoLFPSort-master/bin $ runWolfPsortSummary animal <~/galaxy/test-data/four_human_proteins.fasta sh: 1: /bin/checkFastaInput.pl: not found sh: 1: /bin/psortModifiedForWolfFiles/psortModifiedForWoLF: not found /home/paulh/cbrcRepos/C++/utils/argvParsing/ArgvParser.hh:291 Error opening file: "/bin/../data//animal.wolfw" Usage: /bin/wolfPredict [OPTIONS] weightFile trainingDataFile utilityMatrixFile
That's not what I meant, there is a small but important difference. Just runWolfPsortSummary will search the $PATH for runWolfPsortSummary script. I wanted you to use ./runWolfPsortSummary with a dot slash at the start which means look in the current director for the runWolfPsortSummary script. Please try: $ cd ~/galaxy/CBS/WoLFPSort-master/bin $ ./runWolfPsortSummary animal <~/galaxy/test-data/four_human_proteins.fasta Peter
On Fri, Dec 4, 2015 at 12:59 PM, Olivier CLAUDE <o.claude@outlook.fr> wrote:
Ok i did not saw it. I runned it with ./ and it worked fine. It gave me the same answer you gave me earlier.
Olivier
Excellent :) So, this matches what I found - as long as I changed to the Wolf PSORT directory first, runWolfPsortSummary worked OK. If I just put the runWolfPsortSummary bin folder on the $PATH, then it failed. Perhaps there is a small step in the instructions we both missed? I suggest you try my workaround, which I linked to before: https://github.com/peterjc/pico_galaxy/blob/master/tools/protein_analysis/wo... (1) put runWolfPsortSummary somewhere where your cluster nodes and Galaxy can see it. I used the folder /opt/WoLFPSORT_package_v0.2/ meaning /opt/WoLFPSORT_package_v0.2/bin/runWolfPsortSummary is the script itself. Your folder ~/galaxy/CBS/WoLFPSort-master/ would be fine. (2) Using a text editor (emacs, nano, vi, etc) create a new file named runWolfPsortSummary (without an extension) somewhere on your path, I suggest ~/bin/runWolfPsortSummary $ emacs ~/bin/runWolfPsortSummary (3) Copy this into the ~/bin/runWolfPsortSummary file, #!/usr/bin/env python #Wrapper script to call WoLF PSORT from its own directory. import os import sys import subprocess saved_dir = os.path.abspath(os.curdir) os.chdir("/opt/WoLFPSORT_package_v0.2/bin") args = ["./runWolfPsortSummary"] + sys.argv[1:] return_code = subprocess.call(args) os.chdir(saved_dir) sys.exit(return_code) (3) Mark this wrapper script as executable: $ chmod a+x ~/bin/runWolfPsortSummary (4) Check ~/bin is on your path, so that using runWolfPsortSummary (without a leading dot slash) will run the new wrapper script: $ which runWolfPsortSummary ~/bin/runWolfPsortSummary (5) Test the new wrapper script from some other directory, e.g. $ cd ~ $ runWolfPsortSummary animal <~/galaxy/test-data/four_human_proteins.fasta (6) If that all works, then the Galaxy wrapper should work too. Peter
On Fri, Dec 4, 2015 at 2:16 PM, Peter Cock <p.j.a.cock@googlemail.com> wrote:
On Fri, Dec 4, 2015 at 12:59 PM, Olivier CLAUDE <o.claude@outlook.fr> wrote:
Ok i did not saw it. I runned it with ./ and it worked fine. It gave me the same answer you gave me earlier.
Olivier
Excellent :)
So, this matches what I found - as long as I changed to the Wolf PSORT directory first, runWolfPsortSummary worked OK.
If I just put the runWolfPsortSummary bin folder on the $PATH, then it failed.
Perhaps there is a small step in the instructions we both missed?
I suggest you try my workaround, which I linked to before: https://github.com/peterjc/pico_galaxy/blob/master/tools/protein_analysis/wo...
(1) put runWolfPsortSummary somewhere where your cluster nodes and Galaxy can see it. I used the folder /opt/WoLFPSORT_package_v0.2/ meaning /opt/WoLFPSORT_package_v0.2/bin/runWolfPsortSummary is the script itself.
Your folder ~/galaxy/CBS/WoLFPSort-master/ would be fine.
(2) Using a text editor (emacs, nano, vi, etc) create a new file named runWolfPsortSummary (without an extension) somewhere on your path, I suggest ~/bin/runWolfPsortSummary
$ emacs ~/bin/runWolfPsortSummary
(3) Copy this into the ~/bin/runWolfPsortSummary file,
#!/usr/bin/env python #Wrapper script to call WoLF PSORT from its own directory. import os import sys import subprocess saved_dir = os.path.abspath(os.curdir) os.chdir("/opt/WoLFPSORT_package_v0.2/bin") args = ["./runWolfPsortSummary"] + sys.argv[1:] return_code = subprocess.call(args) os.chdir(saved_dir) sys.exit(return_code)
Sorry, you'd need to change the change director line to match your setup. You can't use the tilde (~) or $HOME here, so something like this I guess: os.chdir("/home/xxxxx/galaxy/CBS/WoLFPSort-master/")
(3) Mark this wrapper script as executable:
$ chmod a+x ~/bin/runWolfPsortSummary
(4) Check ~/bin is on your path, so that using runWolfPsortSummary (without a leading dot slash) will run the new wrapper script:
$ which runWolfPsortSummary ~/bin/runWolfPsortSummary
(5) Test the new wrapper script from some other directory, e.g.
$ cd ~ $ runWolfPsortSummary animal <~/galaxy/test-data/four_human_proteins.fasta
(6) If that all works, then the Galaxy wrapper should work too.
Peter
I filed this as an issue on the GitHub mirror: https://github.com/fmaguire/WoLFPSort/issues/1 Peter
Everything is working fine now. I experienced problems : I forgot to delete some files this made a conflict. If anybody needs, the python script has to be in the bin folder of the computer not in the HOME folder (I've made a mistake with the tilde) Thanks again, normally I will not bother you anymore Peter. Regards, Olivier. -----Message d'origine----- De : Peter Cock [mailto:p.j.a.cock@googlemail.com] Envoyé : vendredi 4 décembre 2015 15:17 À : Olivier CLAUDE <o.claude@outlook.fr> Cc : galaxy-dev@lists.galaxyproject.org Objet : Re: [galaxy-dev] wolfpsort On Fri, Dec 4, 2015 at 12:59 PM, Olivier CLAUDE <o.claude@outlook.fr> wrote:
Ok i did not saw it. I runned it with ./ and it worked fine. It gave me the same answer you gave me earlier.
Olivier
Excellent :) So, this matches what I found - as long as I changed to the Wolf PSORT directory first, runWolfPsortSummary worked OK. If I just put the runWolfPsortSummary bin folder on the $PATH, then it failed. Perhaps there is a small step in the instructions we both missed? I suggest you try my workaround, which I linked to before: https://github.com/peterjc/pico_galaxy/blob/master/tools/protein_analysis/wo... (1) put runWolfPsortSummary somewhere where your cluster nodes and Galaxy can see it. I used the folder /opt/WoLFPSORT_package_v0.2/ meaning /opt/WoLFPSORT_package_v0.2/bin/runWolfPsortSummary is the script itself. Your folder ~/galaxy/CBS/WoLFPSort-master/ would be fine. (2) Using a text editor (emacs, nano, vi, etc) create a new file named runWolfPsortSummary (without an extension) somewhere on your path, I suggest ~/bin/runWolfPsortSummary $ emacs ~/bin/runWolfPsortSummary (3) Copy this into the ~/bin/runWolfPsortSummary file, #!/usr/bin/env python #Wrapper script to call WoLF PSORT from its own directory. import os import sys import subprocess saved_dir = os.path.abspath(os.curdir) os.chdir("/opt/WoLFPSORT_package_v0.2/bin") args = ["./runWolfPsortSummary"] + sys.argv[1:] return_code = subprocess.call(args) os.chdir(saved_dir) sys.exit(return_code) (3) Mark this wrapper script as executable: $ chmod a+x ~/bin/runWolfPsortSummary (4) Check ~/bin is on your path, so that using runWolfPsortSummary (without a leading dot slash) will run the new wrapper script: $ which runWolfPsortSummary ~/bin/runWolfPsortSummary (5) Test the new wrapper script from some other directory, e.g. $ cd ~ $ runWolfPsortSummary animal <~/galaxy/test-data/four_human_proteins.fasta (6) If that all works, then the Galaxy wrapper should work too. Peter
participants (2)
-
Olivier CLAUDE
-
Peter Cock