Closed remkop closed 4 years ago
GROBID is a large Java program which most people run as an executable jar or a web service. See https://grobid.readthedocs.io/en/latest/
I tried to link GROBID in at the Javas library level and it was an effort and not worth it (also bloated the distrib). GROBID is usually run as a service, but here we run in in Batch mode.
Batch mode relies on certain system variables being set. See
|https://grobid.readthedocs.io/en/latest/Grobid-batch/
so ami3
needs to know these. I think that's what @deadlyvices is talking about
From https://github.com/petermr/openVirus/issues/25, the goal is to
allow AMIGrobidTool to
I think that allowing the user to define where GROBID is , is enough. They have to copy/install GROBID but they're probably capable of that. IOW do we need to do something more ...?
I see now why this was a bit cumbersome: the grovid version appears in both the installation directory and in the path to the grovid jar. I fixed it by adding a number of options to the ami grobit
command.
If grobid is installed in $HOME/workspace/grobid/grobid-$GROBID_VERSION
, then just specifying --grobid-version=<VERSION>
is sufficient.
If grobid is installed elsewhere, users can specify --grobid-install-dir
. If they use a grobid version other than the default (0.5.3), they should also specify --grobid-version
.
Here is the full list of the new options:
--grobid-home=<PATH> Optionally, specify the location of the
`grobid-home` directory. If not specified, the
value is derived from the Grobid install
directory.
--grobid-install-dir=<PATH>
Optionally, specify the location where grobid is
installed. If not specified, the value is
derived from the Grobid version as follows:
System.getProperty("user.home") +
"/workspace/grobid/grobid-" + <grobid-version>
--grobid-jar=<PATH> Optionally, specify the location of the Grobid
jar. If not specified, the value is derived from
the Grobid version and Grobid install directory.
--grobid-java-exe=<PATH>
Optionally, specify the location of the java
executable to use to invoke Grobid. If not
specified, the java executable that runs ami is
used.
NOTE: Grobid supported version is Java 8. More
recent JVM version (like JVM 11) might lead to
issues.
Default: C:\apps\jdk-14/bin/java
--grobid-version=<X.Y.Z>
The grobid version to use.
Default: 0.5.3
Great ,
So impressed with how well you hAve understood all the problems, thank you. We may need to use grobid in production quite soon
On Mon, 6 Apr 2020, 04:18 Remko Popma, notifications@github.com wrote:
I see now why this was a bit cumbersome: the grovid version appears in both the installation directory and in the path to the grovid jar. I fixed it by adding a number of options to the ami grobit command.
If grobid is installed in $HOME/workspace/grobid/grobid-$GROBID_VERSION, then just specifying --grobid-version=
is sufficient. If grobid is installed elsewhere, users can specify --grobid-install-dir. If they use a grobid version other than the default (0.5.3), they should also specify --grobid-version.
Here is the full list of the new options:
--grobid-home=
Optionally, specify the location of the grobid-home
directory. If not specified, the value is derived from the Grobid install directory. --grobid-install-dir=Optionally, specify the location where grobid is installed. If not specified, the value is derived from the Grobid version as follows: System.getProperty("user.home") + "/workspace/grobid/grobid-" + --grobid-jar= Optionally, specify the location of the Grobid jar. If not specified, the value is derived from the Grobid version and Grobid install directory. --grobid-java-exe= Optionally, specify the location of the java executable to use to invoke Grobid. If not specified, the java executable that runs ami is used. NOTE: Grobid supported version is Java 8. More recent JVM version (like JVM 11) might lead to issues. Default: C:\apps\jdk-14/bin/java --grobid-version=<X.Y.Z> The grobid version to use. Default: 0.5.3 — You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/petermr/ami3/issues/18#issuecomment-609544394, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAFTCS75IWUDYGLSXOLPK3DRLFCXFANCNFSM4LXFVLKQ .
The changes in my previous comment have been pushed to master.
We need to build a new binary to make this available to @anjackson.
@petermr, do you feel like publishing a release for this in ami-jars
? Alternatively, we can wait until I have the improved deployment mechanism worked out.
"publishing a release" means what? giving it a version? Or is there
something that I personally have to do? I can give you access to ami-jars
.
On Mon, 6 Apr 2020, 07:32 Remko Popma, notifications@github.com wrote:
The changes in my previous comment have been pushed to master.
We need to build a new binary to make this available to @anjackson https://github.com/anjackson.
@petermr https://github.com/petermr, do you feel like publishing a release for this in ami-jars? Alternatively, we can wait until I have the improved deployment mechanism https://github.com/petermr/ami3/issues/24 worked out.
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/petermr/ami3/issues/18#issuecomment-609591929, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAFTCS55ZIXT5GZ7RY4G5ALRLFZOFANCNFSM4LXFVLKQ .
Yes, I meant giving it a version and running ami-jars.sh
to upload it to petermr/ami-jars
, so that @anjackson can download it and try out the new version.
If you want to delegate this to me, then I would need access to ami-jars
. However, I won't be able to do this today, and unsure about tomorrow, because of other commitments. :-)
No problem. I am amazed how much time your have donated. Is there a final jar to upload? Do I build it?
On Mon, Apr 6, 2020 at 8:38 AM Remko Popma notifications@github.com wrote:
Yes, I meant giving it a version and running ami-jars.sh to upload it to petermr/ami-jars, so that @anjackson https://github.com/anjackson can download it and try out the new version.
If you want to delegate this to me, then I would need access to ami-jars. However, I won't be able to do this today, and unsure about tomorrow, because of other commitments. :-)
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/petermr/ami3/issues/18#issuecomment-609627739, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAFTCS7RPN3JHJLHT5HQ3Y3RLGBHJANCNFSM4LXFVLKQ .
-- Peter Murray-Rust Founder ContentMine.org and Reader Emeritus in Molecular Informatics Dept. Of Chemistry, University of Cambridge, CB2 1EW, UK
Is there a final jar to upload? Do I build it?
You would have to build the jar from master (make sure to update first).
@anjackson Can you try the new release (new JAR in https://github.com/petermr/ami-jars2, version is 20200406
) and close this ticket if the new options meet your requirements?
Closing as done.
From Slack conversation: