| Modifier and Type | Method and Description |
|---|---|
Criteria<I,O> |
build()
Builds a
Criteria instance. |
Criteria.Builder<I,O> |
optApplication(Application application)
Sets the model application for this criteria.
|
Criteria.Builder<I,O> |
optArgument(java.lang.String key,
java.lang.Object value)
Sets the optional model loading argument for this criteria.
|
Criteria.Builder<I,O> |
optArguments(java.util.Map<java.lang.String,java.lang.Object> arguments)
Sets an extra model loading argument for this criteria.
|
Criteria.Builder<I,O> |
optArtifactId(java.lang.String artifactId)
Sets optional artifactId of the
ModelLoader for this criteria. |
Criteria.Builder<I,O> |
optBlock(Block block)
Sets an optional model
Block for this criteria. |
Criteria.Builder<I,O> |
optDevice(Device device)
Sets the
Device for this criteria. |
Criteria.Builder<I,O> |
optEngine(java.lang.String engine)
Sets the engine name for this criteria.
|
Criteria.Builder<I,O> |
optFilter(java.lang.String key,
java.lang.String value)
Sets an extra search filter for this criteria.
|
Criteria.Builder<I,O> |
optFilters(java.util.Map<java.lang.String,java.lang.String> filters)
Sets the extra search filters for this criteria.
|
Criteria.Builder<I,O> |
optGroupId(java.lang.String groupId)
Sets optional groupId of the
ModelZoo for this criteria. |
Criteria.Builder<I,O> |
optModelName(java.lang.String modelName)
Sets an optional model name for this criteria.
|
Criteria.Builder<I,O> |
optModelPath(java.nio.file.Path modelPath)
Sets the optional model path of the
ModelLoader for this criteria. |
Criteria.Builder<I,O> |
optModelUrls(java.lang.String modelUrls)
Sets optional model urls of the
ModelLoader for this criteria. |
Criteria.Builder<I,O> |
optModelZoo(ModelZoo modelZoo)
Sets optional
ModelZoo of the ModelLoader for this criteria. |
Criteria.Builder<I,O> |
optOption(java.lang.String key,
java.lang.String value)
Sets the optional model loading option for this criteria.
|
Criteria.Builder<I,O> |
optOptions(java.util.Map<java.lang.String,java.lang.String> options)
Sets the model loading options for this criteria.
|
Criteria.Builder<I,O> |
optProgress(ai.djl.util.Progress progress)
Set the optional
Progress. |
Criteria.Builder<I,O> |
optTranslator(Translator<I,O> translator)
Sets the optional
Translator to override default Translator. |
Criteria.Builder<I,O> |
optTranslatorFactory(TranslatorFactory<I,O> factory)
Sets the optional
TranslatorFactory to override default Translator. |
<P,Q> Criteria.Builder<P,Q> |
setTypes(java.lang.Class<P> inputClass,
java.lang.Class<Q> outputClass)
Creates a new @{code Builder} class with the specified input and output data type.
|
public <P,Q> Criteria.Builder<P,Q> setTypes(java.lang.Class<P> inputClass, java.lang.Class<Q> outputClass)
P - the input data typeQ - the output data typeinputClass - the input classoutputClass - the output classpublic Criteria.Builder<I,O> optApplication(Application application)
application - the model applicationBuilderpublic Criteria.Builder<I,O> optEngine(java.lang.String engine)
engine - the engine nameBuilderpublic Criteria.Builder<I,O> optDevice(Device device)
Device for this criteria.device - the Device for the criteriaBuilderpublic Criteria.Builder<I,O> optGroupId(java.lang.String groupId)
ModelZoo for this criteria.groupId - the groupId of the ModelZooBuilderpublic Criteria.Builder<I,O> optArtifactId(java.lang.String artifactId)
ModelLoader for this criteria.artifactId - the artifactId of the ModelLoaderBuilderpublic Criteria.Builder<I,O> optModelUrls(java.lang.String modelUrls)
ModelLoader for this criteria.modelUrls - the comma delimited url stringBuilderpublic Criteria.Builder<I,O> optModelPath(java.nio.file.Path modelPath) throws java.net.MalformedURLException
ModelLoader for this criteria.modelPath - the path to the model folder/filesBuilderjava.net.MalformedURLException - wrong path formatpublic Criteria.Builder<I,O> optModelZoo(ModelZoo modelZoo)
ModelZoo of the ModelLoader for this criteria.modelZoo - ModelZoo} of the ModelLoader for this criteriaBuilderpublic Criteria.Builder<I,O> optFilters(java.util.Map<java.lang.String,java.lang.String> filters)
filters - the extra search filtersBuilderpublic Criteria.Builder<I,O> optFilter(java.lang.String key, java.lang.String value)
key - the search keyvalue - the search valueBuilderpublic Criteria.Builder<I,O> optBlock(Block block)
Block for this criteria.block - optional model Block for this criteriaBuilderpublic Criteria.Builder<I,O> optModelName(java.lang.String modelName)
modelName - optional model name for this criteriaBuilderpublic Criteria.Builder<I,O> optArguments(java.util.Map<java.lang.String,java.lang.Object> arguments)
arguments - optional model loading argumentsBuilderpublic Criteria.Builder<I,O> optArgument(java.lang.String key, java.lang.Object value)
key - the model loading argument keyvalue - the model loading argument valueBuilderpublic Criteria.Builder<I,O> optOptions(java.util.Map<java.lang.String,java.lang.String> options)
options - the model loading optionsBuilderpublic Criteria.Builder<I,O> optOption(java.lang.String key, java.lang.String value)
key - the model loading option keyvalue - the model loading option valueBuilderpublic Criteria.Builder<I,O> optTranslator(Translator<I,O> translator)
Translator to override default Translator.translator - the override TranslatorBuilderpublic Criteria.Builder<I,O> optTranslatorFactory(TranslatorFactory<I,O> factory)
TranslatorFactory to override default Translator.factory - the override TranslatorFactoryBuilderpublic Criteria.Builder<I,O> optProgress(ai.djl.util.Progress progress)
Progress.progress - the ProgressBuilder