Skip to content

Conversation

glenn-jocher
Copy link
Member

@glenn-jocher glenn-jocher commented Aug 20, 2022

Signed-off-by: Glenn Jocher [email protected]

🛠️ PR Summary

Made with ❤️ by Ultralytics Actions

🌟 Summary

Enhanced batch size selection in autobatch for more robust performance.

📊 Key Changes

  • Added a safety check to ensure the batch size does not fall below 1.

🎯 Purpose & Impact

  • Purpose: Prevents potential errors or crashes when the automatic batch calculation inadvertently suggests a batch size of zero or negative.
  • Impact: Improves the reliability of model inference by ensuring a sensible default batch size, enhancing user experience and stability across various circumstances. 🛡️

@glenn-jocher glenn-jocher self-assigned this Aug 20, 2022
@glenn-jocher glenn-jocher merged commit a409ec7 into master Aug 20, 2022
@glenn-jocher glenn-jocher deleted the glenn-jocher-patch-1 branch August 20, 2022 14:29
ctjanuhowski pushed a commit to ctjanuhowski/yolov5 that referenced this pull request Sep 8, 2022
* AutoBatch protect from negative batch sizes

Signed-off-by: Glenn Jocher <[email protected]>

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* cleanup

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

Signed-off-by: Glenn Jocher <[email protected]>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant