Return-Path: X-Original-To: apmail-uima-user-archive@www.apache.org Delivered-To: apmail-uima-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 8506C11927 for ; Thu, 24 Jul 2014 16:46:22 +0000 (UTC) Received: (qmail 10586 invoked by uid 500); 24 Jul 2014 16:46:22 -0000 Delivered-To: apmail-uima-user-archive@uima.apache.org Received: (qmail 10542 invoked by uid 500); 24 Jul 2014 16:46:22 -0000 Mailing-List: contact user-help@uima.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@uima.apache.org Delivered-To: mailing list user@uima.apache.org Received: (qmail 10517 invoked by uid 99); 24 Jul 2014 16:46:22 -0000 Received: from minotaur.apache.org (HELO minotaur.apache.org) (140.211.11.9) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 24 Jul 2014 16:46:22 +0000 Received: from localhost (HELO highfire.ukp.informatik.tu-darmstadt.de) (127.0.0.1) (smtp-auth username rec, mechanism plain) by minotaur.apache.org (qpsmtpd/0.29) with ESMTP; Thu, 24 Jul 2014 16:46:21 +0000 Content-Type: text/plain; charset=iso-8859-1 Mime-Version: 1.0 (Mac OS X Mail 7.3 \(1878.6\)) Subject: Re: DKpro StanfordNamedEntityRecognizer ClassCastException From: Richard Eckart de Castilho In-Reply-To: Date: Thu, 24 Jul 2014 18:46:13 +0200 Content-Transfer-Encoding: quoted-printable Message-Id: <9174688C-EE2E-4413-91E1-6ECEBEBE6B66@apache.org> References: <2E3B4359-39E8-48A2-A97F-9372EAA8641F@apache.org> <3639B29C-9D66-436B-B7D5-6A34B6D2A852@apache.org> To: user@uima.apache.org X-Mailer: Apple Mail (2.1878.6) Hi Armin, I have absolutely no idea. I have rarely encountered this problem. = Actually the only source of this that I remember is the use of the (de)serialization based on = CASSerializer and/or CASCompleteSerializer (via CASImpl.reinit(...)). Nothing related to this should have changed from uimaFIT 2.0.0 to 2.1.0. = Does it work if you switch back to 2.0.0 (if you can)? What kind of reader are you using? Cheers, -- Richard On 24.07.2014, at 17:05, Armin.Wegner@bka.bund.de wrote: > Hi Richard! >=20 > It looks like your absolutely right. I have changed all JCas stuff in = the consumer's resource to pure CAS and it works. >=20 > But why is JCas support not initialized? The reader calls an annotator = for document meta data that uses JCas. It says "new = DocumentMetaData(cas.getJCas())" and actually is annotated in the CAS. >=20 > All annotator's descriptions are build with = AnalysisEngineFactory.createEngineDescription or read from an XML file. = They are added to an AggregateBuilder. The aggregate description is = given as second argument to SimplePipeline.runPipeline(). The first = argument is the reader's descriptions. One of the ae's is the = cas.getJCas() one you mentioned earlier. What am I missing? Has anything = changed from uimaFit 2.0.0 to 2.1.0? >=20 > Cheers > Armin >=20 >=20 >=20 > -----Urspr=FCngliche Nachricht----- > Von: Richard Eckart de Castilho [mailto:rec@apache.org]=20 > Gesendet: Donnerstag, 24. Juli 2014 15:59 > An: user@uima.apache.org > Betreff: Re: DKpro StanfordNamedEntityRecognizer ClassCastException >=20 > Hi Armin, >=20 > the underlying problem is that you get a simple = org.apache.uima.cas.impl.AnnotationImpl instead of a JCas class like = de.tudarmstadt.ukp.dkpro.core.api.ner.type.NamedEntity. Normally a CAS = that has its JCas support initialized always returns JCas classes. But = is is possible to work entirely without JCas classes and without = initializing JCas support. In such a case, all AnnotationFS feature = structures are returned as AnnotationImpl. >=20 > I don't think this has anything to do with chaining resources. I'm = pretty sure it is related to how CASes are created, (de)serialized, = and/or passed through your pipeline (possibly through multipliers). >=20 > If you find out that this is not related to CAS creation/propagation, = I'll be very curious to hear about it! >=20 > Cheers, >=20 > -- Richard >=20 > On 24.07.2014, at 15:27, Armin.Wegner@bka.bund.de wrote: >=20 >> Hello Richard! >>=20 >> Your fix doesn't change anything. So I tried to narrow down the = problem. At least, I can tell that it is not a problem specific to = DKPro. I have the same kind of exception when not using DKPro at all. My = guess now is that it maybe has something to do with chaining resources. = I tried some simple aes. They run fine. When I try to run components = with resources of resources, they fail. That's all for now. I will try = to find out more and report again. >>=20 >> Cheers, >> Armin >=20