Interface CreateModelForPool<T extends InferenceModel>
- Type Parameters:
T
- model-type
public interface CreateModelForPool<T extends InferenceModel>
Creates a model to use in the pool.
- Author:
- Owen Feehan
-
Method Summary
-
Method Details
-
create
Creates a model.- Parameters:
useGPU
- whether to use a GPU if possible (if not possible, revert to CPU).- Returns:
- the newly created model, if possible.
- Throws:
CreateModelFailedException
- if something unexpected happened. If a GPU is unavailable, prefer to returnOptional.empty()
.
-