ModelPaths class

Absolute filesystem paths to the ML model files each feature needs.

Core no longer bundles any models. Each model is loaded at runtime from a path supplied here, delivered by an opt-in asset package (e.g. vision_ai_models for hand/face, vision_ai_animals for animal models).

A path is required only when its feature is enabled:

  • handModel — gesture .task, required when a HandConfig is provided.
  • emotionModel — emotion .tflite, required when FaceConfig.detectEmotion is true.
  • animalModel — object-detector .tflite, required when an AnimalConfig is provided.
  • breedModel — breed classifier .tflite, required when AnimalConfig.detectBreed is true.
  • poseModel — MediaPipe Pose Landmarker .task, required when a PoseConfig is provided.

Constructors

ModelPaths({String? handModel, String? emotionModel, String? animalModel, String? breedModel, String? poseModel})
const

Properties

animalModel → String?
Path to the TFLite object-detector model used for animal detection.
final
breedModel → String?
Path to the TFLite breed/species classifier model.
final
emotionModel → String?
Path to the TFLite emotion classifier model.
final
handModel → String?
Path to the MediaPipe gesture recognizer .task bundle.
final
hashCode → int
The hash code for this object.
no setterinherited
poseModel → String?
Path to the MediaPipe Pose Landmarker .task bundle.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

copyWith({String? handModel, String? emotionModel, String? animalModel, String? breedModel, String? poseModel}) → ModelPaths
Returns a copy with the given fields replaced. Lets a companion package merge its own model paths onto paths supplied by another package.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited