Class ClassifierFactory

java.lang.Object
es.upm.fi.cig.multictbnc.classification.ClassifierFactory

public class ClassifierFactory extends Object
Provides static methods for the creation of classifiers.
  • Constructor Details

    • ClassifierFactory

      public ClassifierFactory()
  • Method Details

    • getAvailableModels

      public static List<String> getAvailableModels()
      Returns a list with the currently available classifiers.
      Returns:
      list of available classifiers
    • getMultiCTBNC

      public static MultiCTBNC getMultiCTBNC(String nameClassifier, BNLearningAlgorithms bnLearningAlgs, CTBNLearningAlgorithms ctbnLearningAlgs)
      Builds the specified classifier. The node type for the class variables is assumed to be a CPTNode, while for a feature variable a CIMNode.
      Parameters:
      nameClassifier - name of the classifier to build
      bnLearningAlgs - parameter and structure learning algorithms for Bayesian networks
      ctbnLearningAlgs - parameter and structure learning algorithms for continuous-time Bayesian networks
      Returns:
      a MultiCTBNC
    • getMultiCTBNC

      public static MultiCTBNC getMultiCTBNC(String nameClassifier, BNLearningAlgorithms bnLearningAlgs, CTBNLearningAlgorithms ctbnLearningAlgs, Map<String,String> hyperparameters)
      Builds the specified classifier with the provided hyperparameters. The node type for the class variables is assumed to be a CPTNode, while for a feature variable a CIMNode.
      Parameters:
      nameClassifier - name of the classifier to build
      bnLearningAlgs - parameter and structure learning algorithms for Bayesian networks
      ctbnLearningAlgs - parameter and structure learning algorithms for continuous-time Bayesian networks
      hyperparameters - specific hyperparameters for each type of classifier
      Returns:
      a MultiCTBNC
    • getMultiCTBNC

      public static <NodeTypeBN extends Node, NodeTypeCTBN extends Node> MultiCTBNC<NodeTypeBN,NodeTypeCTBN> getMultiCTBNC(String nameClassifier, BNLearningAlgorithms bnLearningAlgs, CTBNLearningAlgorithms ctbnLearningAlgs, Map<String,String> hyperparameters, Class<NodeTypeBN> bnNodeClass, Class<NodeTypeCTBN> ctbnNodeClass)
      Builds the specified classifier with the provided hyperparameters.
      Type Parameters:
      NodeTypeBN - type of the nodes of the Bayesian network
      NodeTypeCTBN - type of the nodes of the continuous-time Bayesian network
      Parameters:
      nameClassifier - name of the classifier to build
      bnLearningAlgs - parameter and structure learning algorithms for Bayesian networks
      ctbnLearningAlgs - parameter and structure learning algorithms for continuous-time Bayesian networks
      hyperparameters - specific hyperparameters for each type of classifier
      bnNodeClass - Bayesian network node type
      ctbnNodeClass - continuous-time Bayesian network node type
      Returns:
      a MultiCTBNC
    • getMultiCTBNC

      public static MultiCTBNC<CPTNode,CIMNode> getMultiCTBNC()
      Generates a Multi-CTBNC including some default nodes and algorithms for the learning of its parameters and structure. This method was thought to easily generate the classifier.
      Returns:
      a Multi-CTBNC
    • getMultiCTBNCLearnedWithCTPC

      public static MultiCTBNC<CPTNode,CIMNode> getMultiCTBNCLearnedWithCTPC()
      Generates a Multi-CTBNC including some default nodes and algorithms for the learning of its parameters and structure. This method was thought to easily generate the classifier. The algorithms could be later modifier.
      Returns:
      a Multi-CTBNC
    • getMultiCTBNCLearnedWithHybridAlgorithm

      public static MultiCTBNC<CPTNode,CIMNode> getMultiCTBNCLearnedWithHybridAlgorithm()
      Generates a Multi-CTBNC including some default nodes and algorithms for the learning of its parameters and structure. This method was thought to easily generate the classifier. The algorithms could be later modifier.
      Returns:
      a Multi-CTBNC
    • getMultiCTBNCLearnedWithMBCTPC

      public static MultiCTBNC<CPTNode,CIMNode> getMultiCTBNCLearnedWithMBCTPC()
      Generates a Multi-CTBNC including some default nodes and algorithms for the learning of its parameters and structure. This method was thought to easily generate the classifier. The algorithms could be later modifier.
      Returns:
      a Multi-CTBNC