<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>onnxruntime · Paolo Stivanin</title><link>https://paolostivanin.github.io/tags/onnxruntime/</link><description>Security QA engineer. FIPS, Common Criteria, openQA, and flaky tests.</description><generator>Hugo</generator><language>en-US</language><lastBuildDate>Fri, 04 Dec 2026 14:00:00 +0100</lastBuildDate><atom:link href="https://paolostivanin.github.io/tags/onnxruntime/index.xml" rel="self" type="application/rss+xml"/><item><title>WebGPU for ONNX Runtime on openSUSE, and a photo editor that uses it</title><link>https://paolostivanin.github.io/opensource/onnxruntime-webgpu-and-greycard/</link><pubDate>Fri, 04 Dec 2026 14:00:00 +0100</pubDate><guid>https://paolostivanin.github.io/opensource/onnxruntime-webgpu-and-greycard/</guid><category>opensuse</category><category>hackweek</category><category>obs</category><category>packaging</category><category>onnxruntime</category><category>webgpu</category><category>rust</category><description>&lt;p&gt;&lt;strong&gt;TL;DR:&lt;/strong&gt; ONNX Runtime 1.31.0 in&#10;&lt;a href="https://build.opensuse.org/package/show/science:machinelearning/onnxruntime"&gt;science:machinelearning&lt;/a&gt;&#10;now has the WebGPU execution provider, so models can run on the GPU through&#10;Vulkan. In September that looked impossible to package. During Hack&#10;Week 26 I found a way to build Dawn, the WebGPU implementation it needs,&#10;offline. I also packaged greycard 0.13.1, a raw photo editor that loads the&#10;system ONNX Runtime for its AI denoising and masks. It is in review for the&#10;graphics project.&lt;/p&gt;&#10;&lt;h2 id="why-it-was-not-packaged"&gt;Why it was not packaged&lt;/h2&gt;&#10;&lt;p&gt;With WebGPU on, ONNX Runtime's build fetches Dawn, and Dawn's configure step&#10;git-clones about 20 more repositories. OBS builds have no network. When I&#10;updated the package to 1.29.0 in September, the only offline route I found&#10;meant bundling hundreds of megabytes of Dawn dependencies, so WebGPU stayed&#10;off.&lt;/p&gt;&#10;&lt;h2 id="how-it-builds-now"&gt;How it builds now&lt;/h2&gt;&#10;&lt;p&gt;Four of those sources turned out to be enough. The package carries them, at&#10;the commits pinned in Dawn's DEPS file: SPIRV-Headers, SPIRV-Tools,&#10;Vulkan-Headers and Vulkan-Utility-Libraries. abseil comes from the system, and so do the Python&#10;modules Dawn's code generators need. A custom Dawn source path skips ONNX&#10;Runtime's own Dawn patches, so the spec applies them by hand. Dawn is built&#10;from the version ONNX Runtime 1.31.0 pins, with its Vulkan backend. The&#10;C++ library gets WebGPU on x86_64 and aarch64; the Python flavours stay CPU&#10;only.&lt;/p&gt;&#10;&lt;p&gt;The first version shipped Dawn as its own library, &lt;code&gt;libwebgpu_dawn0&lt;/code&gt;. Dawn has&#10;no soname and no stable ABI, so that name would have been made up and could&#10;not stay unambiguous across Dawn updates. Debian packages Dawn as&#10;&lt;code&gt;libwebgpu-dawn0&lt;/code&gt;, with the same made-up soname, and I found no distribution&#10;that ships ONNX Runtime with WebGPU enabled. The current package links Dawn&#10;statically into &lt;code&gt;libonnxruntime1&lt;/code&gt;, as upstream does by default. It declares&#10;&lt;code&gt;bundled(dawn)&lt;/code&gt; and three of its dependencies that get compiled in, ships&#10;their licence texts, and recommends &lt;code&gt;libvulkan1&lt;/code&gt;, which Dawn opens at run&#10;time.&lt;/p&gt;&#10;&lt;p&gt;The request to the devel project had been created before the static version&#10;went into my branch, and it was accepted while I was submitting the update.&#10;OBS accepts a request at the revision it was created from, and its cleanup&#10;option then deleted the branched package, fix included. The fix went straight&#10;into science:machinelearning as&#10;&lt;a href="https://build.opensuse.org/package/rdiff/science:machinelearning/onnxruntime?rev=20"&gt;r20&lt;/a&gt;,&#10;13 minutes later. The package is not in Factory yet.&lt;/p&gt;&#10;&lt;h2 id="greycard"&gt;greycard&lt;/h2&gt;&#10;&lt;p&gt;greycard is written in Rust with Slint. Upstream loads its own prebuilt ONNX&#10;Runtime from beside the executable, and only on x86-64-v3 processors, which&#10;that build needs. A patch makes it take the system &lt;code&gt;libonnxruntime.so.1&lt;/code&gt; on&#10;any x86-64 processor. Two more changes: the check for new releases on GitHub is&#10;off by default, because zypper handles updates, and SQLite is the system&#10;library instead of the copy bundled in rusqlite.&lt;/p&gt;&#10;&lt;p&gt;A review before the submission found three problems, fixed before the request&#10;went out:&lt;/p&gt;&#10;&lt;ul&gt;&#10;&lt;li&gt;the first loader patch still sat behind upstream's CPU check, so it did&#10;nothing on older processors;&lt;/li&gt;&#10;&lt;li&gt;the License tag missed an OFL font, and SQLite was still the bundled copy;&lt;/li&gt;&#10;&lt;li&gt;a Recommends line used a Fedora package name.&lt;/li&gt;&#10;&lt;/ul&gt;&#10;&lt;p&gt;The request is&#10;&lt;a href="https://build.opensuse.org/request/show/1402769"&gt;sr#1402769&lt;/a&gt;.&lt;/p&gt;&#10;&lt;p&gt;Not tested: running a model through the WebGPU provider on a real GPU, and&#10;greycard's AI features. What was checked: the OBS builds (ONNX Runtime on&#10;Tumbleweed x86_64 and aarch64, greycard on x86_64), rpmlint with no errors on&#10;ONNX Runtime, and that Dawn is inside &lt;code&gt;libonnxruntime&lt;/code&gt; with no separate library&#10;to install.&lt;/p&gt;&#10;&lt;hr&gt;&#10;&lt;p&gt;&lt;strong&gt;How this was made&lt;/strong&gt;&lt;br&gt;&#10;AI help: an AI agent checked how other distributions package Dawn, reviewed&#10;both packages before submission, and ran the local builds.&lt;br&gt;&#10;Code: the spec files and patches were reviewed line by line by me, like any&#10;other patch, and checked in OBS builds.&lt;/p&gt;&#10;</description></item></channel></rss>