Package org.tribuo.interop.tensorflow
package org.tribuo.interop.tensorflow
Provides an interface to Tensorflow, allowing the training of non-sequential models using any supported
Tribuo output type.
There are two main interfaces for interacting with Tensorflow Tensors,
ExampleTransformer
and
OutputTransformer
, with
provide conversions to and from Tribuo's features and outputs respectively. There
are implementations of a dense feature transformation and one for images as 3d arrays,
along with output transformers for Label
and Regressor
.
N.B. Tensorflow support is experimental and may change without a major version bump.
-
ClassDescriptionDenseTransformer<T extends Output<T>>Converts a sparse example into a dense float vector, then wraps it in a
Tensor
.ExampleTransformer<T extends Output<T>>TensorFlow support is experimental, and may change without a major version bump.ImageTransformer<T extends Output<T>>Image transformer.Can convert aLabel
into aTensor
containing a 32-bit integer and can convert a vector of 32-bit floats into aPrediction
or aLabel
.OutputTransformer<T extends Output<T>>TensorFlow support is experimental, and may change without a major version bump.Can convert aRegressor
to aTensor
containing a 32-bit float and a Tensor into aPrediction
or Regressor.TensorflowCheckpointModel<T extends Output<T>>TensorFlow support is experimental, and may change without a major version bump.TensorflowCheckpointTrainer<T extends Output<T>>Trainer for Tensorflow.TensorflowExternalModel<T extends Output<T>>A Tribuo wrapper around a Tensorflow frozen model.TensorflowModel<T extends Output<T>>This model encapsulates a simple model with a single input tensor (labelledTensorflowModel.INPUT_NAME
), and produces a single output tensor (labelledTensorflowModel.OUTPUT_NAME
).TensorflowTrainer<T extends Output<T>>Trainer for Tensorflow.Helper functions for working with Tensorflow.Build and run a Tensorflow multi-class classifier for a standard dataset.