geraldinepascal / FROGS

FROGS is a galaxy/CLI workflow designed to produce an OTUs count matrix from high depth sequencing amplicon data.
GNU General Public License v3.0
24 stars 22 forks source link

test.sh fails in FROGS docker container #50

Closed cjuigne closed 4 years ago

cjuigne commented 4 years ago

Hi! I'm trying to use FROGS from the Docker container (https://bioconda.github.io/recipes/frogs/README.html) But when I want to verify everything works I get this issue :

/usr/local/share/FROGS-3.1.0/test # sh test.sh ../ 2 4 res
Step preprocess : Flash Tue Jun 23 11:54:06 UTC 2020
Step preprocess : Vsearch Tue Jun 23 11:56:08 UTC 2020
Step clustering Tue Jun 23 11:58:26 UTC 2020
Step remove_chimera Tue Jun 23 12:04:21 UTC 2020
Step filters Tue Jun 23 12:07:39 UTC 2020
Step ITSx Tue Jun 23 12:07:51 UTC 2020
Step affiliation_OTU Tue Jun 23 12:08:11 UTC 2020
ps: bad -o argument 'cpuid', supported arguments: user,group,comm,args,pid,ppid,pgid,tty,vsz,stat,rss
Traceback (most recent call last):
  File "..//app/affiliation_OTU.py", line 515, in <module>
    process_rdp( args.input_fasta, rdp_out_list[0], args.log_file, args.reference, args.java_mem)
  File "..//app/affiliation_OTU.py", line 378, in process_rdp
    rdp_cmd = RDPAffiliation(reference, input, output, memory)
  File "..//app/affiliation_OTU.py", line 171, in __init__
    "taskset -c " + self._get_cpu_id() + " java -Xmx" + str(memory) + "g -jar ##PROGRAM## classify -c 0.0 -t " + ref + ".properties -o " + output + " " + query_fasta,
  File "..//app/affiliation_OTU.py", line 178, in _get_cpu_id
    ps_stdout = subprocess.check_output('ps -o pid,cpuid', shell=True)
  File "/usr/local/lib/python2.7/subprocess.py", line 223, in check_output
    raise CalledProcessError(retcode, cmd, output=output)
subprocess.CalledProcessError: Command 'ps -o pid,cpuid' returned non-zero exit status 1
Error in affiliation_OTU

Could you help me with that? Thank you!

mariabernard commented 4 years ago

Hi,

thank you for trying FROGS.

I never used docker, and it seems that the very basic linux command ps -o pid,cpuid is the one that is not working in your docker environment. I am not sure that I will be able to help you more with that...

The deployment of your docker environment is automatic ? I mean it download FROGS and install all dependencies each time you launch it ? In the next release, we remove this part in the code because it as some other consequences in other environment like SLURM. So if it's not automatic, you could do the same change

So line 171 in /usr/local/share/FROGS-3.1.0/app/affiliation_OTU.py : "taskset -c " + self._get_cpu_id() + " java -Xmx" + str(memory) + "g -jar ##PROGRAM## classify -c 0.0 -t " + ref + ".properties -o " + output + " " + query_fasta, become : " java -Xmx" + str(memory) + "g -jar ##PROGRAM## classify -c 0.0 -t " + ref + ".properties -o " + output + " " + query_fasta,

This is not a very nice solution to change your self the FROGS code, but I don't know what else to tell you since I don't know technically docker.

Hope this will solved your problem

Maria

cjuigne commented 4 years ago

Hello Maria,

Yes, Docker packages an application and its dependencies in an isolated container, this allows to run the tool on any server without having to install all its dependencies. So yes the deployment is automatic but I can change files inside the container.

I changed /usr/local/share/FROGS-3.1.0/app/affiliation_OTU.py just like you said and it solved my problem ! Maybe, when the FROGS conda package updated it could work !

Thank you for your help !

Camille