Skip to content

Instantly share code, notes, and snippets.

View vojtatom's full-sized avatar

Vojta Tomas vojtatom

View GitHub Profile
@Maxxen
Maxxen / app.py
Last active September 29, 2025 14:29
DuckDB Vector Tile Serve w/ Flask + MapLibre
import duckdb
import flask
# Initialize Flask app
app = flask.Flask(__name__)
# Setup a global DuckDB connection with spatial extension loaded
# Connect to a persistent database file with the geometry data
config = {"allow_unsigned_extensions": "true"}
con = duckdb.connect("tiles.db", True, config)
@jpswinski
jpswinski / geoparquet.cpp
Last active September 29, 2025 13:46
Minimal example C++ code to write a GeoParquet file using Apache Arrow
/*
* File: geoparquet.cpp
*
* Purpose: A minimal example to build a GeoParquet file using Apache Arrow.
*
* Prerequisites: The Apache Arrow library is needed and can be installed as follows
* $ git clone https://github.com/apache/arrow.git
* $ cd arrow/cpp
* $ mkdir build
* $ cd build