Notgnoshi / generative

Generative art. A suite of composable tools to generate, transform and visualize WKT geometries

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Refactor Rust/C++ tools into Rust/C++ libraries wrapped with PyO3 and pybind11

Notgnoshi opened this issue · comments

This will

  • Increase consistency from the user perspective

  • Provide experience with language bindings (needed for work)

  • Reduce (or maybe increase?) friction for developing new tools

  • Figure out how to build C++ library with setup.py

  • Figure out how to build Rust library with setup.py

  • Wrap Rust DLA library in Python.

    • Refactor Rust tool into a library
    • Determine if it should use Rust or Python tests
    • Determine what the interface is (geometries, collapsed WKT/TGF text, arrays, or WKT/TGF streams)
    • Rewrite DLA tool in Python using the wrapped library
    • Remove the existing Rust tool
    • Logging: https://pyo3.rs/v0.14.2/ecosystem/logging.html
  • Wrap geom2graph library in Python

    • Refactor tool into a library
    • Determine if it should use C++ or Python tests
    • Determine what the interface is (geometries, collapsed WKT/TGF text, arrays, or WKT/TGF streams)
    • Rewrite tool in Python using the wrapped library
    • Remove the existing C++ tool
    • Logging: pybind/pybind11#3108
  • Add build/install instructions to README

Because this is so tedious, and it's motivation is "hide the rust and c++ grossnesses", I've been convinced to close this out. It hasn't been exciting work, and I'd really rather just move on.