haesleinhuepf / napari-process-points-and-surfaces

Process and analyze surfaces using vedo in napari.
BSD 3-Clause "New" or "Revised" License
21 stars 4 forks source link

Apply scale #8

Closed jo-mueller closed 2 years ago

jo-mueller commented 2 years ago

Fixes #6

codecov-commenter commented 2 years ago

Codecov Report

Merging #8 (7dadacd) into main (395df9d) will decrease coverage by 0.51%. The diff coverage is 95.45%.

@@            Coverage Diff             @@
##             main       #8      +/-   ##
==========================================
- Coverage   92.06%   91.55%   -0.52%     
==========================================
  Files           3        3              
  Lines         290      308      +18     
==========================================
+ Hits          267      282      +15     
- Misses         23       26       +3     
Impacted Files Coverage Δ
napari_process_points_and_surfaces/__init__.py 89.94% <93.33%> (+<0.01%) :arrow_up:
...rocess_points_and_surfaces/_tests/test_function.py 95.34% <100.00%> (-4.66%) :arrow_down:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 395df9d...7dadacd. Read the comment docs.

jo-mueller commented 2 years ago

Hey @haesleinhuepf

I'm wondering if it is possible to write a bit cleaner code?

Sorry about that. I changed the PR to draft mode for fixing it up and will notify you once it's ready for review.

I suggest, either all functions consume layers or all functions consume nparrays. That would make it easier to maintain later.

In that case it would have to be layers - otherwise there's no way to access the scale parameter inside a function.