pypi ultralytics 8.4.81
v8.4.81 - Fix `ValueError` in FastSAM `prompt()` with multiple text prompts (#24952)

5 hours ago

🌟 Summary

This release is mainly a stability and export-quality update for Ultralytics, led by an important FastSAM fix for multiple text prompts 🧠, plus clearer and stricter model export precision handling, better YOLO26 coverage, and several reliability improvements across platforms and integrations πŸš€

πŸ“Š Key Changes

  • πŸ› οΈ FastSAM multiple text prompts no longer crash

    • Fixed a ValueError in FastSAMPredictor.prompt() when users passed more than one text prompt.
    • This especially affected common cases where some small masks were filtered out before prompt matching.
    • The fix vectorizes the index remapping, so lists like ["a photo of a dog", "a photo of a person"] now work as documented.
  • πŸ“¦ Export precision behavior is now clearer and stricter

    • Export logic was cleaned up to use quantize= consistently instead of relying on older half=True / int8=True internal state.
    • Unsupported precision requests now fail clearly instead of silently changing to something else.
    • Examples:
      • CoreML FP32 stays FP32 when requested
      • CPU TorchScript FP16 now raises a clear error instead of quietly falling back
      • Format-specific precision support is better documented
  • πŸ“˜ Export docs got a major accuracy upgrade

    • Many integration docs were updated to explain exactly which precisions each format supports, including:
      • CoreML
      • TorchScript
      • OpenVINO
      • MNN
      • RKNN
      • TensorFlow formats
      • ExecuTorch
      • Sony IMX500
    • This makes deployment choices easier and reduces trial-and-error.
  • πŸ€– YOLO26 became the main export smoke-test model in more places

    • Export smoke tests were updated from YOLO11 to YOLO26 for several formats.
    • This helps ensure the latest recommended model family is tested more directly in CI and export workflows.
  • 🧬 Embedding behavior is more intuitive

    • model.embed() and model.predict() now behave better when used back-to-back.
    • After extracting embeddings, a normal model.predict() call returns standard Results again instead of unexpectedly staying in embedding mode.
  • ⚑ Faster, safer imports for standard YOLO use

    • SAM/SAM3-related imports were made lazier, so normal Ultralytics imports won’t eagerly load optional torchvision pieces.
    • This fixes startup issues like missing torchvision::nms in environments that don’t need SAM at all.
  • πŸͺŸ Windows ONNXRuntime C++ example handles non-ASCII paths better

    • The ONNXRuntime C++ model loader now uses a Windows-safe filesystem path conversion.
    • This improves compatibility for model files stored in folders with UTF-8 or non-English characters.
  • 🧩 Axelera export reliability improved

    • Added a numpy<=2.3.5 pin to avoid broken YOLO26 attention-graph exports.
    • Export output validation was tightened so suspiciously tiny models fail loudly instead of being reported as successful.
  • πŸ“„ Hailo documentation was clarified

    • The docs now more clearly explain that Hailo HEF is currently a manual ONNX-to-HEF workflow, not yet a direct model.export(format="hailo") target.
    • Notes were expanded around YOLO11, YOLO26, supported tasks, and Hailo hardware/SDK differences.

🎯 Purpose & Impact

  • βœ… FastSAM is more usable for natural-language prompting

    • Users working with multiple text prompts can now rely on FastSAM without random crashes.
    • This is the most user-visible fix in the release and especially helpful for prompt-based segmentation workflows.
  • πŸ”’ Exports are more trustworthy

    • If you request a precision the target format cannot actually support, Ultralytics now tells you immediately.
    • This prevents hidden precision mismatches that could lead to confusing model size, speed, or accuracy results.
  • πŸš€ YOLO26 deployment confidence improves

    • Since YOLO26 is the latest stable and recommended Ultralytics model, broader smoke-test coverage means better confidence when exporting it to different runtimes and hardware.
  • 😊 Prediction and embedding workflows feel less surprising

    • Developers switching between feature extraction and normal inference should hit fewer gotchas.
  • 🧯 Fewer environment-related failures

    • Lazy SAM imports reduce import-time breakage in setups that only need standard YOLO tasks.
    • Windows path fixes and stricter export validation also reduce frustrating edge-case failures.
  • πŸ“š Better guidance for non-experts and deployers

    • The docs now do a better job of explaining what each export target really supports, helping users choose the right deployment format without guesswork.

Overall, v8.4.81 is a polish-and-reliability release ✨: it fixes an important FastSAM bug, makes export precision behavior much safer, and strengthens YOLO26 deployment readiness across the stack.

What's Changed

Full Changelog: v8.4.80...v8.4.81

Don't miss a new ultralytics release

NewReleases is sending notifications on new releases.