Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
102 commits
Select commit Hold shift + click to select a range
8e6305d
started implementation
GalaxyCo Nov 20, 2025
4227d4d
testing some things, cyclic group case, added documentation (TODO!!)
GalaxyCo Dec 9, 2025
501bcea
deleted old file
GalaxyCo Dec 9, 2025
a5e44da
added more documentation, renamed file,
GalaxyCo Dec 9, 2025
6115c49
moved file intersting_groups.g into tst folder TODO: write tests with…
GalaxyCo Dec 9, 2025
8299f69
renamed poly_eval_test.g to custom_test_functions.g
GalaxyCo Dec 9, 2025
202c1c0
Added tests, TODO: tests with interesting scalars are missing
GalaxyCo Dec 10, 2025
aeed217
forgot to load interesting_groups.g in testall.g
GalaxyCo Dec 10, 2025
cf59bfb
changed test names, added test from github issue 39
GalaxyCo Dec 10, 2025
870cfcc
small bug fix
GalaxyCo Dec 10, 2025
a7cb0a7
fixed bug, where wrong basis change matrix was used when computing th…
GalaxyCo Dec 10, 2025
46918dd
changed tests to use vectos space dimension
GalaxyCo Dec 10, 2025
26f348a
fixed tests, forgot to set field
GalaxyCo Dec 10, 2025
f1a1b72
fixed typo ....
GalaxyCo Dec 10, 2025
d777d43
changed back test files to only compare list size instead of vector s…
GalaxyCo Dec 10, 2025
6ed901a
deleted useless latex files in doc dir
GalaxyCo Dec 11, 2025
db5c8b3
Added function Filter Formspace to compute Symmetric/Symplectic/Hermi…
GalaxyCo Dec 11, 2025
5fea158
made filter unitary forms return a gf(q) basis (instead of a weird gf…
GalaxyCo Dec 15, 2025
902f5fd
replaced prefix for internal methods
GalaxyCo Dec 15, 2025
8d6449a
fixed test (new prefix)
GalaxyCo Dec 15, 2025
89a2aa2
changed most of max nitpicks
GalaxyCo Dec 15, 2025
ad31c2d
changed FORMS_IsSymmetricMatrix, FORMS_IsSymplecticMatrix, and FORMS_…
GalaxyCo Jan 13, 2026
83eb172
added test
GalaxyCo Jan 13, 2026
51f3988
added char 2 case for FilterFormspace (needs work for bilinear case?)…
GalaxyCo Feb 26, 2026
10803eb
Added PreservedFormsWithScalars and PreservedSesquilinearFormsWithSca…
GalaxyCo Mar 16, 2026
d9c1265
Added benchmark_forms.g to compare PreservedForms and PreservedFormsW…
GalaxyCo Mar 17, 2026
3060214
Changed method for random element selection
GalaxyCo Mar 18, 2026
8831e05
added stagnation optimization, cleaned up dead code, old comments, ad…
GalaxyCo Mar 18, 2026
a34abaf
changed NullMat to ZeroMatrix, fixed stagnation thingy
GalaxyCo Mar 18, 2026
dc35987
Added test, reverted zero matrix change is caused many bugs
GalaxyCo Mar 18, 2026
242416e
Changed ClassicalForms_GeneratorsWithBetterScalarsSesquilinear (might…
GalaxyCo Apr 9, 2026
28e8025
fixed stupid bug from previous commit
GalaxyCo Apr 9, 2026
9f54067
Merge branch 'master' into formspace
GalaxyCo May 30, 2026
17aaa4a
fixed bug with scalars while merging
GalaxyCo May 30, 2026
19584ee
Fixed bug in test function (name collision with gap function)
GalaxyCo Sep 25, 2026
0bc8fde
Made the formspace code mostly work with MatrixObjs
GalaxyCo Sep 28, 2026
54e453a
added AI generated tests for matrix objs
GalaxyCo Sep 29, 2026
9c9acde
Made some changes commiting to return later to this.
GalaxyCo Sep 29, 2026
9151501
all old tests now pass for classical matrices
GalaxyCo Sep 29, 2026
7a55e95
realized i am stuipd and everything is sort of ok
GalaxyCo Sep 29, 2026
9fa3fe3
changed bugs found by AI
GalaxyCo Sep 29, 2026
80cf572
reverted ways matrixobjs get displayed
GalaxyCo Sep 29, 2026
ce24dd3
updated AI slop tests.
GalaxyCo Sep 29, 2026
e78abb9
Sped up poly eval test by doing less iterations.
GalaxyCo Sep 29, 2026
9d82a94
added test matrix obj polynomial eval, messed up formspace computatio…
GalaxyCo Sep 30, 2026
7d35a22
fixed index bug that broke computation
GalaxyCo Sep 30, 2026
925ffb6
added some tests and changed some stuff related to matrix objects
GalaxyCo Oct 1, 2026
2991949
added fix for PolynomialOfForm
GalaxyCo Oct 1, 2026
c809bbd
commit before chaning the \^ operation with a lot of AI slop to solve…
GalaxyCo Oct 1, 2026
4ef782a
changed todos
GalaxyCo Oct 1, 2026
e1be72e
added more test cases for \^ operation and now all tests pass.
GalaxyCo Oct 1, 2026
692cd07
changed a lot of the ai tests in trying to fix them and looking if th…
GalaxyCo Oct 2, 2026
522c00f
made some changes to the logic of OrthogonalSubspace, and EvaluateFor…
GalaxyCo Oct 2, 2026
57454af
fixed the tsts such that it should work ideally and classic.gi to pas…
GalaxyCo Oct 2, 2026
45c5f6b
fixed more test related bugs
GalaxyCo Oct 2, 2026
3cebd5e
excluded slow classic.tst test
GalaxyCo Oct 2, 2026
35bc836
added todos
GalaxyCo Oct 3, 2026
f8ee638
changed back readme.
GalaxyCo Oct 12, 2026
f1e0167
matrix object printing was changed, changed tests accordingly/exclude…
GalaxyCo Oct 13, 2026
5eff83f
Added centralizer code, not removed old code.
GalaxyCo Oct 13, 2026
43d6867
changed formspace computations to use new centralizer methods. Fixed …
GalaxyCo Oct 13, 2026
9776cad
Removed old formspace code and dead code.
GalaxyCo Oct 13, 2026
f747436
fixed stupid bugs
GalaxyCo Oct 14, 2026
bb7298c
added test, changed some comments
GalaxyCo Oct 15, 2026
4f17da9
fixed IntersectVectorSpace function and added test for it.
GalaxyCo Oct 15, 2026
6245000
fixed stupid bug in test functions that used wrong adjoint
GalaxyCo Oct 15, 2026
d953c56
Fixed more stupid bugs, now all tests pass.
GalaxyCo Oct 15, 2026
e53ab11
removed stupid FORMS_IntersectVectorSpaces and its test.
GalaxyCo Oct 15, 2026
278f978
actually remove code from FORMS_IntersectVectorSpaces
GalaxyCo Oct 15, 2026
5927f35
changed FORMS_IntersectVectorSpaces to deal with annoying IsGF2Matrix…
GalaxyCo Oct 15, 2026
af81b83
fixed more stupid bugs
GalaxyCo Oct 15, 2026
9c70044
fixed stupid mistake, renamed method
GalaxyCo Oct 15, 2026
b693695
many small changes and bug fixes that drastically improved performance
GalaxyCo Oct 15, 2026
a7cf075
added method MatrixIntertwiners
GalaxyCo Oct 19, 2026
7b0f33d
added intertwiner benchmark.
GalaxyCo Oct 26, 2026
e5b56db
some changes, this is the commit before i will start to remove the ol…
GalaxyCo Nov 16, 2026
deea120
replaced the functions PreservedForms, PreservedSesquilinearForms, Pr…
GalaxyCo Nov 16, 2026
ef44dff
fixed bugs, removed temporary latex files
GalaxyCo Nov 16, 2026
90b20f7
updated gitignore
GalaxyCo Nov 16, 2026
d0f8b98
Found some bugs, fixed bug in QuadraticForm2, and added test made by …
GalaxyCo Nov 16, 2026
4828697
fixed bugs with char2 bilinear filter function.
GalaxyCo Nov 16, 2026
443ab50
removed old comment
GalaxyCo Nov 16, 2026
b8163a6
changed docs for PreservedForms, PreservedSesquilinearForms, Preserve…
GalaxyCo Nov 17, 2026
2f3f133
fixed a bug caused by the fact that the random vectors did not have t…
GalaxyCo Nov 17, 2026
bdd06a6
Fixed ridcoules bug related to compressed matrices found by claude. T…
GalaxyCo Nov 17, 2026
04ba5c7
fixed typo
GalaxyCo Nov 17, 2026
7113b33
Added code to reuse more computations during the build of the conditi…
GalaxyCo Nov 17, 2026
3345f3d
fix bug in unitary filter function, where the wrong matrix was used d…
GalaxyCo Nov 17, 2026
7b06528
fixed bug when computing scalars. Helped by claude
GalaxyCo Nov 17, 2026
f22b6af
fixed a bug where improvegenerator could result in the improved gener…
GalaxyCo Nov 17, 2026
29682a9
made a change suggested by claude to remove the fallback. I chekede t…
GalaxyCo Nov 19, 2026
8c813d9
deleted dead code.
GalaxyCo Nov 19, 2026
c3f1c93
changed intersting groups to make the example easyer to reproduce.
GalaxyCo Dec 3, 2026
e682f08
Added benchmarking website (vibe coded with claude)
GalaxyCo Dec 3, 2026
440efa8
Added in adding to finding cyclic matrices and changed some heuristics.
GalaxyCo Dec 3, 2026
44997f7
fixed stupid bugs
GalaxyCo Dec 3, 2026
de2556b
changed some things, changed test suite.
GalaxyCo Dec 3, 2026
cceeed4
some more changes
GalaxyCo Dec 3, 2026
2aa7026
ran big benchmark
GalaxyCo Dec 4, 2026
7fb5f07
more changes to benchmark website.
GalaxyCo Dec 4, 2026
e240583
Updated website
GalaxyCo Dec 4, 2026
408f60b
added in meataxe fallback incase where we dont find cyclic elements. …
GalaxyCo Dec 4, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,10 @@
/tmp
/gh-pages
tmp.json
profiling
benchmark.csv
benchmark_old.csv
bench_intertwiners.g
intertwiners_benchmark.csv
/doc/forms.fdb_latexmk
/doc/forms.fls
2 changes: 1 addition & 1 deletion PackageInfo.g
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ PackageDoc := rec(

Dependencies := rec(
GAP := ">=4.9",
NeededOtherPackages := [],
NeededOtherPackages := [["nofoma", "1.0"]],
SuggestedOtherPackages := [],
ExternalConditions := []),

Expand Down
6 changes: 6 additions & 0 deletions benchmarking/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
.cache/
results/run.log
results/full-run.out
results/progress/
__pycache__/
results/*.out
241 changes: 241 additions & 0 deletions benchmarking/NOTES.md

Large diffs are not rendered by default.

76 changes: 76 additions & 0 deletions benchmarking/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
# Benchmarks

A dashboard that compares

* `PreservedForms` of the current working tree (the "branch") with `PreservedForms`
on the `master` branch (the MeatAxe based code), and
* `MatrixIntertwiners` with `MTX.BasisModuleHomomorphisms`,

and records the steps of the new code: possible scalars, the search for a cyclic
element, Frobenius blocks, number of conditions, how the kernel shrinks, how the
solver finished, and the time spent in every phase.

## Use

```sh
cd benchmarking
./run.py -j 2 # full grid, new code and master (a few hours)
./run.py -j 2 --versions branch # only the new code; compare it with master from an earlier run
./run.py --only Sp "S+S" --n 128 256 # some families / cases / sizes (a small run of its own)
./run.py --suite intertwiners # one suite only
./run.py --ref 8c813d9 --label "before X" # benchmark an older commit, for the comparison
./run.py --preset quick # small grid, a few minutes
./run.py --export-only # rebuild site/data.js and site/history.js from results/
./run.py --deprecate 20261203-192924 "older grid" # keep a run, but never pick it by default
```

Then open `site/index.html` in a browser (works from `file://`, no server needed).

**Comparing runs.** Every run is kept as `results/run-<date>.json` and is its own entry on the
site, one per version of the code it ran (a commit, or the working tree with uncommitted `lib/`
changes). Runs are never merged: the selectors at the top of the page pick two entries, and
every comparison uses only the cases both of them measured. By default the newest run of the
new code is compared with master from the same run. `--deprecate STAMP [REASON]` marks an
old run (`results/deprecated.json`): it stays selectable but is never the default, and the
"Compare versions" tab lists it unticked. Names come from `results/labels.json` (edit it, or
pass `--label`). Commit before benchmarking so that each version has a commit to refer to.

Options: `--preset quick|medium|full`, `--reps N`, `--timeout S`, `-j N` (parallel GAP
processes; more is faster but adds noise), `--gap PATH` (default: `gapdev` if found, else
`gap`), `--master-ref REF`, `--label TEXT`.

## Files

| Path | What it is |
|---|---|
| `run.py` | Driver: extracts `master` with `git archive` into `.cache/master/forms`, runs GAP per suite and family, handles timeouts, writes `results/*.json` and `site/data.js`. |
| `gap/common.g` | JSON output, the timing wrappers, and the generators of all benchmark inputs. |
| `gap/main.g` | Runs a list of cases in one GAP process and prints one JSON line per case. |
| `site/` | The dashboard (`index.html`, `app.js`, `charts.js`, `style.css`), the generated `data.js` (the run shown) and `history.js` (all versions, compact, for "Compare versions"). |
| `results/` | `latest.json` (what the dashboard shows), one `run-<date>.json` per run (only what that run measured), `labels.json` (version names), `run.log`. |
| `NOTES.md` | Notes for whoever changes the dashboard next: data flow, what to check first. |

## How phases are measured

`lib/` is not changed. `gap/common.g` replaces some global functions (for example
`FORMS_FindCyclicElement`, `FORMS_NullspaceMat`, `MTX.IsIrreducible`) with wrappers
that time the original and record what it did. The package calls these functions
through global variables, so the unchanged code uses the wrappers. Phase times are
self times, so the phases of one run add up to its total. If a function is renamed
in `lib/`, its phase simply shows up as "other"; add the new name in
`BenchInstrumentBranch`.

## Adding cases

* A group family for `PreservedForms`: add `BenchGroupFamilies.("name")` in
`gap/common.g` and the name to `PRESERVED_FAMILIES` in `run.py` (and a description
in `PRES_INFO` in `site/app.js`).
* An input for `MatrixIntertwiners`: add `BenchIntertwinerCases.("name")`, the name
to `INTERTWINER_CASES` and a description to `INT_INFO`.

## Rebuilding one case in GAP

The case explorer has a "GAP code for this case" button. The snippet uses
`ReadPackage("forms", "benchmarking/gap/common.g")`, so start GAP such that
`LoadPackage("forms")` loads the version you want (for master:
`--packagedirs benchmarking/.cache/master`; `run.py` copies the helpers there).
Binary file added benchmarking/__pycache__/run.cpython-310.pyc
Binary file not shown.
Loading