Skip to content

A short, simple, and sweet ML script that triangulates images by use of Delunay Triangulation.

License

Notifications You must be signed in to change notification settings

RandomGamingDev/MLDelunayImageTriangulator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MLDelunayImageTriangulator

A short, simple, and sweet ML script that triangulates images by use of Delunay Triangulation.

This is a python script that converts an image into a series of triangles

How to use the script:
Start by entering the settings that you want in settings.txt
The 1st line is for the # of instances
The 2nd line is for the # of triangles per instance
The 3rd line is for the # of iterations

Then after confirming the settings enter the filepath to the image relative to the executable or as a direct filepath

Then confirm that that's the image that you want

Wait for the final result in output.jpeg!

This is for Python 3.9 and requires the following dependencies:
pillow,
numpy,
scipy,
matplotlib

It takes a while for the image to generate but you can watch it learn not only in output.jpeg but also on the graph.

This application isn't multithreaded.

Hope you enjoy!

If output.jpeg isn't generating try changing the image type.