Closes #132.#134
Open
mgflast wants to merge 2 commits into
Open
Conversation
A tilt-series XML can carry NaN/Inf alignment values when an upstream alignment (AreTomo, patch-tracking) fails without being flagged. This shouldn't ever happen but sometimes it does - it did for me in 1 out of 55 datasets. `_validate_tilt_series_dimensions` doesn't catch this, so the NaN propagates into the training loss whenever the corrupted tilt series is sampled. This PR adds a check for NaNs during the initialization stage of training. It scans every XML, moves any tilt-series with corrupted alignments into `<training_directory>/excluded_nonfinite_alignment/`, and prints how many were skipped and how many remain (raising only if none remain). Every step re-globs `training_directory/*.xml`, so moving the offenders out leaves them out everywhere (training and the alignment step). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Updated the installation command for torch-projectors to use the default index URL.
Collaborator
|
Thanks for the PR! Can you also add the check to the infer.py script? (commit was needed to get the tests running) |
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.
A tilt-series XML can carry NaN/Inf alignment values when an upstream alignment (AreTomo, patch-tracking) fails without being flagged. This shouldn't ever happen but sometimes it does - it did for me in 1 out of 55 datasets.
_validate_tilt_series_dimensionsdoesn't catch this, so the NaN propagates into the training loss whenever the corrupted tilt series is sampled.This PR adds a check for NaNs during the initialization stage of training. It scans every XML, moves any tilt-series with corrupted alignments into
<training_directory>/excluded_nonfinite_alignment/, and prints how many were skipped and how many remain (raising only if none remain). Every step re-globstraining_directory/*.xml, so moving the offenders out leaves them out everywhere (training and the alignment step).