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.8.2.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.8.2-py3-none-any.whl (14.2 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: nestle-mynest-2.8.2.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.8.2.tar.gz
Algorithm Hash digest
SHA256 bedecf30eefec248a42ed20546111701b3aca7f3fcbe5963fc9cf3ce89d5a99f
MD5 67467a6b7c63638211a127eb043792e8
BLAKE2b-256 40809783e9a1ded60573c0b1e70730592b23c439cccb123eb5fd9ad217ed7a6a

See more details on using hashes here.

File details

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

File metadata

  • Download URL: nestle_mynest-2.8.2-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.8.2-py3-none-any.whl
Algorithm Hash digest
SHA256 983c25cd8961d7ce6547303e3809d15b739150790b38d09be54d42e503d38967
MD5 24a2e5a1f7fa76004379ee3c2922eb73
BLAKE2b-256 b9ca633edd6381efefcdd2cdd88768d711ba12905838fa2b8ee7ae5808f9fe6d

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