-
Notifications
You must be signed in to change notification settings - Fork 82
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
Fix/padded scaling #116
Merged
Merged
Fix/padded scaling #116
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Merged
Codecov Report
@@ Coverage Diff @@
## main #116 +/- ##
==========================================
- Coverage 84.38% 82.27% -2.12%
==========================================
Files 43 43
Lines 3933 4023 +90
Branches 448 447 -1
==========================================
- Hits 3319 3310 -9
- Misses 511 588 +77
- Partials 103 125 +22
|
Also polish the documentation
Check out this pull request on See visual diffs & provide feedback on Jupyter Notebooks. Powered by ReviewNB |
michalk8
added a commit
that referenced
this pull request
Jun 27, 2024
* [ci skip] Fix duplicate bibtex entry and a typo * [ci skip] Update segment docs * Add subset ixs, fix `Geometry` scaling * Update `inv_scale_cost` in PC, privatize methods * Update PC subsetting, LRC `inv_scale_cost` * Rename variable, fix LRC subsetting, typing * Add segmented Sinkhorn divergences to docs * Minor doc fixes * Return mask in `segment`, update Sink div * Fix passing masks in vmap * Fix LRC unflattening * Fix prepare divergences in `PointCloud` * Add masked summary test * Refactor fixture * Fix linter and link to PC in README.md * Fix bug in `test_euclidean_momentum_params` * Put epsilon-related args to `aux_data` * Add shape test * Test inverse scaling of masked geometry * Add test for permutation * Refactor scaling to use masks instead of subsets * Fix `Geometry.inv_scale_cost`, allow `int` * Add tests, fix some TODOs * Fix test, do not fail fast on CI * Update docstrings * Add test for mask conversion * Allow for mask in seg. Sink/Sink divergences * Fix tree flattening * First stab at fixing cont. barycenters * Remove passing segmented arrays to bar problem Also polish the documentation * Update FGW barycenters * Reintroduce the option of pre-segmented measures * Update segment_point_cloud * Fix typo in the docstring, start FGW bary tests * Better division impl. * Clean `GWBarycenter` impl., enable masks * Fix segment sinkhorn, divergences * Add GW barycenter test, fix KL loss * Add FGW barycenter test, clean impl. * Fix unused variables in tests, lexer and badge * Add shape assertions, update docs
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
In this PR:
scale_cost=None
, default isscale_cost=1.0
scale_cost
to also beint
, not onlyfloat
Geometry
functions:compute_cost_matrix
->_compute_cost_matrix()
, to avoid confusion betweencost_matrix
propertycompute_summary_online
->_compute_summary_online()
leading_slice
->_leading_slice()
, technical detail for batchingrescale_cost_fn
, unused{src,tgt}_mask
for geometries that are used to compute statistics of cost matrices, such as mean/median/inv. scaling; useful when padding geomeries insegment_sinkhorn{_divergences}
max_measure_size/num_segment
in case of the 2nd interface (passingnum_per_segment
)kl
GW loss not workingto be merged after #114 (because of the API change)
closes #100