Package org.apache.ctakes.relationextractor.eval

Examples of org.apache.ctakes.relationextractor.eval.RelationExtractorEvaluation$RemoveCTakesMentionsAndCopyGoldRelations


        "-c",
        String.valueOf(params.svmCost),
        "-g",
        String.valueOf(params.svmGamma) };
   
      RelationExtractorEvaluation evaluation = new RelationExtractorEvaluation(
          modelsDir,
          annotatorClass,
          dataWriterClass,
          additionalParameters,
          trainingArguments);
     
      CollectionReader collectionReader = evaluation.getCollectionReader(trainFiles);
      evaluation.train(collectionReader, modelsDir);
     
      // create the description
      AnalysisEngineDescription relationExtractorDescription = AnalysisEngineFactory.createPrimitiveDescription(
          annotatorClass,
          RelationExtractorAnnotator.PARAM_PROBABILITY_OF_KEEPING_A_NEGATIVE_EXAMPLE,
View Full Code Here


        RelationExtractorEvaluation.ANNOTATOR_CLASSES.get(relationClass);
    ParameterSettings params = RelationExtractorEvaluation.BEST_PARAMETERS.get(relationClass);

    // train the relation extractor
    File trainDirectory = new File(resourcesDirectory, modelPath);
    RelationExtractorEvaluation evaluation =
        new RelationExtractorEvaluation(trainDirectory, relationClass, annotatorClass, params);
    evaluation.train(evaluation.getCollectionReader(trainFiles), trainDirectory);

    // create the description
    Object[] pathParameters =
        new Object[] { GenericJarClassifierFactory.PARAM_CLASSIFIER_JAR_PATH,
            "/" + modelPath + "/model.jar" };
View Full Code Here

TOP

Related Classes of org.apache.ctakes.relationextractor.eval.RelationExtractorEvaluation$RemoveCTakesMentionsAndCopyGoldRelations

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.