Skip to main content

lsdo_geo

Documentation Status Tests Python Version License

lsdo_geo is a Python library for geometry representation, implicit deformational parameterization, and analytic adjoint sensitivity analysis tailored for gradient-based Multidisciplinary Design Optimization (MDO).

Developed by the Large-Scale Design Optimization (LSDO) Lab at the University of California, San Diego.


Key Features

  • Geometry-Centric MDO: Serves as a single, consistent geometric "source of truth", generating and updating discipline-specific meshes (CFD, FEA, acoustics) without manual re-meshing or geometric inconsistency.
  • Implicit Parameterization Framework: Formulates geometry parameterization as an inner constrained optimization problem, solving the first-order Karush-Kuhn-Tucker (KKT) system with an exact Newton solver.
  • Hierarchical Free-Form Deformation (FFD): Supports trivariate spline volume lattices with sectional deformation modes—twist, sweep, dihedral, spanwise stretching, and chord taper.
  • Analytic Adjoint Sensitivities: Provides exact implicit derivatives $\frac{d\mathbf{x}}{d\mathbf{x}_g}$ through the converged KKT state, seamlessly propagating gradients across the CSDL computational graph.
  • CAD & Mesh Interoperability: Direct import, fitting, and export across OpenVSP (.vsp3), IGES (.iges), STEP (.stp), and surface/volume meshes (.msh, .stl).

Architecture Overview

Subpackage Key Classes Description
lsdo_geo.core.geometry Geometry, Mesh Central multi-component geometric model, CAD imports, rigid transformations, and discipline mesh projections.
lsdo_geo.core.parameterization ParameterizationSolver, GeometricVariables, FFDBlock, SectionalParameterization Trivariate FFD lattices, sectional mode definitions, and exact Newton KKT solver.
lsdo_geo.optimization Optimization, NewtonOptimizer Connects geometric states and constraints into CSDL graph models for analytic adjoint sensitivity analysis.

Quickstart

import numpy as np
import csdl_alpha as csdl
import lsdo_geo as lg

# 1. Initialize CSDL graph recorder
recorder = csdl.Recorder(inline=True)
recorder.start()

# 2. Define or import geometry
geometry = lg.import_geometry("path/to/wing.stp")

# 3. Create a Free-Form Deformation (FFD) block around the geometry
ffd_block = lg.construct_ffd_block_around_entities(
    geometry,
    num_control_points=(4, 4, 2),
)

# 4. Apply geometric transformations (rotation, translation)
rotation_origin = np.array([0.0, 0.0, 0.0])
rotation_axis = np.array([0.0, 0.0, 1.0])
rotated_points = lg.rotate(
    geometry.coefficients,
    rotation_origin=rotation_origin,
    axis_vector=rotation_axis,
    angles=15.0,
    units="degrees",
)

Installation

Prerequisites & Installation

lsdo_geo relies on CSDL_alpha and lsdo_function_spaces:

# 1. Install dependencies
pip install jax
pip install git+https://github.com/LSDOlab/CSDL_alpha.git@dev_andrew
pip install git+https://github.com/LSDOlab/lsdo_function_spaces.git

# 2. Install lsdo_geo (User)
pip install lsdo_geo
# Or install development version directly from GitHub:
pip install git+https://github.com/LSDOlab/lsdo_geo.git

For Developers

Clone the repository and install in editable mode with testing and documentation extras:

git clone https://github.com/LSDOlab/lsdo_geo.git
cd lsdo_geo
pip install jax
pip install git+https://github.com/LSDOlab/CSDL_alpha.git@dev_andrew
pip install git+https://github.com/LSDOlab/lsdo_function_spaces.git
pip install -e ".[test,docs]"

Testing

Run the test suite using pytest:

pytest

To run fast unit tests only:

pytest -m "not slow"

Documentation

Full documentation, theoretical background, tutorials, and API reference are hosted on Read the Docs: 👉 lsdo-geo.readthedocs.io

To build the documentation locally:

sphinx-build -b html docs docs/_build/html

Citation

If you use lsdo_geo in your work or research, please cite:

@inproceedings{fletcher2026implicit,
  title     = {Implicit Nonlinear Geometry Parameterization for Multidisciplinary Design Optimization},
  author    = {Fletcher, Andrew H. and Hwang, John T.},
  booktitle = {Proceedings of the ASME 2026 International Design Engineering Technical Conferences and Computers and Information in Engineering Conference (IDETC/CIE2026)},
  number    = {DETC2026-192508},
  year      = {2026},
  address   = {Houston, TX}
}

License

lsdo_geo is distributed under the terms of the Apache License, Version 2.0. See LICENSE.txt for details.

Metadata

Release files for lsdo-geo 1.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for lsdo-geo 1.2.0
File Size Uploaded Provenance Actions
lsdo_geo-1.2.0.tar.gz 28.5 MB With provenance Details for lsdo_geo-1.2.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for lsdo-geo 1.2.0
File Interpreter ABI Platform Actions
lsdo_geo-1.2.0-py3-none-any.whl Python 3 none any Details for lsdo_geo-1.2.0-py3-none-any.whl

Total release size: 28.6 MB

Release files / lsdo_geo-1.2.0.tar.gz

Download URL lsdo_geo-1.2.0.tar.gz
Size 28.5 MB
Tags Source
SHA-256 checksum
How to use checksums
eb6c9640a0ae339724d4afa31eb30926f1f33df14f41cee05f381c909d3224f0
BLAKE2b-256 checksum
How to use checksums
18f5e9e82437a113a852cad8993b27037912a16854896433450f208bcc7f07ce
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 3, 2026.

Transparency log

Release files / lsdo_geo-1.2.0-py3-none-any.whl

Download URL lsdo_geo-1.2.0-py3-none-any.whl
Size 64.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
9b7f55f03c20c06c55e3cd17312c124f62020879aab8f6233797e628a07f3fc1
BLAKE2b-256 checksum
How to use checksums
cd0229ec778f2b8a7f88b14d77665f462ac2e5eb1ed3345c073568388a67e79e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 3, 2026.

Transparency log

Security for lsdo-geo 1.2.0

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.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for lsdo_geo-1.2.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 3, 2026.

Transparency log

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.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page