ctakes-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jeff Headley (JIRA)" <j...@apache.org>
Subject [jira] [Comment Edited] (CTAKES-370) Include smoking status in clinical pipeline
Date Sat, 01 Jul 2017 03:03:00 GMT

    [ https://issues.apache.org/jira/browse/CTAKES-370?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16070968#comment-16070968
] 

Jeff Headley edited comment on CTAKES-370 at 7/1/17 3:02 AM:
-------------------------------------------------------------

I'm using version 3.2.2 and trying to do this in my application. It was previously working
with the AggregatePlaintextFastUMLSProcessor. I tried using the one attached to this issue
and made the import changes as mentioned in the description, but I am getting the below error:


{code:java}
org.apache.uima.resource.ResourceInitializationException: Initialization of annotator class
"org.apache.ctakes.smokingstatus.ae.KuRuleBasedClassifierAnnotator" failed.  (Descriptor:
file:/D:/Software/project/cTAKES/desc/ctakes-smoking-status/desc/analysis_engine/KuRuleBasedClassifierAnnotator.xml)
	at org.apache.uima.analysis_engine.impl.PrimitiveAnalysisEngine_impl.initializeAnalysisComponent(PrimitiveAnalysisEngine_impl.java:252)
	at org.apache.uima.analysis_engine.impl.PrimitiveAnalysisEngine_impl.initialize(PrimitiveAnalysisEngine_impl.java:156)
	at org.apache.uima.impl.AnalysisEngineFactory_impl.produceResource(AnalysisEngineFactory_impl.java:94)
	at org.apache.uima.impl.CompositeResourceFactory_impl.produceResource(CompositeResourceFactory_impl.java:62)
	at org.apache.uima.UIMAFramework.produceResource(UIMAFramework.java:269)
	at org.apache.uima.UIMAFramework.produceAnalysisEngine(UIMAFramework.java:387)
	at org.apache.uima.analysis_engine.asb.impl.ASB_impl.setup(ASB_impl.java:254)
	at org.apache.uima.analysis_engine.impl.AggregateAnalysisEngine_impl.initASB(AggregateAnalysisEngine_impl.java:431)
	at org.apache.uima.analysis_engine.impl.AggregateAnalysisEngine_impl.initializeAggregateAnalysisEngine(AggregateAnalysisEngine_impl.java:375)
	at org.apache.uima.analysis_engine.impl.AggregateAnalysisEngine_impl.initialize(AggregateAnalysisEngine_impl.java:185)
	at org.apache.uima.impl.AnalysisEngineFactory_impl.produceResource(AnalysisEngineFactory_impl.java:94)
	at org.apache.uima.impl.CompositeResourceFactory_impl.produceResource(CompositeResourceFactory_impl.java:62)
	at org.apache.uima.UIMAFramework.produceResource(UIMAFramework.java:269)
	at org.apache.uima.UIMAFramework.produceAnalysisEngine(UIMAFramework.java:354)
.
.
Caused by: org.apache.uima.resource.ResourceInitializationException
	at org.apache.ctakes.smokingstatus.ae.KuRuleBasedClassifierAnnotator.initialize(KuRuleBasedClassifierAnnotator.java:74)
	at org.apache.uima.analysis_engine.impl.PrimitiveAnalysisEngine_impl.initializeAnalysisComponent(PrimitiveAnalysisEngine_impl.java:250)
	... 19 more
Caused by: java.lang.IllegalArgumentException: URI is not hierarchical
	at java.io.File.<init>(File.java:418)
	at org.apache.ctakes.core.resource.FileLocator.locateOnClasspath(FileLocator.java:182)
	at org.apache.ctakes.core.resource.FileLocator.getFullPath(FileLocator.java:125)
	at org.apache.ctakes.core.resource.FileLocator.locateFile(FileLocator.java:70)
	at org.apache.ctakes.smokingstatus.ae.KuRuleBasedClassifierAnnotator.initialize(KuRuleBasedClassifierAnnotator.java:67)
	... 20 more
{code}

The error happens in {{FileLocator}} at method {{private static File locateOnClasspath( final
String relativePath )}} and the passed in parameter is: org/apache/ctakes/smokingstatus/data/KU/keywords.txt



was (Author: jheadley):
I'm using version 3.2.2 and trying to do this in my application. It was previously working
with the AggregatePlaintextFastUMLSProcessor. I tried using the one attached to this issue
and made the import changes as mentioned in the description, but I am getting the below error:


{code:java}
org.apache.uima.resource.ResourceInitializationException: Initialization of annotator class
"org.apache.ctakes.smokingstatus.ae.KuRuleBasedClassifierAnnotator" failed.  (Descriptor:
file:/D:/Software/Epividian/cTAKES/desc/ctakes-smoking-status/desc/analysis_engine/KuRuleBasedClassifierAnnotator.xml)
	at org.apache.uima.analysis_engine.impl.PrimitiveAnalysisEngine_impl.initializeAnalysisComponent(PrimitiveAnalysisEngine_impl.java:252)
	at org.apache.uima.analysis_engine.impl.PrimitiveAnalysisEngine_impl.initialize(PrimitiveAnalysisEngine_impl.java:156)
	at org.apache.uima.impl.AnalysisEngineFactory_impl.produceResource(AnalysisEngineFactory_impl.java:94)
	at org.apache.uima.impl.CompositeResourceFactory_impl.produceResource(CompositeResourceFactory_impl.java:62)
	at org.apache.uima.UIMAFramework.produceResource(UIMAFramework.java:269)
	at org.apache.uima.UIMAFramework.produceAnalysisEngine(UIMAFramework.java:387)
	at org.apache.uima.analysis_engine.asb.impl.ASB_impl.setup(ASB_impl.java:254)
	at org.apache.uima.analysis_engine.impl.AggregateAnalysisEngine_impl.initASB(AggregateAnalysisEngine_impl.java:431)
	at org.apache.uima.analysis_engine.impl.AggregateAnalysisEngine_impl.initializeAggregateAnalysisEngine(AggregateAnalysisEngine_impl.java:375)
	at org.apache.uima.analysis_engine.impl.AggregateAnalysisEngine_impl.initialize(AggregateAnalysisEngine_impl.java:185)
	at org.apache.uima.impl.AnalysisEngineFactory_impl.produceResource(AnalysisEngineFactory_impl.java:94)
	at org.apache.uima.impl.CompositeResourceFactory_impl.produceResource(CompositeResourceFactory_impl.java:62)
	at org.apache.uima.UIMAFramework.produceResource(UIMAFramework.java:269)
	at org.apache.uima.UIMAFramework.produceAnalysisEngine(UIMAFramework.java:354)
	at com.epividian.ctakes.utils.CTAKESUtils.getAnalysisEngine(CTAKESUtils.java:143)
	at com.epividian.ctakes.processors.CommandLineProcessor.processLine(CommandLineProcessor.java:144)
	at java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1374)
	at java.util.stream.ReferencePipeline$Head.forEach(ReferencePipeline.java:580)
	at com.epividian.ctakes.processors.CommandLineProcessor.run(CommandLineProcessor.java:112)
	at com.epividian.ctakes.App.main(App.java:109)
Caused by: org.apache.uima.resource.ResourceInitializationException
	at org.apache.ctakes.smokingstatus.ae.KuRuleBasedClassifierAnnotator.initialize(KuRuleBasedClassifierAnnotator.java:74)
	at org.apache.uima.analysis_engine.impl.PrimitiveAnalysisEngine_impl.initializeAnalysisComponent(PrimitiveAnalysisEngine_impl.java:250)
	... 19 more
Caused by: java.lang.IllegalArgumentException: URI is not hierarchical
	at java.io.File.<init>(File.java:418)
	at org.apache.ctakes.core.resource.FileLocator.locateOnClasspath(FileLocator.java:182)
	at org.apache.ctakes.core.resource.FileLocator.getFullPath(FileLocator.java:125)
	at org.apache.ctakes.core.resource.FileLocator.locateFile(FileLocator.java:70)
	at org.apache.ctakes.smokingstatus.ae.KuRuleBasedClassifierAnnotator.initialize(KuRuleBasedClassifierAnnotator.java:67)
	... 20 more
{code}

The error happens in {{FileLocator}} at method {{private static File locateOnClasspath( final
String relativePath )}} and the passed in parameter is: org/apache/ctakes/smokingstatus/data/KU/keywords.txt


> Include smoking status in clinical pipeline
> -------------------------------------------
>
>                 Key: CTAKES-370
>                 URL: https://issues.apache.org/jira/browse/CTAKES-370
>             Project: cTAKES
>          Issue Type: Improvement
>          Components: ctakes-clinical-pipeline, ctakes-smoking-status
>    Affects Versions: 3.2.2
>         Environment: Linux
>            Reporter: Tomasz Oliwa
>            Priority: Minor
>         Attachments: AggregatePlaintextFastUMLSProcessor.xml
>
>
> The smoking status detection can be included in the clinical pipeline. 
> Attached is a AggregatePlaintextFastUMLSProcessor.xml that has the clinical pipeline
+ the smoking status detection integrated.
> Currently cTAKES has smoking status resources that need to have 
> their imports adjusted for any smoking status detection to work. As a workaround, in:
> ProductionPostSentenceAggregate_step1.xml
> change:
> <import name="org.apache.ctakes.core.analysis_engine.TokenizerAnnotator"/>
> <import name="org.apache.ctakes.core.analysis_engine.SentenceDetectorAnnotator"/>
> to the absolute or relative path (depends on the installed system, on my machine it is)
of these annotators:
> <import location="../../../../../../desc/ctakes-core/desc/analysis_engine/TokenizerAnnotator.xml"/>
> <import location="../../../../../../desc/ctakes-core/desc/analysis_engine/SentenceDetectorAnnotator.xml"/>



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Mime
View raw message