Code Monkey home page Code Monkey logo

Comments (13)

nschloe avatar nschloe commented on May 24, 2024

You need http://eigen.tuxfamily.org/index.php?title=Main_Page.

On Debian/Ubuntu and derivates, that's as easy as

sudo apt install libeigen3-dev

from pygalmesh.

steersteer avatar steersteer commented on May 24, 2024

Sorry I should have said I'm on a windows machine

from pygalmesh.

steersteer avatar steersteer commented on May 24, 2024

I changed the setup.py line "os.environ.get("EIGEN_INCLUDE_DIR", "\Eigen3")" so I get past that now.
I'm now getting "src/generate.cpp(5): fatal error C1083: Cannot open include file: 'CGAL/Exact_predicates_inexact_constructions_kernel.h': No such file or directory"

As far as I know I have the latest CGAL installed

from pygalmesh.

nschloe avatar nschloe commented on May 24, 2024

These kind of linking errors are nearly impossible to debug without machine access. You'll have to dig around yourself I'm afraid.

from pygalmesh.

flothesof avatar flothesof commented on May 24, 2024

Hi,
I've got a little further down the process trying to install pygalmesh on a Windows machine.

I've done the following:

  • install eigen and cgal using conda install -c conda-forge eigen cgal
  • added an environment variable 'EIGEN_INCLUDE_DIR' pointing to 'C:\Anaconda3\envs\py37\Library\include\eigen3'

Then doing pip install pygalmesh I'm now stuck on a compile error, which is:

C:\Anaconda3\envs\py37\Library\include\CGAL/Mesh_criteria_3.h(116): error C2664: 'CGAL::Mesh_cell_criteria_3<Tr,CGAL::Mesh_3::Cell_criteria_visitor_with_features<Tr>>::Mesh_cell_criteria_3(const CGAL::Mesh_cell_criteria_3<Tr,CGAL::Mesh_3::Cell_criteria_visitor_with_features<Tr>> &)'ÿ: impossible de convertir l'argument 2 de 'Arg' en 'const double &'
          with
          [
              Tr=pygalmesh::Tr
          ]
          and
          [
              Arg=const pygalmesh::generate_with_sizing_field::<lambda_db8e64dde8d1efacb3178dd659100057>
          ]
  C:\Anaconda3\envs\py37\Library\include\CGAL/Mesh_criteria_3.h(121): note: Raisonÿ: impossible de convertir de 'Arg' en 'const double'
          with
          [
              Arg=const pygalmesh::generate_with_sizing_field::<lambda_db8e64dde8d1efacb3178dd659100057>
          ]

@nschloe Would you be so kind and translate the meaning of that error message for me?

Thank you

Florian

from pygalmesh.

nschloe avatar nschloe commented on May 24, 2024

Looks like an outdated CGAL version.

from pygalmesh.

flothesof avatar flothesof commented on May 24, 2024

Thanks for your quick reply. Indeed, the CGAL version on conda-forge right now is 4.14 (and they're not quite ready to move to CGAL5, see conda-forge/cgal-feedstock#54). So using conda-forge will likely not work until it provides the latest CGAL version... :(

from pygalmesh.

nschloe avatar nschloe commented on May 24, 2024

@flothesof CGAL seems to be updated on conda-forge now. Any interest in writing a recipe for pygalmesh? Would certainly help a number of people.

from pygalmesh.

flothesof avatar flothesof commented on May 24, 2024

Thanks for the suggestion. I've just tried the following on my Mac (not Windows) and it installed pygalmesh successfully:

conda install -c conda-forge eigen cgal
export EIGEN_INCLUDE_DIR=/Users/kappamaki/opt/miniconda3/envs/py37/include/eigen3
git clone https://github.com/nschloe/pygalmesh.git
cd pygalmesh
pip intall -e .

When I run pytest after that, I get:

============================================================================= short test summary info =============================================================================
FAILED test/test_inr.py::test_inr - RuntimeError: Caught an unknown exception!
FAILED test/test_remesh_surface.py::test_inr - meshio._exceptions.ReadError
FAILED test/test_volume_from_surface.py::test_volume_from_surface -   File "<string>", line None
========================================================================== 3 failed, 26 passed in 26.44s ==========================================================================

This may or may not work on Windows, but it seems a good basis for trying to make a recipe on conda-forge. I'll give it a shot (I've never done this before).

from pygalmesh.

nschloe avatar nschloe commented on May 24, 2024

I'm also playing around with it rn. #81

from pygalmesh.

montallban avatar montallban commented on May 24, 2024

I am on a windows computer. I followed your directions, @flothesof , and got past the Eigen\Dense issue. Now I am hung up on a new one. It seems connected to either my C++ compiler or to CGAL, but I thought CGAL was installed via conda-forge so I don't really know what to do. Any ideas?

Error:

    C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.22.27905\bin\HostX86\x64\cl.exe /c /nologo /Ox /W3 /GL /DNDEBUG /MD -I\Users\User\usr\include\eigen-3.3.7\ -IC:\Users\User\AppData\Local\Temp\pip-build-env-cva5itsm\normal\Lib\site-packages\pybind11\include -IC:\Users\User\AppData\Local\Temp\pip-build-env-cva5itsm\normal\Lib\site-packages\pybind11\include -IC:\Users\User\Anaconda3\include -IC:\Users\User\Anaconda3\include "-IC:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.22.27905\ATLMFC\include" "-IC:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.22.27905\include" "-IC:\Program Files (x86)\Windows Kits\NETFXSDK\4.7.2\include\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\shared" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\winrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\cppwinrt" /EHsc /Tpsrc/generate.cpp /Fobuild\temp.win-amd64-3.7\Release\src/generate.obj -std=c++14
    cl : Command line warning D9002 : ignoring unknown option '-std=c++14'
    generate.cpp
    src/generate.cpp(5): fatal error C1083: Cannot open include file: 'CGAL/Exact_predicates_inexact_constructions_kernel.h': No such file or directory
    error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\Community\\VC\\Tools\\MSVC\\14.22.27905\\bin\\HostX86\\x64\\cl.exe' failed with exit status 2
    ----------------------------------------
ERROR: Command errored out with exit status 1: 'C:\Users\User\Anaconda3\python.exe' -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\User\\usr\\include\\pygalmesh\\setup.py'"'"'; __file__='"'"'C:\\Users\\User\\usr\\include\\pygalmesh\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' develop --no-deps Check the logs for full command output.

from pygalmesh.

nschloe avatar nschloe commented on May 24, 2024

@montallban This is a different issue that OP's. Looks like you don't have recent enough version of CGAL installed. Please open a new issue if you need more instructions. https://www.urbandictionary.com/define.php?term=Thread%20Hijacking

from pygalmesh.

nschloe avatar nschloe commented on May 24, 2024

Let me point everyone towards https://anaconda.org/conda-forge/pygalmesh/. This should make installation on Windows a lot easier.

from pygalmesh.

Related Issues (20)

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.