Skip to content

fix(utils): clean the configured tensorboard_path, not only the runs/ dir#90

Merged
bartzbeielstein merged 1 commit into
mainfrom
fix/tensorboard-clean-path
Jun 7, 2026
Merged

fix(utils): clean the configured tensorboard_path, not only the runs/ dir#90
bartzbeielstein merged 1 commit into
mainfrom
fix/tensorboard-clean-path

Conversation

@bartzbeielstein
Copy link
Copy Markdown
Contributor

tensorboard_clean=True previously removed subdirectories of a hardcoded relative runs directory in the CWD and ignored tensorboard_path entirely — with an explicit path the flag deleted unrelated logs and left the actual log directory untouched.

Now, when tensorboard_path is set, the configured directory itself is removed (and re-created empty by the writer), so every run starts with a fresh dashboard. Without a path, the legacy runs/ subdirectory cleanup is kept.

  • test_clean_with_custom_tensorboard_path updated to the new semantics (stale event file removed, unrelated runs/ untouched)
  • new: clean honors a custom path with logging disabled; missing custom path handled gracefully
  • full suite: 1747 passed

Enables spotforecast2's SpotOptimStrategy to default tensorboard_clean=True for fresh per-run dashboards.

🤖 Generated with Claude Code

… dir

tensorboard_clean=True previously removed subdirectories of a hardcoded
relative "runs" directory in the CWD and ignored tensorboard_path
entirely - with an explicit path the flag deleted unrelated logs and
left the actual log directory untouched. Now, when tensorboard_path is
set, the configured directory itself is removed (and re-created empty
by the writer), so every run starts with a fresh dashboard; without a
path the legacy runs/ cleanup is kept.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@bartzbeielstein bartzbeielstein merged commit 3547b89 into main Jun 7, 2026
5 checks passed
@bartzbeielstein bartzbeielstein deleted the fix/tensorboard-clean-path branch June 7, 2026 16:01
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