HighOrderLowRankOp
Use HighOrderLowRankOp to apply an MRI encoding model repeatedly without materializing its full sample-by-voxel phase matrix. It combines NFFT Fourier encoding with low-rank factors for the remaining phase. The default construction is Shared low-rank: local randomized SVD (rSVD) followed by incremental spatial sharing. See the low-rank derivation for the equations, approximation stages and references.
Readout index nDyn encoding profiles of the same image. Input coefficients have shape (nTerm,nSam,nDyn), and times have shape (nSam,nDyn). The single-readout constructor also accepts a coefficient matrix and a time vector. The generated API below gives the complete signatures, defaults and return layout.
Construction methods
shared_basis_method=:shared_low_rank names the default Shared low-rank path; :rsvd remains the compatible default spelling. Opt into shared_basis_method=:joint_adaptive_low_rank with epsilon_H for a common snapshot parent, all-time fitting and empirical global H rank selection; :adaptive remains an alias. See the joint theory for its bounds, budgets and empirical/certification distinction. The older :joint retains its separate sampled per-readout checks.
A complete CPU example
This example defines a small Cartesian grid, two readouts, two coils, a nonzero static field map and a varying second-order field term. It computes synthetic samples and an adjoint backprojection; it does not solve an inverse problem or test convergence on measured data.
using HighOrderMRI
using LinearAlgebra
T = Float32
nX, nY = 8, 8
nSam, nDyn, nCha = nX * nY, 2, 2
grid = Grid(nX, nY, 1, T(1e-3), T(1e-3), T(1e-3))
# Metres, seconds, Hz; the phase coefficients use cycles and cycles/m^p.
kx = T.(-4:3) ./ (T(nX) * grid.Δx)
ky = T.(-4:3) ./ (T(nY) * grid.Δy)
times = repeat(reshape(T.(0:nSam-1) .* T(1e-5), :, 1), 1, nDyn)
kspha = zeros(T, 9, nSam, nDyn)
for i in 1:nDyn
kspha[1, :, i] .= T(0.03) * T(i)
kspha[2, :, i] .= repeat(kx, nY)
ky_samples = repeat(ky; inner=nX)
kspha[3, :, i] .= i == 1 ? ky_samples : reverse(ky_samples)
kspha[5, :, i] .= T(i) .* range(T(-500), T(500); length=nSam)
end
fieldmap = reshape(collect(range(T(-15), T(15); length=nX*nY)), nX, nY, 1)
csm = ones(Complex{T}, nX, nY, 1, nCha)
csm[:, :, 1, 2] .= Complex{T}(T(0.8), T(0.2))
mask = trues(nX, nY, 1)
image = zeros(Complex{T}, nX, nY, 1)
image[3:6, 3:6, 1] .= Complex{T}(one(T), T(0.25))
image[4:5, 4:5, 1] .= Complex{T}(T(0.5), T(-0.2))
op = HighOrderLowRankOp(grid, kspha, times;
fieldmap, csm, mask,
arrayType=Array,
shared_basis_method=:rsvd,
basis_layout=:shared,
normal_distribution=:single,
L_rank=4,
rsvd_oversample=4,
rsvd_seed=1234,
shared_rank_max=8,
shared_basis_tol=T(1e-3),
)
signal, backprojection = try
samples = reshape(op * vec(image), nSam, nDyn, nCha)
adjoint_image = reshape(adjoint(op) * vec(samples), nX, nY, 1)
samples, adjoint_image
finally
close(op)
end
@assert size(signal) == (nSam, nDyn, nCha)
@assert norm(signal) > zero(T)Samples vary fastest, then readouts, then coils. For reconstruction, preserve that ordering and form reshape(signal, nSam*nDyn, nCha) for recon_HOOp. The backprojection above is
Use the default centred Cartesian coordinates on the active NFFT axes. In 2D, only
Shared-basis construction
For each readout L_rank factors of the residual phase matrix. The sketch must satisfy L_rank + rsvd_oversample <= min(nSam,count(mask)). Incremental sharing then combines those retained spatial factors. When the basis grows, earlier saved coefficient blocks are zero-padded; they are not recomputed as projections onto the completed basis. This procedure is not a global optimal SVD.
shared_basis_tol controls the incremental compression of retained local factors. It is not a bound on the original full phase matrix or image error. Optional global_basis_tol introduces a further error relative to the already shared representation. NFFT approximation and local rSVD truncation remain separate error sources.
Optional no-add check
shared_noadd_check affects basis construction, independently of the reconstruction distribution. It is disabled by default and requires the shared, voxel-distributed CUDA rSVD path with Gram finalization.
The update still performs both projection passes and forms the full residual. It accumulates residual energy in FP64 and, when a numerical guard places that energy safely below the tolerance allowance, skips the residual-Gram matrix and its eigendecomposition. Other cases use the original path. The check does not change the requested local rank or reconstruction sample batches. It does not establish a memory or runtime benefit for a particular measured dataset.
Independent readouts
basis_layout=:per_readout retains the local factors independently, without incremental sharing or final shared-basis recompression. The resident option stores those factors on the selected array backend. CUDA also supports host factor streaming (per_readout_storage=:cpu) and regeneration from retained Q/Z factors (:regenerate), with their additional setup and cache constraints listed in the generated API. These storage modes do not select the CG partition by themselves.
Choose setup and reconstruction execution separately
rsvd_distribution controls factor construction. normal_distribution controls operator execution during iterative reconstruction; its default is :single. For rank execution it also selects the direct forward and adjoint paths.
normal_distribution | Work and persistent storage |
|---|---|
:single | CPU with arrayType=Array, or the primary GPU with CuArray. |
:channel | Coil groups. In the shared layout, every worker retains the full temporal and spatial factors; coil-map storage is partitioned. |
:rank | Shared factor columns and coil-map storage are partitioned. Complete factor and coil-map masters remain in host RAM. |
:readout | Independent readout groups, requiring basis_layout=:per_readout; every worker retains all coil maps. |
The distributed reconstruction modes require CUDA and at least two unique GPU IDs. IDs are zero based within CUDA's visible device list, and first(gpus) is the primary GPU for solver vectors. Rank execution additionally requires shared rSVD factors built by the voxel-distributed path with Gram finalization. Its worker count is at most min(length(gpus), shared_rank, nCha), so selecting several devices does not guarantee they all participate.
The setup requirement is different: explicit rsvd_distribution=:voxel accepts one or more unique GPU IDs; the list must be nonempty and must not contain more devices than masked voxels. Automatic voxel setup requires multiple GPUs, the kernel backend and Gram finalization; chunked voxel setup requires explicit selection. The generated API gives the exact combinations. Use the multi-GPU guide for complete device configurations.
Why rank execution must combine forward contributions
Coil groups contain independent observation rows, so their normal contributions can be summed. Rank groups instead contribute to the same samples. If
The implementation combines forward samples across rank workers before applying the weights and adjoint. Summing only
Sample batching and data placement
normal_sample_batch_size limits the number of sample/readout points in each rank-mode batch. Its effective size is min(nSam*nDyn, normal_sample_batch_size). It bounds sample workspaces, not complete factor columns, coil maps, image grids, solver vectors, input/output data, host masters or setup buffers. The other reconstruction distributions do not use this parameter for batching.
With the current NFFT.jl 0.14.3 GPU backend, use a full batch or an exact divisor of nSam*nDyn: its node-update path does not support a shorter final output batch. See sample batching for the backend-specific limitation. Reducing a batch cap therefore is not sufficient to establish that the complete problem fits in GPU memory.
In rank mode, op.q, op.basis and op.csm are host matrices, while solver storage is on the primary GPU. Consequently, allocating op * x returns a host vector in this mode. Use mul! with an appropriately sized GPU output, or transfer the result before reconstruction. CUDA LowRank reconstruction requires the data matrix and raw weight vector on the primary GPU; recon_HOOp does not move them automatically. It returns a CPU image.
Release owned resources
Use try/finally and close(op) after the final direct forward, adjoint or normal use. recon_HOOp releases the distributed backend by default; if release_backend=false, the caller retains that responsibility.
The parent operator owns the workers. release_highorder_normal_backend!(op) releases that backend; close(op) also releases any source streaming or regeneration queue. Closing a derived normal view alone does not release the parent's workers. For distributed normal execution, release the existing backend before changing normal weights and obtain a fresh normal view. Host factor masters remain referenced until the parent and other references are dropped. See resource lifecycle before replacing a large operator.
API
The following source-generated reference separates the operator type, the single-readout convenience constructor and the multi-readout constructor.
Operator type
HighOrderLowRankOpRepresent high-order MRI encoding with NFFT Fourier transforms and low-rank residual-phase factors. Its element type is Complex{T}, with real precision T as the first type parameter.
The zeroth-order coefficient supplies a temporal phase. In 3D, NFFT handles kx*x + ky*y + kz*z; in 2D it handles only kx*x + ky*y, leaving kz*z in the residual. Static off-resonance, selected higher-order terms, and optional concomitant terms also enter the residual. The forward phase uses exp(+2π * im * phase) and normalization 1/sqrt(nVox), where nVox is the number of masked voxels.
Shared low-rank (shared_basis_method=:shared_low_rank, legacy alias :rsvd) builds local factors for each readout i. The default remains :rsvd. basis_layout=:shared incrementally merges their spatial factors; :per_readout retains independent factors from the same rSVD front end. Local truncation, incremental sharing, and optional final recompression introduce distinct approximation errors. Incremental sharing is not a global optimal SVD of all readouts.
Construct the operator with either the single-readout or multi-readout constructor below. The object owns mutable workspaces and optional GPU workers; it and its derived normal views must not be used concurrently. Use close(op) to release owned distributed resources and streaming caches. See Low-rank theory for the factorization and Resource ownership for reuse and cleanup.
Joint adaptive low-rank (shared_basis_method=:joint_adaptive_low_rank, legacy alias :adaptive) selects the shared rank against global H error. The older :joint option retains its separate per-readout validation.
Source: src/EncodingOperator/HighOrderLowRankOp.jl
Single-readout constructor
HighOrderLowRankOp(
grid :: Grid{T} ,
kspha :: AbstractArray{T, 2} ,
times :: AbstractArray{T, 1} ;
kwargs...
) where T <: AbstractFloatConstruct the operator for one readout by adding a singleton readout dimension and forwarding to the multi-readout constructor.
kspha has shape (nTerm, nSam) with 9 or 16 solid-harmonic coefficients, and times has shape (nSam,). Their real element type matches Grid{T}. Use seconds for times when fieldmap is in Hz. Keyword options, coordinate conventions, and resource ownership are those of the multi-readout constructor.
The default nominal trajectory is obtained after reshaping kspha. An explicit k_nominal keyword must still have shape (3, nSam, 1), because keyword arguments are forwarded unchanged. concomitant accepts either (4, nSam) or (4, nSam, 1) for this overload.
The result has dimensions (nSam*nCha, prod(grid.matrixSize)) and element type Complex{T}. The image vector covers the full grid; the forward ignores masked-out voxels and the adjoint fills those voxels with zero.
Source: src/EncodingOperator/HighOrderLowRankOp.jl
Multiple-readout constructor
HighOrderLowRankOp(
grid :: Grid{T} ,
kspha :: AbstractArray{T, 3} ,
times :: AbstractArray{T, 2} ;
fieldmap :: AbstractArray{T} = zeros(T, grid.matrixSize...) ,
csm :: AbstractArray{Complex{T}} = ones(Complex{T}, grid.matrixSize..., 1) ,
mask :: AbstractArray{Bool} = trues(grid.matrixSize...) ,
concomitant = nothing ,
recon_terms :: Union{Nothing,AbstractString} = nothing ,
k_nominal :: AbstractArray{T, 3} = kspha[2:4, :, :] ,
arrayType :: Type{<:AbstractArray} = Array ,
gpus :: Vector{Int} = [0] ,
L_rank :: Int = 15 ,
rsvd_seed :: Int = 1234 ,
rsvd_chunk :: Int = 4096 ,
rsvd_oversample :: Int = 5 ,
rsvd_finalize :: Symbol = :svd ,
rsvd_backend :: Symbol = :auto ,
rsvd_distribution :: Symbol = :auto ,
basis_layout :: Symbol = :shared ,
per_readout_storage:: Symbol = :gpu ,
per_readout_cache_size:: Int = 5 ,
per_readout_gather:: Symbol = :pipeline ,
per_readout_host_cache_bytes:: Int = 0 ,
shared_rank_max :: Int = 128 ,
shared_basis_tol :: T = T(1e-2) ,
shared_noadd_check::Bool = false ,
global_basis_tol :: Union{Nothing,T} = nothing ,
shared_basis_method:: Symbol = :rsvd ,
epsilon_H :: Union{Nothing,Real} = nothing ,
adaptive_options :: NamedTuple = (;) ,
joint_snapshots :: Int = 256 ,
joint_samples :: Int = 512 ,
joint_roi_tol :: Union{Nothing,T} = nothing ,
joint_basis_report:: Union{Nothing,Ref} = nothing ,
normal_distribution:: Symbol = :single ,
normal_sample_batch_size:: Int = 12_000_000 ,
nfft_center_correction :: Bool = true ,
verbose :: Bool = false ,
) where T <: AbstractFloatConstruct a low-rank encoding operator for nDyn readouts. The defaults use CPU arrays, local rSVD, a shared spatial basis, and single-device execution. The keyword normal_distribution selects reconstruction execution; rsvd_distribution independently selects how the factors are built.
shared_basis_method=:shared_low_rank names the default Shared low-rank front end; :rsvd remains its compatible default spelling.
shared_basis_method=:joint_adaptive_low_rank, epsilon_H=0.01 opts into experimental Joint adaptive low-rank. The legacy alias :adaptive remains supported. It builds a stable snapshot master, fits all actual time rows, then uses blocked QR/small SVD and paired residual checks to select the final shared rank. K, J and the parent cap start at 128, 512 and 32; only a failed check triggers bounded expansion. shared_rank_max remains the hard parent cap. adaptive_options forwards resource and evaluation keywords to joint_adaptive_spatial_basis; rsvd_seed and rsvd_chunk provide its seed and chunk size. No NFFT setting changes.
The target is the global relative Frobenius error of the pure residual H over all readouts and masked voxels. It excludes k0, first-order NFFT, center phase, CSM, weights and normalization. The checks are empirical: sqrt(mean(loss)+4SE) is a heuristic, not a probability certificate or an image-error guarantee. joint_basis_report receives construction, empirical, external-audit and certification states without retaining factor arrays. Budget failure fills that report and throws instead of constructing an operator from partial factors. Existing shared_basis_tol and global_basis_tol retain their old meanings; Joint adaptive low-rank requires global_basis_tol=nothing and does not impose joint_roi_tol.
The older :joint method and its joint_* sampling controls remain available with their existing per-readout validation semantics.
Inputs and coordinate convention
grid: reconstruction grid with shape(nX,nY,nZ). NFFT assumes the centered regular coordinates implied by its dimensions and voxel spacings on the active Fourier axes. Arbitrarily transforming those coordinates is not accounted for bynfft_center_correction.kspha:(nTerm,nSam,nDyn)time-integrated solid-harmonic coefficients, withnTerm=9or16. Readout indexiselectskspha[:,:,i]. The basis ordering and normalization must matchbasisfunc_spha.times:(nSam,nDyn)sample times. Use seconds with a field map in Hz; each coefficient times its spatial basis must likewise give phase in cycles.fieldmap: real off-resonance map of shape(nX,nY,nZ); the default is zero.csmcontains complex coil maps of shape(nX,nY,nZ,nCha)and defaults to one coil with unit sensitivity.maskis a Boolean grid mask, all true by default. FornZ==1, shapes(nX,nY)forfieldmap/maskand(nX,nY,nCha)forcsmare accepted. Use consistent real precisionTand complex precisionComplex{T}.concomitant=nothing: optional(4,nSam,nDyn)integrated coefficients forz²,x²+y²,xz, andyz.(4,nSam)is also accepted whennDyn==1. With coordinates in metres, coefficients are in cycles/m² in the same frame and origin. These terms enter the residual independently ofrecon_terms; they are already integrated and are not multiplied bytimesagain.recon_terms=nothing: resolve to"111"for 9 coefficients or"1111"for 16. The binary digits select zeroth-, first-, second-, and third-order terms. A zero removes the selected order except at first order, where it substitutesk_nominal. This substitution preserves nominal Fourier encoding rather than removing it.k_nominalhas shape(3,nSam,nDyn), orderedkx,ky,kz; its default is the supplied first-order coefficients. First-order coefficients use cycles per coordinate-length unit.
In 2D, NFFT uses only kx,ky; any kz*z phase stays in the low-rank residual. In 3D all three linear terms enter NFFT. The nodes on each active axis are -k*Δ, with that axis's voxel spacing Δ. Keep nfft_center_correction=true to include the half-voxel phase on even-sized axes; odd-sized axes need no such phase. Zeroth-order phase, this correction, and 1/sqrt(nVox) are folded into q once.
Local rSVD and shared approximation
L_rank=15is the local truncation rank for every readout, not the final shared rank.rsvd_oversample=5sets the extra sketch width. RequireL_rank>0,rsvd_oversample>=0, andL_rank+rsvd_oversample <= min(nSam,nVox), wherenVox=sum(mask).rsvd_seed=1234: readoutiuses seedrsvd_seed+i-1. Repeatability requires the same backend and setup configuration; changing device count or numerical libraries is not a bitwise-reproducibility guarantee.rsvd_backend=:autochooses:chunkedforArrayand:kernelforCuArray. Explicit:kernelrequires CUDA.rsvd_chunk=4096must be positive and is capped atnVox; it controls voxel chunks for the chunked phase products. It is not a limit on all setup arrays or factor storage.rsvd_finalize=:svdtakes an SVD of the projected adjoint matrix.:gramuses a small Gram eigendecomposition to recover the retained factors. Both absorb the singular values into the spatial factors; finite-precision Gram calculations can lose accuracy in weak directions.rsvd_distribution=:singlebuilds on the selected CPU or primary GPU. Explicit:voxelrequiresCuArray,rsvd_finalize=:gram, and backend:kernelor:chunked. One GPU is accepted; multiple GPUs divide masked voxels. The current partitioning requires at least one voxel per selected setup GPU.:autochooses voxel distribution only with CUDA, multiple GPUs, kernel products, and Gram finalization. Chunked voxel setup requires explicit:voxel.basis_layout=:sharedincrementally merges the local spatial factors.shared_rank_max=128is a positive cap, clamped tomin(nVox,L_rank*nDyn)for this path; exceeding it throws rather than silently relaxing the tolerance.shared_basis_tol=T(1e-2)controls the additional relative Frobenius residual of each local spatial factorV_i*Σ_iunder the shared projection. It is not an error target for the original phase matrix or reconstructed image. Use a finite nonnegative tolerance below one. Earlier readout coefficients receive zero rows when the basis grows; they are not recomputed by a final global projection.global_basis_tol=nothingpreserves the incrementally shared factors. A nonnegative value of typeTapplies a final spectral recompression of that representation, introducing an additional error. This requires shared layout. Use a tolerance below one: the implementation accepts larger values, but its discarded-energy diagnostic is unreliable atglobal_basis_tol>=1because it retains at least one direction.
Local truncation, shared projection, final recompression, and NFFT approximation are separate sources of error. A fixed L_rank does not certify a total phase-matrix or image error. See Low-rank theory for the factor definitions and references.
Optional no-add check
shared_noadd_check=false by default. Enabling it requires shared, voxel-distributed rSVD. Once a shared basis exists, the update keeps its two projection passes and forms the same explicit residual. It accumulates the residual energy in FP64 and applies a guard near the tolerance threshold. When that check accepts the existing basis, it skips the residual Gram matrix and eigendecomposition; otherwise it follows the usual update.
This option changes basis construction only. It does not select a CG execution strategy, reduce L_rank, change the tolerance, or remove the residual workspace. Its early-return diagnostic uses the full residual norm, which can differ from the ordinary diagnostic after tiny residual eigenvalues are discarded. That diagnostic difference is not fed back into the factors. The FP64 reduction does not make the preceding projection arithmetic FP64.
Independent factors and storage
basis_layout=:per_readout keeps each readout's local factors independently. The shared-rank cap and shared tolerance do not control those factors; global_basis_tol and shared_noadd_check=true are unsupported here.
per_readout_storage=:gpumaterializes the spatial bank onarrayType. Despite the name, it uses CPU arrays witharrayType=Array.:cpurequiresCuArrayexecution and keeps the complete spatial bank in host RAM, transferring readout blocks into a bounded GPU cache.:regeneratealso requires CUDA and voxel-distributed kernel/Gram setup. It retains the original rSVDQ/Zand model maps, then generates uncached spatial blocks as(H_iᴴ*Q_i)*Z_i. It avoids materializing the full spatial bank, but retains metadata and regeneration workspaces and adds arithmetic. Regenerated factors are not promised to be bitwise identical to materialized factors.per_readout_cache_size=5is the positive number of resident readout slots per GPU, capped by the number of readouts. The streaming cache uses one pinned host staging buffer and completion events to protect reuse. With regeneration, one slot serializes production/use; multiple slots permit lookahead. These caches are used by forward, adjoint, and normal execution.per_readout_gather=:pipelineoverlaps voxel-distributed setup downloads and host writes using two pinned buffers per GPU.:synchronoususes a blocking gather. This choice does not change single-device setup.per_readout_host_cache_bytes=0is a nonnegative host budget for complete spatial blocks in regeneration mode. A fixed, evenly spaced subset of readouts is materialized during setup, shared by worker caches, and reused. Q/Z and model maps are additional storage outside this budget.
Execution, communication and sample batching
Use arrayType=Array for CPU execution or CuArray for CUDA. gpus=[0] contains unique zero-based CUDA-visible IDs; it must be nonempty. first(gpus) is the primary GPU for solver vectors. The public constructor has no separate primary_gpu keyword. Request at least two IDs for :channel, :readout, or :rank, all of which require CUDA:
normal_distribution=:singleis the default CPU or primary-GPU path.:channeldivides coils, retaining complete shared factors on each active worker. Independent factors can instead use the selected per-readout storage scheme. This mode does not partition shared-rank columns.:readoutdivides independent readouts and requires per-readout layout; each worker retains all coil maps. Workers sum contributions from disjoint observation rows.:rankdivides shared temporal/spatial columns and coil-map storage while retaining complete host master factors. It requires shared layout and either voxel-distributed ordinary rSVD with Gram finalization or adaptive global-H setup. At mostmin(length(gpus),shared_rank,nCha)workers are used. For each coil and sample batch, partial forward signals are copied to host buffers, summed, and broadcast to the workers before weighting and the adjoint. This retains the cross-rank terms ofAᴴ Wᴴ W A. Image contributions are also summed through host buffers. Channel/readout normal products likewise stage image broadcasts and reductions through the host.
Channel/readout workers initialize on the first normal request. Selected adjoint paths reuse them afterward; a standalone forward still uses the parent's single-device path. Rank workers initialize on the first forward, adjoint, or normal request. Allow at least one Julia default thread per active GPU worker, and a coordinator thread where possible.
normal_sample_batch_size=12_000_000 must be positive in every mode, but only rank execution uses it. Its effective size is min(nSam*nDyn,normal_sample_batch_size), in sample/readout points per coil. It bounds sample workspaces, not full temporal-factor columns, spatial factors, coil maps, image/NFFT grids, solver vectors, complete input/output data, or setup allocations. Smaller batches repeat transforms and transfers.
With the default NFFT.jl 0.14.3 GPU plans, use a full batch or a divisor of nSam*nDyn: the current node-update path does not update all output-shape metadata for a shorter final batch. The optional NonuniformFFTs backend supports variable-length nodes; select the backend before construction and keep it fixed while the operator is in use. See Multi-GPU execution for configuration and memory tradeoffs.
Result, weighting and resources
The result is a HighOrderLowRankOp with element type Complex{T} and shape (nSam*nDyn*nCha, prod(grid.matrixSize)). Forward data order matches vec(data) for data shaped (nSam,nDyn,nCha): samples vary fastest, then readouts, then coils. Image vectors cover the full grid; the forward ignores masked-out voxels and the adjoint sets them to zero.
For shared layout, q has shape (nSam*nDyn,shared_rank) and basis has shape (nVox,shared_rank). For per-readout layout, q has shape (nSam*nDyn,L_rank) and the logical spatial bank has shape (nVox,L_rank*nDyn). Regeneration stores that bank implicitly.
In rank mode, q, basis, and csm are host matrices, while solver storage is CUDA storage on the primary GPU. The allocating expression op*x follows q and therefore returns a host vector. mul! accepts a preallocated GPU output. For CUDA recon_HOOp, explicitly place data and raw weights on the primary GPU; that wrapper does not move them automatically.
recon_HOOp receives raw weights w and constructs Aᴴ diag(abs2(w)) A. A direct optimized normalOperator(op,D) instead expects real, nonnegative weights already representing WᴴW, identical for each coil. For :channel, :readout, or :rank, release the cached distributed backend before changing these normal weights and create a fresh view. The :single path has no such owned distributed backend. Positive semidefiniteness of the data normal alone does not establish the positive-definite conditions needed for the usual CG convergence guarantee.
The parent owns distributed workers, plans, and workspaces. By default, recon_HOOp releases that backend in finally; it retains the parent's factors and source cache. For direct use, or release_backend=false, call close(op) in a finally block. close(op) also closes the parent's streaming/regeneration cache; closing a derived normal view alone does not. Factor arrays and any parent-resident plan remain referenced by the parent, so closing is not equivalent to dropping the entire operator. Later use can rebuild owned resources; obtain fresh normal views after release.
The operator and its views share mutable workspaces and are not reentrant. When replacing a large operator, close it and drop old references before constructing the replacement; @rebuild_HOOp provides this sequence for a plain variable. See Resource ownership for details.
verbose=false suppresses optional setup progress and diagnostic timing; some constructor information is still logged unconditionally. Execution cost and memory feasibility depend on the data, rank, backend and hardware.