rdpstaff / RDPTools

Collection of commonly used RDP Tools for easy building
49 stars 52 forks source link

dependency on commons/io/ #8

Closed colinbrislawn closed 8 years ago

colinbrislawn commented 8 years ago

Good afternoon,

I've just deployed the RDP Tools as directed. I'm having trouble using them.

This command works fine.

java -Xmx1g -jar /Users/bris469/anaconda/envs/_test/bin/classifier.jar
USAGE: ClassifierMain <subcommand> <subcommand args ...>
default command is classify
    classify      - classify one or multiple samples
    crossvalidate - cross validate accuracy testing
...

This command fails:

(root)WE2292:recipes bris469$ java -Xmx1g -jar /Users/bris469/anaconda/envs/_test/bin/classifier.jar classify -c 0.5 -o usga_classified.txt -h soil_hier.txt /Users/bris469/anaconda/conda-bld/work/classifier/samplefiles/USGA_2_4_B_trimmed.fasta
Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/commons/io/output/NullWriter
    at edu.msu.cme.rdp.classifier.cli.ClassifierMain.main(ClassifierMain.java:65)
Caused by: java.lang.ClassNotFoundException: org.apache.commons.io.output.NullWriter
    at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
    at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
    ... 1 more

(The path to the .fasta file is correct.)

colinbrislawn commented 8 years ago

I've tested out some other functions, and think this is due to me not haveing Apache Commons installed. I guess I should rephrase my question:

Which Apache Commons dependancies does RDP Tools need? How do I go about installing them from the command line?

Thanks!

colinbrislawn commented 8 years ago

@rdpstaffmsu @wangqion Any updates to this? We are interested in incorporating this soon.

Thank you for your time, Colin

rdpstaffmsu commented 8 years ago

Hi Colin,

I would like to start a fresh installation, if that is possible, using the following commands:

  1. git clone https://github.com/rdpstaff/RDPTools.git
  2. cd to RDPTools
  3. git submodule init
  4. git submodule update
  5. make
  6. Wait for the compiling to finish

sincerely, Santosh

On Wed, Dec 9, 2015 at 1:25 AM, Colin Brislawn notifications@github.com wrote:

@rdpstaffmsu https://github.com/rdpstaffmsu @wangqion https://github.com/wangqion Any updates to this? We are interested in incorporating this soon.

Thank you for your time, Colin

— Reply to this email directly or view it on GitHub https://github.com/rdpstaff/RDPTools/issues/8#issuecomment-163123826.

RDP Staff Ribosomal Database Project Center for Microbial Ecology Michigan State University 567 Wilson Rd. Room 2225 A East Lansing, MI 48824 (517) 353-3842

wangqion commented 8 years ago

When you run make, it should automatically retrieve the correct jars specified in the file "ivy.xml" inside the classifier package and place the jar files into the designated places.

I saw you used command: /Users/bris469/anaconda/envs/_test/bin/classifier.jar

I suggest you put the entire RDPTools in your /Users/bris469/anaconda/envs/_test/bin/directory.

If you want to copy the compiled jars from RDPTools directory to a different location, make sure you also copy the lib directory inside RDPTools. The lib contains the jars the Classifier and other RDP tools need.

The jars needed by classifier.jar are these: AlignmentTools.jar ReadSeq.jar TaxonomyTree.jar commons-cli-1.2.jar commons-io-2.4.jar jcommon-1.0.16.jar jfreechart-1.0.13.jar

colinbrislawn commented 8 years ago

make sure you also copy the lib directory inside RDPTools

Ah ha! Thank you for this guidance. I'll try it now.

colinbrislawn commented 8 years ago

Works great! Thank you all.