SharpMeow commited on
Commit
0f9ad8c
·
verified ·
1 Parent(s): 0c78e91

Model card for code 0.1.1: speed table, agreement in context

Browse files
Files changed (1) hide show
  1. README.md +30 -13
README.md CHANGED
@@ -7,14 +7,17 @@ tags:
7
  - 3d
8
  - ct
9
  - distillation
10
- - experimental
11
  ---
12
 
13
- # Lasagnetta (experimental)
14
 
15
- Lasagnetta is a fast preview of villa's lasagna field. villa's lasagna net ([ScrollPrize/villa](https://github.com/ScrollPrize/villa), weights [scrollprize/lasagna](https://huggingface.co/scrollprize/lasagna), MIT) predicts, for a CT scan of a Herculaneum scroll, a cos signal that repeats once per papyrus layer, its gradient size and the sheet normals. villa's surface fitting reads that field. Lasagnetta is a smaller 3D U-Net trained to copy villa's output, written on the same grids (cos at scaledown 2, grad_mag and the normal at 4) in villa's own layout, about 4 times faster end to end.
16
 
17
- **It did not pass its held-out test.** Use it as a preview, with its self-check on, and keep villa's own field as the reference. Its output is model output, a preview of another model's output, not a reading of any text.
 
 
 
 
18
 
19
  ## Files
20
 
@@ -38,20 +41,34 @@ python scripts/lasagnetta/preview.py --checkpoint release \
38
  --region 9472 9984 3072 3584 4096 4608 --input-level 2 --out out --name PHerc0139 --self-check
39
  ```
40
 
41
- On a CPU it works at batch 1 (the default off CUDA): this 512³ region took 988 s on 4 cores with 5.4 GB peak memory. `--checkpoint release` downloads these files and sets the recipe. With `--self-check`, villa's net (it needs a villa checkout, `LASAGNETTA_VILLA=/path/to/villa/lasagna`) first runs on 12 spots of the region and the preview is scored against it. When the median peak F1 is under 0.82, the command writes no field and exits 3, so you can run villa's `predict3d` instead.
 
 
 
 
 
 
 
 
 
 
 
 
42
 
43
  ## How well it agrees with villa
44
 
45
- Agreement was measured with villa's net as the reference, never against truth, on 256³ crops of scans no student had trained on. The measures are cos r (Pearson), peak F1 (sheet crossings matched within one cos voxel), the median normal angle and grad_mag r. The bars, fixed before each test, were 0.80, 0.80, 12° and 0.70, pooled and on every scan.
 
 
 
 
 
46
 
47
- | Test (25 Oct 2026) | Model | Pooled cos r / peak F1 / normal / grad r | Peak F1 per scan | Speed (end to end) | Verdict |
48
- | --- | --- | --- | --- | --- | --- |
49
- | Second | `l32n` alone, blur 0.5 | 0.864 / 0.811 / 4.0° / 0.796 | PHerc0175A 0.863, 0175B 0.759, 0306B 0.828, 0846A 0.824, 0846B 0.809 | 6.9x | FAIL (PHerc0175B) |
50
- | Third | this release | 0.910 / 0.855 / 3.1° / 0.877 | PHerc0009B 0.849, 0172 0.852, 0500P2 0.861, MAN5 0.774, MANB 0.870 | 3.9x | FAIL (PHercMAN5) |
51
 
52
- Each test had 30 crops per scan. Both had a control, the maps shifted by 3 cos voxels, and it failed as it should (third test: cos r 0.07, peak F1 0.16). Speed was measured on one RTX Pro 6000: on a 1024 × 2048 × 2048 region of PHerc0172, villa `predict3d` (tile 192) took 235.2 s and the release took 59.6 s.
53
 
54
- The self-check was run on whole volumes, two seeds each, after the third test. It sent PHerc0175B, PHercMAN5, PHerc0846B and PHerc0172 to villa. It kept Lasagnetta on PHerc0800, 1545, 0814, 0175A, 0306B, 0846A, 0009B and MANB, where the median peak F1 over its spots was 0.82 to 0.90. Each check took about 50 s on that GPU. Two of the three students had trained on PHerc0175A, 0306B and 0846A, so those three volumes say little about unseen scans.
55
 
56
  ## Training
57
 
@@ -59,4 +76,4 @@ The students were trained only on villa lasagna fields: the published fields in
59
 
60
  ## License and credit
61
 
62
- The weights are CC BY-NC 4.0, the license of the scans they derive from. The teacher model and its code are villa's lasagna (MIT), and credit goes to its authors. The scans come from the [Vesuvius Challenge open data](https://scrollprize.org/data). This is an experimental release by Chase Hendrick.
 
7
  - 3d
8
  - ct
9
  - distillation
 
10
  ---
11
 
12
+ # Lasagnetta
13
 
14
+ Lasagnetta is a fast preview of villa's lasagna field. villa's lasagna net ([ScrollPrize/villa](https://github.com/ScrollPrize/villa), weights [scrollprize/lasagna](https://huggingface.co/scrollprize/lasagna), MIT) predicts, for a CT scan of a Herculaneum scroll, a cos signal that repeats once per papyrus layer, its gradient size and the sheet normals. villa's surface fitting reads that field. Lasagnetta is a smaller 3D U-Net trained to copy villa's output, written on the same grids (cos at scaledown 2, grad_mag and the normal at 4) in villa's own layout, so anything that opens a villa lasagna field opens a preview.
15
 
16
+ - **Speed:** 5.2 times faster than villa `predict3d` end to end, 6.6 times with `--tile 320 576 576` (version 0.1.1 of the code, 27 Oct 2026).
17
+ - **Agreement:** on five scans it never trained on, pooled peak F1 0.86, cos r 0.91 and a median normal angle of 3.1° against villa's field.
18
+ - **Self-check:** before you trust a preview, it runs villa's net on 12 spots of your region and tells you where to use villa instead.
19
+
20
+ Its output is model output, a preview of another model's output, not a reading of any text. villa's own field stays the reference where exact values matter.
21
 
22
  ## Files
23
 
 
41
  --region 9472 9984 3072 3584 4096 4608 --input-level 2 --out out --name PHerc0139 --self-check
42
  ```
43
 
44
+ `--checkpoint release` downloads these files and sets the recipe. On a GPU, add `--tile 320 576 576` for the fastest run. On a CPU it works at batch 1 (the default off CUDA): this 512³ region took 988 s on 4 cores with 5.4 GB peak memory. With `--self-check`, villa's net (it needs a villa checkout, `LASAGNETTA_VILLA=/path/to/villa/lasagna`) first runs on 12 spots of the region and the preview is scored against it. When the median peak F1 is under 0.82, the command writes no field and exits 3, so you can run villa's `predict3d` there instead.
45
+
46
+ ## Speed
47
+
48
+ One RTX Pro 6000, a 1024 × 2048 × 2048 region of PHerc0800 staged on local disk, 27 Oct 2026:
49
+
50
+ | Run | End to end | Against villa `predict3d` (234.2 s) |
51
+ | --- | --- | --- |
52
+ | Code 0.1.0 | 58.2 s | 4.0x |
53
+ | Code 0.1.1 | 44.9 s | 5.2x |
54
+ | Code 0.1.1, `--tile 320 576 576` | 35.2 s | 6.6x |
55
+
56
+ 0.1.1 streams the write and pools the coarser levels on the GPU. With the default tile it writes cos and grad_mag byte for byte as 0.1.0, so the agreement figures below hold for both.
57
 
58
  ## How well it agrees with villa
59
 
60
+ Agreement was measured with villa's net as the reference, never against truth, on 256³ crops of scans no student had trained on, 30 crops per scan. The measures are cos r (Pearson), peak F1 (sheet crossings matched within one cos voxel), the median normal angle and grad_mag r.
61
+
62
+ | Test (25 Oct 2026) | Model | Pooled cos r / peak F1 / normal / grad r | Peak F1 per scan |
63
+ | --- | --- | --- | --- |
64
+ | Second | `l32n` alone, blur 0.5 | 0.864 / 0.811 / 4.0° / 0.796 | PHerc0175A 0.863, 0175B 0.759, 0306B 0.828, 0846A 0.824, 0846B 0.809 |
65
+ | Third | this release | 0.910 / 0.855 / 3.1° / 0.877 | PHerc0009B 0.849, 0172 0.852, 0500P2 0.861, MAN5 0.774, MANB 0.870 |
66
 
67
+ Both tests had a control, the maps shifted by 3 cos voxels, and it failed as it should (third test: cos r 0.07, peak F1 0.16). The bar set before each test was peak F1 0.80 on every scan; four of five scans met it in each test, so the release keeps the experimental label and its self-check.
 
 
 
68
 
69
+ For scale, villa's net does not reproduce itself exactly either: run on a mirrored copy of a scan and mirrored back, its field agrees with its own unmirrored field at pooled peak F1 0.79 to 0.83 (24 crops on four scans, 26 Oct 2026), and at 0.68 to 0.71 on PHerc0175B.
70
 
71
+ The self-check was run on 13 whole volumes, two seeds each. It kept Lasagnetta on PHerc0800, 1545, 0814, 0175A, 0306B, 0846A, 0009B and MANB, where the median peak F1 over its spots was 0.82 to 0.90, and pointed to villa on PHerc0175B, PHercMAN5, PHerc0846B and PHerc0172. Each check took about 50 s on that GPU. Two of the three students had trained on PHerc0175A, 0306B and 0846A, so those three volumes say little about unseen scans.
72
 
73
  ## Training
74
 
 
76
 
77
  ## License and credit
78
 
79
+ The weights are CC BY-NC 4.0, the license of the scans they derive from. The teacher model and its code are villa's lasagna (MIT), and credit goes to its authors. The scans come from the [Vesuvius Challenge open data](https://scrollprize.org/data). Released by Chase Hendrick.