Class RegTree

  • All Implemented Interfaces:
    java.io.Serializable

    public class RegTree
    extends java.lang.Object
    implements java.io.Serializable
    Regression tree.
    See Also:
    Serialized Form
    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
      (package private) static class  RegTree.Node  
      (package private) static class  RegTree.Param
      Parameters.
      (package private) static class  RegTree.RTreeNodeStat
      Statistics each node in tree.
    • Constructor Summary

      Constructors 
      Constructor Description
      RegTree()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      int getLeafIndex​(FVec feat, int root_id)
      Retrieves nodes from root to leaf and returns leaf index.
      float getLeafValue​(FVec feat, int root_id)
      Retrieves nodes from root to leaf and returns leaf value.
      void loadModel​(ModelReader reader)
      Loads model from stream.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • RegTree

        public RegTree()
    • Method Detail

      • loadModel

        public void loadModel​(ModelReader reader)
                       throws java.io.IOException
        Loads model from stream.
        Parameters:
        reader - input stream
        Throws:
        java.io.IOException - If an I/O error occurs
      • getLeafIndex

        public int getLeafIndex​(FVec feat,
                                int root_id)
        Retrieves nodes from root to leaf and returns leaf index.
        Parameters:
        feat - feature vector
        root_id - starting root index
        Returns:
        leaf index
      • getLeafValue

        public float getLeafValue​(FVec feat,
                                  int root_id)
        Retrieves nodes from root to leaf and returns leaf value.
        Parameters:
        feat - feature vector
        root_id - starting root index
        Returns:
        leaf value