You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@uima.apache.org by Spico Florin <sp...@gmail.com> on 2011/11/15 13:56:52 UTC

Generating Pear file when using ConceptMapper Annotator

Hello!
   I have an UIMA project that uses the ConceptMapper Annotator. I would
like to know how to set up the following:
1. How to specify the TokenizerDescriptionPath?
I have used the macro
$main_root/descriptors/conceptMapper/primitive/OffsetTokenizer.xml, but
when I was trying to install the pear file,  the installer throws
exceptions complaining that the file
$main_root/descriptors/conceptMapper/primitive/OffsetTokenizer.xml could
not be found
2. How to set up the value for the DictionaryFileName (A file containing
the dictionary)? In the GUI window for setting up this resource, I've
filled the URL value with $main_root/data/dict/concepts.xml(my dictionary
file) but at the installation time, the installer throws exceptions
complaing that
Verification of uima-pipelines failed =>
 org.apache.uima.resource.ResourceInitializationException: Initialization
of annotator class "org.apache.uima.conceptMapper.ConceptMapper" failed.
Caused by: org.apache.uima.resource.ResourceAccessException: The Resource
/ConceptDetector/ConceptMapper/DictionaryFile requires parameters, none
were specified.
    at
org.apache.uima.resource.impl.ResourceManager_impl.getResource(ResourceManager_impl.java:221)
    at
org.apache.uima.impl.UimaContext_ImplBase.getResourceObject(UimaContext_ImplBase.java:295)
    at
org.apache.uima.analysis_engine.impl.AnnotatorContext_impl.getResourceObject(AnnotatorContext_impl.java:175)
    ... 33 more



I'll look forward for your answers. Thank you.

Regards,
 Florin

Re: Generating Pear file when using ConceptMapper Annotator

Posted by Marshall Schor <ms...@schor.com>.

On 11/17/2011 5:05 AM, Spico Florin wrote:
> Hello!
>   Thank you for your answer. The problem is that the apparently PEAR
> generator plugin doesn't know how to replace the macro $main_root in the
> descriptor of the ConceptMapperTokenizer.xml. 

Pear "Generator"?  It's not supposed to replace the $main_root - the generated
PEAR is supposed to have that string in the paths.
When the Pear is "installed" is when this is replaced with the installation spot.

-Marshall

... <snip>

Re: Generating Pear file when using ConceptMapper Annotator

Posted by Spico Florin <sp...@gmail.com>.
Hello!
  Thank you for your answer. The problem is that the apparently PEAR
generator plugin doesn't know how to replace the macro $main_root in the
descriptor of the ConceptMapperTokenizer.xml. I've added the
ConceptMapperAnnotator in my own project and also the OffsetTokenizer.xml.
Thus is why I've tried to give my own path to the value of it.
But  your idea is good, I'll point out the absolute path to the
installation folder of the ConceptMapperAnnotator addon.
If you are using an absolute path It might be some issues when you would
like to use the Analyze Engine in distributed environments. In this case
perhaps the addon should be put on a shared drive(NFS).

I'll look forward for any other suggestion.

Regards,
 Florin


On Wed, Nov 16, 2011 at 5:00 PM, Marshall Schor <ms...@schor.com> wrote:

>
>
> On 11/15/2011 7:56 AM, Spico Florin wrote:
> > Hello!
> >    I have an UIMA project that uses the ConceptMapper Annotator. I would
> > like to know how to set up the following:
> > 1. How to specify the TokenizerDescriptionPath?
> > I have used the macro
> > $main_root/descriptors/conceptMapper/primitive/OffsetTokenizer.xml, but
> > when I was trying to install the pear file,  the installer throws
> > exceptions complaining that the file
> > $main_root/descriptors/conceptMapper/primitive/OffsetTokenizer.xml could
> > not be found
>
> Did you look in the unzipped folder structure to find
> ..../primitive/OffsetTokenizer.xml ?
> In the 2.3.1 build, it seems to be perhaps under
> "desc/analysis_engine/primitive/OffsetTokenizer.xml", so this may be a
> simple
> spelling problem?
>
> -Marshall
>
> > 2. How to set up the value for the DictionaryFileName (A file containing
> > the dictionary)? In the GUI window for setting up this resource, I've
> > filled the URL value with $main_root/data/dict/concepts.xml(my dictionary
> > file) but at the installation time, the installer throws exceptions
> > complaing that
> > Verification of uima-pipelines failed =>
> >  org.apache.uima.resource.ResourceInitializationException: Initialization
> > of annotator class "org.apache.uima.conceptMapper.ConceptMapper" failed.
> > Caused by: org.apache.uima.resource.ResourceAccessException: The Resource
> > /ConceptDetector/ConceptMapper/DictionaryFile requires parameters, none
> > were specified.
> >     at
> >
> org.apache.uima.resource.impl.ResourceManager_impl.getResource(ResourceManager_impl.java:221)
> >     at
> >
> org.apache.uima.impl.UimaContext_ImplBase.getResourceObject(UimaContext_ImplBase.java:295)
> >     at
> >
> org.apache.uima.analysis_engine.impl.AnnotatorContext_impl.getResourceObject(AnnotatorContext_impl.java:175)
> >     ... 33 more
> >
> >
> >
> > I'll look forward for your answers. Thank you.
> >
> > Regards,
> >  Florin
> >
>

Re: Generating Pear file when using ConceptMapper Annotator

Posted by Marshall Schor <ms...@schor.com>.

On 11/15/2011 7:56 AM, Spico Florin wrote:
> Hello!
>    I have an UIMA project that uses the ConceptMapper Annotator. I would
> like to know how to set up the following:
> 1. How to specify the TokenizerDescriptionPath?
> I have used the macro
> $main_root/descriptors/conceptMapper/primitive/OffsetTokenizer.xml, but
> when I was trying to install the pear file,  the installer throws
> exceptions complaining that the file
> $main_root/descriptors/conceptMapper/primitive/OffsetTokenizer.xml could
> not be found

Did you look in the unzipped folder structure to find
..../primitive/OffsetTokenizer.xml ?
In the 2.3.1 build, it seems to be perhaps under
"desc/analysis_engine/primitive/OffsetTokenizer.xml", so this may be a simple
spelling problem?

-Marshall

> 2. How to set up the value for the DictionaryFileName (A file containing
> the dictionary)? In the GUI window for setting up this resource, I've
> filled the URL value with $main_root/data/dict/concepts.xml(my dictionary
> file) but at the installation time, the installer throws exceptions
> complaing that
> Verification of uima-pipelines failed =>
>  org.apache.uima.resource.ResourceInitializationException: Initialization
> of annotator class "org.apache.uima.conceptMapper.ConceptMapper" failed.
> Caused by: org.apache.uima.resource.ResourceAccessException: The Resource
> /ConceptDetector/ConceptMapper/DictionaryFile requires parameters, none
> were specified.
>     at
> org.apache.uima.resource.impl.ResourceManager_impl.getResource(ResourceManager_impl.java:221)
>     at
> org.apache.uima.impl.UimaContext_ImplBase.getResourceObject(UimaContext_ImplBase.java:295)
>     at
> org.apache.uima.analysis_engine.impl.AnnotatorContext_impl.getResourceObject(AnnotatorContext_impl.java:175)
>     ... 33 more
>
>
>
> I'll look forward for your answers. Thank you.
>
> Regards,
>  Florin
>