public interface SequenceOutputConverter<T extends Output<T>> extends com.oracle.labs.mlrg.olcut.config.Configurable, com.oracle.labs.mlrg.olcut.provenance.Provenancable<com.oracle.labs.mlrg.olcut.provenance.ConfiguredObjectProvenance>, Serializable
N.B. TensorFlow support is experimental and may change without a major version bump.
Modifier and Type | Method and Description |
---|---|
List<List<Prediction<T>>> |
decode(org.tensorflow.Tensor outputs,
List<SequenceExample<T>> inputBatch,
ImmutableOutputInfo<T> labelMap)
Decode graph output tensors corresponding to a batch of input sequences.
|
List<Prediction<T>> |
decode(org.tensorflow.Tensor output,
SequenceExample<T> input,
ImmutableOutputInfo<T> labelMap)
Decode a tensor of graph output into a list of predictions for the input sequence.
|
TensorMap |
encode(List<SequenceExample<T>> batch,
ImmutableOutputInfo<T> labelMap)
Encodes a batch of labels as a feed dict.
|
TensorMap |
encode(SequenceExample<T> example,
ImmutableOutputInfo<T> labelMap)
Encodes an example's label as a feed dict.
|
List<Prediction<T>> decode(org.tensorflow.Tensor output, SequenceExample<T> input, ImmutableOutputInfo<T> labelMap)
output
- graph outputinput
- original input sequence examplelabelMap
- label domainList<List<Prediction<T>>> decode(org.tensorflow.Tensor outputs, List<SequenceExample<T>> inputBatch, ImmutableOutputInfo<T> labelMap)
outputs
- a tensor corresponding to a batch of outputs.inputBatch
- the original input batch.labelMap
- label domainTensorMap encode(SequenceExample<T> example, ImmutableOutputInfo<T> labelMap)
example
- the input examplelabelMap
- label domainTensorMap encode(List<SequenceExample<T>> batch, ImmutableOutputInfo<T> labelMap)
batch
- a batch of examples.labelMap
- label domainCopyright © 2015–2021 Oracle and/or its affiliates. All rights reserved.