Package ai.djl.translate
Interface NoBatchifyTranslator<I,O>
-
- All Superinterfaces:
PostProcessor<O>
,PreProcessor<I>
,Translator<I,O>
- All Known Implementing Classes:
BigGANTranslator
,QaServingTranslator
,SpeechRecognitionTranslator
,StyleTransferTranslator
,TextClassificationServingTranslator
,TextEmbeddingServingTranslator
,TokenClassificationServingTranslator
public interface NoBatchifyTranslator<I,O> extends Translator<I,O>
ATranslator
that does not use aBatchifier
.There are two major cases for avoiding the use of a
Batchifier
.First, you want to translate between
Batch
es rather thanRecord
s. For example, you might go from String[] to Int[].The second option is when using a model that does not use batching. Then, the model expects only a single record at a time.
- See Also:
Translator
-
-
Method Summary
All Methods Instance Methods Default Methods Modifier and Type Method Description default Batchifier
getBatchifier()
Returns theBatchifier
.-
Methods inherited from interface ai.djl.translate.PostProcessor
processOutput
-
Methods inherited from interface ai.djl.translate.PreProcessor
processInput
-
Methods inherited from interface ai.djl.translate.Translator
getExpansions, prepare, toBatchTranslator, toBatchTranslator
-
-
-
-
Method Detail
-
getBatchifier
default Batchifier getBatchifier()
Returns theBatchifier
.- Specified by:
getBatchifier
in interfaceTranslator<I,O>
- Returns:
- the
Batchifier
-
-