hello eveybody,
I have to use CRF package that I have downloaded. I use Ubuntu 11.10 as an OS.
I had installed JDK 6 and ANT 1.8.3. And I want to run the sample given in the README file.
There is a .sh file that I have to run, but first I have to set the CRF_HOME to the directory to where I have the program.
This is the .sh file:
# settings for CRF..
# Check if CRF_HOME is set
if [ ! ${CRF_HOME} ]; then
echo "CRF_HOME is not set. Using default as current working directory."
export CRF_HOME=.
fi
echo "Using CRF_HOME=${CRF_HOME}"
# Setting the classpath variable
for file in `ls $CRF_HOME/lib/*.jar`
do
export CLASSPATH=$file:$CLASSPATH
done
For running the exemple, I proceed as follows:
amira@amira-VirtualBox:~$ export CRF_HOME=/home/amira/CRF
amira@amira-VirtualBox:~$ cd /home/amira/CRF
amira@amira-VirtualBox:~/CRF$ ./settings.sh
amira@amira-VirtualBox:~/CRF$ java iitb.Segment.Segment train -f samples/us50.conf
But I have the following response:
Exception in thread "main" java.lang.NoClassDefFoundError: iitb/Segment/Segment
Caused by: java.lang.ClassNotFoundException: iitb.Segment.Segment
at java.net.URLClassLoader$1.run(URLClassLoader.java:217)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:205)
at java.lang.ClassLoader.loadClass(ClassLoader.java:321)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:294)
at java.lang.ClassLoader.loadClass(ClassLoader.java:266)
Could not find the main class: iitb.Segment.Segment. Program will exit.
Could you help me to solve this problem.