ctakes-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dlig...@apache.org
Subject svn commit: r1746739 - /ctakes/sandbox/ctakes-wsd/src/main/java/org/apache/ctakes/pipelines/PositiveAndNegativeExamplePrinter.java
Date Fri, 03 Jun 2016 16:53:16 GMT
Author: dligach
Date: Fri Jun  3 16:53:16 2016
New Revision: 1746739

URL: http://svn.apache.org/viewvc?rev=1746739&view=rev
Log:
checking if output files alread exist; if they do, delete them

Modified:
    ctakes/sandbox/ctakes-wsd/src/main/java/org/apache/ctakes/pipelines/PositiveAndNegativeExamplePrinter.java

Modified: ctakes/sandbox/ctakes-wsd/src/main/java/org/apache/ctakes/pipelines/PositiveAndNegativeExamplePrinter.java
URL: http://svn.apache.org/viewvc/ctakes/sandbox/ctakes-wsd/src/main/java/org/apache/ctakes/pipelines/PositiveAndNegativeExamplePrinter.java?rev=1746739&r1=1746738&r2=1746739&view=diff
==============================================================================
--- ctakes/sandbox/ctakes-wsd/src/main/java/org/apache/ctakes/pipelines/PositiveAndNegativeExamplePrinter.java
(original)
+++ ctakes/sandbox/ctakes-wsd/src/main/java/org/apache/ctakes/pipelines/PositiveAndNegativeExamplePrinter.java
Fri Jun  3 16:53:16 2016
@@ -73,8 +73,14 @@ public class PositiveAndNegativeExampleP
   public static void main(String[] args) throws Exception {
     
     File trainFile = new File(trainDataFile);
+    if(trainFile.exists()) {
+      trainFile.delete();
+    }
     trainFile.createNewFile();
     File devFile = new File(devDataFile);
+    if(devFile.exists()) {
+      devFile.delete();
+    }
     devFile.createNewFile();
     
     Options options = CliFactory.parseArguments(Options.class, args);



Mime
View raw message