loadModel method

Future<void> loadModel()

モデルをロード

Implementation

Future<void> loadModel() async {
  _options.threads = 4;

  try {
    await _interpreter.fromAsset(
      'assets/mlmodels/evaluate_pose_model.tflite',
      options: _options,
    );

    if (kDebugMode) {
      print('Interpreter loaded successfully');
    }
  } catch (_) {
    throw ServiceException(
      ServiceErrorType.loadModelError,
      ServiceErrorType.loadModelError.message,
    );
  }
}