Class FeatureSetProvenance

java.lang.Object
org.tribuo.provenance.FeatureSetProvenance
All Implemented Interfaces:
com.oracle.labs.mlrg.olcut.provenance.ObjectProvenance, com.oracle.labs.mlrg.olcut.provenance.Provenance, Serializable, Iterable<com.oracle.labs.mlrg.olcut.util.Pair<String,com.oracle.labs.mlrg.olcut.provenance.Provenance>>

public final class FeatureSetProvenance extends Object implements com.oracle.labs.mlrg.olcut.provenance.ObjectProvenance
Contains provenance information for an instance of a SelectedFeatureSet.

Made up of the class name of the feature set object, the provenance of the training data, the provenance of the selection algorithm and the Tribuo version.

See Also:
  • Constructor Details

    • FeatureSetProvenance

      public FeatureSetProvenance(String className, DatasetProvenance datasetProvenance, FeatureSelectorProvenance fsProvenance)
      Creates a feature set provenance tracking the dataset provenance and feature selector provenance.
      Parameters:
      className - The class name of the host object (usually SelectedFeatureSet).
      datasetProvenance - The dataset provenance.
      fsProvenance - The feature selector provenance.
    • FeatureSetProvenance

      public FeatureSetProvenance(Map<String,com.oracle.labs.mlrg.olcut.provenance.Provenance> map)
      Used by the provenance unmarshalling system.

      Throws ProvenanceException if there are missing fields.

      Parameters:
      map - The provenance map.
  • Method Details

    • getDatasetProvenance

      public DatasetProvenance getDatasetProvenance()
      The training dataset provenance.
      Returns:
      The training dataset provenance.
    • getFeatureSelectorProvenance

      public FeatureSelectorProvenance getFeatureSelectorProvenance()
      The feature selector provenance.
      Returns:
      The feature selector provenance.
    • getTribuoVersion

      public String getTribuoVersion()
      The Tribuo version used to create this feature set.
      Returns:
      The Tribuo version.
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • getClassName

      public String getClassName()
      Specified by:
      getClassName in interface com.oracle.labs.mlrg.olcut.provenance.ObjectProvenance
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • internalProvenances

      protected List<com.oracle.labs.mlrg.olcut.util.Pair<String,com.oracle.labs.mlrg.olcut.provenance.Provenance>> internalProvenances()
      Returns a list of all the provenances in this model provenance so subclasses can append to the list.
      Returns:
      A list of all the provenances in this class.
    • iterator

      public Iterator<com.oracle.labs.mlrg.olcut.util.Pair<String,com.oracle.labs.mlrg.olcut.provenance.Provenance>> iterator()
      Calls internalProvenances() and returns the iterator from that list.
      Specified by:
      iterator in interface Iterable<com.oracle.labs.mlrg.olcut.util.Pair<String,com.oracle.labs.mlrg.olcut.provenance.Provenance>>
      Returns:
      An iterator over all the provenances.