junidude14 commited on
Commit
96d84b1
·
verified ·
1 Parent(s): bb7dbb6

Archive 4 checkpoints (1-4)

Browse files
paper-releases/pbisc-diffusion/updates/20261014T113716Z-figure1-overview-training-corpus/diffusion/dataset/server_1/model8/presentations/2026-09-30--paper-summary--r00/figures/figure1_revision_20261014/train_corpus/training_corpus_composition.pdf ADDED
Binary file (52.3 kB). View file
 
paper-releases/pbisc-diffusion/updates/20261014T113716Z-figure1-overview-training-corpus/diffusion/dataset/server_1/model8/presentations/2026-09-30--paper-summary--r00/figures/figure1_revision_20261014/train_corpus/training_corpus_composition.png ADDED

Git LFS Details

  • SHA256: eb6c44392a266f271ff0c7b1dc0121eafc376ac7540ec5b6559474c0a891bcdb
  • Pointer size: 131 Bytes
  • Size of remote file: 446 kB
paper-releases/pbisc-diffusion/updates/20261014T113716Z-figure1-overview-training-corpus/diffusion/dataset/server_1/model8/presentations/2026-09-30--paper-summary--r00/figures/figure1_revision_20261014/train_corpus/training_corpus_composition.svg ADDED
paper-releases/pbisc-diffusion/updates/20261014T113716Z-figure1-overview-training-corpus/diffusion/dataset/server_1/model8/presentations/2026-09-30--paper-summary--r00/tools/build_figure1_master_20261014.py ADDED
@@ -0,0 +1,104 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """Replace Figure1a and insert the exact training-corpus Figure1b in the saved master."""
2
+ from pathlib import Path
3
+ from collections import defaultdict
4
+ from datetime import datetime,timezone
5
+ import copy
6
+ import csv
7
+ import hashlib
8
+ import json
9
+ import os
10
+ import re
11
+ import sys
12
+ if os.environ.get('CUDA_VISIBLE_DEVICES') != '':raise SystemExit('CPU-only')
13
+ D=Path(__file__).resolve().parents[1];A=D/'data/figure1_revision_20261014'
14
+ PARENT=D/'data/strengthening_20261013/spec.json'
15
+ OUT='PBISC-Diffusion_expanded_master_20261014_figure1'
16
+ sys.path[:0]=[str(D),str(D/'tools')]
17
+ import generate_deck as G
18
+ from reorder_master_figures_20261013 import draw_card,draw_note
19
+ from pptx import Presentation
20
+ from pptx.util import Inches
21
+
22
+
23
+ def sha(p):
24
+ with Path(p).open('rb') as f:return hashlib.file_digest(f,'sha256').hexdigest()
25
+
26
+
27
+ def main():
28
+ parent=json.loads(PARENT.read_text())['slides'];assert len(parent)==154
29
+ inputs=[PARENT,Path(__file__),D/'generate_deck.py',D/'tools/reorder_master_figures_20261013.py']
30
+ bundles={name:json.loads((A/name/'result.json').read_text()) for name in ['overview','train_corpus']}
31
+ inputs.extend(A/name/'result.json' for name in bundles)
32
+ source_bindings={str(p):{'sha256':sha(p)} for p in inputs}
33
+ # Family proofs bind the exact plotted values and the source hash roster.
34
+ for name,b in bundles.items():
35
+ for r in b['sources']:
36
+ assert sha(r['path'])==r['sha256'],r['path']
37
+ source_bindings[r['path']]={'sha256':r['sha256']}
38
+ train_check=json.loads((A/'train_corpus/VERIFICATION.json').read_text())
39
+ assert train_check['status']=='PASS'
40
+ slides=[]
41
+ for n,ss in enumerate(parent,1):
42
+ s=copy.deepcopy(ss);s['parent_154_page']=n
43
+ if n==7:
44
+ replacement=copy.deepcopy(bundles['overview']['slides'][0])
45
+ s['superseded_overview_figure']=s['figures']
46
+ s.update(replacement);s['revision_key']='figure1a:organic_schematic'
47
+ for key in ['text_source','say','refs','refs_full']:s.pop(key,None)
48
+ if n==8:
49
+ train=copy.deepcopy(bundles['train_corpus']['slides'][0])
50
+ train.update(kind='content',deck_group='Figure 1',section='Figure 1',section_label='Fig. 1b',layout='full',
51
+ addition_key='figure1b:training_corpus',keywords=[])
52
+ # Keep the long metadata roster in the source manifest, not speaker notes.
53
+ train['sources']='data/figure1_revision_20261014/train_corpus/result.json; data/figure1_revision_20261014/train_corpus/source_hashes.json; tools/figure1_train_corpus_20261014.py'
54
+ train.pop('source_refs',None);train.pop('source_bindings',None)
55
+ slides.append(train)
56
+ s['section_label']='Figure 1 support'
57
+ s['title']='Full source corpus: training, validation and test'
58
+ slides.append(s)
59
+ assert len(slides)==155
60
+ mapping={s['parent_154_page']:i for i,s in enumerate(slides,1) if 'parent_154_page' in s}
61
+ assert sorted(mapping)==list(range(1,155))
62
+ assert sorted(s['original_slide'] for s in slides if 'original_slide' in s)==list(range(1,77))
63
+ for s in slides:
64
+ if s.get('kind')=='plan_card':
65
+ s['rows']=[(h,b,re.sub(r'\d+',lambda m:str(mapping[int(m.group())]),loc) if re.match(r'^pp?\.',loc) else loc)
66
+ for h,b,loc in s['rows']]
67
+ guide=next(s for s in slides if s.get('parent_154_page')==6)
68
+ guide['rows']=[('1a','Pretraining > paired adaptation > new-bulk generation','p. 7'),
69
+ ('1b','Actual training corpus: condition and cell-type composition','p. 8'),
70
+ ('Support','Full 41.4M source corpus; train/validation/test allocation','pp. 9, 10'),
71
+ ('1c','K recipes and repeated training exposure','p. 11'),
72
+ ('1d','Recorded noise-to-cell PCA stages','p. 13')]
73
+ guide['footnote']='Main corpus panel counts 33,141,380 unique training cells. The full 41,395,184-cell source pool remains support.'
74
+ guide['footnote_full']=guide['footnote']
75
+ slides[0]['subtitle']='155 slides | Organic experimental overview | Exact 33.14M training-corpus composition'
76
+ groups=defaultdict(list)
77
+ for i,s in enumerate(slides,1):groups[s['deck_group']].append(i)
78
+ prs=Presentation();prs.slide_width=Inches(G.SLIDE_W);prs.slide_height=Inches(G.SLIDE_H)
79
+ functions={'title':G.build_title,'agenda':G.build_agenda,'divider':G.build_divider,'content':G.build_content,'plan_card':draw_card,'evidence_note':draw_note}
80
+ for n,s in enumerate(slides,1):
81
+ fn=functions[s['kind']];fn(prs,s) if s['kind']=='title' else fn(prs,s,n)
82
+ prs.save(D/(OUT+'.pptx'))
83
+ spec={'deck':{'output_pptx':OUT+'.pptx','output_pdf':OUT+'.pdf'},'slides':slides}
84
+ (A/'spec.json').write_text(json.dumps(spec,indent=2)+'\n')
85
+ rows=[dict(page=n,parent_154_page=s.get('parent_154_page',''),original_76_page=s.get('original_slide',''),
86
+ group=s['deck_group'],panel=s.get('section_label',''),title=s['title']) for n,s in enumerate(slides,1)]
87
+ with (A/'page_map.csv').open('w',newline='',encoding='utf-8-sig') as f:
88
+ writer=csv.DictWriter(f,fieldnames=list(rows[0]));writer.writeheader();writer.writerows(rows)
89
+ oldm=json.loads((PARENT.parent/'manifest.json').read_text())
90
+ for s in parent:
91
+ for f in s.get('figures',[]):
92
+ p=str(D/f);assert sha(p)==oldm['sources'][p]['sha256']
93
+ for s in slides:
94
+ for f in s.get('figures',[]):source_bindings[str(D/f)]={'sha256':sha(D/f)}
95
+ protected={str(p):sha(p) for p in [PARENT,D/'PBISC-Diffusion_expanded_master_20261013_strengthened.pptx',D/'PBISC-Diffusion_expanded_master_20261013_strengthened.pdf']}
96
+ manifest={'schema':'pbisc.figure1-master.20261014.v1','created_at':datetime.now(timezone.utc).isoformat(),
97
+ 'parent_spec':str(PARENT),'total_slides':155,'parent_pages':154,'groups':dict(groups),
98
+ 'modified_parent_pages':[7],'newpages':[8],'sources':source_bindings,'protected_sources':protected,
99
+ 'new_training':False,'new_inference':False,'output':{'pptx':{'path':str(D/(OUT+'.pptx')),'sha256':sha(D/(OUT+'.pptx'))}}}
100
+ (A/'manifest.json').write_text(json.dumps(manifest,indent=2)+'\n')
101
+ print(json.dumps({'slides':155,'overview':7,'training_corpus':8,'full_source_support':9,'source_bindings':len(source_bindings)}))
102
+
103
+
104
+ if __name__=='__main__':main()