Skip to content

Generalized Cauchy direction and box constraints#554

Open
mateuszbaran wants to merge 134 commits intodev-0.6from
mbaran/gcp
Open

Generalized Cauchy direction and box constraints#554
mateuszbaran wants to merge 134 commits intodev-0.6from
mbaran/gcp

Conversation

@mateuszbaran
Copy link
Copy Markdown
Member

@mateuszbaran mateuszbaran commented Nov 28, 2025

This is a WIP PR that implements the GCP idea to L-BFGS and maybe some other solvers, so that they can be used in the presence of box constraints on the Euclidean part of the manifold. The constraints are handled similarly to L-BFGS-B (although not all Euclidean tricks are applied).

TODO:

  • a full example of working with a box domain
  • code coverage

The implementation was prepared in collaboration with @paprzybysz .

@mateuszbaran mateuszbaran added enhancement WIP Work in Progress (for a pull request) labels Nov 28, 2025
@codecov
Copy link
Copy Markdown

codecov Bot commented Nov 28, 2025

Codecov Report

❌ Patch coverage is 99.46381% with 4 lines in your changes missing coverage. Please review.
⚠️ Please upload report for BASE (dev-0.6@00c160b). Learn more about missing BASE report.

Files with missing lines Patch % Lines
src/plans/stopping_criterion.jl 94.20% 4 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             dev-0.6     #554   +/-   ##
==========================================
  Coverage           ?   99.96%           
==========================================
  Files              ?       91           
  Lines              ?    11605           
  Branches           ?        0           
==========================================
  Hits               ?    11601           
  Misses             ?        4           
  Partials           ?        0           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

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

Comment thread src/plans/stopping_criterion.jl Outdated
@mateuszbaran
Copy link
Copy Markdown
Member Author

I have also added a simple direction-based stepsize limiting that can be used in solvers that don't approximate the Hessian to limit the stepsize.

Copy link
Copy Markdown
Member

@kellertuer kellertuer left a comment

Choose a reason for hiding this comment

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

Here is a set of comments.

I think most of them are merely something to work though. The major points to check is

  • What is a Finder? Is that the best name we can come up with?
  • Why does a Finder store a manifold – the manifold should only be stored in the problem and otherwise passed down.

Comment thread docs/src/solvers/generalized_cauchy_direction_subsolver.md Outdated
Comment thread docs/src/solvers/generalized_cauchy_direction_subsolver.md
Comment thread docs/src/solvers/generalized_cauchy_direction_subsolver.md Outdated
Comment thread docs/src/solvers/generalized_cauchy_direction_subsolver.md Outdated
Comment thread src/plans/stepsize/linesearch.jl Outdated
Comment thread src/plans/box_plan.jl Outdated
Comment thread src/plans/box_plan.jl
Comment thread src/plans/box_plan.jl Outdated
Comment thread src/plans/box_plan.jl Outdated
Comment thread src/plans/box_plan.jl Outdated
@mateuszbaran
Copy link
Copy Markdown
Member Author

The major points to check is

  • What is a Finder? Is that the best name we can come up with?
  • Why does a Finder store a manifold – the manifold should only be stored in the problem and otherwise passed down.

Probably a "subsolver" would be a better alternative to "finder", what do you think?

I can easily remove manifold from GeneralizedCauchyDirectionFinder if that's a problem, sure.

@kellertuer
Copy link
Copy Markdown
Member

Ah it is a subsolver ;) I did not see that.
Yes, I would prefer for consistency to not “copy” (I know it is a reference) the manifold, the only thing it can lead to is inconsistencies, when someone (myself not excluded even) manages to create such a thingy /finder/subsolver) with a manifold different from the one in the problem.

To avoid that a user makes this mistake, the easiest is to not double information :)

Copy link
Copy Markdown
Member

@kellertuer kellertuer left a comment

Choose a reason for hiding this comment

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

I think all my points are clarified by now. Thanks for the productive discussions.

@kellertuer kellertuer changed the base branch from master to dev-0.6 April 7, 2026 08:30
@kellertuer
Copy link
Copy Markdown
Member

Since this will also be part of the next major version 0.6, I diverted the base branch (this merges into) already to dev-0.6; I can also resolve the conflicts somewhen the next few days.

kellertuer and others added 4 commits April 8, 2026 09:48
# Conflicts:
#	Changelog.md
#	src/helpers/LineSearchesTypes.jl
#	src/plans/stepsize/linesearch.jl
#	src/plans/stepsize/stepsize.jl
#	src/plans/stopping_criterion.jl
#	test/plans/test_stepsize.jl
#	test/plans/test_stopping_criteria.jl
#	test/solvers/test_quasi_Newton.jl
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement Ready-for-Review A label for pull requests that are feature-ready

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Allow specifying a small positive constant as the lower limit of y-s products in QN

2 participants