ModuleNotFoundError: No module named 'triangle'
See original GitHub issueHello,
today I installed trimesh on a Windows x64 using:
conda install -c conda-forge trimesh
With:
trimesh.__version__
I get: 3.6.20.
I wanted to extrude a shapely polygon using the following:
import trimesh
my_mesh = trimesh.creation.extrude_polygon(my_poly, 12, transform=None, triangle_args=None)
This results in the following error:
ModuleNotFoundError: No module named 'triangle'
I thought that with using conda all dependencies would be installed.
The exact location where the error is occuring is:
File "C:\Anaconda3\envs\my_env\lib\site-packages\trimesh\creation.py", line 187, in extrude_polygon
polygon, triangle_args=triangle_args, **kwargs)
File "C:\Anaconda3\envs\my_env\lib\site-packages\trimesh\creation.py", line 435, in triangulate_polygon
from triangle import triangulate
Issue Analytics
- State:
- Created 3 years ago
- Comments:6 (3 by maintainers)
Top Results From Across the Web
No module named triangle · Issue #298 - GitHub
from pylayers.simul.link import * after show me this message "No module named triangle" I installed the triangle through the "conda install ...
Read more >How to fix "ModuleNotFoundError: No module named 'triangle'"
You must first install the package before you can use it in your code. Run the following command to install the package and...
Read more >ModuleNotFoundError: No module named 'triangle.py'
Hi, My Python program is throwing following error: ModuleNotFoundError: No module named 'triangle.py' How to remove the Module.
Read more >No module named 'meshpy._triangle' - python - Stack Overflow
Likely you have created file named meshpy within your python package, which leads to the module shadowing, renaming your file shall fix the ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hey, looks like you’re missing the soft dependency triangle, try running: pip install triangle
On Fri, Jul 24, 2020 at 9:33 AM Fernando Gomes notifications@github.com wrote:
Hey, yeah I don’t know how conda handles it, I tested with
pip
in a venv which also works pretty well.triangle
is on conda-forge which may be in your env but if not you would need to install it withconda install -c conda-forge triangle
Though
triangle
unfortunately was removed from requires for license issues in this pr. The logic if you calltrimesh.creation.triangulate_polygon(..., engine='triangle')
is still there because it requires opt-in and independently installing triangle.Defaults were switched to
mapbox-earcut
: https://pypi.org/project/mapbox-earcut/ which you can get through pip (pip install mapbox-earcut
) or conda (conda install -c conda-forge mapbox_earcut
).