You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ctakes.apache.org by dl...@apache.org on 2014/04/02 17:51:26 UTC
svn commit: r1584073 -
/ctakes/trunk/ctakes-temporal/src/main/java/org/apache/ctakes/temporal/duration/EventDurationDistribution.java
Author: dligach
Date: Wed Apr 2 15:51:25 2014
New Revision: 1584073
URL: http://svn.apache.org/r1584073
Log:
added a few more negation key words
Modified:
ctakes/trunk/ctakes-temporal/src/main/java/org/apache/ctakes/temporal/duration/EventDurationDistribution.java
Modified: ctakes/trunk/ctakes-temporal/src/main/java/org/apache/ctakes/temporal/duration/EventDurationDistribution.java
URL: http://svn.apache.org/viewvc/ctakes/trunk/ctakes-temporal/src/main/java/org/apache/ctakes/temporal/duration/EventDurationDistribution.java?rev=1584073&r1=1584072&r2=1584073&view=diff
==============================================================================
--- ctakes/trunk/ctakes-temporal/src/main/java/org/apache/ctakes/temporal/duration/EventDurationDistribution.java (original)
+++ ctakes/trunk/ctakes-temporal/src/main/java/org/apache/ctakes/temporal/duration/EventDurationDistribution.java Wed Apr 2 15:51:25 2014
@@ -173,7 +173,9 @@ public class EventDurationDistribution {
} catch (IOException e) {
System.out.println("Could not open output file: " + outputFile);
}
- }
+ } else {
+ System.out.println("No duration data for: " + mentionText);
+ }
}
/**
@@ -183,7 +185,9 @@ public class EventDurationDistribution {
private static boolean isNegated(JCas jCas, EventMention mention) {
for(BaseToken token : JCasUtil.selectPreceding(jCas, BaseToken.class, mention, 3)) {
- if(token.getCoveredText().equals("no")) {
+ if(token.getCoveredText().equals("no") ||
+ token.getCoveredText().equals("not") ||
+ token.getCoveredText().equals("off")) {
return true;
}
}