jannessm / quadric-mesh-simplification

Fast python implementation of the quadric mesh simplification algorithm from http://mgarland.org/files/papers/quadrics.pdf
MIT License
105 stars 10 forks source link

Issue with 3.10 wheels #14

Open friggog opened 2 years ago

friggog commented 2 years ago

Hi @jannessm - unfortunately seems like there is some issue with python 3.10 wheels. No windows wheels exist at https://pypi.org/project/quad-mesh-simplify/1.1.5/#files and installing on linux ends up with error ModuleNotFoundError: No module named 'quad_mesh_simplify'. Looking in the wheel it seems like the so file is named incorrectly?

image

jannessm commented 2 years ago

please check again! Sorry for the long time it took me to help you out!

TeresaRoberts commented 2 years ago

Hi, I have a similar issue on windows 10, python 3.9. This got installed as a requirement for another package, and pip seems to think its there. When I go to the site-packages folder I can see the folder quad_mesh_simplify-1.1.5.dist-info but no quad_mesh_simplify folder, which I'd expect? And when I try to run code that imports it I get the message that it can't be found. I've tried re-installing it, and a different environment, but with the same result.

alexge233 commented 2 years ago

Same issue here, Running Python 3.9.11 and pip 22.2. I install pip install quad_mesh_simplify but when I try to import it, I get no module named 'quad_mesh_simplify'.

alexge233 commented 2 years ago

As a quick workaround for anyone who comes across this problem (I'm using VoxelFuse which depends on quad_mesh_simplify you can download the repo, build it and then copy the build folder into your virtual environment. I tried installing by pointing pip to it, but it still failed. I suspect it's an export that's broken.

StevenLiuWen commented 2 years ago

I meet the same issue, no module named 'quad_mesh_simplify, Centos 7.2 with Anaconda Python 3.9.

I have tried the two ways to install this module, pip install quad_mesh_simplify and git clone then installs at local. Both of them encounter the same issue.

alexander-hagg commented 2 years ago

As a quick workaround for anyone who comes across this problem (I'm using VoxelFuse which depends on quad_mesh_simplify you can download the repo, build it and then copy the build folder into your virtual environment. I tried installing by pointing pip to it, but it still failed. I suspect it's an export that's broken.

This works, but be sure to copy both the entire folder quad_mesh_simplify (named as such) into the virtual environment, as well as the built simplify.cpython-38-x86_64-linux-gnu.so file.

YiLin32Wang commented 2 years ago

As a quick workaround for anyone who comes across this problem (I'm using VoxelFuse which depends on quad_mesh_simplify you can download the repo, build it and then copy the build folder into your virtual environment. I tried installing by pointing pip to it, but it still failed. I suspect it's an export that's broken.

This works, but be sure to copy both the entire folder quad_mesh_simplify (named as such) into the virtual environment, as well as the built simplify.cpython-38-x86_64-linux-gnu.so file.

Hi, thanks for the solution. I'm currently having the same problem here. As I tried this solution, things still can't work. I have tried copying the "quad_mesh_simplify" folder & the built simplify.cpython-38-x86_64-linux-gnu.so to the root folder of my virtual environment as well as the subfolder bin, but neither works as said. Could you help me double check if I have ever mistaken some steps in between? or have I mistaken the required destination folder ?

alexander-hagg commented 2 years ago

You might need to use a relative import. Try importing it while being in the actual module directory and there it probably should work. So relative imports it is (or add the folder to the python path)

alexander-hagg commented 2 years ago

Anyway I suspect there is something basic missing from the pip install but I can't see it

alexander-hagg commented 1 year ago

You might need to use a relative import. Try importing it while being in the actual module directory and there it probably should work. So relative imports it is (or add the folder to the python path)

I did the following before using simplify (quadric was cloned and compiled in util/quadric):

import sys sys.path.insert(0,'util/quadric')

andy-5 commented 1 year ago

For me it works out of the box if I change the import to

from simplify import simplify_mesh

This seems to be caused by a wrong package name in setup.py, which I think would be fixed by #17 .

hernot commented 1 year ago

Seems as if README examples are outdated concerning how to import.