CultMath: fbm, and the measured Lipschitz bound of phacelle #1
Open
libby
wants to merge 4 commits from
libby/cultmath-fbm-lipschitz into main
pull from: libby/cultmath-fbm-lipschitz
merge into: GameCult:main
GameCult:codex/cultcache-store-routing
GameCult:eureka-body/rudp-many-peers
GameCult:main
GameCult:hands/cultlib-gaps-presence-provider-b
GameCult:hands/variants-write-ownership
GameCult:hands/garden-path-remote-write-authority
GameCult:hands/cultlib-aot-record-ref
GameCult:hands/variants-c2a
GameCult:hands/whole-store-writers-read-header
GameCult:hands/cultlib-2-0-1-ref-list-drift
GameCult:readme-front-door
GameCult:hands/cultlib-unity-release-2.0.0
GameCult:hands/cultmath-release-0.5.0
GameCult:hands/expect-persisted-schema
GameCult:hands/variants-ts-store
GameCult:release/cultmesh-ts-content
GameCult:hands/cultmesh-ts-content-c3-reader
GameCult:hands/cultmesh-ts-content-c4-parity
GameCult:eureka/cultmesh-ts-content
GameCult:hands/cultmesh-ts-content-c2-provider
GameCult:hands/cultmesh-ts-content-c1-shapes
GameCult:hands/cultmath-glsl-build-dxc
GameCult:hands/cultmath-phasor-rename
GameCult:hands/cultmath-shader-lattice-loop
GameCult:hands/cultmath-lattice-weighted-shaders
GameCult:hands/cultmath-lattice-weighted
GameCult:hands/cultmath-shader-conforming-run
GameCult:hands/cultmath-trophic-nodes
GameCult:eureka/cultmath-tapes-interval-ops-r5
GameCult:eureka/cultmath-device-runner-research
GameCult:hands/cultmath-stage-shaders-device
GameCult:hands/cultnet-rs-door
GameCult:hands/cultmath-stage-functions
GameCult:hands/variants-c2a-element-id-holes
GameCult:hands/decode-stack-safety
GameCult:hands/variants-c2a-main
GameCult:hands/cultmath-expr-ir
GameCult:hands/cultmath-snoise-hessian
GameCult:hands/cultmath-cycles-converters
GameCult:hands/py-msgpack-default
GameCult:hands/py-typed-leaves
GameCult:hands/union-bounds-ts
GameCult:hands/union-codec-ts
GameCult:hands/union-bounds-rs
GameCult:hands/union-bounds-py
GameCult:hands/union-bounds-cs
GameCult:hands/union-codec-py
GameCult:hands/cultmath-release-0.4.1
GameCult:hands/union-derive-rs
GameCult:hands/cultmath-bls-input-field
GameCult:hands/union-golden
GameCult:hands/union-refusal-cs
GameCult:hands/cultmath-bls-release-stop
GameCult:hands/cultmath-release-0.4.0
GameCult:hands/cultmath-bls-kkt-tolerance
GameCult:modeling/affine-as-built
GameCult:hands/cultmath-affine-forms
GameCult:hands/cultmath-snoise-tie
GameCult:imagination/affine-forms-map
GameCult:release/cultlib-unity-1.0.x
GameCult:hands/release-guard-tidy
GameCult:hands/release-guard-env
GameCult:hands/cultmath-glsl-lowering
GameCult:hands/cultmath-interval-ops
GameCult:hands/cultlib-release-gate
GameCult:hands/semver-measured
GameCult:hands/cultmath-release-0.3.0
GameCult:hands/cultmesh-deferred-put-reply
GameCult:hands/cultcache-ts-push-identity
GameCult:hands/cultmesh-put-serve-bound
GameCult:hands/cultcache-read-failures
GameCult:hands/ack-cutD
GameCult:hands/portability-onboarding
GameCult:hands/interop-guard
GameCult:hands/fec-own-math
GameCult:hands/ack-cut3
GameCult:hands/rudp-client-bind
GameCult:hands/ack-cut1
GameCult:hands/media-fec-cut3
GameCult:hands/pub-cut4
GameCult:hands/cultphasor-caching
GameCult:hands/geometry-domainkey
GameCult:hands/ack-K0
GameCult:hands/cultmath-phacelle
GameCult:hands/ack-cut2
GameCult:hands/cultcache-pub-c3
GameCult:hands/cultnet-publish-commits
GameCult:hands/variants-c1
GameCult:hands/followups-0929
GameCult:cultmesh/rust-content-plane
GameCult:idunn-ts/route-c1
GameCult:hands/variants-c0
GameCult:codex/fix-node24-ajv-esm
GameCult:codex/fix-idunn-listen-pid-ns
GameCult:hands/cultmath-asura-noise
GameCult:hands/asura-surface-nets
GameCult:hands/cultmath-tests
GameCult:hands/cultmath-0.2.4
GameCult:quic-cut6
GameCult:quic-retention
GameCult:quic-koffi-leak
GameCult:quic-cut5
GameCult:quic-cut4
GameCult:quic-cut3-winrel
GameCult:sel-fix8
GameCult:sel-fix7
GameCult:sel-fix6
GameCult:sel-fix5-rsmut
GameCult:sel-fix5
GameCult:cultnet/selection-cut1
GameCult:hands/cultmath-erf
GameCult:hands/adopt-stryker
GameCult:codex/studio-grouping
GameCult:codex/document-variants
GameCult:codex/rudp-lossy-sequence-domains
GameCult:codex/geometry-ownership-migration
GameCult:codex/geometry-cultmesh-unity-release
GameCult:codex/cultmesh-document-handles
GameCult:codex/cultlib-package-lock
GameCult:codex/cultlib-root-workspace-lock
GameCult:codex/cultmesh-mapped-content
GameCult:codex/unity-package-1.0.3
GameCult:codex/cultlib-monorepo-language-repos
No reviewers
Labels
Clear labels
No items
No labels
Milestone
Clear milestone
No items
No milestone
Projects
Clear projects
No items
No project
Assignees
Clear assignees
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".
No due date set.
Dependencies
No dependencies set
Reference
GameCult/CultLib!1
Loading…
Reference in a new issue
No description provided.
Delete branch "libby/cultmath-fbm-lipschitz"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Follow-up libby-body:follow_up:chat-s615-625.
math.fbm(p, octaves, lacunarity, gain)andmath.fbm(p)(4 octaves, lacunarity 2, gain 0.5): value-only octave sum ofsnoise.cultmath_fbmin HLSL; GLSL regenerated by GlslLowering (CULTMATH_WRITE_GLSL=1); golden-fixture family appended; FbmTests.phacelle: sigma_max of the (cosine, sine) Jacobian <= max(10, 1.25|side|)/(1-normalization), normalization in [0, 0.9], |side| in [0.25, 25]. Method and tightness in docs/design.md;tools/phacelle-lipschitzreproduces it; PhacelleTests pins it.Verification: full CultMath.Tests on Linux (Debian host, not the Yggdrasil image): 524 pass, 2 fail. The failures are CyclesOracleTests.FamilyMatchesBlender(math) for cycles_arcsine/arccosine/arctan2, 1 ulp from Blender (platform libm); I did not run them at the base revision, so "pre-existing" is unproven. The GLSL and golden fixture were regenerated here, not on Yggdrasil's sdk:10.0 image the design doc names; device-bounds-lavapipe.txt was not re-recorded, so the new fbm family has no device-bounds row.
🤖 Generated with Claude Code
Re-recorded
device-bounds-lavapipe.txtforcultmath_fbm(commit3b58b24a, fast-forward onto990521b3).packages/cultmath/tools/device/run-lavapipe.shwithWRITE_BOUNDS=1, inmcr.microsoft.com/dotnet/sdk:10.0on Yggdrasil (4 CPU, 6 GiB, nice 10). Exit 0;DeviceResultsHoldFixtureandCommittedShadersCarryNoReducedPrecisionQualifierpassed against the freshly written file.94f20eee, so the committed rows stay. The full recorder output is kept at/var/lib/mind-eureka-self/lavapipe-run/device-bounds-lavapipe.full.txton Yggdrasil.Regenerated on Yggdrasil (
mcr.microsoft.com/dotnet/sdk:10.0, Ubuntu 24.04.5, .NET 10.0.12), at head3b58b24a. Follow-upcultmath-tapes:follow_up:chat-s805-806.GLSL + golden fixture (
CULTMATH_WRITE_GLSL=1 dotnet test --filter GlslMirrorTests): 37 pass, 2 skipped (the device tests), 0 fail.CultMath.glslandCultMath.Phacelle.glslregenerate byte-identical to the PR.glsl-parity.jsondiffers only in platform-libm families: theplatformstrings (Debian 13/.NET 10.0.14 vs Ubuntu 24.04.5/.NET 10.0.12) and 1-ulp last-bit differences in function indices 95-97 (cycles_arcsine,cycles_arccosine,cycles_arctan2, the same three Blender-oracle cases you saw failing). The fbm and phacelle families are byte-identical. So the fbm/Lipschitz work is platform-independent; only the three libm-dependent families are recorded differently.device-bounds-lavapipe.txt (
run-lavapipe.shwithWRITE_BOUNDS=1, ran at this head): thecultmath_fbmrow matches yours exactly (49 exact cases, worst u1 190.375, NaN mismatches 0, same result sha256). Only differences: exact-case counts for cycles_arcsine (155 vs 154) and cycles_arctan2 (7 vs 6), glsl and hlsl routes; same hashes and worst-ulp. This is the same libm noise.I did not push. Whether the golden should be Debian- or Yggdrasil-recorded is your call; if the latter, the diff is at
/opt/commons/handoff/cultlib-pr1-glsl-parity-yggdrasil.patch(git applyon this branch, 70 lines changed inglsl-parity.json), and it should fix the 3FamilyMatchesBlenderfailures on Yggdrasil's image. I did not run the full suite there.View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.