Urban Solar Carver
Urban Solar Carver (USC) is a Python library for generating maximum buildable volumes that respect solar access, daylight, and thermal comfort constraints in urban environments. It uses GPU-accelerated voxel carving driven by climate data to produce 3D building envelopes ready for urban planning, design, and architectural applications.
Paper: USC is presented at ReSBE 2026 (ReShaping the Built Environment through Sustainability and Circularity), 20-23 October 2026, Thessaloniki, Greece. The paper is published open access in Springer's Lecture Notes in Civil Engineering, vol. 905: doi.org/10.1007/978-3-032-34930-9_70 (PDF).

How It Works
The user provides a maximum volume mesh (the theoretical buildable mass, e.g., a block extrusion from zoning boundaries), a set of test surfaces (planar faces whose solar or daylight access must be protected, such as facades, courtyards, or PV arrays), an EPW weather file for the site location, and a YAML configuration specifying the carving mode, analysis period, and thresholding parameters.
USC voxelizes the maximum volume, casts rays from the test surfaces toward the sky, and scores each voxel by how much it obstructs the environmental quantity of interest (solar radiation, daylight, sky view). A threshold is then applied to produce a binary carving mask, and the surviving voxels are reconstructed into a mesh: the maximum developable volume that satisfies the given constraints.
The pipeline has three stages: preprocessing (score computation), thresholding (binary mask), and exporting (mesh reconstruction). Each stage is independently re-runnable: change the threshold without recomputing scores, or swap export settings without re-thresholding.
The tool is scale-agnostic and works on any voxelizable geometry. Surface normals must face outward (toward the direction of carving). Test surfaces can be placed anywhere, including inside the maximum volume (e.g., to carve a courtyard or an interior void).
Carving Modes
| Mode | Description |
|---|---|
| tilted_plane | Cuts voxels above a fixed angle from each test surface, uniform or varying by orientation octant. Suitable for daylight access envelopes and quick regulatory checks. No weather data required. |
| time-based | Solar envelope: traces actual sun paths for specific dates and hours, carving any voxel that casts a shadow on protected surfaces during those times. |
| irradiance | Weights sky directions by cumulative solar energy over an analysis period (direct + diffuse, Perez all-weather model). |
| benefit | Like irradiance, but filtered by a heating-benefit criterion: only hours when the outdoor temperature is below the building's balance-point temperature minus a dead-band (balance_offset) contribute, so carving protects the sun of hours when solar gain reduces heating. Optionally consumes simulated weights from a built-in hourly building simulation (ISO 13790 5R1C) that captures thermal lag and mass state; see Simulated Weights. |
| daylight | Weights sky patches by CIE overcast luminance for diffuse daylight access. |
| radiative_cooling | Preserves sky-dome access for passive nighttime cooling, weighting sky patches with the Martin-Berdahl sky emissivity for a single night-time dew point (no weather file needed). Valid for horizontal surfaces only (experimental). |
Thresholding
After scoring, a threshold determines which voxels to carve and which to keep. The threshold controls the trade-off between solar protection and buildable volume:
| Strategy | Config | Recommended for |
|---|---|---|
| Carve fraction | threshold: carve_fractioncarve_fraction: 0.7 |
Design exploration. Directly controls how much obstruction to remove: 0.7 = aggressive (taller, slimmer volumes, more solar access), 0.3 = conservative (bulkier volumes, more floor area). Think of it as a solar protection slider. The share counts what carve_above removes; a slope limit (max_slope_deg, 75° by default) then turns cliffs and spires into ramps. |
| Head-tail breaks | threshold: headtail |
Heavy-tailed distributions. Biased toward removing only the worst obstructors, preserving more buildable volume when most voxels have low scores. |
| Manual | threshold: 0.35 |
Expert use. Carves all voxels with score above this value. Inspect the score histogram (diagnostics: true) first. |
The strategies above apply to the weighted modes (irradiance, benefit, daylight, radiative_cooling). The two binary modes have fixed semantics: tilted_plane has no threshold (voxels above the cut plane are always removed); time-based scores the shading a voxel causes in m²·h, shaded protected area times duration (threshold: 0 = remove any voxel that casts a shadow at any sampled moment, threshold: 5 = tolerate up to 5 m²·h; the sun is sampled every 5 minutes by default, see sun_steps_per_hour).
The decomposed pipeline is designed for threshold exploration: compute scores once (the expensive step), then re-run thresholding with different values instantly.
https://github.com/user-attachments/assets/7fb20820-bd24-4ccd-86f5-4f4f868b372a
Features
- GPU-accelerated ray tracing via NVIDIA Warp, with CPU fallback
- Simulated benefit weights: a built-in ISO 13790 (5R1C) hourly building simulation derives when a marginal joule of solar gain is actually useful (thermal lag, mass state, gain saturation), independently implemented and validated against ETH's RC_BuildingSimulator
- Browser UI (
usc ui): a local app with a 3D view where you add the inputs, choose a mode, run the analysis, adjust how much to carve against a score histogram, build the envelope and building massing, and download the files; it runs on your computer and uses the same engine - Grasshopper plugin for Rhino 3D with 27 components and persistent GPU daemon
- 3-stage pipeline (preprocessing, thresholding, exporting), each re-runnable independently
- YAML configuration with CLI overrides (
-o voxel_size=0.5 -o mode=irradiance) and mode-specific templates - Smooth or cubic meshes: marching cubes + Taubin smoothing, or axis-aligned voxels
- Floor-plate massing: stacked floor plates (5 m ground floor, 3 m floors) that follow the footprint and step back where the envelope requires, with floor areas per floor
Installation
Python (API, CLI, Jupyter)
git clone https://github.com/avarth/UrbanSolarCarver.git
cd UrbanSolarCarver
python setup_env.py
Auto-detects your GPU and installs the correct PyTorch + CUDA wheels. Use --cpu for CPU-only mode. The browser UI is installed with it; --no-ui leaves it out.
Tests: python -m pytest -m "not slow" -n 8 runs the everyday set in under a minute; docs/testing.md gives the runs for commits and merges.
Grasshopper (Rhino 3D)
- Complete the Python installation above.
- Copy all
.ghuserfiles fromgrasshopper/USC_GHplugin/into your Grasshopper User Objects folder. - On the Grasshopper canvas, use the USC_Session component to start the GPU daemon.

Usage
Browser UI
Double-click start-urbansolarcarver.bat (Windows) or run ./start-urbansolarcarver.sh (Linux, macOS) in the repository folder. On a fresh clone it installs everything with setup_env.py first, then opens the interface in your browser, on this computer only. From a terminal with the environment active, usc ui does the same. See Browser UI for the steps, where projects are kept and how it behaves without a CUDA-enabled GPU.
Python and CLI
from urbansolarcarver import load_config, run_pipeline
cfg = load_config("config.yaml")
result = run_pipeline(cfg, out_dir="./outputs")
Run stages independently to change threshold parameters without recomputing scores:
from urbansolarcarver import load_config, preprocessing, thresholding, exporting
from pathlib import Path
cfg = load_config("config.yaml")
pre = preprocessing(cfg, Path("out/pre"))
thr = thresholding(pre, cfg, Path("out/thr"))
exp = exporting(thr, cfg, Path("out/exp"))
CLI:
$ urbansolarcarver preprocessing -c config.yaml
$ urbansolarcarver thresholding -c config.yaml -f out/pre/manifest.json
$ urbansolarcarver exporting -c config.yaml -f out/thr/manifest.json
# Override any config parameter on the fly
$ urbansolarcarver preprocessing -c config.yaml -o voxel_size=0.5 -o mode=irradiance
# View all available parameters
$ urbansolarcarver schema
Mode-specific config templates are in configs/. See Configuration for the full parameter reference.
Documentation
avarth.github.io/UrbanSolarCarver: installation options, configuration reference, mode theory, Grasshopper setup, API docs.
Tutorial notebooks are in examples/.

Research Context
USC builds on earlier solar form-finding methods (Knowles' solar envelope, iso-solar surfaces, solar ordinance methods) and combines them with climate-based sky weighting and GPU voxel ray tracing in one tool.
Citation
If you use USC, please cite the paper:
Vartholomaios, A. (2026). Urban Solar Carver: A GPU-Accelerated Framework for Solar-Driven Urban Form Finding. In: Bragança, L., Tsikaloudaki, K., Giarma, C., Mateus, R., Kontoleon, K., Askar, R., Salles, A. & Cervantes, C. (Eds.), ReShaping the Built Environment through Sustainability and Circularity: Proceedings of ReSBE 2026 International Conference, Volume 1. Lecture Notes in Civil Engineering, vol. 905. Springer, pp. 600-607. https://doi.org/10.1007/978-3-032-34930-9_70
@inproceedings{vartholomaios2026usc,
author = {Vartholomaios, Aristotelis},
title = {Urban Solar Carver: A GPU-Accelerated Framework for Solar-Driven Urban Form Finding},
booktitle = {ReShaping the Built Environment through Sustainability and Circularity: Proceedings of ReSBE 2026 International Conference, Volume 1},
editor = {Bragan{\c{c}}a, Lu{\'i}s and Tsikaloudaki, Katerina and Giarma, Christina and Mateus, Ricardo and Kontoleon, Karolos and Askar, Rand and Salles, Adriana and Cervantes, Camila},
series = {Lecture Notes in Civil Engineering},
volume = {905},
pages = {600--607},
publisher = {Springer},
year = {2026},
doi = {10.1007/978-3-032-34930-9_70}
}
The paper is open access. A copy is in docs/publications/; it is licensed under CC BY-NC-ND 4.0, not under the AGPL-3.0 that covers the code. To cite the software itself, use the Zenodo DOI. See CITATION.cff for machine-readable metadata.
Built With
PyTorch · NVIDIA Warp · Ladybug Tools · Trimesh · Shapely · scikit-image
AI-Assisted Development
This tool was developed with AI assistance (OpenAI ChatGPT 4.1 and Anthropic Claude Opus 4.6 / Sonnet 4.6). The author designed the architecture and planned all features; AI tools were used to draft code diffs, code cleanup and implementation. All AI-generated code was reviewed by the author before inclusion. The author takes full responsibility for the correctness, design, and scientific validity of the code.
The scientific methodology, analysis modes, and validation are entirely the author's work. AI tools were not used in the formulation of the research approach or interpretation of results.
License
AGPL-3.0. This software is provided as-is with no warranty. See LICENSE for details. For commercial licensing inquiries, contact the author.
Author
Aristotelis Vartholomaios, Department of Planning and Regional Development, University of Thessaly, Volos, Greece. Contact: avartholomaios@uth.gr