Releases: QuantumKitHub/MatrixAlgebraKit.jl
v0.6.1
MatrixAlgebraKit v0.6.1
Compare: v0.6.0...v0.6.1
Date: 2025-12-28
Added
- Support for null-space computation via Householder QR in the
GenericLinearAlgebraextension (#132). - New truncated-eigensolver variants:
eig_trunc_no_errorandeigh_trunc_no_error(#117). - New truncated-singular value variant:
svd_trunc_no_errorto improve GPU synchronization and AD support (#116). - AD: ChainRules support for
svd_vals,eig_vals,eigh_vals, anddiagonal(#107).
Changed
- Improved GPU compatibility for some wrapper arrays (#100).
- Test infrastructure migrated to a common
TestSuiteto reduce duplication (#119, #130, #131, #127, #125, #123, #124).
Fixed
ishermitiannow correctly handles all-zero matrices (#121).
Merged pull requests:
- A few more updates for GPU compatibility for TensorKit (#100) (@kshyatt)
- Bump actions/checkout from 5 to 6 (#105) (@dependabot[bot])
- Implement
DiagonalAlgorithms for the GPU (#106) (@kshyatt) - [AD] add chainrules support for
svd_valsandeig(h)_valsand adddiagonal(#107) (@lkdvos) - Support Subarray{<:Adjoint{<:GPUMatrix}} (#108) (@kshyatt)
- Comment out some Mooncake tests to slim down CI runs (#110) (@kshyatt)
- Bump Mooncake version (#112) (@kshyatt)
- Add optional epsilon vector and keyword arg for error (#113) (@kshyatt)
- Split svd_trunc (#116) (@kshyatt)
- Add
eig_trunc_no_errorandeigh_trunc_no_error(#117) (@kshyatt) - Test eigh_trunc_no_error with Mooncake (#118) (@kshyatt)
- Use TestSuite for QR and LQ (#119) (@kshyatt)
- Fix
ishermitianfor zero-matrix (#121) (@ogauthe) - stabilize eig(h) tests (#122) (@Jutho)
- Testsuite for polar (#123) (@kshyatt)
- Actually test GPU QR/LQ (#124) (@kshyatt)
- Use TestSuite for projections tests (#125) (@kshyatt)
- Use Testsuite for Schur (#127) (@kshyatt)
- Use TestSuite for eig (#130) (@kshyatt)
- Use TestSuite for eigh (#131) (@kshyatt)
- add gla_householder_qr_null (#132) (@Jutho)
- Bump v0.6.1 (#134) (@lkdvos)
Closed issues:
v0.6.0
MatrixAlgebraKit v0.6.0
We are pleased to announce the release of MatrixAlgebraKit.jl v0.6.0! This release brings significant new features, enhanced GPU support, and improved automatic differentiation capabilities.
🎉 Highlights
- Expanded GPU Support: GPU acceleration for polar decomposition, projections, and orthogonal space computations
- Mooncake AD Integration: New reverse-mode automatic differentiation rules using Mooncake.jl
- BigFloat Support: Arbitrary precision computing via GenericLinearAlgebra extension
- New Projection Operations: Introduction of
project_isometricfor manifold projections - Enhanced Matrix Properties: New functions for Hermitian and anti-Hermitian decomposition
✨ New Features
Matrix Projections
project_isometric- Project matrices onto the isometric manifold (#67)PolarNewton- New Newton-iteration-based algorithm for polar decomposition (#67)
Matrix Property Functions
New functions for analyzing and manipulating matrix properties (#64):
ishermitian- Check if a matrix is Hermitianisantihermitian- Check if a matrix is anti-Hermitianhermitianpart!/hermitianpart- Extract Hermitian component (in-place and allocating)antihermitianpart!/antihermitianpart- Extract anti-Hermitian component (in-place and allocating)
Extended Type Support
- BigFloat precision through new
GenericLinearAlgebraextension (#87) - GPU wrapper types now have default algorithm implementations (#49)
Automatic Differentiation
- Mooncake.jl reverse-mode AD rules added (#85)
GPU Acceleration
Extended GPU support across multiple operations:
- Image and null space computations (#82)
- Polar decomposition (#83)
- Projection operations (#81)
- Improved SVD operations (#80)
Truncation Features
- Truncation error output for truncated decompositions (#75)
- Enhanced documentation for truncated decomposition keyword arguments (#71)
🔄 Breaking Changes
Renamed Functions
isisometry→isisometricfor consistency withproject_isometric(#73)
Interface Changes
- Refactored interface for
left_orth,right_orth,left_null, andright_null(#79)
🔧 Improvements
Behavior Changes
- Optional gauge fixing -
gaugefix!is now optional (#95) - Relaxed Hermitian checks - Loosened strictness on hermiticity checks (#78)
- Updated pullback tolerances for improved numerical stability when the input norms are large or small (#92)
📦 Dependencies
New Extensions
MatrixAlgebraKitGenericLinearAlgebraExt- BigFloat supportMatrixAlgebraKitGenericSchurExt- BigFloat supportMatrixAlgebraKitMooncakeExt- Mooncake AD integration
Compatibility
- Julia: 1.10+
- AMDGPU: 2
- CUDA: 5
- ChainRulesCore: 1
- GenericLinearAlgebra: 0.3.19+
- GenericSchur: 0.5.6+
- Mooncake: 0.4.174+
🙏 Acknowledgments
Thank you to all contributors who made this release possible! Special thanks to those who submitted pull requests, reported issues, and participated in discussions.
📚 Documentation
For detailed documentation, please visit:
🔗 Links
For any issues or questions, please file an issue on our GitHub repository.
Merged pull requests:
- Updates for TensorKit compatibility (#49) (@kshyatt)
- [Feature] Add
ishermitian,isantihermitian,hermitianpart(!)andantihermitianpart(!)(#64) (@lkdvos) - [Features]
project_isometricandPolarNewton(#67) (@Jutho) - remove additional unnecessary
::AbstractMatrixannotation (#70) (@lkdvos) - Add documentation for truncated decomposition keyword arguments (#71) (@Copilot)
- Rename
isisometrytoisisometricfor consistency withproject_isometric(#73) (@Copilot) - Output truncation error for truncated decompositions (#75) (@Jutho)
- Loosen strictness on hermitian checks (#78) (@lkdvos)
- Refactor orthogonalization and nullspace interface (#79) (@lkdvos)
- GPU improvements for SVD (#80) (@kshyatt)
- Support new projections on GPU (#81) (@kshyatt)
- Add tests for image and null space for GPU (#82) (@kshyatt)
- Add tests for polar decomposition for GPU (#83) (@kshyatt)
- Mooncake reverse rules (#85) (@kshyatt)
- add support for BigFloats via a new extension (#87) (@sanderdemeyer)
- update pullback tolerances (#92) (@lkdvos)
- Make
gaugefix!optional (#95) (@lkdvos) - Release v0.6 + small fixes (#97) (@lkdvos)
Closed issues:
- safe_inv should have a different tol from pullback_gaugetol (#7)
- [Feature request] Add support for BigFloats (#8)
- Support passing
Hermitianmatrix toeigh_x(#35) left_orthandright_orthinterface improvements (#66)- Document how to pass a truncation strategy to a truncated factorization (and other kwarg mysteries) (#68)
- Rename
isisometrytoisisometric(#69) - Reinstate outputting the truncation error for truncated decompositions (#72)
- Necessity of the hard symmetry/hermiticity checks in
eigh(!)decompositions (#76) - [Bug] SVD pullback does not properly take into account the norm of the initial matrix (#89)
v0.5.0
MatrixAlgebraKit v0.5.0
This release introduces pullback functions for nullspace decompositions, refactors the truncation interface to return indices, and includes several code quality improvements and internal consistency enhancements.
🚀 New Features & Enhancements
-
Nullspace Pullback Functions: Added dedicated pullback functions
qr_null_pullback!andlq_null_pullback!for computing gradients through nullspace decompositions. These functions provide a cleaner and more efficient interface for automatic differentiation throughqr_nullandlq_nulloperations. -
Renamed Pullback Functions: The pullback functions have been renamed for consistency:
qr_compact_pullback!→qr_pullback!lq_compact_pullback!→lq_pullback!
The new names are marked as
publicand are now part of the package's public API. -
Changed Truncation Interface: The internal
truncatefunction replaces the oldtruncate!and returns both the truncated result and the indices that were kept, enabling more efficient implementations in ChainRules extensions and other downstream code. -
Enhanced ChainRules Integration:
- Streamlined pullback implementations for
qr_null!andlq_null!to use the new dedicated pullback functions - Improved type stability in truncation-related rules
- Added
@non_differentiabledeclarations for utility functions (select_algorithm,initialize_output,check_input,isisometry,isunitary) - More generic type signatures (removed
AbstractMatrixconstraints) for better compatibility with custom array types
- Streamlined pullback implementations for
📋 Public API Changes and breaking changes
New Public Functions
qr_null_pullback!- Compute pullback for QR nullspace decompositionlq_null_pullback!- Compute pullback for LQ nullspace decompositiontruncate- Now marked as public (previously unexportedtruncate!)
Renamed Functions
qr_compact_pullback!→qr_pullback!(old name removed)lq_compact_pullback!→lq_pullback!(old name removed)
Note: The previous pullback function names are no longer available. If you were using these internal functions (they were not exported but marked as public in v0.4.1), you will need to update your code to use the new names.
🔧 Migration Guide
If you were using the pullback functions directly:
# Old code (v0.4.1)
qr_compact_pullback!(ΔA, A, QR, ΔQR)
lq_compact_pullback!(ΔA, A, LQ, ΔLQ)
# New code (v0.5.0)
qr_pullback!(ΔA, A, QR, ΔQR)
lq_pullback!(ΔA, A, LQ, ΔLQ)For nullspace pullbacks, use the new dedicated functions:
# v0.5.0
qr_null_pullback!(ΔA, A, N, ΔN)
lq_null_pullback!(ΔA, A, Nᴴ, ΔNᴴ)Replace truncate!(args...) calls with truncate, ensure they don't mutate the input arguments and also return the truncated inds.
For further details, see the updated docs and the diff for this release: v0.4.1...v0.5.0
Merged pull requests:
v0.4.1
MatrixAlgebraKit v0.4.1
🚀 New Features & Enhancements
- Truncated factorization pullbacks:: The chainrules have now been extended to truncated decompositions. This required a slight modification to the previous pullback function API, which is deemed non-breaking as these methods were not exported, nor marked as public. Henceforth however, the pullback methods are marked as public.
For further details, see the updated docs and the diff for this release: v0.4.0...v0.4.1
Merged pull requests:
v0.4.0
MatrixAlgebraKit v0.4.0
This release introduces an overhaul of the truncation interface, significant improvements to consistency and code clarity, and generalizes the truncation API for matrix decompositions. It also includes some bug fixes, code cleanup, and improved documentation.
Note: This release contains breaking changes, especially in the truncation API and related function signatures.
🚀 New Features & Enhancements
-
Overhauled Truncation API
- Introduced new types with consistent names:
TruncationByOrder,TruncationByValue,TruncationByFilter,TruncationByError, andTruncationIntersection. - New user-facing convenience constructors:
truncrank,trunctol,truncerror,truncfilter, andnotrunc. - Renamed
findtruncated_sortedtofindtruncated_svdas the standard for SVD truncation (values assumed sorted). - Documentation for the new truncation interface.
- Introduced new types with consistent names:
-
Export and API Changes
- New exports:
notrunc,truncrank,trunctol,truncerror,truncfilter. - New public structs:
TruncationByOrder,TruncationByValue,TruncationByFilter,TruncationByErrorandTruncationIntersection - Improved and clarified exported algorithm types.
- New exports:
-
Documentation Improvements
- Improved and clarified docstrings for truncation strategies.
-
Developer Improvements
- Separated the truncation interface and implementation to
src/interface/truncation.jlandsrc/implementation/truncation.jl - Switched to the Runic.jl code formatter
- Separated the truncation interface and implementation to
💥 Breaking Changes
-
Truncation API has changed:
- The old
TruncationKeepAbove,TruncationKeepBelow, andTruncationKeepSortedare replaced by new types and constructors. - All places accepting a truncation strategy now expect the new types or the new keyword-based syntax (see docs).
- The function
findtruncated_sortedis replaced byfindtruncated_svd. - The default truncation strategy is now
notrunc()instead ofNoTruncation(). - Function signatures for all decomposition and truncation routines have changed to use the new API.
- The old
-
Keyword Arguments:
- Truncation-related keyword arguments have changed (
maxrankinstead ofhowmany,trunctol(; atol, rtol, ...), etc.). keep_belowkeyword controls whether the truncation keeps values below or above the threshold.
- Truncation-related keyword arguments have changed (
-
Test and Extension Code:
- All code using the old truncation types or calling decomposition/truncation routines will need to be updated for compatibility.
🛠️ Internal & Code Quality
- Code formatting through Runic
- Bg fixes and clarifications in test code and docstrings.
For further details, see the updated docs and the diff for this release: v0.3.2...v0.4.0
Disclaimer: these notes have been generated with the help of Copilot -- check for correctness.
Merged pull requests:
v0.3.2
v0.3.1
v0.3.0
MatrixAlgebraKit v0.3.0
Changelog:
- Added support for CUDA and ROCm through extensions -- currently QR, LQ, and SVD are supported on GPU
- Added support for svd_trunc! on GPU including randomized SVD from CUDA
- Added support for generalized eigensolving (CPU only)
- Modified check_input to allow algorithm-specific checks
- Added
gaugefixfunction for eigensolving and SVD
Merged pull requests:
- WIP CUDA support (#20) (@Jutho)
- Add generalized eigenvalue decomposition, fix some bugs (#39) (@kshyatt)
- Bump actions/checkout from 4 to 5 (#40) (@dependabot[bot])
- [WIP] Attempting to wrap randomized SVD (#41) (@kshyatt)
- Create extension for AMD and generalize GPU wrappers (#42) (@kshyatt)
- Resolve comments (#44) (@kshyatt)
- Loosen types on polar copy_input to work with TensorMap (#45) (@kshyatt)
- Bump minor version to 0.3.0 (#46) (@kshyatt)
v0.2.5
MatrixAlgebraKit v0.2.5
This release features the new isisometry(A; kind=:left), isisometry(A; kind=:right) and isunitary functions to conveniently verify whether or not A' * A = I and/or A * A' = I.
Merged pull requests: