Class MutableClusteringInfo
java.lang.Object
org.tribuo.clustering.ClusteringInfo
org.tribuo.clustering.MutableClusteringInfo
- All Implemented Interfaces:
Serializable,MutableOutputInfo<ClusterID>,OutputInfo<ClusterID>,ProtoSerializable<org.tribuo.protos.core.OutputDomainProto>
A mutable
ClusteringInfo. Can record new observations of ClusterIDs, incrementing the
appropriate counts.- See Also:
-
Field Summary
Fields inherited from class org.tribuo.clustering.ClusteringInfo
clusterCounts, unknownCountFields inherited from interface org.tribuo.protos.ProtoSerializable
DESERIALIZATION_METHOD_NAME, PROVENANCE_SERIALIZER -
Method Summary
Modifier and TypeMethodDescriptionvoidclear()Clears the OutputInfo, removing all things it's observed.copy()Generates a copy of this OutputInfo, including it's mutability.static MutableClusteringInfodeserializeFromProto(int version, String className, com.google.protobuf.Any message) Deserialization factory.voidRecords an output value or statistics thereof.Methods inherited from class org.tribuo.clustering.ClusteringInfo
equals, generateImmutableOutputInfo, generateMutableOutputInfo, getDomain, getUnknownCount, hashCode, outputCountsIterable, serialize, size, toReadableString, toStringMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface org.tribuo.OutputInfo
generateImmutableOutputInfo, generateMutableOutputInfo, getDomain, getUnknownCount, outputCountsIterable, size, toReadableStringMethods inherited from interface org.tribuo.protos.ProtoSerializable
serialize
-
Method Details
-
deserializeFromProto
public static MutableClusteringInfo deserializeFromProto(int version, String className, com.google.protobuf.Any message) throws com.google.protobuf.InvalidProtocolBufferException Deserialization factory.- Parameters:
version- The serialized object version.className- The class name.message- The serialized data.- Returns:
- The deserialized object.
- Throws:
com.google.protobuf.InvalidProtocolBufferException- If the protobuf could not be parsed from themessage.
-
observe
Description copied from interface:MutableOutputInfoRecords an output value or statistics thereof.- Specified by:
observein interfaceMutableOutputInfo<ClusterID>- Parameters:
output- The observed output.
-
clear
public void clear()Description copied from interface:MutableOutputInfoClears the OutputInfo, removing all things it's observed.- Specified by:
clearin interfaceMutableOutputInfo<ClusterID>
-
copy
Description copied from interface:OutputInfoGenerates a copy of this OutputInfo, including it's mutability.- Specified by:
copyin interfaceOutputInfo<ClusterID>- Specified by:
copyin classClusteringInfo- Returns:
- A copy of the OutputInfo.
-