3 Star 0 Fork 0

mirrors_lepy / vedo

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
贡献代码
同步代码
取消
提示: 由于 Git 不支持空文件夾,创建文件夹后会生成空的 .keep 文件
Loading...
README
MIT

vlogo

lics Anaconda-Server Badge Ubuntu 20.10 DOI Downloads CircleCI

A lightweight and powerful python module for scientific analysis and visualization of 3d objects.

✨ Philosophy

Inspired by the vpython manifesto "3D programming for ordinary mortals", vedo makes it easy to work with 3D pointclouds, meshes and volumes, in just a few lines of code, even for less experienced programmers.

vedo is based on VTK and numpy, with no other dependencies.

💾 Installation

pip install vedo
additional installation details [click to expand]
  • To install the latest dev version of vedo:
    pip install -U git+https://github.com/marcomusy/vedo.git

  • To install from the conda-forge channel:
    conda install -c conda-forge vedo

📙 Documentation

The webpage of the library with documentation is available here.

📌 Need help? Have a question, or wish to ask for a missing feature?

Do not hesitate to ask any questions on the image.sc forum or by opening a github issue.

🎨 Features

The library includes a large set of working examples for a wide range of functionalities:

working with polygonal meshes and point clouds [click to expand]
  • Import meshes from VTK format, STL, Wavefront OBJ, 3DS, Dolfin-XML, Neutral, GMSH, OFF, PCD (PointCloud),
  • Export meshes as ASCII or binary to VTK, STL, OBJ, PLY ... formats.
  • Analysis tools like Moving Least Squares, mesh morphing and more..
  • Tools to visualize and edit meshes (cutting a mesh with another mesh, slicing, normalizing, moving vertex positions, etc..).
  • Split mesh based on surface connectivity. Extract the largest connected area.
  • Calculate areas, volumes, center of mass, average sizes etc.
  • Calculate vertex and face normals, curvatures, feature edges. Fill mesh holes.
  • Subdivide faces of a mesh, increasing the number of vertex points. Mesh simplification.
  • Coloring and thresholding of meshes based on associated scalar or vectorial data.
  • Point-surface operations: find nearest points, determine if a point lies inside or outside of a mesh.
  • Create primitive shapes: spheres, arrows, cubes, torus, ellipsoids...
  • Generate glyphs (associate a mesh to every vertex of a source mesh).
  • Create animations easily by just setting the position of the displayed objects in the 3D scene. Add trailing lines and shadows to moving objects is supported.
  • Straightforward support for multiple sync-ed or independent renderers in the same window.
  • Registration (alignment) of meshes with different techniques.
  • Mesh smoothing.
  • Delaunay triangulation in 2D and 3D.
  • Generate meshes by joining nearby lines in space.
  • Find the closest path from one point to another, traveling along the edges of a mesh.
  • Find the intersection of a mesh with lines, planes or other meshes.
  • Interpolate scalar and vectorial fields with Radial Basis Functions and Thin Plate Splines.
  • Add sliders and buttons to interact with the scene and the individual objects.
  • Visualization of tensors.
  • Analysis of Point Clouds:
  • Moving Least Squares smoothing of 2D, 3D and 4D clouds
  • Fit lines, planes, spheres and ellipsoids in space
  • Identify outliers in a distribution of points
  • Decimate a cloud to a uniform distribution.
working with volumetric data and tetrahedral meshes
  • Import data from VTK format volumetric TIFF stacks, DICOM, SLC, MHD and more
  • Import 2D images as PNG, JPEG, BMP
  • Isosurfacing of volumes
  • Composite and maximum projection volumetric rendering
  • Generate volumetric signed-distance data from an input surface mesh
  • Probe volumes with lines and planes
  • Generate stream-lines and stream-tubes from vectorial fields
  • Slice and crop volumes
  • Support for other volumetric structures (structured and grid data)
plotting and histogramming in 2D and 3D
  • Polygonal 3D text rendering with Latex-like syntax and unicode characters, with 14 different fonts.
  • Fully customizable axis styles
  • donut plots and pie charts
  • Scatter plots in 2D and 3D
  • Surface function plotting
  • 1D customizable histograms
  • 2D hexagonal histograms
  • Polar plots, spherical plots and histogramming
  • Draw latex-formatted formulas in the rendering window.
  • Quiver, violin, whisker and stream-line plots
  • Graphical markers analogous to matplotlib
integration with other libraries
  • Integration with the Qt5 framework.
  • Support for FEniCS/Dolfin platform for visualization of PDE/FEM solutions.
  • Interoperability with the trimesh, pyvista and pymeshlab libraries.
  • Export 3D scenes and embed them into a web page.
  • Embed 3D scenes in jupyter notebooks with K3D (can export an interactive 3D-snapshot page here).

⌨ Command Line Interface

Visualize a polygonal mesh or a volume from a terminal window simply with:

vedo https://vedo.embl.es/examples/data/embryo.tif

Volumetric files (mhd, vti, slc, tiff, DICOM etc..) can be visualized in different modes:

Volume 3D slicing
vedo --slicer embryo.slc
Ray-casting
vedo -g
2D slicing
vedo --slicer2d
Colorize voxels
vedo --lego
slicer isohead viz_slicer lego

Type vedo -h for the complete list of options.

🐾 Gallery

vedo currently includes 300+ working examples and notebooks.

bunny dolf greyscott
Work with volumes, tetrahedral and polygonal meshes. Interoperability with many external libraries Animations of physical systems

Run any of the built-in examples. In a terminal type: vedo -r earthquake_browser

Check out the example galleries organized by subject here:


✏ Contributing

Any contributions you make are greatly appreciated! If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement".

📜 References

Scientific publications leveraging vedo:

  • X. Diego et al.: "Key features of Turing systems are determined purely by network topology", Phys. Rev. X 8, 021071, DOI.
  • M. Musy, K. Flaherty et al.: "A Quantitative Method for Staging Mouse Limb Embryos based on Limb Morphometry", Development (2018) 145 (7): dev154856, DOI.
  • F. Claudi, A. L. Tyson, T. Branco, "Brainrender. A python based software for visualisation of neuroanatomical and morphological data.", eLife 2021;10:e65751, DOI.
  • J. S. Bennett, D. Sijacki, "Resolving shocks and filaments in galaxy formation simulations: effects on gas properties and star formation in the circumgalactic medium", Monthly Notices of the Royal Astronomical Society, Volume 499, Issue 1, DOI.
  • J.D.P. Deshapriya et al., "Spectral analysis of craters on (101955) Bennu". Icarus 2020, DOI.
  • A. Pollack et al., "Stochastic inversion of gravity, magnetic, tracer, lithology, and fault data for geologically realistic structural models: Patua Geothermal Field case study", Geothermics, Volume 95, September 2021, DOI.
  • X. Lu et al., "3D electromagnetic modeling of graphitic faults in the Athabasca Basin using a finite-volume time-domain approach with unstructured grids", Geophysics, DOI.
  • M. Deepa Maheshvare et al., "A Graph-Based Framework for Multiscale Modeling of Physiological Transport", Front. Netw. Physiol. 1:802881, DOI.
  • F. Claudi, T. Branco, "Differential geometry methods for constructing manifold-targeted recurrent neural networks", bioRxiv 2021.10.07.463479, DOI.
  • J. Klatzow, G. Dalmasso, N. Martínez-Abadías, J. Sharpe, V. Uhlmann, "µMatch: 3D shape correspondence for microscopy data", Front. Comput. Sci., 15 February 2022. DOI
  • G. Dalmasso et al., "4D reconstruction of developmental trajectories using spherical harmonics", bioRxiv 2021.12.16.472948, DOI.

Have you found this software useful for your research? Star ✨ the project and cite it as:

M. Musy et al., "vedo, a python module for scientific analysis and visualization of 3D objects and point clouds", Zenodo, 2021, doi: 10.5281/zenodo.5842090.

embl_logo

Files: vedo/fonts/Bongas.* Source: https://www.1001freefonts.com/boogaloo.font Copyright: 2011 John Vargas Beltrán, with Reserved Font Name Boogaloo 2020 M. Musy Comment: 2020 subset and polygonized for vedo with name Bongas License: OFL Files: vedo/fonts/Calco.* Source: https://www.1001freefonts.com/calling-code.font Copyright: 2017 Ryoichi Tsunekawa, with Reserved Font Name Calling Code 2020 M. Musy Comment: 2020 subset and polygonized for vedo with name Calco License: OFL Files: vedo/fonts/Comae.* Source: https://www.1001freefonts.com/comfortaa.font Copyright: 2011 Johan Aakerlund, with Reserved Font Name Comfortaa 2020 M. Musy Comment: 2020 subset and polygonized for vedo with name Comae License: OFL Files: vedo/fonts/Glasgo.* Source: https://www.1001freefonts.com/class-coder.font Copyright: 2017 Walter E Stewart, with Reserved Font Name Class Coder 2020 M. Musy Comment: 2020 subset and polygonized for vedo with name Glasgo License: OFL Files: vedo/fonts/Kanopus.* Source: https://www.1001freefonts.com/kelvinch.font Copyright: 2016 Paul Miller, with Reserved Font Names "Kelvinch" and "SIL" 2020 M. Musy Comment: 2020 subset and polygonized for vedo with name Kanopus License: OFL Files: vedo/fonts/Normografo.* Source: https://www.1001freefonts.com/tecnico-font-19886.font Copyright: 2017 Cristhian Gomez, with Reserved Font Name Tecnico 2020 M. Musy Comment: 2020 subset and polygonized for vedo with name Normografo License: OFL Files: vedo/fonts/SmartCouric.* Source: https://www.fontsquirrel.com/fonts/courier-prime Copyright: 2013 Quote-Unquote Apps, with Reserved Font Name Courier Prime 2020 M. Musy Comment: 2020 subset and polygonized for vedo with name SmartCouric License: OFL Files: vedo/fonts/Theemim.* Source: https://www.1001freefonts.com/theano-didot.font Copyright: Alexey Kryukov, with Reserved Font Name Theano Didot 2020 M. Musy Comment: 2020 subset and polygonized for vedo with name Theemim License: OFL Files: vedo/fonts/VictorMono.ttf Source: https://www.fontsquirrel.com/fonts/victor-mono Copyright: 2019 Rune Bjørnerås, (https://rubjo.github.io/victor-mono) License: MIT Files: vedo/fonts/Quikhand.ttf Source: https://www.1001freefonts.com/quikhand.font Copyright: 2020 Qwerks (http://graphicriver.net/user/joiaco) License: public-domain License: MIT Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: . The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. . THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. License: public-domain Files in the public domain have no restrictions on use and may be used, modified and redistributed freely. Licence: OFL SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007 . PREAMBLE The goals of the Open Font License (OFL) are to stimulate worldwide development of collaborative font projects, to support the font creation efforts of academic and linguistic communities, and to provide a free and open framework in which fonts may be shared and improved in partnership with others. . The OFL allows the licensed fonts to be used, studied, modified and redistributed freely as long as they are not sold by themselves. The fonts, including any derivative works, can be bundled, embedded, redistributed and/or sold with any software provided that any reserved names are not used by derivative works. The fonts and derivatives, however, cannot be released under any other type of license. The requirement for fonts to remain under this license does not apply to any document created using the fonts or their derivatives. . DEFINITIONS "Font Software" refers to the set of files released by the Copyright Holder(s) under this license and clearly marked as such. This may include source files, build scripts and documentation. . "Reserved Font Name" refers to any names specified as such after the copyright statement(s). . "Original Version" refers to the collection of Font Software components as distributed by the Copyright Holder(s). . "Modified Version" refers to any derivative made by adding to, deleting, or substituting -- in part or in whole -- any of the components of the Original Version, by changing formats or by porting the Font Software to a new environment. . "Author" refers to any designer, engineer, programmer, technical writer or other person who contributed to the Font Software. . PERMISSION & CONDITIONS Permission is hereby granted, free of charge, to any person obtaining a copy of the Font Software, to use, study, copy, merge, embed, modify, redistribute, and sell modified and unmodified copies of the Font Software, subject to the following conditions: . 1) Neither the Font Software nor any of its individual components, in Original or Modified Versions, may be sold by itself. . 2) Original or Modified Versions of the Font Software may be bundled, redistributed and/or sold with any software, provided that each copy contains the above copyright notice and this license. These can be included either as stand-alone text files, human-readable headers or in the appropriate machine-readable metadata fields within text or binary files as long as those fields can be easily viewed by the user. . 3) No Modified Version of the Font Software may use the Reserved Font Name(s) unless explicit written permission is granted by the corresponding Copyright Holder. This restriction only applies to the primary font name as presented to the users. . 4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font Software shall not be used to promote, endorse or advertise any Modified Version, except to acknowledge the contribution(s) of the Copyright Holder(s) and the Author(s) or with their explicit written permission. . 5) The Font Software, modified or unmodified, in part or in whole, must be distributed entirely under this license, and must not be distributed under any other license. The requirement for fonts to remain under this license does not apply to any document created using the Font Software. . TERMINATION This license becomes null and void if any of the above conditions are not met. . DISCLAIMER THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER DEALINGS IN THE FONT SOFTWARE.

简介

暂无描述 展开 收起
Python 等 2 种语言
MIT
取消

发行版

暂无发行版

贡献者

全部

近期动态

加载更多
不能加载更多了
1
https://gitee.com/mirrors_lepy/vedo.git
git@gitee.com:mirrors_lepy/vedo.git
mirrors_lepy
vedo
vedo
master

搜索帮助

53164aa7 5694891 3bd8fe86 5694891