brisvag / blik

Python tool for visualising and interacting with cryo-ET and subtomogram averaging data.
https://brisvag.github.io/blik/
GNU General Public License v3.0
23 stars 8 forks source link

Particle mesh depictor #99

Closed brisvag closed 3 years ago

brisvag commented 3 years ago

This PR implements a way of depicting particles as isosurfaces meshes. Performance is quite bad for medium to high numbers of triangles, but it's a working prototype.

To use it, one needs to have a volume (array, xarray or ImageBlock) and pass it as such:

peeper.show(mode='mesh', volume=volume, iso=0.121, step_size=7)
codecov[bot] commented 3 years ago

Codecov Report

Merging #99 (756f32f) into develop (95027e0) will increase coverage by 0.25%. The diff coverage is 80.43%.

:exclamation: Current head 756f32f differs from pull request most recent head cb3bf07. Consider uploading reports for the commit cb3bf07 to get more accurate results Impacted file tree graph

@@             Coverage Diff             @@
##           develop      #99      +/-   ##
===========================================
+ Coverage    83.19%   83.45%   +0.25%     
===========================================
  Files           92       92              
  Lines         2089     2133      +44     
===========================================
+ Hits          1738     1780      +42     
- Misses         351      353       +2     
Impacted Files Coverage Δ
peepingtom/depictors/__init__.py 100.00% <ø> (ø)
...ingtom/datablocks/simpleblocks/orientationblock.py 80.48% <50.00%> (-3.30%) :arrow_down:
peepingtom/depictors/napari/naparidepictor.py 96.87% <66.66%> (+13.54%) :arrow_up:
peepingtom/datablocks/abstractblocks/datablock.py 79.27% <75.00%> (-0.54%) :arrow_down:
peepingtom/io_/reading/main.py 87.50% <75.00%> (ø)
peepingtom/depictors/napari/particledepictor.py 87.50% <78.33%> (-2.50%) :arrow_down:
peepingtom/__main__.py 86.20% <100.00%> (+2.33%) :arrow_up:
...datablocks/abstractblocks/_tests/test_datablock.py 100.00% <100.00%> (ø)
peepingtom/datablocks/multiblocks/particleblock.py 66.66% <100.00%> (ø)
peepingtom/depictors/napari/__init__.py 100.00% <100.00%> (ø)
... and 8 more

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 3449588...cb3bf07. Read the comment docs.

brisvag commented 3 years ago

Yes, I agree that we should wait! Let's leave this PR around, as it gives us a baseline of looks and performance.

alisterburt commented 3 years ago

was this closed by deleting the develop branch or on purpose?

brisvag commented 3 years ago

Oops, that was not on purpose...