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 C70B611FBF for ; Wed, 16 Apr 2014 09:39:51 +0000 (UTC) Received: (qmail 78106 invoked by uid 500); 16 Apr 2014 09:39:50 -0000 Delivered-To: apmail-uima-user-archive@uima.apache.org Received: (qmail 77888 invoked by uid 500); 16 Apr 2014 09:39:50 -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 77875 invoked by uid 99); 16 Apr 2014 09:39:49 -0000 Received: from minotaur.apache.org (HELO minotaur.apache.org) (140.211.11.9) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 16 Apr 2014 09:39:49 +0000 Received: from localhost (HELO s1654.dyn.hrz.tu-darmstadt.de) (127.0.0.1) (smtp-auth username rec, mechanism plain) by minotaur.apache.org (qpsmtpd/0.29) with ESMTP; Wed, 16 Apr 2014 09:39:48 +0000 Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 7.2 \(1874\)) Subject: Re: CAS Multiplier usage in UIMAfit From: Richard Eckart de Castilho In-Reply-To: <20140416092736.GW6156@machine.or.cz> Date: Wed, 16 Apr 2014 11:39:44 +0200 Content-Transfer-Encoding: quoted-printable Message-Id: <055D8055-D512-4EC6-B92C-9E7DBC146379@apache.org> References: <0415d209e8661a1e057a0632512d917f@crydee.eu> <20140416092736.GW6156@machine.or.cz> To: user@uima.apache.org X-Mailer: Apple Mail (2.1874) Hum, I had totally forgotten about this code by Philipp W. But anyway, I recently looked into the problem as well [1] and I wasn't particularly happy because whatever I could=20 come up with required client code to call CAS.release() explicitly - at least when trying to solve the problem in JCasIterable. Addressing that only on the level of SimplePipeline may be more straight-forward. I'll look into that as well. Btw. feel free to comment on the issue if you have further insight or suggestions (or patches ;) ). Cheers, -- Richard [1] https://issues.apache.org/jira/browse/UIMA-3470 On 16.04.2014, at 11:27, Petr Baudis wrote: > Hi! >=20 > On Wed, Apr 16, 2014 at 03:26:54PM +0900, Hugo Mougard wrote: >> I'm trying to use a multiplier to discard some CASes based on some >> annotation. It currently doesn't work (the CASes are not discarded). = I >> also noticed several tickets opened on the suject of multipliers and >> am therefore not sure if it's currently possible to use them in >> UIMAfit. >=20 > Perhaps a better solution exists meanwhile, but some time ago, > Philipp W suggested on this mailing list a SimplePipeline replacement > that can deal with CAS multipliers: >=20 > = https://groups.google.com/forum/#!topic/uimafit-users/yA0w2Q8tGNE >=20 > I had to wrap it up in an actual class and fix it for Aggregate = Engines, > my version is at: >=20 > = https://github.com/brmson/yodaqa/blob/master/src/main/java/cz/brmlab/yodaq= a/flow/MultiCASPipeline.java >=20 > You just use it in the same way as you'd use SimplePipeline then, = e.g.: >=20 > = https://github.com/brmson/yodaqa/blob/9e12a80c/src/main/java/cz/brmlab/yod= aqa/YodaQAApp.java >=20 >=20 > P.S.: I think ideally, to enable better scale-out and for consistency > if you are using other Aggregate Engines anyway, you would probably > create a single aggregate engine for your pipeline with the proper = flow > controller setup within, setting FlowController's = ActionForIntermediateSegments > to "drop". In XML CPE descriptor you'd do that like this: >=20 > = https://github.com/brmson/yodaqa/blob/bad64d5c/src/main/resources/cz/brmla= b/yodaqa/pipeline/YodaQA.xml >=20 > If you come up with a way to do that in UIMAfit, I will be glad if = you'd > share a working code snippet. >=20 > Petr "Pasky" Baudis