Closed ceesem closed 4 years ago
Merging #57 into master will decrease coverage by
0.11%
. The diff coverage is73.91%
.
@@ Coverage Diff @@
## master #57 +/- ##
==========================================
- Coverage 76.35% 76.24% -0.12%
==========================================
Files 12 12
Lines 1844 1928 +84
==========================================
+ Hits 1408 1470 +62
- Misses 436 458 +22
Impacted Files | Coverage Δ | |
---|---|---|
meshparty/trimesh_repair.py | 83.84% <0%> (ø) |
:arrow_up: |
meshparty/trimesh_io.py | 71.81% <74.24%> (+0.13%) |
:arrow_up: |
meshparty/skeleton.py | 92.43% <76%> (-1.93%) |
: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 99af30b...0064537. Read the comment docs.
This branch adds a voxel_scaling parameter to meshes and skeletons that allows a dynamic and reversible rescaling of mesh vertex locations. This should only be used for analysis to avoid multiple sources of truth for the same data. This initial version only handles multiplicative scaling, although the framework should permit other types of transformations without much trouble.
Basic use:
1) From a MeshMeta with a default voxel scaling to apply to all meshes it loads:
2) From an existing mesh:
3) To reset to the original dimensions:
4) For skeletons:
Note that for some actions, one does not want scaled vertex values. These include saving the mesh to disk and adding link edges. There are internal controls that handle this, but they are only invoked if the action is called from the mesh itself. Thus:
This approach does NOT know to rescale vertices:
trimesh_repair.get_link_edges(mesh, ... )
sk.write_to_h5
command that can respect the internal voxel_scaling parameter.