-
Notifications
You must be signed in to change notification settings - Fork 0
Perl Cocument Ingestion Services
See the file doc/IngestionSystem.doc on how to install and use the ingestion services.
All services except DOIServer can be run as standalone perl scripts instead of through a web service.
This is great when testing if everything works as expected.
I couldn't get FileConversion to work using PDFBox because I got an error about FontBox classes not being available even though the FontBox jar file was in the classpath.
The solution to this was to change the following in Config.pm:
$PDFBoxLocation = "$FindBin::Bin/../converters/PDFBox/PDFBox-0.7.3.jar";
to
$PDFBoxLocation = "$FindBin::Bin/../converters/PDFBox/PDFBox-0.7.3.jar:path/to/FontBox.jar";
This worked because the variable $PDFBoxLocation is being used as a classpath variable when running the service. (using java -cp)
When trying to run HeaderParserService to extract the header from each paper, I got the following error:
./svm_learn: cannot execute binary file. ./svm_classify: cannot execute binary file.
This is because the provided svm_classify and svm_learn are compiled for a 32bit architecture. I was trying to run this on a 64bit architecture, thus the error. If you are trying to run this on 64bit architecture follow the instructions below:
-
Download SVM-Light from svmlight.joachims.org and save it in a directory. (i.e /tmp):
curl -k -L http://download.joachims.org/svm_light/v5.00/svm_light.tar.gz > /tmp/svm_light.tar.gzMake sure you download version 5.00 because CiteSeerX expects this version.
-
Extract and build svm_light:
mkdir svm_light cd svm_light tar -zxvf /tmp/svm_light.tar.gz make -
Replace svm_learn and svm_classify:
rm -f /path/to/CiteSeerHeaderParser/svm-light/svm_classify /path/to/CiteSeerHeaderParser/svm-light/svm_learn install -m 555 ./svm_learn /path/to/CiteSeerHeaderParser/svm-light/ install -m 555 ./svm_classify /path/to/CiteSeerHeaderParser/svm-light/
The "cannot execute binary file." error should now disappear.
I had some problems running the web services because after obtaining SOAP::Lite for perl I was getting a "Wrong SOAP version specified" reply. I realised it was a newer version than what the original citeseerx team based their web services on. So, to make the older code work with the newer version of SOAP::Lite add the following to the client file of each service:
To deal with "Wrong SOAP version specified" error:
1) Find the line 'my $service = SOAP::Lite' in [service name]-client.pl
and add "-> soapversion('1.2')" between the "->service" and "-> on_fault" lines
2) add the following lines to [service name]-client.pl
#- Overriding the constant for SOAP 1.2
$SOAP::Constants::DEFAULT_HTTP_CONTENT_TYPE
= 'application/soap+xml';