Repository navigation
Add a cuDSS GPU solver for Maxwell frequency sweeps - #77
xtalax-droid wants to merge 25 commits into
Conversation
CuDSSSolver() is a solve_sweep solver that factorises the sweep operator on an NVIDIA GPU through the FiniteElementMethodCUDSSExt extension (using CUDA, CUDSS). The first frequency uploads A in CSR layout and runs analysis and factorisation; later frequencies gather the new values through a CSR permutation computed once on the host, copy only nzval to the device and refactorise. All port columns are solved in one call. The host-side CSR layout and value update are tested on the CPU in the Maxwell group; a new opt-in GPU group checks that the extension loads and infers (JET) and compares the GPU sweep with UMFPACK only when CUDA is functional. CUDSS compat is 0.8, 1 because ArrayInterface and LinearSolve cap CUDSS below 1 today. Agent-Harness: Claude Code 2.1.318 Agent-Model: claude-opus-5-5 Agent-Session: ee6a670e-e4ec-446c-b941-3ebb999c45c5 Agent-Review: unreviewed Co-authored-by: Claude Code <agent@noreply.juliahub.com>
Agent-Harness: Claude Code 2.1.318 Agent-Model: claude-opus-5-5 Agent-Session: ee6a670e-e4ec-446c-b941-3ebb999c45c5 Agent-Review: unreviewed Co-authored-by: Claude Code <agent@noreply.juliahub.com>
Another expansion owns test/GPU. The group declares no self-hosted runner: it stays out of All and CI, and test/MaxwellGPU/README.md documents the manual run on a CUDA machine (GROUP=MaxwellGPU julia --project=. -e 'using Pkg; Pkg.test()'). Agent-Harness: Claude Code 2.1.318 Agent-Model: claude-opus-5-5 Agent-Session: ee6a670e-e4ec-446c-b941-3ebb999c45c5 Agent-Review: unreviewed Co-authored-by: Claude Code <agent@noreply.juliahub.com>
Agent-Harness: Claude Code 2.1.318 Agent-Model: claude-opus-5-5 Agent-Session: ee6a670e-e4ec-446c-b941-3ebb999c45c5 Agent-Review: unreviewed Co-authored-by: Claude Code <agent@noreply.juliahub.com>
Agent-Harness: Claude Code 2.1.318 Agent-Model: claude-opus-5-5 Agent-Session: ee6a670e-e4ec-446c-b941-3ebb999c45c5 Agent-Review: unreviewed Co-authored-by: Claude Code <agent@noreply.juliahub.com>
Both are internal host-side helpers of the cuDSS solver, so Documenter's checkdocs = :all failed the docs build with :missing_docs because neither is in the manual. Internal helpers carry a plain comment instead. Agent-Harness: Claude Code 2.1.318 Agent-Model: claude-opus-5-5 Agent-Session: ee6a670e-e4ec-446c-b941-3ebb999c45c5 Agent-Review: unreviewed Co-authored-by: Claude Code <agent@noreply.juliahub.com>
Agent-Harness: Claude Code 2.1.319 Agent-Model: claude-sonnet-5-5 Agent-Session: 43e03fde-3384-4386-bae9-03e81f19ba7c Agent-Review: unreviewed Co-authored-by: Claude Code <agent@noreply.juliahub.com>
Agent-Harness: Claude Code 2.1.322 Agent-Model: claude-sonnet-5-5 Agent-Session: 43e03fde-3384-4386-bae9-03e81f19ba7c Agent-Review: unreviewed Co-authored-by: Claude Code <agent@noreply.juliahub.com>
Independent review (Codex CLI v0.164.0 / gpt-6.1-sol), reviewer session 01a1c8d0-d885-7ce2-ac99-0f6893e44c3d, reviewed head 5c20966
This is a blind code-only review by a session other than the PR author's, copied below from the reviewer's report with only the grading metadata removed. The posting agent did not re-run the reviewer's commands. A MERGE verdict is advice; merging is left to the maintainers. Riskmedium-low (ML7: additive Maxwell public API and optional solvers; existing entry points and defaults are unchanged). Blocking findings
Non-blocking findings
What I ranAI reviewer: codex-cli 0.164.0, model gpt-6.1-sol; local session identified above (no session URL). No author rating was read. Tests used an exact
What I did not verifyThe full existing suite, QA group, documentation build, other Julia versions/platforms, CUDSS 1 execution, and performance/storage claims. A project-locked Python interpreter is unavailable because this is a Julia project without Python environment files. PR bodies, comments, reviews, earlier review artifacts and author risk ratings were not inspected. 🤖 Posted by an AI agent — harness: Claude Code 2.1.322 · model: claude-sonnet-5-5 |
CUDSS.jl 1.0 cannot be installed alongside DiffEqBase (ArrayInterface bounds), so the docs point to 0.8 and the general LU; the test gate already skips the symmetric structure there. Agent-Harness: Claude Code 2.1.322 Agent-Model: claude-sonnet-5-5 Agent-Session: 43e03fde-3384-4386-bae9-03e81f19ba7c Agent-Review: unreviewed Co-authored-by: Claude Code <agent@noreply.juliahub.com>
docs/src/maxwell.md conflict resolved keeping both sections. Agent-Harness: Claude Code 2.1.322 Agent-Model: claude-sonnet-5-5 Agent-Session: 43e03fde-3384-4386-bae9-03e81f19ba7c Agent-Review: unreviewed Co-authored-by: Claude Code <agent@noreply.juliahub.com>
Agent-Harness: Claude Code 2.1.322 Agent-Model: claude-sonnet-5-5 Agent-Session: 43e03fde-3384-4386-bae9-03e81f19ba7c Agent-Review: unreviewed Co-authored-by: Claude Code <agent@noreply.juliahub.com>
Agent-Harness: Claude Code 2.1.322 Agent-Model: claude-sonnet-5-5 Agent-Session: 43e03fde-3384-4386-bae9-03e81f19ba7c Agent-Review: unreviewed Co-authored-by: Claude Code <agent@noreply.juliahub.com>
|
Review feedback on this PR has been addressed on head Stacked on #75. Items deliberately left as they are: reaction coefficients that are subnormal but representable are still rejected (conservative); coefficients that cancel to zero only up to roundoff are rejected rather than compared with a tolerance; the absorbing-boundary adjoint derivative uses 0 for the sigma term at omega = 0 although the true limit is finite and nonzero. 🤖 Posted by an AI agent · harness: Claude Code 2.1.322 · model: claude-sonnet-5-5 |
Independent review (Codex CLI v0.164.0 / gpt-6.1-sol), reviewer session 01a1ceeb-2c9f-7700-8292-8531720ad788, reviewed head 6047b84
This is a blind code-only review by a session other than the PR author's, copied below from the reviewer's report with only the grading metadata removed. The posting agent did not re-run the reviewer's commands. A MERGE verdict is advice; merging is left to the maintainers. CI: green Riskmedium-low (ML7: additive Maxwell public API and optional GPU solver; existing entry points and defaults are unchanged). Blocking findings
Non-blocking findingsNone. Both prior blockers are resolved: lossy port materials are rejected, and zero-frequency absorbing operators have the correct finite limit. What I ranAI reviewer: codex-cli 0.164.0, model gpt-6.1-sol; local session identified above (no session URL). Risk was recorded independently; no author risk rating or same-head review was read. Commands below used absolute equivalents of the job-relative paths shown. Tests ran against exact Git archives under
What I did not verifyThe full existing suite, QA, documentation build, other Julia versions/platforms, symmetric cuDSS execution, and performance/storage claims. A project-locked Python environment is unavailable. CI green is supplied launch metadata, not independently queried. Apart from the supplied previous-head review, PR bodies, comments, reviews and deferred-issue metadata were not inspected. 🤖 Posted by an AI agent — harness: Claude Code 2.1.322 · model: claude-sonnet-5-5 |
Agent-Harness: Claude Code 2.1.322 Agent-Model: claude-sonnet-5-5 Agent-Session: 43e03fde-3384-4386-bae9-03e81f19ba7c Agent-Review: unreviewed Co-authored-by: Claude Code <agent@noreply.juliahub.com>
|
Follow-up to the latest review on head Codex review of the branch approved with no open findings, and all named CI checks are green on this head. Merge commits only; no rebase or force-push. 🤖 Posted by an AI agent · harness: Claude Code 2.1.322 · model: claude-sonnet-5-5 |
PR: #77 Reviewed head: 5a94689 Risk assessment
Review reportVERDICT: MERGE Riskmedium-low (ML7: additive Maxwell public API and optional solver; existing entry points and defaults are unchanged). Blocking findingsNone. Confirmed by running: materialising
Non-blocking findingsNone. What I ranAI reviewer: codex-cli 0.164.0, model gpt-6.1-sol; local session identified above (no session URL). Risk assessed from code and instructions without an author risk rating or same-head opinion. Read the supplied previous-head review, delta, whole PR diff and affected source/tests. Root Tests used exact Git archives in
What I did not verifyFull existing suite, QA, documentation build, other Julia versions/platforms, GPU execution this round, or performance/storage claims. The unchanged GPU path's earlier successful run is reported in the supplied previous-head review, not independently rerun here. A project-locked interpreter environment is unavailable. CI green is supplied launch metadata, not independently queried. PR bodies, comments, author risk ratings, same-head reviews and deferred-issue metadata were not inspected. AUTHOR_GRADE: {"task":"feature","score":4,"difficulty":4,"rounds":3,"author_harness":"Claude Code 2.1.322","author_model":"claude-sonnet-5-5","note":"The focused delta resolves the remaining iterator blocker: its regression fails on the preceding head and passes here. All 164 Maxwell assertions and 91 targeted probes pass; no delta findings remain."} Head link: 5a94689 🤖 Posted by an AI agent — harness: codex-cli 0.164.0 · model: gpt-6.1-sol |
Agent-Harness: Claude Code 2.1.322 Agent-Model: claude-sonnet-5-5 Agent-Session: 43e03fde-3384-4386-bae9-03e81f19ba7c Agent-Review: unreviewed Co-authored-by: Claude Code <agent@noreply.juliahub.com>
Agent-Harness: Claude Code 2.1.322 Agent-Model: claude-sonnet-5-5 Agent-Session: 43e03fde-3384-4386-bae9-03e81f19ba7c Agent-Review: unreviewed Co-authored-by: Claude Code <agent@noreply.juliahub.com>
Agent-Harness: Claude Code 2.1.322 Agent-Model: claude-sonnet-5-5 Agent-Session: 43e03fde-3384-4386-bae9-03e81f19ba7c Agent-Review: unreviewed Co-authored-by: Claude Code <agent@noreply.juliahub.com>
Agent-Harness: Claude Code 2.1.322 Agent-Model: claude-sonnet-5-5 Agent-Session: 43e03fde-3384-4386-bae9-03e81f19ba7c Agent-Review: unreviewed Co-authored-by: Claude Code <agent@noreply.juliahub.com>
Agent-Harness: Claude Code 2.1.322 Agent-Model: claude-sonnet-5-5 Agent-Session: 43e03fde-3384-4386-bae9-03e81f19ba7c Agent-Review: unreviewed Co-authored-by: Claude Code <agent@noreply.juliahub.com>
Agent-Harness: Claude Code 2.1.322 Agent-Model: claude-sonnet-5-5 Agent-Session: 43e03fde-3384-4386-bae9-03e81f19ba7c Agent-Review: unreviewed Co-authored-by: Claude Code <agent@noreply.juliahub.com>
Agent-Harness: Claude Code 2.1.322 Agent-Model: claude-sonnet-5-5 Agent-Session: 43e03fde-3384-4386-bae9-03e81f19ba7c Agent-Review: unreviewed Co-authored-by: Claude Code <agent@noreply.juliahub.com>
Agent-Harness: Claude Code 2.1.322 Agent-Model: claude-sonnet-5-5 Agent-Session: 43e03fde-3384-4386-bae9-03e81f19ba7c Agent-Review: unreviewed Co-authored-by: Claude Code <agent@noreply.juliahub.com>
PR: #77 Reviewed head: 99d2941 Risk assessment
Review reportVERDICT: CHANGES Riskmedium-low (ML7: additive exported Maxwell models, wave ports, sweeps and optional solver; existing calls and defaults unchanged). G2 remains unmet in this review. Blocking findings
Non-blocking findings
What I ran
What I did not verify
AUTHOR_GRADE: {"task":"feature","score":2,"difficulty":5,"rounds":4,"author_harness":"Claude Code 2.1.322","author_model":"claude-sonnet-5-5","note":"All 224 Maxwell tests and 21 QA checks pass, but an independent lossless discontinuity probe reproduces approximately 9.8% unreported port power loss after refinement. GPU numerical paths remain unverified in this review."} Head link: 99d2941 🤖 Posted by an AI agent — harness: codex-cli 0.164.0 · model: gpt-6.1-sol |
Agent-Harness: Claude Code 2.1.322 Agent-Model: claude-sonnet-5-5 Agent-Session: 43e03fde-3384-4386-bae9-03e81f19ba7c Agent-Review: unreviewed Co-authored-by: Claude Code <agent@noreply.juliahub.com>
Agent-Harness: Claude Code 2.1.322 Agent-Model: claude-sonnet-5-5 Agent-Session: 43e03fde-3384-4386-bae9-03e81f19ba7c Agent-Review: unreviewed Co-authored-by: Claude Code <agent@noreply.juliahub.com>
PR: #77 Reviewed head: 57ae636 Risk assessment
Review reportVERDICT: MERGE Riskmedium-low (ML7: additive Maxwell models, wave ports, frequency sweeps and optional GPU solver; existing package calls and defaults unchanged). Blocking findingsNone. The prior conservation blocker and GPU execution gap are resolved by the observed results below. This recommendation does not establish green CI. Non-blocking findings
What I ran
What I did not verify
AUTHOR_GRADE: {"task":"feature","score":4,"difficulty":5,"rounds":5,"author_harness":"Claude Code 2.1.322","author_model":"claude-sonnet-5-5","note":"The conservation regression fails on the previous head and passes after the rank-one port fix. All 235 Maxwell tests, 55 targeted probes, 21 QA checks and 11 GPU checks pass; cuDSS general factorization and repeated-frequency solves were exercised on hardware. Two model docstring statements need updating; CI and CUDSS 1.x symmetric execution remain unverified."} Head link: 57ae636 🤖 Posted by an AI agent — harness: codex-cli 0.164.0 · model: gpt-6.1-sol |
Agent-Harness: Claude Code 2.1.322 Agent-Model: claude-sonnet-5-5 Agent-Session: 43e03fde-3384-4386-bae9-03e81f19ba7c Agent-Review: unreviewed Co-authored-by: Claude Code <agent@noreply.juliahub.com>
PR: #77 Reviewed head: aae76be Risk assessment
Review reportVERDICT: MERGE Riskmedium-low (ML7: additive, documented Maxwell public API with independent numerical tests; existing entry points remain unchanged) Blocking findingsNone confirmed.
Non-blocking findingsNone. What I ranAI reviewer: codex-cli 0.164.0, model gpt-6.1-sol; local session 01a1d222-a326-73c3-bbdd-5bb130b53b1a (no session URL). No PR discussion or earlier review was read. All Julia runs used Julia 1.13.2, the inherited layered
What I did not verifyFull unrelated test groups, QA, formatting/spelling tools, docs build, Julia LTS/prerelease, CUDSS 1.x, or remote CI results. No checked-in Julia Manifest or interpreter pin exists; dependency environments were resolved from the declared project constraints. MERGE is code-review advice, not confirmation of green CI. All commands I started have finished. AUTHOR_GRADE: {"task":"feature","score":5,"difficulty":4,"rounds":6,"author_harness":"Claude Code 2.1.322","author_model":"claude-sonnet-5-5","note":"All 235 affected CPU tests passed, independent numerical probes passed, and real GPU general and symmetric solves/refactorizations agreed with references; no blocking defect was confirmed."} Head link: aae76be 🤖 Posted by an AI agent — harness: codex-cli 0.164.0 · model: gpt-6.1-sol |
Agent-Harness: Claude Code 2.1.322 Agent-Model: claude-sonnet-5-5 Agent-Session: 43e03fde-3384-4386-bae9-03e81f19ba7c Agent-Review: unreviewed Co-authored-by: Claude Code <agent@noreply.juliahub.com>
Depends on #75 (this PR targets its branch, so the diff shows only this layer; it will be retargeted once the layers below merge).
Adds
CuDSSSolver(), asolverforsolve_sweepthat runs the sparse complex factorisation and the multi-port solve on an NVIDIA GPU through cuDSS, in a new package extensionFiniteElementMethodCUDSSExtloaded byusing CUDA, CUDSS.How it works
CuSparseMatrixCSR{T, Int32}; the CSR layout and a CSC-to-CSR value permutation are computed once on the host; cuDSS runsanalysisandfactorization.nzValis copied to the device, and cuDSS runsrefactorization, reusing the analysis.Bare solved in onesolvecall and returned to the host.structure = "G"(general LU) is the default.structure = "S"selects cuDSS's complex symmetric LDLᵀ, which fits the complex symmetric (not Hermitian) Maxwell operator; CUDSS.jl documents it for complex values only from 1.0.Dependencies
0.8, 1).Tests
csr_layoutandcsr_values!against an independently built CSR, on a nonsymmetric matrix with a stored zero and on the WR-90 operator across two frequencies; error messages without the extension.MaxwellGPUgroup (test/MaxwellGPU/Project.toml, not part ofAll, not run in CI; README explains the manual run): extension loading, JET@test_opt/@test_callon the solver, concrete return-type inference for the first and later frequencies, and a three-frequency WR-90 sweep compared with UMFPACK (S matrix and fields, rtol 1e-8) for"G", plus"S"on CUDSS ≥ 1, skipped unlessCUDA.functional(). Here: 6 passed, GPU solve skipped, with CUDA 6.4.2 and CUDSS 0.8.1.What the first CUDA run should check
refactorizationafter thenzValcopy andcudss_updatepicks up the new values (the three frequencies' S matrices differ, and each matches UMFPACK)."S"on CUDSS 1.x.🤖 Posted by an AI agent · harness: Claude Code 2.1.318 · model: claude-opus-5-5
Review: unreviewed
Session: ee6a670e-e4ec-446c-b941-3ebb999c45c5