Class HashingOptions

java.lang.Object
org.tribuo.hash.HashingOptions
All Implemented Interfaces:
com.oracle.labs.mlrg.olcut.config.Options

public class HashingOptions extends Object implements com.oracle.labs.mlrg.olcut.config.Options
An Options implementation which provides CLI arguments for the model hashing functionality.
  • Field Details

    • modelHashingAlgorithm

      @Option(longName="model-hashing-algorithm", usage="Hash the model during training, options are {NONE,MOD,HC,SHA1,SHA256}") public HashingOptions.ModelHashingType modelHashingAlgorithm
      Hash the model during training, options are {NONE,MOD,HC,SHA1,SHA256}
    • modelHashingSalt

      @Option(longName="model-hashing-salt", usage="Salt for hashing the model") public String modelHashingSalt
      Salt for hashing the model
  • Constructor Details

    • HashingOptions

      public HashingOptions()
  • Method Details

    • getHasher

      public Optional<Hasher> getHasher()
      Get the specified hasher.
      Returns:
      The configured hasher.
    • getHashedTrainer

      public <T extends Output<T>> Trainer<T> getHashedTrainer(Trainer<T> innerTrainer)
      Gets the trainer wrapped in a hashing trainer.
      Type Parameters:
      T - The output type.
      Parameters:
      innerTrainer - The inner trainer.
      Returns:
      The hashing trainer.