Skip to content

fixedpoint improvements#337

Merged
leburgel merged 11 commits intomasterfrom
pb-fixedpoint-improvements
Mar 3, 2026
Merged

fixedpoint improvements#337
leburgel merged 11 commits intomasterfrom
pb-fixedpoint-improvements

Conversation

@pbrehmer
Copy link
Collaborator

As suggested by @leburgel in #336, here we improve a couple of things about the fixedpoint optimization routine:

  • We add a check_input(::typeof(fixedpoint), args...) method that verifies that the chosen inputs are compatible with the PEPS optimization algorithm
  • For any boundary contraction algorithm, its leading_boundary call should return an info named tuple which contains a contraction_metrics field that carries boundary-algorithm-specific information such as the truncation error, condition number, etc.
  • I added a boundary algorithm type parameter to PEPSOptimize and also loosened type restrictions of fixedpoint such that it is compatible with different environment types.

I'm not so sure yet about the name contraction_metrics, so let me know what you think. After the first round of reviews I will update the examples such that they match the new fixedpoint.

@github-actions
Copy link
Contributor

github-actions bot commented Feb 24, 2026

Your PR no longer requires formatting changes. Thank you for your contribution!

@codecov
Copy link

codecov bot commented Feb 24, 2026

Codecov Report

❌ Patch coverage is 93.93939% with 2 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
...rithms/optimization/fixed_point_differentiation.jl 80.00% 2 Missing ⚠️
Files with missing lines Coverage Δ
src/algorithms/ctmrg/c4v.jl 90.29% <100.00%> (+0.19%) ⬆️
src/algorithms/ctmrg/ctmrg.jl 90.27% <100.00%> (ø)
src/algorithms/ctmrg/sequential.jl 100.00% <100.00%> (ø)
src/algorithms/ctmrg/simultaneous.jl 100.00% <100.00%> (ø)
src/algorithms/optimization/peps_optimization.jl 98.66% <100.00%> (+0.01%) ⬆️
src/algorithms/select_algorithm.jl 78.57% <100.00%> (+2.57%) ⬆️
...rithms/optimization/fixed_point_differentiation.jl 94.65% <80.00%> (-0.86%) ⬇️

... and 7 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Member

@leburgel leburgel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall looks good, I'm happy losing any restrictions on the contraction algorithm where possible. I don't know if contraction_metrics is the best name and whether this change will break things for many users, but I can't think of a better name and it shouldn't be too big of a change I guess.

Aside from the minor comments, can you update the changelog to record the fact that the truncation_error and condition_number have moved to a different place? We've been forgetting about that a bit, but I think this should definitely go in there at least.

@pbrehmer
Copy link
Collaborator Author

pbrehmer commented Mar 3, 2026

Alright, the PEPSOptimize constructor now errors when the user uses anything else than symmetrization = RotateReflect(). Still, when calling fixedpoint and specifying alg = :c4v as the boundary algorithm, the symmetrization defaults to RotateReflect since that is the only sensible default. This would be good to go for me now!

@leburgel leburgel enabled auto-merge (squash) March 3, 2026 13:20
@leburgel leburgel merged commit 98fb536 into master Mar 3, 2026
63 checks passed
@leburgel leburgel deleted the pb-fixedpoint-improvements branch March 3, 2026 18:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants