GithubHelp home page GithubHelp logo

pymesh / pymesh Goto Github PK

View Code? Open in Web Editor NEW
1.8K 62.0 355.0 21.44 MB

Geometry Processing Library for Python

CMake 3.78% C 10.65% C++ 68.48% Python 16.78% Makefile 0.01% TeX 0.08% Shell 0.06% Dockerfile 0.17%
python geometry geometry-processing graphics convex-hull outer-hull mesh-generation mesh-boolean mesh-cleanup 3d

pymesh's Introduction

CircleCI Build Status Documentation Status

About PyMesh

PyMesh is a code base developed by Qingnan Zhou for his PhD research at New York University. It is a rapid prototyping platform focused on geometry processing. PyMesh is written with both C++ and Python, where computational intensive functionalities are realized in C++, and Python is used for creating minimalistic and easy to use interfaces.

PyMesh (Model source: Bust of Sappho)

Documentation

Latest documentation

Quick try

Perhaps the easiest way of trying out PyMesh is through docker:

docker run -it pymesh/pymesh
Python 3.6.4 (default, Feb 17 2018, 09:32:33)
[GCC 4.9.2] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import pymesh

For example, to run meshstat.py:

docker run -it --rm -v `pwd`:/models pymesh/pymesh meshstat.py -x /models/model.obj

This command mounts your current working directory to the /models directory in a docker container and executes the meshstat.py script on the mesh file model.obj in the current directory.

Download Source

To retrieve the code:

git clone https://github.com/PyMesh/PyMesh.git
cd PyMesh
git submodule update --init

Dependencies

PyMesh has the following required dependencies:

The following C++ libraries are required. They are included in $PYMESH_PATH/third_party directory.

PyMesh also has a number of optional dependencies:

  • Carve: A fast, robust constructive solid geometry library.
  • CGAL: The Computational Geometry Algorithms Library.
  • Clipper: An open source freeware library for clipping and offsetting lines and polygons.
  • Cork: A 3D boolean/CSG library.
  • Draco: An open-source library for compressing and decompressing 3D geometric meshes and point clouds
  • Geogram: A programming library of geometric algorithms
  • libigl: A simple C++ geometry processing library.
  • MMG: Robust, open source & multidisciplinary software for remeshing.
  • Qhull: Engine for convex hulls, Delaunay triangulations, Voronoi diagrams computations.
  • Quartet: A tetrahedral mesh generator that does isosurface stuffing with an acute tetrahedral tile.
  • TBB: Thread building blocks from Intel.
  • Tetgen: Tetrahedral mesh generation engine.
  • Triangle: A two-Dimensional quality mesh generator and Delaunay triangulator.

All of the optional libraries are included in $PYMESH_PATH/third_party directory.

Specify Dependency Locations

All dependencies are included as git submodules in the third_party directory. It is recommended to build these dependencies directly (see Build section). However, it is possible to use an existing dependency installed on your system. If the dependent library is not installed in standard locations (/usr/local/, /opt/local), one needs to set environment variables that point to the correct directories. PyMesh check the following environment variables:

  • Eigen: Set EIGEN_PATH to the directory containing the eigen3 directory.
  • CGAL: Set CGAL_PATH to the directory containing UseCGAL.cmake file.
    • Boost: Set BOOST_INC to the directory containing boost.
    • GMP: Set GMP_INC and GMP_LIB to the directories containing GMP header and library.
  • libigl: Set LIBIGL_PATH the include directory of libigl sources.
  • Cork: Set CORK_PATH to the install directory of Cork.
  • Tetgen: Set TETGEN_PATH to the install directory of Tetgen.
  • Triangle: Set TRIANGLE_PATH to the install directory of Triangle.
  • Qhull: Set QHULL_PATH to the install directory of Qhull.
  • Clipper: Set CLIPPER_PATH to the install directory of Clipper.
  • Carve: Set CARVE_PATH to the install directory of Carve.
  • Geogram: Set GEOGRAM_PATH to the install directory of Geogram.
  • Quartet: Set QUARTET_PATH to the install directory of Quartet.
  • Draco: Set Draco_PATH to the install directory of Draco.
  • MMG: Set MMG_PATH to the install directory of MMG.

Build

Let $PYMESH_PATH be the root directory of the repository. The first step is to compile the optional third party dependencies:

cd $PYMESH_PATH/third_party
build.py all

Third party dependencies will be installed in $PYMESH_PATH/python/pymesh/third_party directory.

Now we can build the main project. It is recommended to build out of source:

cd $PYMESH_PATH
mkdir build
cd build
cmake ..

To build the PyMesh library:

make
make tests

Make sure all unit tests are passed before using the library.

Install

The output of building PyMesh consists a set of C++ libraries and a python module. Installing the C++ library is currently not available. However, installing the python package can be done:

./setup.py build # This an alternative way of calling cmake/make
./setup.py install

To check PyMesh is installed correctly, run the following python unit tests::

python -c "import pymesh; pymesh.test()"

Once again, make sure all unit tests are passed, and report any unit test failures.

Feedback

Thank you for using PyMesh! Please consider help PyMesh improve by leaving feedback!

pymesh's People

Contributors

aaarne avatar aaronang avatar athompson673 avatar aymericferreira avatar cascades avatar dpellegr avatar jdumas avatar jjerphan avatar jpanetta avatar matillamartin avatar neoglez avatar paulmiller avatar prashantraina avatar qnzhou avatar rdaems avatar rfleschenberg avatar robnagler avatar skw1335 avatar sumpfralle avatar udnaan avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

pymesh's Issues

compile error

In PyMesh/tools/CGAL/SelfIntersection.cpp, on line 68, it looks like there is a typo - CGAL::bbox_3 should be CGAL::Bbox_3. With the fix, it complains of a function signature mismatch (2 args given, 6 expected)

link error in libSparseSolver.so

I have the problem when system try to link shared library libSparseSolver.so
Is something I missing or configuration not correct?

Linking CXX shared library ../../../python/pymesh/lib/libSparseSolver.so
/usr/bin/ld: /usr/lib/gcc/x86_64-linux-gnu/5/../../../x86_64-linux-gnu/libsuitesparseconfig.a(SuiteSparse_config.o): relocation R_X86_64_PC32 against undefined symbol `malloc@@GLIBC_2.2.5' can not be used when making a shared object; recompile with -fPIC
/usr/bin/ld: final link failed: Bad value
collect2: error: ld returned 1 exit status

Pymesh on docker is not working

Hello,
After pulling pymesh on docker, I run a test with a python script but it shows an error
"ImportError: libMesh.so: cannot open shared object file: No such file or directory"

It seems that python of the docker container did not find libMesh.so.
Do you have an idea?
Thank you for your help.
Sorry if I post in a wrong place.
Huu Phuoc BUI

import error

Hello Mr. Zhou,

can you please help me with the problem:
Traceback (most recent call last):
File "/usr/local/lib/python3.5/dist-packages/pymesh2-0.1.14-py3.5-linux-x86_64.egg/pymesh/swig/PyMesh.py", line 14, in swig_import_helper
return importlib.import_module(mname)
File "/usr/lib/python3.5/importlib/init.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "", line 986, in _gcd_import
File "", line 969, in _find_and_load
File "", line 958, in _find_and_load_unlocked
File "", line 666, in _load_unlocked
File "", line 577, in module_from_spec
File "", line 906, in create_module
File "", line 222, in _call_with_frames_removed
ImportError: dynamic module does not define module export function (PyInit__PyMesh)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "", line 1, in
File "/usr/local/lib/python3.5/dist-packages/pymesh2-0.1.14-py3.5-linux-x86_64.egg/pymesh/init.py", line 18, in
from .Mesh import Mesh
File "/usr/local/lib/python3.5/dist-packages/pymesh2-0.1.14-py3.5-linux-x86_64.egg/pymesh/Mesh.py", line 5, in
import PyMesh
File "/usr/local/lib/python3.5/dist-packages/pymesh2-0.1.14-py3.5-linux-x86_64.egg/pymesh/swig/PyMesh.py", line 17, in
_PyMesh = swig_import_helper()
File "/usr/local/lib/python3.5/dist-packages/pymesh2-0.1.14-py3.5-linux-x86_64.egg/pymesh/swig/PyMesh.py", line 16, in swig_import_helper
return importlib.import_module('_PyMesh')
File "/usr/lib/python3.5/importlib/init.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
ImportError: dynamic module does not define module export function (PyInit__PyMesh)

There was no problem with my installation and i just doubt whether i make mistake with swig.

Thank you very much.

HM

Error when "make tools"

Hello, I'm using Ubuntu 16.04. After many trials and error I could install all the dependencies and now when I try to use "make tools" I get this error:

[ 19%] Building CXX object tools/IGL/CMakeFiles/lib_igl.dir/MinkowskiSum.cpp.o
In file included from /home/vivar/tools/PyMesh/third_party/libigl/include/igl/copyleft/cgal/../../edges.cpp:9:0,
                 from /home/vivar/tools/PyMesh/third_party/libigl/include/igl/copyleft/cgal/../../edges.h:34,
                 from /home/vivar/tools/PyMesh/third_party/libigl/include/igl/copyleft/cgal/minkowski_sum.cpp:14,
                 from /home/vivar/tools/PyMesh/third_party/libigl/include/igl/copyleft/cgal/minkowski_sum.h:107,
                 from /home/vivar/tools/PyMesh/tools/IGL/MinkowskiSum.cpp:4:
/home/vivar/tools/PyMesh/third_party/libigl/include/igl/copyleft/cgal/../../adjacency_matrix.h:12:0: warning: "EIGEN_YES_I_KNOW_SPARSE_MODULE_IS_NOT_STABLE_YET" redefined
 #define EIGEN_YES_I_KNOW_SPARSE_MODULE_IS_NOT_STABLE_YET
 ^
<command-line>:0:0: note: this is the location of the previous definition
In file included from /usr/include/eigen3/Eigen/Core:366:0,
                 from /home/vivar/tools/PyMesh/src/Core/EigenTypedef.h:4,
                 from /home/vivar/tools/PyMesh/tools/IGL/MinkowskiSum.h:5,
                 from /home/vivar/tools/PyMesh/tools/IGL/MinkowskiSum.cpp:2:
/home/vivar/tools/PyMesh/third_party/libigl/include/igl/copyleft/cgal/minkowski_sum.cpp: In instantiation of ‘void igl::copyleft::cgal::minkowski_sum(const Eigen::PlainObjectBase<Derived>&, const Eigen::PlainObjectBase<DerivedFA>&, const Eigen::Matrix<sType, 1, sCols, sOptions>&, const Eigen::Matrix<dType, 1, dCols, dOptions>&, bool, Eigen::PlainObjectBase<DerivedW>&, Eigen::PlainObjectBase<DerivedG>&, Eigen::PlainObjectBase<DerivedJ>&) [with DerivedVA = Eigen::Matrix<double, -1, -1, 1>; DerivedFA = Eigen::Matrix<int, -1, -1, 1>; sType = double; int sCols = 3; int sOptions = 1; dType = double; int dCols = 3; int dOptions = 1; DerivedW = Eigen::Matrix<double, -1, -1, 1>; DerivedG = Eigen::Matrix<int, -1, -1, 1>; DerivedJ = Eigen::Matrix<int, -1, 1>]’:
/home/vivar/tools/PyMesh/third_party/libigl/include/igl/copyleft/cgal/minkowski_sum.cpp:370:23:   required from ‘void igl::copyleft::cgal::minkowski_sum(const Eigen::PlainObjectBase<Derived>&, const Eigen::PlainObjectBase<DerivedFA>&, const Eigen::Matrix<sType, 1, sCols, sOptions>&, const Eigen::Matrix<dType, 1, dCols, dOptions>&, Eigen::PlainObjectBase<DerivedW>&, Eigen::PlainObjectBase<DerivedG>&, Eigen::PlainObjectBase<DerivedJ>&) [with DerivedVA = Eigen::Matrix<double, -1, -1, 1>; DerivedFA = Eigen::Matrix<int, -1, -1, 1>; sType = double; int sCols = 3; int sOptions = 1; dType = double; int dCols = 3; int dOptions = 1; DerivedW = Eigen::Matrix<double, -1, -1, 1>; DerivedG = Eigen::Matrix<int, -1, -1, 1>; DerivedJ = Eigen::Matrix<int, -1, 1>]’
/home/vivar/tools/PyMesh/tools/IGL/MinkowskiSum.cpp:45:30:   required from here
/usr/include/eigen3/Eigen/src/Core/PlainObjectBase.h:482:22: error: ‘Eigen::PlainObjectBase<Derived>& Eigen::PlainObjectBase<Derived>::operator=(Eigen::PlainObjectBase<Derived>&&) [with Derived = Eigen::Matrix<int, -1, 1>]’ is protected
     PlainObjectBase& operator=(PlainObjectBase&& other)
                      ^
In file included from /home/vivar/tools/PyMesh/third_party/libigl/include/igl/copyleft/cgal/minkowski_sum.h:107:0,
                 from /home/vivar/tools/PyMesh/tools/IGL/MinkowskiSum.cpp:4:
/home/vivar/tools/PyMesh/third_party/libigl/include/igl/copyleft/cgal/minkowski_sum.cpp:349:7: error: within this context
     J = slice(DerivedJ(J),SJ,1);
       ^
tools/IGL/CMakeFiles/lib_igl.dir/build.make:86: recipe for target 'tools/IGL/CMakeFiles/lib_igl.dir/MinkowskiSum.cpp.o' failed
make[3]: *** [tools/IGL/CMakeFiles/lib_igl.dir/MinkowskiSum.cpp.o] Error 1
CMakeFiles/Makefile2:3097: recipe for target 'tools/IGL/CMakeFiles/lib_igl.dir/all' failed
make[2]: *** [tools/IGL/CMakeFiles/lib_igl.dir/all] Error 2
CMakeFiles/Makefile2:263: recipe for target 'tools/CMakeFiles/tools.dir/rule' failed
make[1]: *** [tools/CMakeFiles/tools.dir/rule] Error 2
Makefile:144: recipe for target 'tools' failed
make: *** [tools] Error 2

Any idea? Thanks in advance

distance_to_mesh memory leak

I am getting a memory leak when I use pymesh.distance_to_mesh. Can anyone reproduce this problem?

mesh = <your mesh>
pnts = <your pnts>

import resource; 
initial_memory = resource.getrusage(resource.RUSAGE_SELF).ru_maxrss
while True:
  pymesh.distance_to_mesh(mesh, pnts)
  print "Memory footprint increased by {:d} KB".format(
    resource.getrusage(resource.RUSAGE_SELF).ru_maxrss-initial_memory)

Ubuntu 16.04 installation issue

When installing on Ubuntu 16.04, I am getting the following issue while running "make tools" at 75%:

/usr/bin/ld: cannot find -llib_triangle_wrapper
/usr/bin/ld: /home/rsmith/software/cork-master/lib/libcork.a(cork.o): relocation R_X86_64_32 against `.rodata.str1.1' can not be used when making a shared object; recompile with -fPIC
/home/rsmith/software/cork-master/lib/libcork.a: error adding symbols: Bad value
collect2: error: ld returned 1 exit status

I had a similar error when linking to the libtriangles-dev library. I tried adding the fPIC option to cmakecache.txt but haven't been able to get it to work. What should I try next? Let me know if I can provide any helpful system information.

Problems compiling tools

I'm trying to install on Arch Linux using a PKGBUILD modified from the aur:
https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=python-pymesh-git
If you're not on Arch, it's just a bash script to install into a fakeroot and compress for the package manager...

The script builds a broken package, so I've modified it to build also src_tests, tools, and tools_tests (lines 61,62,63 on the PKGBUILD.

This fails on the tools and tools_tests, so when I try to install them individually, the hangups are here:
no targets for:
EigenUtils_tests
outer_hull_tests
tetrahedronization_tests

build failures on:
boolean_tests
SparseSolver
SparseSolver_tests
wires_tests

For my project, I don't (currently) need the additional libraries, but I don't want to proceed without building at least EigenUtils_tests!
I've tried setting the variable EIGEN_INC to /usr/include/eigen3, but this didn't seem to help... do I need to pass anything special to cmake?

Here's my modified PKGBUILD:

PKGBUILD.txt

Thanks in advance,
Kyle McD

ImportError: No Module named '_PyMesh'

I managed to build and installed PyMesh in Windows and with Python 3.4. After build and install I tried to test with 'python -c "import pymesh; pymesh.test()" as described in the manual (readme.md).

However, I got this error;

Traceback (most recent call last):
File "C:\Python\3_4\lib\site-packages\pymesh-0.1-py3.4.egg\pymesh\swig\PyMesh.py", line 18, in swig_import_helper
return importlib.import_module(mname)
File "C:\Python\3_4\lib\importlib__init__.py", line 109, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "", line 2254, in _gcd_import
File "", line 2237, in _find_and_load
File "", line 2224, in _find_and_load_unlocked
ImportError: No module named '_PyMesh'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "", line 1, in
File "C:\Python\3_4\lib\site-packages\pymesh-0.1-py3.4.egg\pymesh__init__.py", line 18, in
from .Mesh import Mesh
File "C:\Python\3_4\lib\site-packages\pymesh-0.1-py3.4.egg\pymesh\Mesh.py", line 5, in
import PyMesh
File "C:\Python\3_4\lib\site-packages\pymesh-0.1-py3.4.egg\pymesh\swig\PyMesh.py", line 21, in
PyMesh = swig_import_helper()
File "C:\Python\3_4\lib\site-packages\pymesh-0.1-py3.4.egg\pymesh\swig\PyMesh.py", line 20, in swig_import_helper
return importlib.import_module('PyMesh')
File "C:\Python\3_4\lib\importlib__init
.py", line 109, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
ImportError: No module named '_PyMesh'

Could you please help, did I do something wrong during installation? (no error during build and install excepted only some unnecessary library).

Dependencies?

Hi. According to the readme, the only requirements are,

Python v3.x.
NumPy v1.8 or higher
SciPy v0.13 or higher
SWIG v3.0.5 or higher
Eigen v3.2 or higher

But it looks like even with those all installed, compiling fails on my machine. A lot of the errors are around missing libraries. Are there any other dependencies that are required (and not optional) not listed in the readme?

Simple mesh edits

Suppose I want to add translate a mesh by 1, 1, 1.

So the simplest way which I thought would work is:

mesh = pymesh.load_mesh(objfile)
mesh.vertices += 1

But this does not work. It shows:

AttributeError: can't set attribute

What is the easiest (or the possible) ways of updating vertices or faces of a mesh?

Trouble inflating wireframe: short edges, self intersections, and printability

I'm having trouble creating an inflated wire network. I've attached the file decimated-knight.wire. I have a little test program wire.py:

#!/usr/bin/env python
import sys
import os
import pymesh
wire_network = pymesh.wires.WireNetwork.create_from_file(
        os.path.expandvars(os.path.expanduser(sys.argv[1])))
inflator = pymesh.wires.Inflator(wire_network)
inflator.inflate(float(sys.argv[3]))
pymesh.save_mesh(
        os.path.expandvars(os.path.expanduser(sys.argv[2])))

If I call this program like this:

python wire.py ~/Downloads/decimated-knight.{wire,obj} 0.05

I get an error:

Traceback (most recent call last):
  File "wire.py", line 8, in <module>
    inflator.inflate(float(sys.argv[3]))
  File "/usr/local/lib/python2.7/site-packages/pymesh2-0.1.14-py2.7-macosx-10.12-x86_64.egg/pymesh/wires/Inflator.py", line 86, in inflate
    inflator.inflate();
  File "/usr/local/lib/python2.7/site-packages/pymesh2-0.1.14-py2.7-macosx-10.12-x86_64.egg/pymesh/swig/PyWires.py", line 1217, in inflate
    return _PyWires.InflatorEngine_inflate(self)
RuntimeError: Edge 0 is too short: len=0.0385346
Its length needs to be  at least 0.128943 to ensure inflation is self-intersection free

If I try using a smaller inflation amount (0.01) I get:

Traceback (most recent call last):
  File "wire.py", line 8, in <module>
    inflator.inflate(float(sys.argv[3]))
  File "/usr/local/lib/python2.7/site-packages/pymesh2-0.1.14-py2.7-macosx-10.12-x86_64.egg/pymesh/wires/Inflator.py", line 86, in inflate
    inflator.inflate();
  File "/usr/local/lib/python2.7/site-packages/pymesh2-0.1.14-py2.7-macosx-10.12-x86_64.egg/pymesh/swig/PyWires.py", line 1217, in inflate
    return _PyWires.InflatorEngine_inflate(self)
RuntimeError: Edge 1 is too short: len=0.0238506
Its length needs to be  at least 0.0454767 to ensure inflation is self-intersection free

So it seems like if I decrease the inflation thickness then the minimal length will be less than my smallest edge, but if I lower the thickness too much (0.009) I get a different error:

Traceback (most recent call last):
  File "wire.py", line 8, in <module>
    inflator.inflate(float(sys.argv[3]))
  File "/usr/local/lib/python2.7/site-packages/pymesh2-0.1.14-py2.7-macosx-10.12-x86_64.egg/pymesh/wires/Inflator.py", line 80, in inflate
    inflator.set_thickness(thickness);
  File "/usr/local/lib/python2.7/site-packages/pymesh2-0.1.14-py2.7-macosx-10.12-x86_64.egg/pymesh/swig/PyWires.py", line 1226, in set_thickness
    return _PyWires.InflatorEngine_set_thickness(self, thickness)
RuntimeError: Very thin thickness detected: 0.009
PyWires assumes thickness have unit mm
Thickness of such small value is typically not printible.

Is there a fool-proof way of creating a wire mesh at a desired thickness?

Somehow I was under the impression that PyMesh was dealing with acute angles and overlapping thickened wires, but it seems like it just throws an error. Am I mistaken?

decimated-knight.wire.zip

libMesh.so: cannot open shared object file: No such file or directory

After compiling and installing pymesh, I get this error when importing pymesh.
The file is installed in /usr/lib/python3.6/site-packages/pymesh/lib, but it seems that the interpreter doesn't find it there.
Am I missing something obvious?

I'm on Archlinux 4.9.11, swig 3.0.12, python 3.6

The install script I'm using is https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=python-pymesh-git
I don't compile the tools because tools_tests fail, and I also remove all scripts because I only need the main module, but I don't believe either have anything to do with this error.

mac 10.12.5 import error

I have compiled PyMesh according to http://pymesh.readthedocs.io/en/latest/installation.html,
and all unit tests are passed.

But when I import it using import pymesh, it reports errors.

OS X cmake error

Hi Qingnan,

I can't for the life of me figure this one out... here is the output from my terminal after installing the third party libraries and running cmake .. in the PyMesh directory:

BGoodwin-MacBook-Pro:PyMesh l-bgoodwin$ mkdir build
BGoodwin-MacBook-Pro:PyMesh l-bgoodwin$ cd build
BGoodwin-MacBook-Pro:build l-bgoodwin$ cmake ..
-- The C compiler identification is AppleClang 8.1.0.8020038
-- The CXX compiler identification is AppleClang 8.1.0.8020038
-- Check for working C compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc
-- Check for working C compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/c++
-- Check for working CXX compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Performing Test IS_SUPPORTED_-Wno-deprecated-declarations
-- Performing Test IS_SUPPORTED_-Wno-deprecated-declarations - Success
-- Found Eigen: /Users/l-bgoodwin/PyMesh/python/pymesh/third_party/include/eigen3
-- Found PythonInterp: /usr/local/bin/python (found version "2.7.13")
-- Found Python: /usr/local/opt/python/Frameworks/Python.framework/Versions/2.7/include/python2.7
-- Found NumPy: version "1.12.1" /usr/local/lib/python2.7/site-packages/numpy/core/include
CMake Error at /usr/local/Cellar/cmake/3.7.2/share/cmake/Modules/FindSWIG.cmake:38 (message):
Command "/usr/local/bin/swig -swiglib" failed with output:

dyld: Library not loaded: @rpath/libpcre.1.dylib

Referenced from: /usr/local/bin/swig
Reason: image not found

Call Stack (most recent call first):
cmake/FindAllDependencies.cmake:22 (FIND_PACKAGE)
Settings.cmake:51 (FIND_PACKAGE)
CMakeLists.txt:16 (INCLUDE)

CMake Error at /usr/local/Cellar/cmake/3.7.2/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:138 (message):
Could NOT find SWIG (missing: SWIG_DIR)
Call Stack (most recent call first):
/usr/local/Cellar/cmake/3.7.2/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:378 (_FPHSA_FAILURE_MESSAGE)
/usr/local/Cellar/cmake/3.7.2/share/cmake/Modules/FindSWIG.cmake:63 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
cmake/FindAllDependencies.cmake:22 (FIND_PACKAGE)
Settings.cmake:51 (FIND_PACKAGE)
CMakeLists.txt:16 (INCLUDE)

-- Configuring incomplete, errors occurred!
See also "/Users/l-bgoodwin/PyMesh/build/CMakeFiles/CMakeOutput.log".

Thanks for any help you are able to provide!

Sincerely,
Brian Goodwin

Python not found within virtualenv

All dependencies are successfully installed and found, but Python itself is still missing,

CMake Error at /usr/share/cmake-3.5/Modules/FindPackageHandleStandardArgs.cmake:148 (message):
  Python library is not found.  Please ensure python is installed (missing:
  PYTHON_INCLUDE_DIRS PYTHON_LIBRARIES)
Call Stack (most recent call first):
  /usr/share/cmake-3.5/Modules/FindPackageHandleStandardArgs.cmake:388 (_FPHSA_FAILURE_MESSAGE)
  cmake/FindPython.cmake:50 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
  cmake/FindAllDependencies.cmake:10 (FIND_PACKAGE)
  Settings.cmake:51 (FIND_PACKAGE)
  CMakeLists.txt:16 (INCLUDE)

-- Configuring incomplete, errors occurred!
See also "/home/tom/vision/env/PyMesh/build/CMakeFiles/CMakeOutput.log".

Now I tried adding explicit statements for the location of python, like @dansand suggests (here: #5):

cmake DPYTHON_INCLUDE_DIR=/home/tom/vision/env/include/python3.5m -DPYTHON_LIBRARY=/home/tom/vision/env/lib/python3.5 -DPYTHON_EXECUTABLE=/home/tom/vision/bin/python3.5 -DPYTHON_PACKAGES_PATH=/home/tom/vision/env/lib/python3.5/site-packages ..

However that does not solve it. Could you maybe point me in the right direction?

Thanks in advance!

PyMesh test error: retriangulation (Ubuntu 14.04)

Just want to know if anyone has solved this problem I am having with the pymesh.test() check:

Running unit tests for pymesh
NumPy version 1.11.3
NumPy relaxed strides checking option: False
NumPy is installed in /home/admindlam/anaconda2-7/envs/intelpy352/lib/python3.5/site-packages/numpy
Python version 3.5.2 |Intel Corporation| (default, Feb 5 2017, 09:07:18) [GCC 4.8.2 20140120 (Red Hat 4.8.2-15)]
nose version 1.3.7
...........................................................................................................................E.

ERROR: Failure: ImportError (cannot import name 'retriangulate')

Traceback (most recent call last):
File "/home/admindlam/anaconda2-7/envs/intelpy352/lib/python3.5/site-packages/nose/failure.py", line 39, in runTest
raise self.exc_val.with_traceback(self.tb)
File "/home/admindlam/anaconda2-7/envs/intelpy352/lib/python3.5/site-packages/nose/loader.py", line 418, in loadTestsFromName
addr.filename, addr.module)
File "/home/admindlam/anaconda2-7/envs/intelpy352/lib/python3.5/site-packages/nose/importer.py", line 47, in importFromPath
return self.importFromDir(dir_path, fqname)
File "/home/admindlam/anaconda2-7/envs/intelpy352/lib/python3.5/site-packages/nose/importer.py", line 94, in importFromDir
mod = load_module(part_fqname, fh, filename, desc)
File "/home/admindlam/anaconda2-7/envs/intelpy352/lib/python3.5/imp.py", line 234, in load_module
return load_source(name, filename, file)
File "/home/admindlam/anaconda2-7/envs/intelpy352/lib/python3.5/imp.py", line 172, in load_source
module = _load(spec)
File "", line 693, in _load
File "", line 673, in _load_unlocked
File "", line 665, in exec_module
File "", line 222, in _call_with_frames_removed
File "/home/admindlam/.local/lib/python3.5/site-packages/pymesh2-0.1.14-py3.5-linux-x86_64.egg/pymesh/tests/test_triangulate.py", line 3, in
from pymesh import triangulate, retriangulate
ImportError: cannot import name 'retriangulate'


Ran 125 tests in 6.407s

FAILED (errors=1)

Loading mesh causes memory leak

I observed that if I load meshes in a loop, it causes memory leak as the memory used by my script seems to increase continuously. This could be due to other factors, but is being caused at least by load_mesh function, which I narrowed down. For example, the following code results in the increase in memory with time - which should not happen as, the variable mesh should be destroyed by the end of the loop.

filename = './bathtub/train/bathtub_0057.off'
for i in range (10000):
    mesh = pymesh.load_mesh(filename)

Compile error on python 3 (anaconda)

cmake cannot complete the configuration with the following output:

Traceback (most recent call last):
  File "/home/hazmil/Software/pythonPackages/PyMesh/cmake/SetInstallRpath.py", line 23, in <module>
    site_location = [os.path.join(loc, install_path) for loc in site_location] +\
  File "/home/hazmil/Software/pythonPackages/PyMesh/cmake/SetInstallRpath.py", line 23, in <listcomp>
    site_location = [os.path.join(loc, install_path) for loc in site_location] +\
  File "/home/hazmil/Software/anaconda3/lib/python3.6/posixpath.py", line 78, in join
    a = os.fspath(a)
TypeError: expected str, bytes or os.PathLike object, not list
CMake Error at Settings.cmake:58 (INCLUDE):
  include could not find load file:

    SetInstallRpath
Call Stack (most recent call first):
CMakeLists.txt:16 (INCLUDE)

Using python 2.7, I can get the cmake configuration completed if I add "/" in front of defined paths in the script "SetInstallRpath.py" (due to another type of error), then can successfully complete the compilation (with a few failed test cases). However, I encountered an error when trying to import "pymesh", and I relate this to a latest requirement in the home address of Pymesh which is

PyMesh depends on the following tools/libraries: Python v3.x.

Then I changed to Python 3 to work with this package, however encountered with the above error.

'pymesh' has no attribute 'distance_to_mesh'

Hi,
When I try to run pymesh.distance_to_mesh, I get the following error:
AttributeError: module 'pymesh' has no attribute 'distance_to_mesh'

I have no problem with load_mesh and accessing mesh faces, vertices and so on.

'igl/copyleft/cgal/delaunay_triangulation.h' file not found

I followed your installation instructions in the documentation, everything goes well until make tools when I get the following error:

[ 65%] Building CXX object tools/Triangulation/CMakeFiles/lib_triangulation.dir/IGL/DelaunayTriangulation.cpp.o
/Users/grpaul/myapps/PyMesh/tools/Triangulation/IGL/DelaunayTriangulation.cpp:4:10: fatal error: 
      'igl/copyleft/cgal/delaunay_triangulation.h' file not found
#include <igl/copyleft/cgal/delaunay_triangulation.h>

Checking a little bit the files, it actually does not exist. It seems that it is defined in igl/copyleft/cgal/remesh_intersections.cpp... as a lambda? Really looking forward to try your library!

make tools_tests failed on Ubuntu

Hello,
When I run "make tools_tests", and get these errors:

[ 58%] Linking CXX executable ../../../../bin/triangulation_tests
[==========] Running 8 tests from 2 test cases.
[----------] Global test environment set-up.
[----------] 4 tests from LexicographicTriangulationTest
[ RUN ] LexicographicTriangulationTest.simple
unknown file: Failure
C++ exception with description "Triangulation engine igl_lexicographic is not supported" thrown in the test body.
[ FAILED ] LexicographicTriangulationTest.simple (0 ms)
[ RUN ] LexicographicTriangulationTest.simple2
unknown file: Failure
C++ exception with description "Triangulation engine igl_lexicographic is not supported" thrown in the test body.
[ FAILED ] LexicographicTriangulationTest.simple2 (0 ms)
[ RUN ] LexicographicTriangulationTest.simple3
unknown file: Failure
C++ exception with description "Triangulation engine igl_lexicographic is not supported" thrown in the test body.
[ FAILED ] LexicographicTriangulationTest.simple3 (0 ms)
[ RUN ] LexicographicTriangulationTest.degenerate
unknown file: Failure
C++ exception with description "Triangulation engine igl_lexicographic is not supported" thrown in the test body.
[ FAILED ] LexicographicTriangulationTest.degenerate (0 ms)
[----------] 4 tests from LexicographicTriangulationTest (0 ms total)

Do you have any idea please? Thank you!
Notice that I followed all installation steps.

tools/ConvexHull does not compile

Hello, the default tools/ConvexHull does not compile for me. Specifically it isn't able to find shared_ptr. I added the line

set(CMAKE_CXX_FLAGS "-std=c++11 ${CMAKE_CXX_FLAGS}")

inside tools/ConvexHull/CMakeLists.txt to fix it (for gcc).

Figured I'd put this up here in case it helps somebody else.

ERROR: Failure: ImportError (No module named 'PyWires') ... and more...

I thought these deserve a new issue, or are they a result from wrongdoing here #31 ?

Please let me know if I am being helpful or annoying ;-)!

(env) tom@vision:~/vision$ python -c "import pymesh; pymesh.test()"
Running unit tests for pymesh
NumPy version 1.12.0
NumPy relaxed strides checking option: True
NumPy is installed in /home/tom/vision/env/lib/python3.5/site-packages/numpy
Python version 3.5.2 (default, Nov 17 2016, 17:05:23) [GCC 5.4.0 20160609]
nose version 1.3.7
......F.....................................EE.EEEEEEEEEEEEEEEEEEEEEEEEE.......EEEEEE.........EEEEEEEEEEEEEEEE
======================================================================
ERROR: Failure: ImportError (No module named 'PyWires')
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/nose/failure.py", line 39, in runTest
    raise self.exc_val.with_traceback(self.tb)
  File "/home/tom/vision/env/lib/python3.5/site-packages/nose/loader.py", line 418, in loadTestsFromName
    addr.filename, addr.module)
  File "/home/tom/vision/env/lib/python3.5/site-packages/nose/importer.py", line 47, in importFromPath
    return self.importFromDir(dir_path, fqname)
  File "/home/tom/vision/env/lib/python3.5/site-packages/nose/importer.py", line 94, in importFromDir
    mod = load_module(part_fqname, fh, filename, desc)
  File "/home/tom/vision/env/lib/python3.5/imp.py", line 244, in load_module
    return load_package(name, filename)
  File "/home/tom/vision/env/lib/python3.5/imp.py", line 216, in load_package
    return _load(spec)
  File "<frozen importlib._bootstrap>", line 693, in _load
  File "<frozen importlib._bootstrap>", line 673, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 665, in exec_module
  File "<frozen importlib._bootstrap>", line 222, in _call_with_frames_removed
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/wires/__init__.py", line 1, in <module>
    from .WireNetwork import WireNetwork
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/wires/WireNetwork.py", line 5, in <module>
    import PyWires
ImportError: No module named 'PyWires'

======================================================================
ERROR: test_single_mesh (test_CSGTree.CSGTreeTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_CSGTree.py", line 11, in test_single_mesh
    tree = CSGTree({"mesh": mesh});
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/CSGTree.py", line 40, in __init__
    mesh.vertices, mesh.faces);
RuntimeError: CSG engine igl is not supported

======================================================================
ERROR: Failure: ImportError (cannot import name 'distance_to_mesh')
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/nose/failure.py", line 39, in runTest
    raise self.exc_val.with_traceback(self.tb)
  File "/home/tom/vision/env/lib/python3.5/site-packages/nose/loader.py", line 418, in loadTestsFromName
    addr.filename, addr.module)
  File "/home/tom/vision/env/lib/python3.5/site-packages/nose/importer.py", line 47, in importFromPath
    return self.importFromDir(dir_path, fqname)
  File "/home/tom/vision/env/lib/python3.5/site-packages/nose/importer.py", line 94, in importFromDir
    mod = load_module(part_fqname, fh, filename, desc)
  File "/home/tom/vision/env/lib/python3.5/imp.py", line 234, in load_module
    return load_source(name, filename, file)
  File "/home/tom/vision/env/lib/python3.5/imp.py", line 172, in load_source
    module = _load(spec)
  File "<frozen importlib._bootstrap>", line 693, in _load
  File "<frozen importlib._bootstrap>", line 673, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 665, in exec_module
  File "<frozen importlib._bootstrap>", line 222, in _call_with_frames_removed
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_aabb_tree.py", line 2, in <module>
    from pymesh import distance_to_mesh
ImportError: cannot import name 'distance_to_mesh'

======================================================================
ERROR: test_corner_corner_touch (test_boolean.BooleanTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_boolean.py", line 63, in test_corner_corner_touch
    "intersection", "igl");
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/boolean.py", line 73, in boolean
    engine = PyBoolean.BooleanEngine.create(engine);
RuntimeError: Boolean engine "igl" is not supported.


======================================================================
ERROR: test_cross_union (test_boolean.BooleanTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_boolean.py", line 478, in test_cross_union
    mesh = boolean(mesh_1, mesh_2, "union", "igl");
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/boolean.py", line 73, in boolean
    engine = PyBoolean.BooleanEngine.create(engine);
RuntimeError: Boolean engine "igl" is not supported.


======================================================================
ERROR: test_edge_edge_orthogonal_touch (test_boolean.BooleanTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_boolean.py", line 397, in test_edge_edge_orthogonal_touch
    mesh = boolean(mesh_1, mesh_2, "union", "igl");
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/boolean.py", line 73, in boolean
    engine = PyBoolean.BooleanEngine.create(engine);
RuntimeError: Boolean engine "igl" is not supported.


======================================================================
ERROR: test_edge_edge_touch (test_boolean.BooleanTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_boolean.py", line 104, in test_edge_edge_touch
    "intersection", "igl");
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/boolean.py", line 73, in boolean
    engine = PyBoolean.BooleanEngine.create(engine);
RuntimeError: Boolean engine "igl" is not supported.


======================================================================
ERROR: test_edge_edge_touch_with_different_length (test_boolean.BooleanTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_boolean.py", line 279, in test_edge_edge_touch_with_different_length
    "intersection", "igl");
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/boolean.py", line 73, in boolean
    engine = PyBoolean.BooleanEngine.create(engine);
RuntimeError: Boolean engine "igl" is not supported.


======================================================================
ERROR: test_eps_corner_intersection (test_boolean.BooleanTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_boolean.py", line 230, in test_eps_corner_intersection
    "intersection", "igl");
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/boolean.py", line 73, in boolean
    engine = PyBoolean.BooleanEngine.create(engine);
RuntimeError: Boolean engine "igl" is not supported.


======================================================================
ERROR: test_eps_edge_intersection (test_boolean.BooleanTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_boolean.py", line 246, in test_eps_edge_intersection
    "intersection", "igl");
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/boolean.py", line 73, in boolean
    engine = PyBoolean.BooleanEngine.create(engine);
RuntimeError: Boolean engine "igl" is not supported.


======================================================================
ERROR: test_eps_face_intersection (test_boolean.BooleanTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_boolean.py", line 263, in test_eps_face_intersection
    "intersection", "igl");
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/boolean.py", line 73, in boolean
    engine = PyBoolean.BooleanEngine.create(engine);
RuntimeError: Boolean engine "igl" is not supported.


======================================================================
ERROR: test_face_corner_touch (test_boolean.BooleanTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_boolean.py", line 316, in test_face_corner_touch
    mesh = boolean(mesh_1, mesh_2, "union", "igl");
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/boolean.py", line 73, in boolean
    engine = PyBoolean.BooleanEngine.create(engine);
RuntimeError: Boolean engine "igl" is not supported.


======================================================================
ERROR: test_face_corner_touch_off_center (test_boolean.BooleanTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_boolean.py", line 336, in test_face_corner_touch_off_center
    mesh = boolean(mesh_1, mesh_2, "union", "igl");
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/boolean.py", line 73, in boolean
    engine = PyBoolean.BooleanEngine.create(engine);
RuntimeError: Boolean engine "igl" is not supported.


======================================================================
ERROR: test_face_edge_touch (test_boolean.BooleanTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_boolean.py", line 356, in test_face_edge_touch
    mesh = boolean(mesh_1, mesh_2, "union", "igl");
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/boolean.py", line 73, in boolean
    engine = PyBoolean.BooleanEngine.create(engine);
RuntimeError: Boolean engine "igl" is not supported.


======================================================================
ERROR: test_face_face_touch (test_boolean.BooleanTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_boolean.py", line 146, in test_face_face_touch
    "intersection", "igl");
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/boolean.py", line 73, in boolean
    engine = PyBoolean.BooleanEngine.create(engine);
RuntimeError: Boolean engine "igl" is not supported.


======================================================================
ERROR: test_face_face_touch_with_different_area (test_boolean.BooleanTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_boolean.py", line 296, in test_face_face_touch_with_different_area
    "intersection", "igl");
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/boolean.py", line 73, in boolean
    engine = PyBoolean.BooleanEngine.create(engine);
RuntimeError: Boolean engine "igl" is not supported.


======================================================================
ERROR: test_intersection_with_self (test_boolean.BooleanTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_boolean.py", line 405, in test_intersection_with_self
    mesh = boolean(mesh_1, mesh_1, "intersection", "igl");
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/boolean.py", line 73, in boolean
    engine = PyBoolean.BooleanEngine.create(engine);
RuntimeError: Boolean engine "igl" is not supported.


======================================================================
ERROR: test_intersection_with_slighly_rotated_self (test_boolean.BooleanTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_boolean.py", line 419, in test_intersection_with_slighly_rotated_self
    mesh = boolean(mesh_1, mesh_2, "intersection", "igl");
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/boolean.py", line 73, in boolean
    engine = PyBoolean.BooleanEngine.create(engine);
RuntimeError: Boolean engine "igl" is not supported.


======================================================================
ERROR: test_nested_mesh (test_boolean.BooleanTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_boolean.py", line 444, in test_nested_mesh
    mesh = boolean(mesh_1, mesh_2, "intersection", "igl");
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/boolean.py", line 73, in boolean
    engine = PyBoolean.BooleanEngine.create(engine);
RuntimeError: Boolean engine "igl" is not supported.


======================================================================
ERROR: test_rotate_union_120_degrees (test_boolean.BooleanTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_boolean.py", line 499, in test_rotate_union_120_degrees
    mesh = boolean(mesh_1, mesh_2, "union", "igl");
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/boolean.py", line 73, in boolean
    engine = PyBoolean.BooleanEngine.create(engine);
RuntimeError: Boolean engine "igl" is not supported.


======================================================================
ERROR: test_rotation_180 (test_boolean.BooleanTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_boolean.py", line 553, in test_rotation_180
    mesh = boolean(mesh_1, mesh_2, "union", "cgal");
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/boolean.py", line 73, in boolean
    engine = PyBoolean.BooleanEngine.create(engine);
RuntimeError: Boolean engine "cgal" is not supported.


======================================================================
ERROR: test_rotation_union_stress (test_boolean.BooleanTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_boolean.py", line 519, in test_rotation_union_stress
    mesh = boolean(mesh, mesh_2, "union", "igl");
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/boolean.py", line 73, in boolean
    engine = PyBoolean.BooleanEngine.create(engine);
RuntimeError: Boolean engine "igl" is not supported.


======================================================================
ERROR: test_rotation_union_stress_2 (test_boolean.BooleanTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_boolean.py", line 538, in test_rotation_union_stress_2
    mesh = boolean(mesh, mesh_2, "union", "igl");
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/boolean.py", line 73, in boolean
    engine = PyBoolean.BooleanEngine.create(engine);
RuntimeError: Boolean engine "igl" is not supported.


======================================================================
ERROR: test_separated_shapes (test_boolean.BooleanTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_boolean.py", line 22, in test_separated_shapes
    "intersection", "igl");
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/boolean.py", line 73, in boolean
    engine = PyBoolean.BooleanEngine.create(engine);
RuntimeError: Boolean engine "igl" is not supported.


======================================================================
ERROR: test_simple_intersection (test_boolean.BooleanTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_boolean.py", line 187, in test_simple_intersection
    "intersection", "igl");
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/boolean.py", line 73, in boolean
    engine = PyBoolean.BooleanEngine.create(engine);
RuntimeError: Boolean engine "igl" is not supported.


======================================================================
ERROR: test_union_with_45_rotated_self (test_boolean.BooleanTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_boolean.py", line 433, in test_union_with_45_rotated_self
    mesh = boolean(mesh_1, mesh_2, "union", "igl");
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/boolean.py", line 73, in boolean
    engine = PyBoolean.BooleanEngine.create(engine);
RuntimeError: Boolean engine "igl" is not supported.


======================================================================
ERROR: test_union_with_rotated_self (test_boolean.BooleanTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_boolean.py", line 377, in test_union_with_rotated_self
    mesh = boolean(mesh_1, mesh_2, "union", "igl");
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/boolean.py", line 73, in boolean
    engine = PyBoolean.BooleanEngine.create(engine);
RuntimeError: Boolean engine "igl" is not supported.


======================================================================
ERROR: Failure: ImportError (No module named 'PyIGL')
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/nose/failure.py", line 39, in runTest
    raise self.exc_val.with_traceback(self.tb)
  File "/home/tom/vision/env/lib/python3.5/site-packages/nose/loader.py", line 418, in loadTestsFromName
    addr.filename, addr.module)
  File "/home/tom/vision/env/lib/python3.5/site-packages/nose/importer.py", line 47, in importFromPath
    return self.importFromDir(dir_path, fqname)
  File "/home/tom/vision/env/lib/python3.5/site-packages/nose/importer.py", line 94, in importFromDir
    mod = load_module(part_fqname, fh, filename, desc)
  File "/home/tom/vision/env/lib/python3.5/imp.py", line 234, in load_module
    return load_source(name, filename, file)
  File "/home/tom/vision/env/lib/python3.5/imp.py", line 172, in load_source
    module = _load(spec)
  File "<frozen importlib._bootstrap>", line 693, in _load
  File "<frozen importlib._bootstrap>", line 673, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 665, in exec_module
  File "<frozen importlib._bootstrap>", line 222, in _call_with_frames_removed
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_minkowski_sum.py", line 3, in <module>
    from pymesh import minkowski_sum, detect_self_intersection
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/minkowski_sum.py", line 1, in <module>
    import PyIGL
ImportError: No module named 'PyIGL'

======================================================================
ERROR: test_face_face_touch (test_outerhull.OuterHullTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_outerhull.py", line 89, in test_face_face_touch
    outer_hulls = compute_outer_hull(mesh, all_layers=True);
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/outerhull.py", line 40, in compute_outer_hull
    engine = PyOuterHull.OuterHullEngine.create(engine);
RuntimeError: Unknown outer hull engine: igl

======================================================================
ERROR: test_intersecting_cubes (test_outerhull.OuterHullTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_outerhull.py", line 43, in test_intersecting_cubes
    outer_hull = compute_outer_hull(mesh);
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/outerhull.py", line 40, in compute_outer_hull
    engine = PyOuterHull.OuterHullEngine.create(engine);
RuntimeError: Unknown outer hull engine: igl

======================================================================
ERROR: test_multiple_components (test_outerhull.OuterHullTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_outerhull.py", line 74, in test_multiple_components
    outer_hulls = compute_outer_hull(mesh, all_layers=True);
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/outerhull.py", line 40, in compute_outer_hull
    engine = PyOuterHull.OuterHullEngine.create(engine);
RuntimeError: Unknown outer hull engine: igl

======================================================================
ERROR: test_nested_cubes (test_outerhull.OuterHullTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_outerhull.py", line 54, in test_nested_cubes
    outer_hulls = compute_outer_hull(mesh, all_layers=True);
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/outerhull.py", line 40, in compute_outer_hull
    engine = PyOuterHull.OuterHullEngine.create(engine);
RuntimeError: Unknown outer hull engine: igl

======================================================================
ERROR: test_simple_cube (test_outerhull.OuterHullTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_outerhull.py", line 28, in test_simple_cube
    outer_hulls = compute_outer_hull(mesh, all_layers=True);
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/outerhull.py", line 40, in compute_outer_hull
    engine = PyOuterHull.OuterHullEngine.create(engine);
RuntimeError: Unknown outer hull engine: igl

======================================================================
ERROR: test_corner_corner_touch (test_selfintersection.SelfIntersectionTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_selfintersection.py", line 81, in test_corner_corner_touch
    output_mesh = resolve_self_intersection(mesh);
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/selfintersection.py", line 41, in resolve_self_intersection
    resolver = PySelfIntersection.SelfIntersectionResolver.create(engine);
RuntimeError: Self-intersection engine "igl" is not supported

======================================================================
ERROR: test_cross_union (test_selfintersection.SelfIntersectionTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_selfintersection.py", line 214, in test_cross_union
    output_mesh = resolve_self_intersection(mesh);
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/selfintersection.py", line 41, in resolve_self_intersection
    resolver = PySelfIntersection.SelfIntersectionResolver.create(engine);
RuntimeError: Self-intersection engine "igl" is not supported

======================================================================
ERROR: test_edge_edge_touch (test_selfintersection.SelfIntersectionTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_selfintersection.py", line 94, in test_edge_edge_touch
    output_mesh = resolve_self_intersection(mesh);
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/selfintersection.py", line 41, in resolve_self_intersection
    resolver = PySelfIntersection.SelfIntersectionResolver.create(engine);
RuntimeError: Self-intersection engine "igl" is not supported

======================================================================
ERROR: test_face_corner_touch (test_selfintersection.SelfIntersectionTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_selfintersection.py", line 160, in test_face_corner_touch
    output_mesh = resolve_self_intersection(mesh);
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/selfintersection.py", line 41, in resolve_self_intersection
    resolver = PySelfIntersection.SelfIntersectionResolver.create(engine);
RuntimeError: Self-intersection engine "igl" is not supported
-------------------- >> begin captured logging << --------------------
pymesh.meshutils.merge_meshes: WARNING: Not all input meshes represent a volume, so dropping all voxels.
--------------------- >> end captured logging << ---------------------

======================================================================
ERROR: test_face_corner_touch_off_center (test_selfintersection.SelfIntersectionTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_selfintersection.py", line 179, in test_face_corner_touch_off_center
    output_mesh = resolve_self_intersection(mesh);
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/selfintersection.py", line 41, in resolve_self_intersection
    resolver = PySelfIntersection.SelfIntersectionResolver.create(engine);
RuntimeError: Self-intersection engine "igl" is not supported
-------------------- >> begin captured logging << --------------------
pymesh.meshutils.merge_meshes: WARNING: Not all input meshes represent a volume, so dropping all voxels.
--------------------- >> end captured logging << ---------------------

======================================================================
ERROR: test_face_edge_touch (test_selfintersection.SelfIntersectionTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_selfintersection.py", line 128, in test_face_edge_touch
    output_mesh = resolve_self_intersection(mesh);
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/selfintersection.py", line 41, in resolve_self_intersection
    resolver = PySelfIntersection.SelfIntersectionResolver.create(engine);
RuntimeError: Self-intersection engine "igl" is not supported
-------------------- >> begin captured logging << --------------------
pymesh.meshutils.merge_meshes: WARNING: Not all input meshes represent a volume, so dropping all voxels.
--------------------- >> end captured logging << ---------------------

======================================================================
ERROR: test_face_face_touch (test_selfintersection.SelfIntersectionTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_selfintersection.py", line 107, in test_face_face_touch
    output_mesh = resolve_self_intersection(mesh);
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/selfintersection.py", line 41, in resolve_self_intersection
    resolver = PySelfIntersection.SelfIntersectionResolver.create(engine);
RuntimeError: Self-intersection engine "igl" is not supported

======================================================================
ERROR: test_face_face_touch_with_different_area (test_selfintersection.SelfIntersectionTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_selfintersection.py", line 141, in test_face_face_touch_with_different_area
    output_mesh = resolve_self_intersection(mesh);
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/selfintersection.py", line 41, in resolve_self_intersection
    resolver = PySelfIntersection.SelfIntersectionResolver.create(engine);
RuntimeError: Self-intersection engine "igl" is not supported

======================================================================
ERROR: test_intersect_with_rotated_self (test_selfintersection.SelfIntersectionTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_selfintersection.py", line 197, in test_intersect_with_rotated_self
    output_mesh = resolve_self_intersection(mesh);
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/selfintersection.py", line 41, in resolve_self_intersection
    resolver = PySelfIntersection.SelfIntersectionResolver.create(engine);
RuntimeError: Self-intersection engine "igl" is not supported
-------------------- >> begin captured logging << --------------------
pymesh.meshutils.merge_meshes: WARNING: Not all input meshes represent a volume, so dropping all voxels.
--------------------- >> end captured logging << ---------------------

======================================================================
ERROR: test_no_intersection (test_selfintersection.SelfIntersectionTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/selfintersection.py", line 70, in detect_self_intersection
    import PyCGAL
ImportError: No module named 'PyCGAL'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_selfintersection.py", line 55, in test_no_intersection
    intersecting_faces = detect_self_intersection(mesh);
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/selfintersection.py", line 73, in detect_self_intersection
    "Self intersection detection is not supported");
NotImplementedError: Self intersection detection is not supported

======================================================================
ERROR: test_rotate_120 (test_selfintersection.SelfIntersectionTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_selfintersection.py", line 232, in test_rotate_120
    output_mesh = resolve_self_intersection(mesh);
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/selfintersection.py", line 41, in resolve_self_intersection
    resolver = PySelfIntersection.SelfIntersectionResolver.create(engine);
RuntimeError: Self-intersection engine "igl" is not supported
-------------------- >> begin captured logging << --------------------
pymesh.meshutils.merge_meshes: WARNING: Not all input meshes represent a volume, so dropping all voxels.
--------------------- >> end captured logging << ---------------------

======================================================================
ERROR: test_simple_intersection (test_selfintersection.SelfIntersectionTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_selfintersection.py", line 69, in test_simple_intersection
    output_mesh = resolve_self_intersection(mesh);
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/selfintersection.py", line 41, in resolve_self_intersection
    resolver = PySelfIntersection.SelfIntersectionResolver.create(engine);
RuntimeError: Self-intersection engine "igl" is not supported

======================================================================
ERROR: test_box (test_slice_Mesh.SliceMeshTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_slice_Mesh.py", line 22, in test_box
    slices = slice_mesh(mesh, [1, 0, 0], N);
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/slice_mesh.py", line 53, in slice_mesh
    slabs = boolean(boxes, mesh, "intersection");
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/boolean.py", line 73, in boolean
    engine = PyBoolean.BooleanEngine.create(engine);
RuntimeError: Boolean engine "igl" is not supported.


======================================================================
ERROR: test_diag_box (test_slice_Mesh.SliceMeshTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_slice_Mesh.py", line 33, in test_diag_box
    slices = slice_mesh(mesh, [1, 1, 1], N);
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/slice_mesh.py", line 53, in slice_mesh
    slabs = boolean(boxes, mesh, "intersection");
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/boolean.py", line 73, in boolean
    engine = PyBoolean.BooleanEngine.create(engine);
RuntimeError: Boolean engine "igl" is not supported.


======================================================================
ERROR: Failure: ImportError (No module named 'PyTriangle')
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/nose/failure.py", line 39, in runTest
    raise self.exc_val.with_traceback(self.tb)
  File "/home/tom/vision/env/lib/python3.5/site-packages/nose/loader.py", line 418, in loadTestsFromName
    addr.filename, addr.module)
  File "/home/tom/vision/env/lib/python3.5/site-packages/nose/importer.py", line 47, in importFromPath
    return self.importFromDir(dir_path, fqname)
  File "/home/tom/vision/env/lib/python3.5/site-packages/nose/importer.py", line 94, in importFromDir
    mod = load_module(part_fqname, fh, filename, desc)
  File "/home/tom/vision/env/lib/python3.5/imp.py", line 234, in load_module
    return load_source(name, filename, file)
  File "/home/tom/vision/env/lib/python3.5/imp.py", line 172, in load_source
    module = _load(spec)
  File "<frozen importlib._bootstrap>", line 693, in _load
  File "<frozen importlib._bootstrap>", line 673, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 665, in exec_module
  File "<frozen importlib._bootstrap>", line 222, in _call_with_frames_removed
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_triangulate.py", line 3, in <module>
    from pymesh import triangulate, retriangulate
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/triangulate.py", line 1, in <module>
    import PyTriangle
ImportError: No module named 'PyTriangle'

======================================================================
ERROR: test_cube (test_winding_number.WindingNumberTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/tests/test_winding_number.py", line 21, in test_cube
    winding_numbers = compute_winding_number(mesh, queries);
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/winding_number.py", line 10, in compute_winding_number
    engine = PyWindingNumber.WindingNumberEngine.create(engine);
RuntimeError: Unknown winding number engine: igl

======================================================================
FAIL: test_degenerated_triangles (test_collapse_short_edges.CollapseShortEdgesTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tom/vision/env/lib/python3.5/site-packages/pymesh-0.1-py3.5.egg/pymesh/meshutils/tests/test_collapse_short_edges.py", line 81, in test_degenerated_triangles
    self.assertEqual(3, len(out_vertices));
AssertionError: 3 != 4
-------------------- >> begin captured logging << --------------------
pymesh.meshutils.collapse_short_edges: INFO: Minimum edge threshold: 0.5
pymesh.meshutils.collapse_short_edges: INFO: 0 edges collapsed
--------------------- >> end captured logging << ---------------------

----------------------------------------------------------------------
Ran 110 tests in 0.928s

FAILED (errors=49, failures=1)

[mac installation] library not found for -llib_wires

Trying to install PyMesh, I got this error.

(after clone github and cmake)

build git:(master) make
[ 42%] Built target Mesh
[ 44%] Built target lib_igl
[ 46%] Built target lib_predicates
[ 63%] Built target lib_MeshUtils
[ 63%] Built target MeshUtils
[ 66%] Built target lib_convex_hull
[ 73%] Built target lib_boolean
[ 74%] Built target lib_self_intersection
[ 76%] Built target lib_outer_hull
[ 77%] Built target lib_winding_number
[ 82%] Built target lib_triangulation
[ 84%] Built target cgal_wrapper
[ 85%] Built target lib_tetrahedronization
[ 85%] Linking CXX shared module ../../python/pymesh/lib/PyMesh.so
ld: library not found for -llib_wires
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [../python/pymesh/lib/PyMesh.so] Error 1
make[1]: *** [python/CMakeFiles/PyMesh.dir/all] Error 2
make: *** [all] Error 2

Another question:
On my computer are Python 2.7 and Python 3.6 two versions.
By default it is 2.7.
How should I tell the computer in which version should be installed the package? (3.6 precisely)

Did I miss something? Thanks in advance!

Can't build third party tools on Windows 10

Hey guys,

I'm trying to run PyMesh on Windows 10 and currently am facing the difficulty that I can't even build the third party tools.
I use CMake and VS 2015 resulting in a bunch of errors. It's possible to configure and generate the solution via CMake.

For example:

8>D:\Code\PyMesh\third_party\cork\src\math\vec.h(96): error C2988: Unerkannte Vorlagendeklaration/-definition
8>D:\Code\PyMesh\third_party\cork\src\math\vec.h(96): error C2059: Syntaxfehler: "const"
8>D:\Code\PyMesh\third_party\cork\src\math\vec.h(96): error C2065: "N": nichtdeklarierter Bezeichner
8>D:\Code\PyMesh\third_party\cork\src\math\vec.h(96): error C2923: "Vec2": "N" ist kein gültiges template-Typargument für den N-Parameter.
8>D:\Code\PyMesh\third_party\cork\src\math\vec.h(96): error C2059: Syntaxfehler: ")"
8>D:\Code\PyMesh\third_party\cork\src\math\vec.h(98): error C2065: "N": nichtdeklarierter Bezeichner

As you can see, the error messages are in German, but nevertheless the error codes are clear. Most of these errors come from cork and carve. Any suggestions how to fix this?

where is bsplib

I found there is external bsp lib is used. where can I find it?

Segmentation fault When link all the c++ library

Hi James,
I tried to use the wires part of PyMesh in c++ and I had successfully compiled all the libraries.
In my project, I linked all the libraries in cmake file just in case I use other part of PyMesh. However, I found that the output of the code is either Segmentation fault or frozen.
But same code can run well and output correct result if I only link libMesh.so and libwires.so (learn from the tests).

I cannot find out the reason why it happens.

ERROR: Failure: ImportError (cannot import name SparseSolver)

Running python -c "import pymesh; pymesh.test()" returns:

Running unit tests for pymesh
NumPy version 1.11.2
NumPy relaxed strides checking option: False
NumPy is installed in /home/grpaul/.pyenv/versions/2.7.11/lib/python2.7/site-packages/numpy
Python version 2.7.11 (default, Oct 25 2016, 09:45:51) [GCC 4.9.2]
nose version 1.3.7
......................................................................................................................E....
======================================================================
ERROR: Failure: ImportError (cannot import name SparseSolver)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/grpaul/.pyenv/versions/2.7.11/lib/python2.7/site-packages/nose/loader.py", line 418, in loadTestsFromName
    addr.filename, addr.module)
  File "/home/grpaul/.pyenv/versions/2.7.11/lib/python2.7/site-packages/nose/importer.py", line 47, in importFromPath
    return self.importFromDir(dir_path, fqname)
  File "/home/grpaul/.pyenv/versions/2.7.11/lib/python2.7/site-packages/nose/importer.py", line 94, in importFromDir
    mod = load_module(part_fqname, fh, filename, desc)
  File "/home/grpaul/.pyenv/versions/2.7.11/lib/python2.7/site-packages/pymesh-0.1-py2.7.egg/pymesh/tests/test_solver.py", line 1, in <module>
    from pymesh import SparseSolver
ImportError: cannot import name SparseSolver

----------------------------------------------------------------------
Ran 123 tests in 2.358s

FAILED (errors=1)

After checking you have python/pymesh/Solver.py where a class SparseSolver is defined. The problem is that it imports PySparseSolver which is not defined.

error while loading ply file

hi, I came across two issues while loading a mesh in ply format.

  1. pymesh seems not support ply in ascii format
  2. wrong reporting of duplicated property for a file with the following header:
element vertex 2503
property float32 x
property float32 y
property float32 z
property uint8 red
property uint8 green
property uint8 blue
property uint8 alpha
element face 4968
property list uint8 int32 vertex_indices
property list uint8 float32 texcoord
property uint8 red
property uint8 green
property uint8 blue
property uint8 alpha
end_header

The error message is:

OSError: Duplicated property name: red
PyMesh requires unique custom property names

However, as we can see, red properties belong to different elements.

Installation error during cmake stage for 3rd party libs (Ubuntu 14.04)

The first CMake error I encounter is:

CMake Error in cgal/Installation/src/CGAL/CMakeLists.txt:
Cannot find source file:

INTERFACE

Tried extensions .c .C .c++ .cc .cpp .cxx .m .M .mm .h .hh .h++ .hm .hpp
.hxx .in .txx

CMake Error: CMake can not determine linker language for target: CGAL
CMake Error in cgal/Installation/src/CGAL/CMakeLists.txt:
Exporting the target "CGAL" is not allowed since its linker language cannot
be determined

I am wondering what I've done wrong? I have downloaded and installed CGAL, Geogram and Sparsehash from their own sources, and it is sitting in my home directory.

I have also entered export CGAL_PATH=/path/to/CGAL-4.9.1

Failure to run tests

I tried to install on a brand new MacBook Pro using home-brew and pip. Everything seemed to install and compile OK but the test command

python -c "import pymesh; pymesh.test()"

Produced a set of import errors:

Running unit tests for pymesh
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/usr/local/lib/python2.7/site-packages/numpy/testing/nosetester.py", line 374, in test
    self._show_system_info()
  File "/usr/local/lib/python2.7/site-packages/numpy/testing/nosetester.py", line 227, in _show_system_info
    nose = import_nose()
  File "/usr/local/lib/python2.7/site-packages/numpy/testing/utils.py", line 70, in import_nose
    raise ImportError(msg)
ImportError: Need nose >= 1.0.0 for tests - see http://nose.readthedocs.io

"free(): invalid pointer" after using "pymesh.form_mesh"

I stumbled upon the following error while using pymesh:

*** Error in `python': free(): invalid pointer: 0x81d73400 ***

The full crash log is here: pymesh_free_error.txt

The minimal example for triggering this problem is the following (tested with python3):

import numpy
import pymesh


if __name__ == "__main__":
    vertices = [(0, 0, 0), (0, 1, 0), (0, 0, 1)]
    facets = [(0, 1, 2)]
    vertices_array = numpy.ndarray((len(vertices), 3), buffer=numpy.array(vertices), dtype=numpy.float32)
    facets_array = numpy.ndarray((len(facets), 3), buffer=numpy.array(facets), dtype=numpy.uint32)
    mesh = pymesh.form_mesh(vertices_array, facets_array)

The same happens when using complete meshs (more than one triangle - as above), as well.

Get list of undirected edges from pymesh?

Is there already a method to retrieve a list of (unique undirected) edges from a mesh?

mesh = pymesh.load_mesh('/usr/local/libigl/tutorial/shared/decimated-knight.off');

I tried

mesh.edges

but get an error.

HashMapTrait and sparsehash

Hi James,

This is a small issue, but currently preventing me from compiling PyMesh. In Misc/HashMapTrait.h, you should not include the sparsehash headers under the PyMesh namespace, as it is done currently (it leads to a compilation error on my machine with sparsehash 2.0.3 and gcc 6.1.1).

Installation problems on Mac

I had previously built PyMesh (about 6 months ago) but I ran into a problem trying to update to the current version. I think the problems may stem from the fact that when I run setup.py build it builds against my Mac python not anaconda (which is the Python I would like it to build against).

Last time I hit this problem, I was able to manually change the *.dylib links, and it all worked. But this time I'm still having trouble with bad links.

Maybe this would simpler if I could get the setup.py build to build against Anaconda from the beginning. Any suggestions would be appreciated.

Orientation in Convex Hull

Hi James,

The your convex hull wrapper, you are reorienting the facets of the convex hull based on the center of the bouding box of the hull. However, this center is not always inside the convex hull. You can take instead the barycenter of the points on the convex hull, which is guaranteed to be inside the hull, as a reference point instead.

Possible to call Wire Mesh inflator from cpp rather than python?

It seems like the bulk of the wire mesh inflation code is actually C++ code. Is that correct?

If so is it possible to call this directly from C++ and skip the python/swig interface?

Ideally I'd like to pass Eigen::MatrixXd V vertices and Eigen::MatrixXi E edges (libigl-style).

Optional libraries are required: libIGL (PyIGL) and PyWires

The following files contain uncondiitional imports:

  • pymesh/matrixio.py: PyIGL
  • pymesh/cell_partition.py: PyIGL
  • pymesh/minkowski_sum.py: PyIGL
  • pymesh/init.py: from . import wires -> PyWires

The resulting ImportError can be triggered by import pymesh on a system without PyIGL or PyWires.

libIGL (PyIGL?) is listed as an optional library in README.md.
PyWires is not mentioned, yet.

Probably the list of dependencies needs an update?
Or maybe (better?) tolerate these missing python modules? Since both modules are not available via pip, they can prove a bit complicated to install.

RuntimeError: Boolean engine "igl" is not supported.

After installing when I run:
python -c "import pymesh; pymesh.test()"
I get errors saying that "Boolean engine "igl" is not supported."
I have inserted some of the error messages blow.
I have tried to check for igl and i get:

Unix@DESKTOP-CAS28DH:~/PyMesh/build$ grep -i libigl CMakeCache.txt
LIBIGL_INCLUDE_DIRS:PATH=/home/Unix/PyMesh/third_party/libigl/include
//Details about finding LIBIGL
FIND_PACKAGE_MESSAGE_DETAILS_LIBIGL:INTERNAL=[/home/Unix/PyMesh/third_party/libigl/include][v()]
//ADVANCED property for variable: LIBIGL_INCLUDE_DIRS
LIBIGL_INCLUDE_DIRS-ADVANCED:INTERNAL=1

======================================================================
ERROR: test_no_intersection (test_selfintersection.SelfIntersectionTest)

Traceback (most recent call last):
File "/home/Unix/.local/lib/python3.6/site-packages/pymesh2-0.1.14-py3.6-linux-x86_64.egg/pymesh/selfintersection.py", line 70, in detect_self_intersection
import PyCGAL
ModuleNotFoundError: No module named 'PyCGAL'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/home/Unix/.local/lib/python3.6/site-packages/pymesh2-0.1.14-py3.6-linux-x86_64.egg/pymesh/tests/test_selfintersection.py", line 55, in test_no_intersection
intersecting_faces = detect_self_intersection(mesh);
File "/home/Unix/.local/lib/python3.6/site-packages/pymesh2-0.1.14-py3.6-linux-x86_64.egg/pymesh/selfintersection.py", line 73, in detect_self_intersection
"Self intersection detection is not supported");
NotImplementedError: Self intersection detection is not supported

======================================================================
ERROR: test_diag_box (test_slice_Mesh.SliceMeshTest)

Traceback (most recent call last):
File "/home/Unix/.local/lib/python3.6/site-packages/pymesh2-0.1.14-py3.6-linux-x86_64.egg/pymesh/tests/test_slice_Mesh.py", line 33, in test_diag_box
slices = slice_mesh(mesh, [1, 1, 1], N);
File "/home/Unix/.local/lib/python3.6/site-packages/pymesh2-0.1.14-py3.6-linux-x86_64.egg/pymesh/slice_mesh.py", line 53, in slice_mesh
slabs = boolean(boxes, mesh, "intersection");
File "/home/Unix/.local/lib/python3.6/site-packages/pymesh2-0.1.14-py3.6-linux-x86_64.egg/pymesh/boolean.py", line 73, in boolean
engine = PyBoolean.BooleanEngine.create(engine);
RuntimeError: Boolean engine "igl" is not supported.

======================================================================
ERROR: test_cube (test_winding_number.WindingNumberTest)

Traceback (most recent call last):
File "/home/Unix/.local/lib/python3.6/site-packages/pymesh2-0.1.14-py3.6-linux-x86_64.egg/pymesh/tests/test_winding_number.py", line 21, in test_cube
winding_numbers = compute_winding_number(mesh, queries);
File "/home/Unix/.local/lib/python3.6/site-packages/pymesh2-0.1.14-py3.6-linux-x86_64.egg/pymesh/winding_number.py", line 10, in compute_winding_number
engine = PyWindingNumber.WindingNumberEngine.create(engine);
RuntimeError: Unknown winding number engine: igl


Ran 112 tests in 1.482s

FAILED (errors=48)

boolean operations on non-solid 3d meshes

What would be the best technique to apply boolean operations, let's say intersect two 3D planes?

I have been trying the boolean example but is simply says the surfaces at play are not orientable.

I have Important problem in using PyMesh

I'm using python 2.7 in windows by personal Reason.
Then I wanna use 'pymesh' library for some works.
but although the 'pymesh' module is already installed by using

python setup.py install

, the python show me this error message

Traceback (most recent call last):
File "", line 1, in
File "E:\ProgramData\Anaconda2\lib\site-packages\pymesh-0.1-py2.7.egg\pymesh_init_.py", line 18, in
from .Mesh import Mesh
File "E:\ProgramData\Anaconda2\lib\site-packages\pymesh-0.1-py2.7.egg\pymesh\Mesh.py", line 5, in
import PyMesh
importError: No module named PyMesh

and because I thought that the reason of this error is I didn't build 'pymesh', I entered this code in CMD

python setup.py build

but the prompt also show me error message

running build
Overriding default build process
error: [Error 2]

so ... in this case , how can i fix this simple problem
Plz help me ... T-T

  • I changed name of pymesh to PyMesh , then now it want be given PyMeshUtils

Conda package

I successfully installed PyMesh using the system Python 2.7. All tests work. However, when I attempt
to install PyMesh as a package within Anaconda I get the following error upon running the tests:

python -c "import pymesh; pymesh.test()"
Fatal Python error: PyThreadState_Get: no current thread

Any ideas on how to make this work?

Windows compatibility

Hi! First of all, awesome library. I wanted to ask if it is working correctly on windows. I downloaded it with pip install but when I use the method load_mesh, an error pops up telling me that it is not defined. When I checked the files in the instalation folder I feel like there are missing files. Do you know something about this?

Cheers

Compiling with Carve

Hi James,

I was just trying to compile PyMesh recently with the Carve library, but I'm getting some compilation issues. It's complaining with stuff like error: ‘meshset_t’ in ‘class carve::csg::CSG’ does not name a type. Which version of Carve are you using? The type meshset_t is never defined in the archive I can download from the Google Code archive (v1.4.0), but it is defined in this fork from Github. If you are using the latter, maybe you could update the documentation accordingly?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.