Repository navigation
learning: Patchwise repeats a single item's keywords for every patch - #165
Merged
Merged
Conversation
positions with one index more than the phase encodes -- (y, x) in 2D, (z, y, x) in 3D -- are single samples on the grid, as GROG-gridded non-Cartesian samples are. A weight per position (e.g. sqrt of a density compensation) multiplies the samples, its conjugate the adjoint, and enters the normal squared; it works for whole readouts too. For single samples the normal kernel is summed straight from the samples, kept only at the places they reach, and applied between FFTs on the image grid (one coset, no doubled grid) through the same cuFFT callbacks, coil kernels and coil slabs as the Cartesian normal. Nothing the size of frames x volume is built; off the card the normal applies the compressed kernel between BART's transforms. Place coordinates become (z, y, x0) in the gather/scatter kernels so lines and points share them. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01MFB6QNUxWSoR8RjtuWacSY
With an operator, data_scaling handed |A^H y| to BART's estimate_scaling_norm, which copies it to the host and sorts the whole array for three order statistics. At 256^3 x rank 4 that is 34 s of a recon. The median, the 90th percentile, the maximum (or the asked-for percentile) are now found with torch.kthvalue at BART's indices, on the operator's card when it has one: the same rule and the same elements, to the last bit of the magnitude. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01MFB6QNUxWSoR8RjtuWacSY
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01MFB6QNUxWSoR8RjtuWacSY
…ies its probes on a device A solve's start computes A^H y anyway, and on a card a volume's probe crossing the bus twice cost a second of a 256^3 recon. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01MFB6QNUxWSoR8RjtuWacSY
…ce='cuda') sees cuda:0 as its card A host-built operator given a card probe segfaulted in BART's normal, and a solve placed on 'cuda' recursed since cuda:0 != cuda. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01MFB6QNUxWSoR8RjtuWacSY
…; scaling sorts once on a card CG(device='cuda') handed BART card vectors with a host operator and segfaulted; it now says to build the encoding on the card, as the test does. kthvalue over 67 M magnitudes took about a second on an A40; one radix sort gives the same order statistics. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01MFB6QNUxWSoR8RjtuWacSY
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01MFB6QNUxWSoR8RjtuWacSY
…of a batch A class-conditioned network (MRI2Qmap's teacher) given one label for one volume failed its shape check at batch > 1. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01MFB6QNUxWSoR8RjtuWacSY
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
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.
Patchwise._runrepeated per-item keywords (andsigma) across the patches of a call only when there was more than one item. With one volume andbatch > 1, a class-conditioned network got a label of shape(1,)forbatchpatches, and MRI2Qmap's teacher UNet failed its shape assertion (unet.py:655). Now one item's values are repeated as well.Test: a network that asserts one label and one sigma per patch, at batch 1 and 3. It fails before the fix and passes after.
Generated by Claude Code