Package com.clarkparsia.modularity

Examples of com.clarkparsia.modularity.IncrementalClassifier.classify()


   
    // Get an instance of the incremental classifier
    IncrementalClassifier classifier = new IncrementalClassifier( ontology );

    // trigger classification
    classifier.classify();
       
    // persist the current state of the classifier to a file
    try {
      System.out.print( "Saving the state of the classifier to the file ... " );
      System.out.flush();
View Full Code Here


    // We classify the ontology and use a specific timer to keep track of
    // the time required for the classification
    Timer t = timers.createTimer( "First classification" );
    t.start();
    classifier.classify();
    t.stop();
       
    System.out.println( "\nClassification time: " + t.getTotal() + "ms");
    System.out.println( "Subclasses of " + pain + ": " + classifier.getSubClasses( pain, true ).getFlattened() + "\n");
   
View Full Code Here

    // Now we create a second timer to keep track of the performance of the
    // second classification
    t = timers.createTimer("Second classification");
    t.start();
    classifier.classify();
    t.stop();
   
    System.out.println( "\nClassification time: " + t.getTotal() + "ms");
    System.out.println( "Subclasses of " + pain + ": " + classifier.getSubClasses( pain, true ).getFlattened() + "\n");
View Full Code Here

    OWL.manager.applyChange( new RemoveAxiom( ontologyTBox, axiom ) );

    // Now we create a third timer to keep track of the performance of the
    // third classification
    timers.startTimer( "Third classification" );
    classifier.classify();
    timers.stopTimer( "Third classification" );
   
    System.out.println( "\nClassification time: " + t.getTotal() + "ms");
    System.out.println( "Subclasses of " + pain + ": " + classifier.getSubClasses( pain, true ).getFlattened() + "\n");
   
View Full Code Here

      if( !isConsistent )
        throw new PelletCmdException( "Ontology is inconsistent, run \"pellet explain\" to get the reason" );

      startTask( "classification" );
      incrementalClassifier.classify();
      finishTask( "classification" );
    }

    TaxonomyPrinter<OWLClass> printer = new OWLClassTreePrinter();
    printer.print( incrementalClassifier.getTaxonomy() );
View Full Code Here

    // We classify the ontology and use a specific timer to keep track of
    // the time required for the classification
    Timer t = timers.createTimer( "First classification" );
    t.start();
    classifier.classify();
    t.stop();
       
    System.out.println( "\nClassification time: " + t.getTotal() + "ms");
    System.out.println( "Subclasses of " + pain + ": " + classifier.getSubClasses( pain, true ).getFlattened() + "\n");
   
View Full Code Here

    // Now we create a second timer to keep track of the performance of the
    // second classification
    t = timers.createTimer( "Second classification" );
    t.start();
    classifier.classify();
    t.stop();
   
    System.out.println( "\nClassification time: " + t.getTotal() + "ms");
    System.out.println( "Subclasses of " + pain + ": " + classifier.getSubClasses( pain, true ).getFlattened() + "\n");
View Full Code Here

    OWL.manager.applyChange( new RemoveAxiom( ontology, axiom ) );

    // Now we create a third timer to keep track of the performance of the
    // third classification
    timers.startTimer( "Third classification" );
    classifier.classify();
    timers.stopTimer( "Third classification" );
   
    System.out.println( "\nClassification time: " + t.getTotal() + "ms");
    System.out.println( "Subclasses of " + pain + ": " + classifier.getSubClasses( pain, true ).getFlattened() + "\n");
   
View Full Code Here

   
    // Get an instance of the incremental classifier
    IncrementalClassifier classifier = new IncrementalClassifier( ontology );

    // trigger classification
    classifier.classify();
       
    // persist the current state of the classifier to a file
    try {
      System.out.print( "Saving the state of the classifier to the file ... " );
      System.out.flush();
View Full Code Here

  public void addNonLocal() throws OWLException {
    OWLAxiom[] axioms = { subClassOf( A, B ), subClassOf( C, D ) };
    createOntology( axioms );

    IncrementalClassifier modular = PelletIncremantalReasonerFactory.getInstance().createReasoner( ontology );
    modular.classify();
   
    assertTrue( modular.isEntailed( subClassOf( A, B ) ) );
    assertFalse( modular.isEntailed( subClassOf( B, C ) ) );
    assertTrue( modular.isEntailed( subClassOf( C, D ) ) );
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.