Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add primal_cost property to output of GW, to compute cost without any regularization. #286

Merged
merged 7 commits into from
Feb 15, 2023

Conversation

marcocuturi
Copy link
Contributor

@marcocuturi marcocuturi commented Feb 14, 2023

Adds a primal_cost property to the output of a GW solver (regular and LR), solves #186

@marcocuturi marcocuturi changed the title add primal_cost add primal_cost property to output of GW, to compute cost without any regularization. Feb 14, 2023
src/ott/problems/quadratic/quadratic_problem.py Outdated Show resolved Hide resolved
src/ott/problems/quadratic/quadratic_problem.py Outdated Show resolved Hide resolved
tests/solvers/quadratic/gw_test.py Outdated Show resolved Hide resolved
tests/solvers/quadratic/gw_test.py Outdated Show resolved Hide resolved
tests/solvers/quadratic/gw_test.py Outdated Show resolved Hide resolved
@codecov-commenter
Copy link

codecov-commenter commented Feb 15, 2023

Codecov Report

Merging #286 (7df60ed) into main (2995ef4) will increase coverage by 0.02%.
The diff coverage is 71.42%.

📣 This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #286      +/-   ##
==========================================
+ Coverage   85.93%   85.95%   +0.02%     
==========================================
  Files          52       52              
  Lines        5587     5590       +3     
  Branches      852      853       +1     
==========================================
+ Hits         4801     4805       +4     
+ Misses        663      662       -1     
  Partials      123      123              
Impacted Files Coverage Δ
src/ott/geometry/costs.py 99.04% <ø> (ø)
src/ott/geometry/epsilon_scheduler.py 88.88% <ø> (ø)
src/ott/geometry/geometry.py 91.17% <ø> (+0.32%) ⬆️
src/ott/geometry/graph.py 31.87% <ø> (ø)
src/ott/geometry/grid.py 91.66% <ø> (ø)
src/ott/geometry/low_rank.py 96.40% <ø> (ø)
src/ott/geometry/pointcloud.py 86.12% <ø> (ø)
src/ott/geometry/segment.py 100.00% <ø> (ø)
src/ott/initializers/linear/initializers.py 94.73% <ø> (ø)
src/ott/initializers/linear/initializers_lr.py 92.38% <ø> (ø)
... and 53 more

docs/references.bib Outdated Show resolved Hide resolved
src/ott/problems/quadratic/quadratic_problem.py Outdated Show resolved Hide resolved
tests/solvers/quadratic/gw_test.py Outdated Show resolved Hide resolved
src/ott/problems/quadratic/quadratic_problem.py Outdated Show resolved Hide resolved
@marcocuturi
Copy link
Contributor Author

thanks a lot Michal for the great comments, sorry for giving you extra work :)

@marcocuturi marcocuturi self-assigned this Feb 15, 2023
Copy link
Collaborator

@michalk8 michalk8 left a comment

Choose a reason for hiding this comment

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

One small typo in the docs, after it's fixed, feel free to merge without tests passing (they were passing before).

src/ott/problems/quadratic/quadratic_problem.py Outdated Show resolved Hide resolved
@marcocuturi marcocuturi merged commit 963f3b1 into main Feb 15, 2023
@marcocuturi marcocuturi deleted the m_ott branch February 15, 2023 23:38
michalk8 pushed a commit that referenced this pull request Jun 27, 2024
…ny regularization. (#286)

* add primal_cost

* precommit

* avoid using unbalanced for LRSinkhorn

* take comments into account.

* bib

* incorporating comments.

* update
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants