kernel-insect-classifier / docs /deployment.md
ganesh333's picture
Upload folder using huggingface_hub
575e16b verified
|
Raw History Blame Contribute Delete
1.48 kB

Local deployment

Desktop / local service integration

The supported entry point is src.inference.predict_wav. Install requirements and keep model.h5, config.json, labels.json, and src/ together. There is no network dependency in the inference code.

Android / Kernel integration notes

Kernel's supplied architecture requires all live inference to remain on-device. This package is a Python/PyTorch training artifact, not yet a drop-in Android artifact. Before shipping:

  1. Freeze the audio frontend and compare it against the training implementation using a golden WAV fixture.
  2. Convert the model to an Android-supported runtime (e.g. LiteRT/TFLite) and test numerical parity; do not rename .pt/.h5 to .tflite.
  3. Benchmark on the actual iQOO 15: latency, thermal/battery, noise, sample-rate path and memory.
  4. Validate with field-collected grain-pest recordings and verified physical inspections.
  5. Keep outputs experimental until false-positive, false-negative, uncertainty and cross-device performance are evaluated.
  6. Store model version, audio quality and human-verified outcome separately. Never treat a Clean prediction as proof of pest-free grain.

Suggested production architecture

Microphone -> signal-quality gate -> exactly matched local preprocessing -> local model -> experimental result UI -> local SQLite record. GCP services, if enabled, should sync only authorized metadata and must not receive raw audio or perform inference.