Return-Path: Delivered-To: apmail-incubator-uima-user-archive@minotaur.apache.org Received: (qmail 72257 invoked from network); 1 Feb 2010 19:29:13 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 1 Feb 2010 19:29:13 -0000 Received: (qmail 885 invoked by uid 500); 1 Feb 2010 19:29:13 -0000 Delivered-To: apmail-incubator-uima-user-archive@incubator.apache.org Received: (qmail 826 invoked by uid 500); 1 Feb 2010 19:29:13 -0000 Mailing-List: contact uima-user-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: uima-user@incubator.apache.org Delivered-To: mailing list uima-user@incubator.apache.org Received: (qmail 816 invoked by uid 99); 1 Feb 2010 19:29:12 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 01 Feb 2010 19:29:12 +0000 X-ASF-Spam-Status: No, hits=2.2 required=10.0 tests=HTML_MESSAGE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of aradwen@gmail.com designates 74.125.78.147 as permitted sender) Received: from [74.125.78.147] (HELO ey-out-1920.google.com) (74.125.78.147) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 01 Feb 2010 19:29:04 +0000 Received: by ey-out-1920.google.com with SMTP id 26so1036244eyw.8 for ; Mon, 01 Feb 2010 11:28:44 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:content-type; bh=aYJ6eM56l2jVZHvl9++dJXWgEzfrSuuThG4yX7BKzGI=; b=v60yJz8/TeImiZzb6MqzcdCdC7AVkSjroI6PL/GGdT2BEEMEcEkp5+29nHHTdBfDDX Ky0RjiIVD4WO5Cz4+K1SHXRGKURL0hypnsBBrtUhObPvk+XpyTDU6FJ90deEGUgYdfnJ q1K/FZSD6941lijuX4y2JQhRnHGAkmgtqBJQc= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; b=cO2tvF8Adg/XARh0H0vcYTyS/1kmAp8yHAB4gYhPTBkIn1oRxtRP8Vl23ee4tY9dg9 eVKzywtyxode8m3qhMrfqWMbNZFD4mA5DmqdQtPSoFjQ7PWEas55f86/PTmM0psh8ApL eaCiANHZ849Aj/Idn+ydRh81D2EIucM4wjzgg= MIME-Version: 1.0 Received: by 10.216.88.85 with SMTP id z63mr3367542wee.129.1265052523976; Mon, 01 Feb 2010 11:28:43 -0800 (PST) In-Reply-To: <4B66EDE2.7030006@schor.com> References: <4B63290B.4020606@schor.com> <4B66EDE2.7030006@schor.com> Date: Mon, 1 Feb 2010 20:28:43 +0100 Message-ID: Subject: Re: AE parameters don't change From: Radwen ANIBA To: uima-user@incubator.apache.org Content-Type: multipart/alternative; boundary=0016e6d7ed30505832047e8efe27 X-Virus-Checked: Checked by ClamAV on apache.org --0016e6d7ed30505832047e8efe27 Content-Type: text/plain; charset=ISO-8859-1 Thank you Marshall, The SimpleRunCPM example is good but did not answer my question since I already have a coded CPE and do not need to use CPM. Or does it mean that instead of calling the CPE descriptor I have to follow CPM example to add manually all the AEs I have developped including the one that I change programmatically in the main class ? Radwen 2010/2/1 Marshall Schor > > > Radwen ANIBA wrote: > > Well I tried again but still have the same bug. > > > > After changing AE parameters programatically how to tell the CPE (before > or > > when calling it) to look if the AE changed or not ? > > > > See the example code in the examples, under > org.apache.uima.examples.cpe.SimpleRunCPM, for an example of setting up > a CPM to run after individually instantiating some components. > > HTH. -Marshall > > Radwen > > > > 2010/1/30 Radwen ANIBA > > > > > >> I simply used reconfigure for the AE, i thought CPE will see the latest > >> modification in the descriptor > >> > >> Am I wrong ? > >> > >> 2010/1/29 Marshall Schor > >> > >> > >> > >>> Radwen ANIBA wrote: > >>> > >>>> Hi > >>>> > >>>> I'm trying to change a parameter in an AE and then to call the CPE > that > >>>> > >>> uses > >>> > >>>> this AE but the changes are not made despite the fact that I don't > have > >>>> errors. > >>>> > >>> How did you indicate to the CPE (Collection Processing Engine) that it > >>> should use this configured Analysis Engine? > >>> -Marshall > >>> > >>>> Here is the part of code I'm using > >>>> > >>>> ResourceSpecifier aeSpecifier; > >>>> try { > >>>> aeSpecifier = > >>>> UIMAFramework.getXMLParser().parseResourceSpecifier(new > >>>> XMLInputSource("desc/TestSeePredAED.xml")); > >>>> AnalysisEngine ae = > >>>> UIMAFramework.produceAnalysisEngine(aeSpecifier); > >>>> > >>>> ConfigurationParameterSettings aesettings = > >>>> ae.getMetaData().getConfigurationParameterSettings(); > >>>> > >>>> NameValuePair[] valuePairs2 = > >>>> aesettings.getParameterSettings(); > >>>> > >>>> for (NameValuePair nvp2 : valuePairs2) { > >>>> > >>>> > >>>> > >>>> > >>>> > >>> > if(nvp2.getName().matches("OUTPUTDIR"))nvp2.setValue("/home/radwen/Bureau/Fold"); > >>> > >>>> System.out.format("name='%s'; value='%s'\n", > >>>> > >>>> nvp2.getName(), nvp2.getValue()); > >>>> > >>>> } > >>>> > >>>> ae.reconfigure(); > >>>> > >>>> > >>>> But after calling my CPE programmaticaly just after this code, well > the > >>>> changes seems to be not made. > >>>> > >>>> Can you help me figuring this out ? > >>>> > >>>> Thx > >>>> > >>>> Radwen > >>>> > >>>> > >>>> > >> > > > > > --0016e6d7ed30505832047e8efe27--