improve geometric models fitting (line, circle) using LSM #2433

Open
wants to merge 5 commits into
from

Projects

None yet

5 participants

@Borda
Contributor
Borda commented Jan 7, 2017 edited

Description

improve geometric models fitting (line, circle) using LSM, it closes line #2427 and circle #2428

Checklist

[It's fine to submit PRs which are a work in progress! But before they are merged, all PRs should provide:]

References

@codecov-io
codecov-io commented Jan 7, 2017 edited

Current coverage is 90.80% (diff: 93.51%)

Merging #2433 into master will increase coverage by 0.12%

@@             master      #2433   diff @@
==========================================
  Files           304        304          
  Lines         21417      21443    +26   
  Methods           0          0          
  Messages          0          0          
  Branches       1838       1844     +6   
==========================================
+ Hits          19421      19471    +50   
+ Misses         1655       1629    -26   
- Partials        341        343     +2   

Powered by Codecov. Last update 42f2e7d...fbe0340

Borda added some commits Jan 7, 2017
@Borda Borda fit circle using LSM
* correct params
* correct tests
47bff64
@Borda Borda line fitting by eq. y = a*x + b
* add doc tests
* add assert tests
* correct assert tests
075236c
@Borda Borda model lineND
* change implementation to be in general form
* update test (setting new params) and correct previous duplication
* correct line testing
ec08331
@Borda Borda lineND model move back to polar coord
* correct tests
8280f07
@Borda Borda deprecated LineModel
fbe0340
@Borda
Contributor
Borda commented Jan 8, 2017

@sciunto I think, ready for a review...

@soupault soupault added this to the 0.14 milestone Jan 9, 2017
@JDWarner

This is beautiful, thank you @Borda - great use of linalg.pinv!

My only reservation is about the coordinate naming conventions of (x, y), rather than (r, c). However, perhaps it's worth keeping here as in skimage.transform given the long history of the traditional x/y in fitting and line equations.

Approved, but would appreciate input from another member of @scikit-image/core

@Borda
Contributor
Borda commented Jan 15, 2017

@JDWarner it was used there before, but if you think (r, c) is better I can change it...

_check_data_atleast_2D(data)
-
- X0 = data.mean(axis=0)
+ # https://www.youtube.com/watch?v=puVoOw3hNGY
@soupault
soupault Jan 17, 2017 Member

This is something new 😆

@Borda
Contributor
Borda commented Jan 17, 2017

@soupault thanks :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment