Module org.elasticsearch.xcore
Class Tree
java.lang.Object
org.elasticsearch.xpack.core.ml.inference.trainedmodel.tree.Tree
- All Implemented Interfaces:
org.apache.lucene.util.Accountable,NamedWriteable,Writeable,ToXContent,ToXContentObject,LenientlyParsedTrainedModel,StrictlyParsedTrainedModel,TrainedModel,NamedXContentObject
public class Tree
extends Object
implements LenientlyParsedTrainedModel, StrictlyParsedTrainedModel, org.apache.lucene.util.Accountable
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from interface org.elasticsearch.xcontent.ToXContent
ToXContent.DelegatingMapParams, ToXContent.MapParams, 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 ParseFieldstatic final ParseFieldstatic final ParseFieldstatic final 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 Tree.Builderbuilder()booleanlongstatic TreefromXContentLenient(XContentParser parser) static TreefromXContentStrict(XContentParser parser) Collection<org.apache.lucene.util.Accountable> getName()inthashCode()longtoString()toXContent(XContentBuilder builder, ToXContent.Params params) voidvalidate()Runs validations against the model.voidwriteTo(StreamOutput out) Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface org.elasticsearch.xcontent.ToXContentObject
isFragmentMethods inherited from interface org.elasticsearch.xpack.core.ml.inference.trainedmodel.TrainedModel
getMinimalCompatibilityVersion
-
Field Details
-
NAME
-
FEATURE_NAMES
-
TREE_STRUCTURE
-
CLASSIFICATION_LABELS
-
-
Constructor Details
-
Tree
- Throws:
IOException
-
-
Method Details
-
fromXContentStrict
-
fromXContentLenient
-
getName
- Specified by:
getNamein interfaceNamedXContentObject- Returns:
- The name of the XContentObject that is to be serialized
-
targetType
- Specified by:
targetTypein interfaceTrainedModel- Returns:
TargetTypefor the model.
-
getWriteableName
- Specified by:
getWriteableNamein interfaceNamedWriteable
-
writeTo
- Specified by:
writeToin interfaceWriteable- Throws:
IOException
-
toXContent
public XContentBuilder toXContent(XContentBuilder builder, ToXContent.Params params) throws IOException - Specified by:
toXContentin interfaceToXContent- Throws:
IOException
-
toString
-
equals
-
hashCode
public int hashCode() -
builder
-
validate
public void validate()Description copied from interface:TrainedModelRuns validations against the model. Example:Treeshould check if there are any loops- Specified by:
validatein interfaceTrainedModel
-
estimatedNumOperations
public long estimatedNumOperations()- Specified by:
estimatedNumOperationsin interfaceTrainedModel- Returns:
- The estimated number of operations required at inference time
-
ramBytesUsed
public long ramBytesUsed()- Specified by:
ramBytesUsedin interfaceorg.apache.lucene.util.Accountable
-
getChildResources
- Specified by:
getChildResourcesin interfaceorg.apache.lucene.util.Accountable
-