ctakes-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From c...@apache.org
Subject svn commit: r1602285 - /ctakes/trunk/ctakes-temporal/src/main/java/org/apache/ctakes/temporal/ae/feature/NumberOfEventTimeBetweenCandidatesExtractor.java
Date Thu, 12 Jun 2014 20:35:38 GMT
Author: clin
Date: Thu Jun 12 20:35:38 2014
New Revision: 1602285

URL: http://svn.apache.org/r1602285
Log:
check in the a feature extractor which count the number of eventMentions and timeMentions
between two arguments.

Modified:
    ctakes/trunk/ctakes-temporal/src/main/java/org/apache/ctakes/temporal/ae/feature/NumberOfEventTimeBetweenCandidatesExtractor.java

Modified: ctakes/trunk/ctakes-temporal/src/main/java/org/apache/ctakes/temporal/ae/feature/NumberOfEventTimeBetweenCandidatesExtractor.java
URL: http://svn.apache.org/viewvc/ctakes/trunk/ctakes-temporal/src/main/java/org/apache/ctakes/temporal/ae/feature/NumberOfEventTimeBetweenCandidatesExtractor.java?rev=1602285&r1=1602284&r2=1602285&view=diff
==============================================================================
--- ctakes/trunk/ctakes-temporal/src/main/java/org/apache/ctakes/temporal/ae/feature/NumberOfEventTimeBetweenCandidatesExtractor.java
(original)
+++ ctakes/trunk/ctakes-temporal/src/main/java/org/apache/ctakes/temporal/ae/feature/NumberOfEventTimeBetweenCandidatesExtractor.java
Thu Jun 12 20:35:38 2014
@@ -10,6 +10,7 @@ import org.apache.ctakes.typesystem.type
 import org.apache.uima.analysis_engine.AnalysisEngineProcessException;
 import org.apache.uima.jcas.JCas;
 import org.cleartk.classifier.Feature;
+import org.cleartk.util.ViewURIUtil;
 import org.uimafit.util.JCasUtil;
 
 public class NumberOfEventTimeBetweenCandidatesExtractor implements
@@ -45,6 +46,12 @@ RelationFeaturesExtractor {
 		feats.add(new Feature("NumOfEvents_InBetween", eventsInBetween));
 		feats.add(new Feature("NumOfTimes_InBetween", timesInBetween));
 		feats.add(new Feature("NumOfEventsAndTimes_InBetween", timesInBetween+eventsInBetween));
+		
+//		//print long distances
+//		if (eventsInBetween >= 200){
+//			System.out.println("++++++++++Long Distance Relation in "+ ViewURIUtil.getURI(jCas).toString()
+ "+++++++");
+//			System.out.println("["+arg1.getCoveredText()+"] "+ jCas.getDocumentText().substring(arg1.getEnd(),
arg2.getBegin()) +" ["+arg2.getCoveredText()+"]");
+//		}
 
 		return feats;
 	}



Mime
View raw message