Skip to main content

Trial library for nesting and laser cutting

Project description

Modules for Laser Cutting

This is a repository containing certain modules required for laser cutting. The code is completely written in python.
Following are the modules currently present:
1. Formation of Shapes
2. Detection of shapes from a .DXF and .svg file or any image(.png, .jpeg or .tiff) file format
3. Nesting of Shapes
Following are the modules to be added:
4. Path-planning & the options of lead-in and lead-out
5. Conversion of machine code

Brief:

1. Formation of Shapes:

i) The dimensions of shapes are to be entered as the input in the code.
ii) The code forms the shape by doing simple mathematical calculations and gives the output in the form of coordinates.

2. Processing of .DXF file:

i) Shapes from the drawing file will be extracted by detecting the individual entities like Polyline, Line, Arc, Circle.
ii) Coordinates are extracted by geometrical calculation on the shapes.

3. Detection of shapes from a .svg file or any image(.png, jpeg or tiff) file format

i) An image is to be provided as the input to let the code detect the shapes. If the file is in ".svg" format, it is first converted to ".png" format. The edges of the shapes are detected using canny operator.
ii) After the detection of shapes from an image, the coordinates of the detected shapes are fetched.

4. Nesting of Shapes:

i) The shapes get automatically nested once we provide the coordinates of the shapes which are entered. More about the nesting is available below in the form of a flowchart.
ii) Nesting is a combination of the following approaches:
a) Bottom-Left approach b) DJD Heuristic approach

These are the images of nested shapes from the Drawing file(.DXF) as file source:

Here are the images of nested shapes from the image as file source:

These are the images depicting contour detection in the cases of images given as inputs:

Flowchart for the modules created presently:

1) Flow chart for extraction of coordinates and/or creation of shapes:

2) Flow chart for nesting of the extracted coordinates from image as file source:

3) Flow Chart for Contour Detection from an image to extracting shape coordinates:

NOTE: Following packages need to be installed for proper usage of this nesting module: 1. ezDXF 2. cv2 2. matplotlib 4.svglib 5.reportlab 6.math 7.time

To-do list:

  1. Optimisation of nesting by adding more functions for distances
  2. Creating the library for the nesting code

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

nestle-mynest-2.4.1.tar.gz (14.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

nestle_mynest-2.4.1-py3-none-any.whl (14.2 kB view details)

Uploaded Python 3

File details

Details for the file nestle-mynest-2.4.1.tar.gz.

File metadata

  • Download URL: nestle-mynest-2.4.1.tar.gz
  • Upload date:
  • Size: 14.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.2.0 requests-toolbelt/0.9.1 tqdm/4.48.0 CPython/3.8.0

File hashes

Hashes for nestle-mynest-2.4.1.tar.gz
Algorithm Hash digest
SHA256 f99f4db9a7574c9710e3585883261180e6afcdb67b156573369550a7e7f8ba1f
MD5 a6128019ed3220c657684c20021c13f2
BLAKE2b-256 d846689e112f18414a20d594708d89f0be7a9494e17e81ccf5951008e7ac7499

See more details on using hashes here.

File details

Details for the file nestle_mynest-2.4.1-py3-none-any.whl.

File metadata

  • Download URL: nestle_mynest-2.4.1-py3-none-any.whl
  • Upload date:
  • Size: 14.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.2.0 requests-toolbelt/0.9.1 tqdm/4.48.0 CPython/3.8.0

File hashes

Hashes for nestle_mynest-2.4.1-py3-none-any.whl
Algorithm Hash digest
SHA256 a372fd233b27b13d5240e9fe3b18bb55788ef771bcb7fcd241d0c4a5098761de
MD5 f252ea5b1b941183512059a8f7e43cd6
BLAKE2b-256 b9be978ae78ffbe05d3849fc9fbeca8cd2b849e17140b8f34df976c90ce7f000

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page