Module org.elasticsearch.xcore
Class TreeNode
java.lang.Object
org.elasticsearch.xpack.core.ml.inference.trainedmodel.tree.TreeNode
- All Implemented Interfaces:
org.apache.lucene.util.Accountable,Writeable,org.elasticsearch.xcontent.ToXContent,org.elasticsearch.xcontent.ToXContentObject
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from interface org.elasticsearch.xcontent.ToXContent
org.elasticsearch.xcontent.ToXContent.DelegatingMapParams, org.elasticsearch.xcontent.ToXContent.MapParams, org.elasticsearch.xcontent.ToXContent.ParamsNested classes/interfaces inherited from interface org.elasticsearch.common.io.stream.Writeable
Writeable.Reader<V>, Writeable.Writer<V> -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final org.elasticsearch.xcontent.ParseFieldstatic final org.elasticsearch.xcontent.ParseFieldstatic final org.elasticsearch.xcontent.ParseFieldstatic final org.elasticsearch.xcontent.ParseFieldstatic final Stringstatic final org.elasticsearch.xcontent.ParseFieldstatic final org.elasticsearch.xcontent.ParseFieldstatic final org.elasticsearch.xcontent.ParseFieldstatic final org.elasticsearch.xcontent.ParseFieldstatic final org.elasticsearch.xcontent.ParseFieldstatic final org.elasticsearch.xcontent.ParseFieldFields inherited from interface org.apache.lucene.util.Accountable
NULL_ACCOUNTABLEFields inherited from interface org.elasticsearch.xcontent.ToXContent
EMPTY, EMPTY_PARAMS -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic TreeNode.Builderbuilder(int nodeIndex) booleanstatic TreeNode.BuilderfromXContent(org.elasticsearch.xcontent.XContentParser parser, boolean lenient) double[]intintlongintintdoubledoubleinthashCode()booleanbooleanisLeaf()longtoString()org.elasticsearch.xcontent.XContentBuildertoXContent(org.elasticsearch.xcontent.XContentBuilder builder, org.elasticsearch.xcontent.ToXContent.Params params) voidwriteTo(StreamOutput out) Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface org.apache.lucene.util.Accountable
getChildResourcesMethods inherited from interface org.elasticsearch.xcontent.ToXContentObject
isFragment
-
Field Details
-
NAME
- See Also:
-
DECISION_TYPE
public static final org.elasticsearch.xcontent.ParseField DECISION_TYPE -
THRESHOLD
public static final org.elasticsearch.xcontent.ParseField THRESHOLD -
LEFT_CHILD
public static final org.elasticsearch.xcontent.ParseField LEFT_CHILD -
RIGHT_CHILD
public static final org.elasticsearch.xcontent.ParseField RIGHT_CHILD -
DEFAULT_LEFT
public static final org.elasticsearch.xcontent.ParseField DEFAULT_LEFT -
SPLIT_FEATURE
public static final org.elasticsearch.xcontent.ParseField SPLIT_FEATURE -
NODE_INDEX
public static final org.elasticsearch.xcontent.ParseField NODE_INDEX -
SPLIT_GAIN
public static final org.elasticsearch.xcontent.ParseField SPLIT_GAIN -
LEAF_VALUE
public static final org.elasticsearch.xcontent.ParseField LEAF_VALUE -
NUMBER_SAMPLES
public static final org.elasticsearch.xcontent.ParseField NUMBER_SAMPLES
-
-
Constructor Details
-
TreeNode
- Throws:
IOException
-
-
Method Details
-
fromXContent
public static TreeNode.Builder fromXContent(org.elasticsearch.xcontent.XContentParser parser, boolean lenient) -
getOperator
-
getThreshold
public double getThreshold() -
getSplitFeature
public int getSplitFeature() -
getNodeIndex
public int getNodeIndex() -
getSplitGain
public double getSplitGain() -
getLeafValue
public double[] getLeafValue() -
isDefaultLeft
public boolean isDefaultLeft() -
getLeftChild
public int getLeftChild() -
getRightChild
public int getRightChild() -
isLeaf
public boolean isLeaf() -
getNumberSamples
public long getNumberSamples() -
writeTo
- Specified by:
writeToin interfaceWriteable- Throws:
IOException
-
toXContent
public org.elasticsearch.xcontent.XContentBuilder toXContent(org.elasticsearch.xcontent.XContentBuilder builder, org.elasticsearch.xcontent.ToXContent.Params params) throws IOException - Specified by:
toXContentin interfaceorg.elasticsearch.xcontent.ToXContent- Throws:
IOException
-
equals
-
hashCode
public int hashCode() -
toString
-
builder
-
ramBytesUsed
public long ramBytesUsed()- Specified by:
ramBytesUsedin interfaceorg.apache.lucene.util.Accountable
-