loadModel method
Loads the YOLO model for inference.
This method must be called before predict to initialize the model.
Returns true if the model was loaded successfully, false otherwise.
Example:
final ok = await yolo.loadModel();
throws ModelLoadingException if the model file cannot be found
Implementation
Future<bool> loadModel() async {
await _ensureResolved();
final success = await _modelManager!.loadModel();
if (success) {
_isInitialized = true;
}
return success;
}