コード例 #1
0
 public static File getCorpusPath(final File resourcesDir, final GrobidModels model) {
   File theFile = new File(resourcesDir, "dataset/" + model.getFolderName() + "/corpus");
   if (!theFile.exists()) {
     theFile = new File("resources/dataset/" + model.getFolderName() + "/corpus");
   }
   return theFile;
 }
コード例 #2
0
 public static File getTemplatePath(final File resourcesDir, final GrobidModels model) {
   File theFile =
       new File(
           resourcesDir,
           "dataset/" + model.getFolderName() + "/crfpp-templates/" + model.getTemplateName());
   if (!theFile.exists()) {
     theFile =
         new File(
             "resources/dataset/"
                 + model.getFolderName()
                 + "/crfpp-templates/"
                 + model.getTemplateName());
   }
   return theFile;
 }
コード例 #3
0
 public static File getModelPath(final GrobidModels model) {
   return new File(
       get_GROBID_HOME_PATH(),
       FOLDER_NAME_MODELS
           + File.separator
           + model.getFolderName()
           + File.separator
           + FILE_NAME_MODEL
           + "."
           + grobidCRFEngine.getExt());
 }