polycube
A Python Package for Generating Polycube Models
This package can be used to easily generate models of polycubes that are appropriate for 3D printing.
It generate code in the openscad format (i.e. .scad files).
These can be viewed and transformed using OpenSCAD, which is a free software for creating solid 3D CAD objects.
These files can then be converted directly to .stl files via either the OpenSCAD GUI or from the command line.
Installation
pip install polycube
Tutorial
The basic input to make a polycube is a list of triple indicating the coordinates of the cubes. The assumption is that the coordinates will be integers. The actual size is scaled up according to the size of the cubes.
from polycube import polycube
pc = polycube([[0,0,0], [0,0,1], [0,1,0], [1,0,0]])
You can output to the scad file.
scad_render_to_file(pc, 'filename.scad')
You can use the OpenSCAD commandline utility to convert this .scad file to a .stl file suitable for use with a 3D printing slicer.
openscad -o outfilename.stl infilename.scad
Metadata
Release files for polycube 0.0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| polycube-0.0.1.tar.gz | 3.2 kB | Without provenance | Details for polycube-0.0.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| polycube-0.0.1-py3-none-any.whl | Python 3 | none | any | Details for polycube-0.0.1-py3-none-any.whl |
Total release size: 6.9 kB
Release files / polycube-0.0.1.tar.gz
| Download URL | polycube-0.0.1.tar.gz |
|---|---|
| Size | 3.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f0ac3a8d80acf558b04909a1cf7dee3ed66987d8ee5dfa32aaf22a650d07efb9
|
|
BLAKE2b-256 checksum How to use checksums |
452c6c7ae2426686e0eabdb8e580ad6ae7787d14d71b032b86eed3b9da3bbdce
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.9.13
|
Release files / polycube-0.0.1-py3-none-any.whl
| Download URL | polycube-0.0.1-py3-none-any.whl |
|---|---|
| Size | 3.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
c0dd8199db0c2f65cabea4216b4b6d34e21a8ab2aa86769eca6e603ebc16f753
|
|
BLAKE2b-256 checksum How to use checksums |
4c3b1a77ed2d77ecf2366200ade80dc1951f4dd2e37b6cefff60fe4b2e3be8f9
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.9.13
|
Security for polycube 0.0.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.