Skip to content

Conversation

@LINYV0719
Copy link

Description

This PR adds a min_delta parameter to NewBestMetric. Motivation: In many training scenarios, we want to avoid saving checkpoints or triggering actions for negligible improvements (e.g., floating point noise). min_delta allows users to specify a minimum threshold for improvement. Changes:

Added min_delta to NewBestMetric.init.

Updated test() logic to require new_value > best_value + min_delta (if higher is better).

Added unit test test_new_best_metric_with_min_delta in new_best_metric_test.py.

Type of change

For a new feature or function, please create an issue first to discuss it
with us before submitting a pull request.

Note: Please delete options that are not relevant.

  • New feature (non-breaking change which adds functionality)

Tests

I added a new test case test_new_best_metric_with_min_delta in orbit/actions/new_best_metric_test.py to verify the new functionality.

Test Configuration:

  • OS: Windows 11
  • Python Version: 3.10
  • Command: python -m orbit.actions.new_best_metric_test
  • Result: Passed

Checklist

@LINYV0719 LINYV0719 requested a review from a team as a code owner December 27, 2025 09:17
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