Repository navigation
Route NERO and NCES/CLIP trainer output through logging instead of print - #658
Merged
Merged
Conversation
Also puts the unsupported-optimizer message in the ValueError it belonged to. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This was referenced Oct 23, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Third of the
printto logger cleanup PRs (Improvements.md§3), after #656 and #657.learners/nero.py:verbose > 0messages becomelogger.info,verbose > 1oneslogger.debug(gates kept). The "queue exceeded max, stopping search" notice is now an unconditionallogger.warning, since it explains why the search ended early.nces_trainer.py,clip_trainer.py: progress/summary prints becomelogger.info; the decorative#/*banners and blank-line spacers are collapsed into single messages.raise ValueErrorfollowed byprint('Unsupported optimizer'). The print was unreachable, so the message never showed. It is nowValueError(f"Unsupported optimizer: {optimizer}").Improvements.mdoffender list refreshed from an AST count (202 to 155 realprintcalls; the old per-file numbers were stale); CHANGELOG updated.Local:
test_nero_simple,test_nces_trainer,test_clip_trainer,test_clip,test_nces,test_rocespass; ruff clean. Note: on a machine with a GPU, 6test_nero_simpletests fail with a CPU/CUDA device mismatch, identically on unmodifieddevelop(so unrelated to this PR); they pass withCUDA_VISIBLE_DEVICES="", which is what CI effectively has.🤖 Generated with Claude Code