Skip to content

Improve startup performance: drop lilv + requests, defer pedalboard hydration#207

Open
sastraxi wants to merge 7 commits into
mainfrom
perf/startup-performance
Open

Improve startup performance: drop lilv + requests, defer pedalboard hydration#207
sastraxi wants to merge 7 commits into
mainfrom
perf/startup-performance

Conversation

@sastraxi

Copy link
Copy Markdown
Collaborator

The pistomp core (v2; rpi 3a+) was taking almost 7 seconds to load.

  • Pedalboard parsed every board's .ttl through lilv at construction — a World per Pedalboard, bundle load, plugin scan — to fill in plugins and connections we only read once a board is actually selected. Boards now construct bare and carry a hydrated flag; the plugin/connection data is pulled from mod-ui's HTTP API on demand.

  • This is actually kind of big: we don't actually need lilv, because we can get everything we need from data we're already loading from MOD-UI.

  • We also move away from requests to save 1.3s of startup time(!) on this device. pistomp/httpclient.py implements the minimum viable amount of the requests API via urllib instead.

  • Some smaller ones: the NAM panel scanned the model wav to derive gain; hardcode it instead. And the tuner imports at first use rather than at handler construction.

At the end of this it's down to around ~3.5-4s.

@sastraxi
sastraxi requested a review from rreichenbach July 14, 2026 04:21

@rreichenbach rreichenbach left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pretty cool that we can leave all the lilv to MOD.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants