hanghang214 commited on
Commit
24599ef
·
verified ·
1 Parent(s): 1de71d7

Add files using upload-large-folder tool

Browse files
This view is limited to 50 files because it contains too many changes.   See raw diff
Files changed (50) hide show
  1. bbflow_base/docs/HANDOFF_2026-07-17.txt +1309 -0
  2. bbflow_base/docs/cmfm_failure_localization.md +138 -0
  3. bbflow_base/docs/cmfm_handoff_2026-07-31.md +534 -0
  4. bbflow_base/docs/cmfm_problem_statement_2026-07-31.md +169 -0
  5. bbflow_base/docs/covariance_matching_problem.md +209 -0
  6. bbflow_base/docs/experiment_trace_2026-07-05.md +1367 -0
  7. bbflow_base/docs/gencov_handoff_2026-08-08.md +168 -0
  8. bbflow_base/docs/mdsubspace_handoff_2026-08-04.md +262 -0
  9. bbflow_base/docs/protein_project_conversation_record_2026-07-13.jsonl +13 -0
  10. bbflow_base/docs/protein_project_conversation_record_2026-07-13.txt +71 -0
  11. bbflow_base/docs/protein_project_full_chat_2026-07-13.jsonl +0 -0
  12. bbflow_base/docs/superpowers/plans/2026-06-28-kabsch-static-control.md +53 -0
  13. bbflow_base/docs/superpowers/specs/2026-06-28-kabsch-static-control-design.md +28 -0
  14. bbflow_base/lightning_logs/version_10/hparams.yaml +264 -0
  15. bbflow_base/lightning_logs/version_100/hparams.yaml +314 -0
  16. bbflow_base/lightning_logs/version_101/hparams.yaml +314 -0
  17. bbflow_base/lightning_logs/version_102/hparams.yaml +314 -0
  18. bbflow_base/lightning_logs/version_104/hparams.yaml +314 -0
  19. bbflow_base/lightning_logs/version_12/hparams.yaml +266 -0
  20. bbflow_base/lightning_logs/version_13/hparams.yaml +267 -0
  21. bbflow_base/lightning_logs/version_2/hparams.yaml +256 -0
  22. bbflow_base/lightning_logs/version_22/hparams.yaml +269 -0
  23. bbflow_base/lightning_logs/version_25/hparams.yaml +269 -0
  24. bbflow_base/lightning_logs/version_27/hparams.yaml +273 -0
  25. bbflow_base/lightning_logs/version_33/hparams.yaml +273 -0
  26. bbflow_base/lightning_logs/version_35/hparams.yaml +273 -0
  27. bbflow_base/lightning_logs/version_39/hparams.yaml +279 -0
  28. bbflow_base/lightning_logs/version_4/hparams.yaml +261 -0
  29. bbflow_base/lightning_logs/version_43/hparams.yaml +289 -0
  30. bbflow_base/lightning_logs/version_45/hparams.yaml +289 -0
  31. bbflow_base/lightning_logs/version_47/hparams.yaml +289 -0
  32. bbflow_base/lightning_logs/version_51/hparams.yaml +289 -0
  33. bbflow_base/lightning_logs/version_55/hparams.yaml +289 -0
  34. bbflow_base/lightning_logs/version_56/hparams.yaml +289 -0
  35. bbflow_base/lightning_logs/version_57/hparams.yaml +289 -0
  36. bbflow_base/lightning_logs/version_58/hparams.yaml +281 -0
  37. bbflow_base/lightning_logs/version_59/hparams.yaml +281 -0
  38. bbflow_base/lightning_logs/version_62/hparams.yaml +288 -0
  39. bbflow_base/lightning_logs/version_68/hparams.yaml +297 -0
  40. bbflow_base/lightning_logs/version_69/hparams.yaml +311 -0
  41. bbflow_base/lightning_logs/version_79/hparams.yaml +313 -0
  42. bbflow_base/lightning_logs/version_8/hparams.yaml +264 -0
  43. bbflow_base/lightning_logs/version_83/hparams.yaml +313 -0
  44. bbflow_base/lightning_logs/version_85/hparams.yaml +313 -0
  45. bbflow_base/lightning_logs/version_88/hparams.yaml +313 -0
  46. bbflow_base/lightning_logs/version_9/hparams.yaml +264 -0
  47. bbflow_base/lightning_logs/version_94/hparams.yaml +313 -0
  48. bbflow_base/lightning_logs/version_96/hparams.yaml +314 -0
  49. bbflow_base/outputs/hydra/.hydra/config.yaml +285 -0
  50. bbflow_base/outputs/hydra/.hydra/hydra.yaml +170 -0
bbflow_base/docs/HANDOFF_2026-07-17.txt ADDED
@@ -0,0 +1,1309 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ================================================================================
2
+ HANDOFF DOCUMENT - BBFlow generator-response covariance line
3
+ Date: 2026-07-17
4
+ Audience: the next Claude / engineer picking this up cold
5
+ ================================================================================
6
+
7
+ HOW TO USE THIS DOC
8
+ -------------------
9
+ Read sections 1-4 first (goal, scoreboard, the core diagnosis). Then section 6
10
+ (current mechanism) and section 8 (THE TEACHER BUG - do not repeat it).
11
+ Section 14 lists process rules that were learned the expensive way.
12
+
13
+ This doc supplements docs/experiment_trace_2026-07-05.md, which holds the older
14
+ experiment log. Where they disagree, this doc is newer.
15
+
16
+
17
+ ================================================================================
18
+ 1. PROJECT GOAL AND HARD CONSTRAINTS
19
+ ================================================================================
20
+
21
+ GOAL
22
+ Beat BBFlow (Wolf et al., NeurIPS 2025) on the ATLAS test set (82 proteins,
23
+ 250 conformations each) on its own official metrics:
24
+ - RMSF correlation (r) and RMSF MAE
25
+ - Pairwise RMSD MAE
26
+ - PCA W2
27
+
28
+ USER'S HARD CONSTRAINT (stated repeatedly, non-negotiable)
29
+ "We must be better than BBFlow." Tying is not accepted as a result. Do not
30
+ propose a paper narrative that relies only on cross-covariance / auxiliary
31
+ metrics while conceding the official table.
32
+
33
+ STANDING PROHIBITIONS (user has explicitly rejected these; do not re-propose)
34
+ - ENM (elastic network model) as a basis or forward feature. Absolutely refused.
35
+ - Oracle information in any deployable component. See section 12.
36
+ - Expensive full ensemble-rollout training losses (20-step sampling per step).
37
+ - Multi-seed re-runs purely to measure noise floor ("100% against 多跑").
38
+
39
+ CONTEXT ON WHY THE USER IS FRUSTRATED
40
+ This line has burned weeks. Multiple runs were wasted on OOM crashes and on a
41
+ silent bug (section 8). Be precise, verify before proposing commands, and do
42
+ not over-promise speedups or "free" fixes. Two things this session were
43
+ over-claimed and had to be retracted: (a) "1 delta is unbiased and free" -
44
+ false for the normalized-shape objective, see section 6; (b) "removing the
45
+ teacher restores v1 speed" - it was only ~15%.
46
+
47
+
48
+ ================================================================================
49
+ 2. ENVIRONMENT AND PATHS
50
+ ================================================================================
51
+
52
+ MACHINES
53
+ Local (Windows): D:\pycharm\pythonProject\protein\bbflow_base
54
+ - This is a CODE MIRROR ONLY. There is NO python and NO torch installed.
55
+ You can read and edit code here. You CANNOT run, test, or syntax-check
56
+ by execution. Only careful reading.
57
+ - The user copies files to the server MANUALLY.
58
+ Server: gn11 / gn14, 3x NVIDIA H100 PCIe 80GB
59
+ Repo: /home/wangyusong/LD-FPG-main/bbflow_base
60
+ Conda: `protein` env (also seen: /data/shared/conda_envs/ldfpg)
61
+
62
+ KEY PATHS
63
+ Official BBFlow checkpoint (warm-start source for everything):
64
+ /home/wangyusong/LD-FPG-main/bbflow/models/bbflow-0.1/bbflow-0.1.ckpt
65
+ NOTE the path is under .../LD-FPG-main/bbflow/ (NOT bbflow_base/).
66
+
67
+ Repro root:
68
+ /data/shared/wangyusong/atals/bbflow_official_reproduction
69
+
70
+ "Version A" reference run (the protected baseline to beat/compare against):
71
+ ${REPRO}/outputs/checkpoints/
72
+ bbflow_base_energy_from_q_diag_orth1_recon0_30ep_3gpu_20260707_165355
73
+
74
+ Motion target cache (used by the current runs):
75
+ /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/
76
+ atlas_full_md_motion_targets_k8_kabsch_v1.pt
77
+ WARNING: docs/experiment_trace_2026-07-05.md lists caches under
78
+ ${REPRO}/shape_fingerprints/. The running command uses the /home/... path.
79
+ These may be different copies. VERIFY before trusting a comparison to A.
80
+ Required cache fields: local_cov, cross_cov, rmsf, oracle_mean_disp.
81
+ Optional: gen_response_trace_anchor, oracle_modes, oracle_energy.
82
+
83
+ LAUNCHER / SCRIPT INTERFACES (never write commands from memory - read them)
84
+ Training: base_stages/00_train_final_mog_ddp.sh
85
+ env-var interface + EXTRA_HYDRA_ARGS passthrough.
86
+ `+experiment.training.X=Y` adds NEW hydra keys; existing keys
87
+ take no `+`.
88
+ Sampling: reproduction/02_sample_test.sh
89
+ Uses REPRO_ROOT, METADATA_ROOT, CKPT_PATH, GPU_ID,
90
+ SAMPLES_PER_PROTEIN, SAMPLE_BATCH_SIZE, MAX_NUM_RES_SQUARED,
91
+ INFERENCE_NAME, CONDITION_MODE, CONDITION_SCALE, ...
92
+ It IGNORES OUTPUT_DIR and writes to ${REPRO_ROOT}/inference
93
+ Evaluation: reproduction/03_evaluate.sh
94
+ Uses ENSEMBLE_DIR, ATLAS_VIEW_ROOT, METRICS_DIR, TEST_CSV,
95
+ METHOD_NAME, METHOD_TIME_SECONDS, NUM_WORKERS
96
+ ATLAS_VIEW_ROOT must point at the REAL trajectories:
97
+ ${REPRO}/datasets/ATLAS
98
+ If you see "No reference trajectory found ... reproduction/
99
+ outputs/data/ATLAS", STOP - the metrics are invalid.
100
+
101
+ OUTPUTS PER RUN
102
+ ${RUN_DIR}/config.yaml <- the ONLY source of truth for
103
+ what actually ran
104
+ ${RUN_DIR}/latent_train_epoch_metrics.csv <- one row per epoch, ALL metrics
105
+ (rank 0 only). This is the file
106
+ to read/paste for diagnosis.
107
+ ${RUN_DIR}/epoch:0NN.ckpt, last.ckpt
108
+ Console line per epoch: "[epoch NNN md] key=val, ..." driven by
109
+ MD_EPOCH_SUMMARY_KEYS in bbflow/models/bbflow_module.py
110
+
111
+
112
+ ================================================================================
113
+ 3. THE SCOREBOARD (this is what everything is measured against)
114
+ ================================================================================
115
+
116
+ Method RMSF r RMSF MAE Pairwise MAE PCA W2
117
+ -------------------------------------- ------ -------- ------------ ------
118
+ BBFlow official rerun (250 samples) 0.89 0.48 0.77 1.34
119
+ (same official, second record) 0.89 0.47 0.78 1.34
120
+ Version A (energy_from_q_diag, 30ep) 0.89 0.45 0.79 1.35
121
+ Long finetune orth1/recon0 100ep 0.88 0.48 0.81 1.35
122
+ A with SHUFFLED condition 0.89 0.48 1.27 1.51
123
+
124
+ READING OF THE SCOREBOARD
125
+ - A WINS RMSF MAE (0.45 vs 0.47-0.48). This is a real, repeated win.
126
+ - A ties RMSF r.
127
+ - A is behind on Pairwise (0.79 vs 0.77-0.78) and PCA W2 (1.35 vs 1.34) by
128
+ 0.01-0.02 - i.e. by roughly the amount BBFlow's own two records differ from
129
+ each other (0.77 vs 0.78; 0.47 vs 0.48).
130
+ - Shuffled-condition collapse (Pairwise 0.79 -> 1.27) proves the condition
131
+ carries real information.
132
+ - NOBODY HAS EVER MEASURED THE SEED-TO-SEED VARIANCE of these numbers. The
133
+ user has refused multi-seed runs. So "we are 0.01 behind" is currently not
134
+ distinguishable from noise, and cannot be, under the current constraints.
135
+ A paired significance test over the 82 per-protein values from the EXISTING
136
+ saved runs would answer it at zero GPU cost, if the per-protein metric CSVs
137
+ still exist on the server. This was suggested and declined; it remains the
138
+ cheapest unexploited information in the project.
139
+
140
+ Upper bound reference (NOT deployable, oracle):
141
+ per-protein oracle scale selection gives Pairwise MAE 0.5583.
142
+ Best-scale distribution is bimodal (scale12: 31 proteins, scale30: 27),
143
+ length does not predict it, no deployable predictor was ever found.
144
+
145
+
146
+ ================================================================================
147
+ 4. THE CORE DIAGNOSIS (the reason this whole line exists)
148
+ ================================================================================
149
+
150
+ THE ARCHITECTURE
151
+ x_eq --> LatentEncoder --> modes U, prior q(c | x_eq)
152
+ |
153
+ sample c ~ q
154
+ |
155
+ (x_eq, c) --> BBFlow generator --> conformation
156
+ repeat 250x -----------------> ensemble --> official metrics
157
+
158
+ THE BUG IN THE OBJECTIVE (not a code bug - a design gap)
159
+ The existing losses:
160
+ local_cov_loss, cross_cov_loss, rmsf_loss
161
+ supervise the PRIOR's THEORETICAL covariance:
162
+ Sigma_prior = sum_k energy_k * U_k U_k^T ( = U E_q[cc^T] U^T )
163
+ This quantity contains NO GENERATOR PARAMETERS AT ALL.
164
+
165
+ The official metrics measure the GENERATOR's OUTPUT ensemble covariance:
166
+ Sigma_gen = Cov(x_1 ... x_250)
167
+
168
+ There was never a loss connecting the two. The generator hears c (verified:
169
+ condition injection works, FiLM adapters receive nonzero grad, signed paths
170
+ alive) but was never required to turn c into the correct ensemble statistics.
171
+
172
+ This single fact explains the entire history:
173
+ - probe/proxy metrics improve (they measure the prior)
174
+ - downstream stays flat (it measures the generator)
175
+ - more training on proxies makes downstream worse (30->60 pca_align)
176
+ - the generator UNDER-DISPERSES: contraction diagnostics measured
177
+ gen_amp_median/MD = 0.71-0.79, PC1 var/MD = 0.34-0.54
178
+ i.e. the generator systematically compresses the ensemble.
179
+
180
+ Plain statement: "the generator was never controlled at the ensemble level."
181
+
182
+ WHY THE MECHANISM'S SIGNAL DOESN'T SHOW UP IN THE OFFICIAL TABLE
183
+ The condition's information lives in cross-covariance / collective directional
184
+ structure (far cross_cov corr is the one metric that reliably improves). The
185
+ three official metrics are mostly amplitude/spread statistics that BBFlow
186
+ already does well. The improved dimension is largely orthogonal to what the
187
+ metrics reward. That is why proxies win and the table doesn't move.
188
+
189
+
190
+ ================================================================================
191
+ 5. WHAT WAS TRIED BEFORE AND FAILED (condensed - details in experiment_trace)
192
+ ================================================================================
193
+
194
+ - Long latent finetune (100ep, orth1/recon0): worse than official on Pairwise.
195
+ - PCA-align loss (lambda 0.1, 30ep): train proxies improve, held-out test82
196
+ mode-PCA alignment DROPS. Not a downstream win.
197
+ NOTE: even ON THE TRAINING SET, with a loss explicitly pushing it, the
198
+ energy-weighted overlap with MD top-2 PCs saturated at only ~0.22 (60ep
199
+ ~0.31). Learning MD principal DIRECTIONS from x_eq appears intrinsically
200
+ hard here. Also: pca_align uses oracle_modes as a training target, which
201
+ the "non-negotiable oracle policy" (section 12) appears to forbid. This
202
+ tension was never resolved.
203
+ - PCA-align 30 -> 60 epochs: proxies keep improving, downstream degrades.
204
+ - Global condition_scale sweep on the 60ep ckpt: no globally good scale exists.
205
+ Larger scale fixes the median but not the MAE; PCA W2 best near scale10.
206
+ - Per-protein oracle scale: strong upper bound (0.5583) but bimodal and no
207
+ inference-time predictor was found. Length does not explain the split.
208
+ - Condition cycle loss (lambda 0.05): internal targets improve, downstream
209
+ worse. MECHANISM: cycle forces each frame to equal sum_k c_k U_k exactly,
210
+ which CONTRACTS the ensemble and kills diversity. It is ANTAGONISTIC to the
211
+ current generator-response loss (one contracts, one wants correct
212
+ dispersion). KEEP lambda_condition_cycle = 0.0.
213
+ - q temperature (tau) scaling: improves far cross-cov, hurts Pairwise/PCA.
214
+ - fullcov variant: PCA improves, Pairwise breaks.
215
+
216
+ PATTERN: every local knob produces a seesaw - improve one metric, break
217
+ another. The trace explicitly warns against per-protein drilldowns as a
218
+ default next step; they consumed time without producing decisions.
219
+
220
+
221
+ ================================================================================
222
+ 6. THE CURRENT MECHANISM: generator-response covariance loss
223
+ ================================================================================
224
+
225
+ IDEA
226
+ Put a loss on the GENERATOR'S OWN OUTPUT response to the condition, cheaply,
227
+ without any 20-step rollout.
228
+
229
+ ANTITHETIC CENTRAL DIFFERENCE
230
+ For one protein, one noisy state, sample a zero-mean fluctuation of q:
231
+ delta = (c_sample - mu_bar) * delta_scale, c_sample ~ q,
232
+ mu_bar = softmax(mixture_logits) . mixture_mu (the mean of q)
233
+ Build two conditions and run the generator on both:
234
+ c_plus = mu_bar + delta
235
+ c_minus = mu_bar - delta
236
+ Take the one-step clean predictions (model_output["pred_trans"]), align both
237
+ to trans_equilibrium (Kabsch, same convention as the MD targets), and take:
238
+ d = ( align(pred(c_plus)) - align(pred(c_minus)) ) / 2
239
+
240
+ d[i] is the 3D displacement of residue i caused by this fluctuation. Because
241
+ +delta and -delta share the same background noisy state, subtracting cancels
242
+ everything not caused by c.
243
+
244
+ WHY IT IS STATISTICALLY VALID WITH FEW SAMPLES
245
+ To first order d = J*delta, so
246
+ E_delta[ d d^T ] = J Cov_q J^T = the generator's response covariance.
247
+ You NEVER reconstruct the 250-sample covariance. Each step contributes one
248
+ unbiased rank-1 sample and SGD averages over thousands of steps - exactly the
249
+ way flow matching learns a whole distribution one noisy sample at a time.
250
+ "8 vs 250" is a non-issue because nothing is estimated per-step.
251
+
252
+ IMPORTANT CORRECTION (this cost us an argument, get it right):
253
+ The above unbiasedness holds for RAW covariance matching (v1). It does NOT
254
+ hold for the NORMALIZED shape objective (v2), because C/tr(C) is NONLINEAR:
255
+ E[ C / tr(C) ] != E[C] / tr(E[C])
256
+ A single-delta rank-1 normalized outer product is a BIASED estimator of the
257
+ target normalized covariance. Therefore, under v2, going from 2 deltas to
258
+ 1 delta CHANGES THE OBJECTIVE - it is not merely a variance increase, and it
259
+ is not "free". DO NOT cut student deltas to 1 to save time.
260
+
261
+ WHY NORMALIZED SHAPE (v2 over v1)
262
+ Raw covariance matching lets the model take a shortcut: globally amplify the
263
+ response. That can improve PCA W2 while blowing up RMSF/Pairwise. v2 compares
264
+ SHAPE only:
265
+ C/tr(C) vs C_MD/tr(C_MD)
266
+ which is scale-invariant, so amplification cannot reduce the shape loss. It
267
+ forces the model to learn WHICH residues/directions move together.
268
+
269
+ WHY AN AMPLITUDE ANCHOR IS THEN REQUIRED
270
+ Shape normalization removes ALL amplitude constraint. Without an anchor the
271
+ response magnitude drifts freely. So a weak anchor pins the trace:
272
+ trace_anchor_loss = mean( log( tr(C) / tr(anchor) )^2 )
273
+ Current anchor target = tr(local_cov_MD), i.e. the MD ensemble's own trace.
274
+
275
+ COST
276
+ Extra forwards per step = 2 * num_deltas (= 4 with 2 deltas), all gradient
277
+ checkpointed. The condition is DETACHED, so gradients flow ONLY into the
278
+ generator - this deliberately isolates "make the generator honor the given
279
+ condition" from the prior/q fit. U and q are NOT trained by this loss.
280
+
281
+ APPLIED ONLY IN A NOISE BAND
282
+ Only samples with t in [GENERATOR_COV_T_MIN, GENERATOR_COV_T_MAX] = [0.1, 0.6]
283
+ contribute. CONVENTION: interpolant_bbflow.py does
284
+ trans_t = (1 - t)*noise + t*data
285
+ so t=1 is CLEAN and t=0 is PURE NOISE. "mid-high noise" = low-to-mid t.
286
+ The extra forwards run on the WHOLE batch every step regardless (out-of-band
287
+ samples get loss weight 0) - this is deliberate, to keep the DDP autograd
288
+ graph STATIC. Do not "optimize" this into a conditional skip without thinking
289
+ about DDP dynamic-graph errors.
290
+
291
+
292
+ ================================================================================
293
+ 7. CURRENT CODE: WHAT IS WHERE
294
+ ================================================================================
295
+
296
+ LINEAGE WARNING
297
+ The v1 implementation (single delta, raw covariance) was written by Claude and
298
+ has been ENTIRELY OVERWRITTEN by Codex's v2 rewrite. Do not look for v1 config
299
+ names (lambda_gen_local_cov, lambda_gen_rmsf, generator_cov_use_cross was v1
300
+ too). The md_trace fix (section 8) was applied on top of v2.
301
+
302
+ bbflow/models/latent.py
303
+ def generator_response_cov_loss(
304
+ self, response_deltas, res_mask, targets,
305
+ use_cross=False, sample_weight=None,
306
+ teacher_response_deltas=None, teacher_trace_anchor=None,
307
+ teacher_trace_denominator="teacher",
308
+ amplitude_anchor="teacher_trace")
309
+ - response_deltas has shape (S, B, N, 3), S = number of independent deltas.
310
+ - CRITICAL ORDER (do not break this):
311
+ C = mean_s( d_s d_s^T ) # combine across ALL deltas
312
+ trace_sample = tr(C)
313
+ C_norm = C / trace_sample # normalize ONCE, afterwards
314
+ loss = || C_norm - C_MD_norm ||^2 / denom
315
+ You must NOT compute a shape loss per delta and average them. Because the
316
+ normalization is nonlinear, mean_i( C_i/tr(C_i) ) != (sum_i C_i)/tr(sum_i C_i).
317
+ This invariant holds at EVERY chunking granularity, so chunking the forwards
318
+ is safe; splitting the loss is not.
319
+ - amplitude_anchor == "md_trace" -> anchor_trace = trace_target (MD's trace)
320
+ - amplitude_anchor == "teacher_trace" -> DEAD PATH, see section 8.
321
+ - Everything is wrapped in torch.autocast(enabled=False) and .float(), so the
322
+ covariance/trace/normalization math stays FP32 even under bf16-mixed. This
323
+ is why bf16-mixed is safe for this loss.
324
+
325
+ bbflow/models/bbflow_module.py
326
+ - _generator_response_cov_loss(...) : builds the deltas, the +/- conditions,
327
+ runs the chunked student forwards, optionally the teacher, calls the loss.
328
+ - _initial_generator_response_teacher() : deepcopy(self.model), eval(),
329
+ requires_grad_(False). ONLY reached when amplitude_anchor=="teacher_trace".
330
+ DO NOT RE-ENABLE. See section 8.
331
+ - _latent_group_z(): looks up motion_targets and stashes self._gen_cov_targets
332
+ - training_step(): calls the loss, adds gen_cov_loss into train_loss, and the
333
+ existing NaN guard covers it (NaN -> step skipped, 5 in a row -> raise).
334
+ - MD_EPOCH_SUMMARY_KEYS: the console per-epoch summary key list.
335
+
336
+ LOSS COMPOSITION (as actually assembled)
337
+ train_loss = official_loss (flow matching)
338
+ + lambda_shape * latent_regularizer (motion/q/orth - PRIOR side)
339
+ + condition_cycle_loss (currently 0)
340
+ + gen_cov_loss
341
+
342
+ gen_cov_loss = lambda_generator_cov * (
343
+ lambda_gen_local_shape * gen_local_shape_loss
344
+ + lambda_gen_cross_shape * gen_cross_shape_loss (if use_cross)
345
+ + lambda_gen_trace_anchor * gen_trace_anchor_loss )
346
+
347
+ METRIC NAME LANDMINE
348
+ `gen_trace_ratio_to_teacher` IS A MISNOMER. Since the md_trace fix it reports
349
+ tr(C_student) / tr(local_cov_MD)
350
+ It has nothing to do with a teacher any more. The name was never updated.
351
+ Read it as "generator response amplitude / MD amplitude". 1.0 = matched.
352
+
353
+
354
+ ================================================================================
355
+ 8. THE TEACHER BUG - THE MOST IMPORTANT THING IN THIS DOC
356
+ ================================================================================
357
+
358
+ WHAT v2 ORIGINALLY DID
359
+ It anchored the response amplitude to a "frozen teacher" =
360
+ copy.deepcopy(self.model) taken at training step 0, run under no_grad with the
361
+ same deltas.
362
+
363
+ WHY IT WAS CATASTROPHICALLY WRONG
364
+ The condition-injection adapters are ZERO-INITIALIZED on purpose, so that a
365
+ warm-started model initially reproduces vanilla BBFlow exactly:
366
+ bbflow/models/embedder.py:181-188
367
+ nn.init.zeros_ on z_node_adapter[-1], z_edge_adapter[-1],
368
+ disp_node_adapter[-1], disp_edge_adapter[-1]
369
+ (both weight and bias)
370
+ bbflow/models/bbflow_model.py:107-108
371
+ nn.init.zeros_ on film_mlp[-1] (weight and bias)
372
+
373
+ Therefore at step 0 the model's response to c is IDENTICALLY ZERO. The teacher
374
+ is a frozen snapshot of exactly that state, so the teacher's response to c is
375
+ zero FOREVER. Then:
376
+ teacher_trace -> clamp_min(1e-8) -> pinned at the floor
377
+ trace_ratio = student_trace / 1e-8 -> ~1e6
378
+ anchor loss = log(ratio)^2, minimized at student_trace = 1e-8
379
+ => THE ANCHOR WAS ACTIVELY TRAINING THE STUDENT'S RESPONSE TO ZERO.
380
+ A model that ignores c cannot serve as a calibration reference for a response
381
+ to c. The anchor's purpose was inverted.
382
+
383
+ THE EVIDENCE (how it was caught - reuse this technique)
384
+ epoch 0: trace_mean=0.03611, ratio=4.363e6
385
+ epoch 1: trace_mean=0.004766, ratio=5.438e5
386
+ trace ratio between epochs: 0.03611/0.004766 = 7.58
387
+ metric ratio between epochs: 4.363e6/5.438e5 = 8.02
388
+ The two agree => the DENOMINATOR IS A CONSTANT => teacher_trace is pinned at
389
+ the 1e-8 clamp floor. Also 0.03611/1e-8 = 3.6e6, the right order of magnitude.
390
+ Meanwhile gen_response_abs_mean was dying: 0.001946 -> 0.0006519.
391
+
392
+ THE FIX (already applied, in the code now)
393
+ New config: generator_cov_amplitude_anchor, DEFAULT "md_trace".
394
+ "md_trace" -> anchor_trace = trace_target = tr(local_cov_MD).
395
+ Physically real, nonzero, needs NO teacher and NO extra
396
+ forwards (trace_target is already computed for the shape
397
+ normalization).
398
+ "teacher_trace" -> the old, broken path. Retained as dead code.
399
+ generator_cov_initial_trace_anchor=false sets amplitude_anchor="none".
400
+ latent.py carries a comment recording this diagnosis at the md_trace branch.
401
+
402
+ RULE
403
+ DO NOT set generator_cov_amplitude_anchor=teacher_trace. If you ever want a
404
+ teacher-style anchor, the teacher must be a checkpoint whose adapters are
405
+ ALREADY TRAINED (e.g. A30), not a step-0 snapshot.
406
+
407
+
408
+ ================================================================================
409
+ 9. VALIDATION RUN - EVIDENCE THE MECHANISM WORKS
410
+ ================================================================================
411
+
412
+ RUN: bbflow_base_gen_cov_v2_mdtrace_k8_10ep_3gpu_120k_bs10_20260717_003351
413
+ CONFIG: use_cross=false, lambda_gen_trace_anchor=0.05, md_trace anchor,
414
+ bf16-mixed, 120000/bs10, 3 GPU, warm start from official BBFlow.
415
+ KILLED at ~epoch 5 (validation achieved; config cannot win PCA W2).
416
+
417
+ metric ep0 ep1 ep2 ep3 ep4 ep5
418
+ ---------------------- ------ ------ ------ ------ ------ ------
419
+ gen_trace_ratio(vs MD) 1.044 1.077 1.061 0.655 0.650 0.632
420
+ gen_response_abs_mean 0.512 0.593 0.554 0.460 0.453 0.478
421
+ gen_local_shape_loss 0.706 0.654 0.637 0.563 0.532 0.516
422
+ gen_trace_anchor_loss 1.168 0.658 0.656 0.467 0.325 0.299
423
+ official_loss - 0.760 0.477 0.473 0.442 0.427
424
+ rmsf_loss 0.487 0.488 0.438 0.428 0.429 0.439
425
+ cross_cov_far_corr 0.013 0.063 0.119 0.151 0.178 0.190
426
+ mode_gram_condition 2.3e5 1.8e5 8146 819.9 15.29 6.307
427
+ mode_max_cosine_abs 0.907 0.968 0.809 0.547 0.459 0.375
428
+
429
+ VERDICT: THE MECHANISM IS ENGAGED. All four validation criteria passed:
430
+ - ratio starts at ~1.04 (the 4.36e6 pathology is gone)
431
+ - gen_response_abs_mean stable ~0.45-0.6 (previously dying to 0.0006)
432
+ - gen_local_shape_loss MONOTONICALLY DECREASING 0.706 -> 0.516
433
+ => the generator IS learning to match MD's covariance SHAPE
434
+ - official_loss healthy 0.760 -> 0.427 (the new loss did not wreck training)
435
+ Also good: mode basis conditioning collapsed from 2.3e5 to 6.3, modes becoming
436
+ orthogonal (max_cosine 0.907 -> 0.375), far cross-cov corr rising 0.013 -> 0.190.
437
+
438
+
439
+ ================================================================================
440
+ 10. THE KNOWN OPEN PROBLEM: AMPLITUDE DRIFT
441
+ ================================================================================
442
+
443
+ OBSERVATION
444
+ gen_trace_ratio drifts 1.044 -> 0.632 and is still falling. The generator's
445
+ response amplitude is only ~63% of MD's -> UNDER-DISPERSED BY ~37%.
446
+
447
+ WHY
448
+ - gen_local_shape_loss (lambda 1.0) is SCALE-INVARIANT: it constrains nothing
449
+ about amplitude.
450
+ - gen_trace_anchor_loss is the ONLY amplitude constraint, at lambda 0.05 -
451
+ 20x weaker.
452
+ - official_loss / motion_loss structurally PREFER contraction (predicting the
453
+ conditional mean is the safe play for a single-frame objective).
454
+ => the weak anchor loses; amplitude sinks.
455
+
456
+ WHY IT MATTERS
457
+ This is exactly the project's known failure mode: contraction diagnostics
458
+ measured gen_amp/MD = 0.71-0.79 and PC1 var/MD = 0.34-0.54. Under-dispersion
459
+ directly damages Pairwise RMSD (spread too small) and PCA W2.
460
+
461
+ A TRAP IN READING THE METRICS (do not misdiagnose this)
462
+ gen_trace_anchor_loss DECREASES (1.168 -> 0.299) WHILE the ratio drifts AWAY
463
+ from 1. That is not a contradiction:
464
+ - the metric is mean(ratio)
465
+ - the loss is mean(log(ratio)^2)
466
+ ep0: log(1.044)^2 = 0.002, but loss = 1.168 => almost ALL of it is spread.
467
+ RMS(log) ~ 1.08 => per-sample ratios spanned roughly [0.34, 2.9] and
468
+ merely AVERAGED to 1.04.
469
+ ep5: log(0.632)^2 = 0.211, loss = 0.299 => only 0.088 is spread.
470
+ So the anchor IS working - it tightened the distribution - but it tightened
471
+ around the WRONG CENTER (0.63 instead of 1.0).
472
+
473
+ THE FIX (to be tested in the next run)
474
+ Raise lambda_gen_trace_anchor from 0.05 to 0.3.
475
+ Watch: if ratio still sinks below ~0.8 by epoch 3 -> raise to 0.5-1.0.
476
+ if official_loss starts climbing / NaNs appear -> drop to 0.15.
477
+
478
+ A SUBTLETY WORTH KNOWING (unresolved, probably benign)
479
+ Anchoring the c-INDUCED response trace to MD's FULL trace implicitly asks c
480
+ alone to explain all of MD's variance, ignoring that at inference the flow's
481
+ own noise (different x_0 per sample) also contributes spread. Strictly, the
482
+ ideal target may be < 1.0. BUT empirically the full generated ensemble is
483
+ UNDER-dispersed (0.7-0.8 of MD), so pushing up is the right direction. If a
484
+ future run over-disperses, lower the anchor target to ~0.8 rather than
485
+ abandoning the anchor.
486
+
487
+
488
+ ================================================================================
489
+ 11. WHAT IS RUNNING / THE NEXT RUN
490
+ ================================================================================
491
+
492
+ STATUS AS OF 2026-07-17: the validation run was KILLED at ~epoch 5. Nothing is
493
+ training. epoch:005.ckpt from that run still exists and could be evaluated
494
+ downstream on idle GPUs for a free read on local-shape-only (low priority - it
495
+ targets RMSF, the metric already won).
496
+
497
+ NEXT RUN = validation config + EXACTLY TWO CHANGES:
498
+ GENERATOR_COV_USE_CROSS : false -> true (the EXPERIMENT: cross shape is
499
+ the only component that can
500
+ move PCA W2)
501
+ LAMBDA_GEN_TRACE_ANCHOR : 0.05 -> 0.3 (a BUG FIX for section 10)
502
+
503
+ Two changes at once is justified here: one is the experiment, one is a fix for a
504
+ measured defect. Running cross with a provably sinking amplitude would waste the
505
+ run.
506
+
507
+ COMMAND:
508
+
509
+ pkill -u wangyusong -9 -f experiments/train.py; sleep 3
510
+
511
+ cd ~/LD-FPG-main/bbflow_base
512
+ export PYTHONPATH=$PWD:${PYTHONPATH:-}
513
+
514
+ ATLAS_REPRO_ROOT=/data/shared/wangyusong/atals/bbflow_official_reproduction \
515
+ RUN_DIR=/data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_$(date +%Y%m%d_%H%M%S) \
516
+ FINGERPRINT_CACHE=/home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt \
517
+ GPU_IDS=0,1,2 NUM_DEVICES=3 MAX_EPOCHS=10 \
518
+ CHECKPOINT_EVERY_N_EPOCHS=1 CHECKPOINT_SAVE_LAST=true CHECKPOINT_SAVE_TOP_K=-1 \
519
+ PRECISION=bf16-mixed MAX_NUM_RES_SQUARED=120000 MAX_BATCH_SIZE=10 \
520
+ ENERGY_FROM_Q=true ENERGY_FROM_Q_FULL_COV=false Q_DETACH_SHARED_ENCODER=false \
521
+ LAMBDA_MOTION=1.0 LAMBDA_Q=1.0 LAMBDA_MODE_ORTH=1.0 LAMBDA_MODE_RECON=0.0 LAMBDA_PCA_ALIGN=0.0 \
522
+ LAMBDA_CONDITION_CYCLE=0.0 \
523
+ LAMBDA_GENERATOR_COV=1.0 GENERATOR_COV_USE_CROSS=true \
524
+ GENERATOR_COV_T_MIN=0.1 GENERATOR_COV_T_MAX=0.6 GENERATOR_COV_DELTA_SCALE=1.0 \
525
+ GENERATOR_COV_NUM_DELTAS=2 GENERATOR_COV_STUDENT_CHUNK_DELTAS=1 \
526
+ GENERATOR_COV_CHECKPOINT=true GENERATOR_COV_INITIAL_TRACE_ANCHOR=true \
527
+ LAMBDA_GEN_LOCAL_SHAPE=1.0 LAMBDA_GEN_CROSS_SHAPE=1.0 LAMBDA_GEN_TRACE_ANCHOR=0.3 \
528
+ bash base_stages/00_train_final_mog_ddp.sh
529
+
530
+ POST-LAUNCH AUDIT (mandatory - a stray value already cost one run):
531
+ RUN_DIR=$(ls -dt .../bbflow_base_gen_cov_v2_mdtrace_cross_* | head -1)
532
+ grep -nE "generator_cov_use_cross|lambda_gen_trace_anchor|lambda_condition_cycle|precision" "$RUN_DIR/config.yaml"
533
+ MUST SEE: use_cross: true / trace_anchor: 0.3 / condition_cycle: 0.0 /
534
+ precision: bf16-mixed
535
+
536
+ WATCH IN THE FIRST FEW EPOCHS:
537
+ 1. gen_cross_shape_loss APPEARS and DECREASES. If the key never appears,
538
+ use_cross did not take effect.
539
+ 2. gen_trace_ratio_to_teacher (= tr(C)/tr(MD)) holds ~0.9-1.0, does not sink
540
+ to 0.6 again.
541
+ 3. official_loss keeps falling smoothly (0.76 -> 0.43 last run).
542
+
543
+ DECISION RULE: if by epoch 3 the ratio is holding and cross shape is falling,
544
+ let it run to 10. Otherwise stop and adjust the anchor rather than burning 20h.
545
+
546
+
547
+ ================================================================================
548
+ 12. THE ORACLE POLICY (verbatim intent, from the trace, 2026-07-09)
549
+ ================================================================================
550
+ - Oracle information is forbidden in training, checkpoint selection,
551
+ inference, calibration, routing, gating, or any deployable component.
552
+ - This includes test/validation MD frames, projected per-frame oracle
553
+ coefficients, oracle PCA modes/energies, oracle best scales, and any
554
+ feature derived from the target ensemble.
555
+ - Oracle quantities may only be used AFTER generation as offline diagnostic
556
+ labels or upper-bound analyses.
557
+
558
+ UNRESOLVED TENSION: the policy text explicitly lists "oracle PCA modes/
559
+ energies" as forbidden from influencing model parameters, yet
560
+ pca_alignment_loss trains on oracle_modes. Whoever picks this up should get a
561
+ ruling from the user before using oracle_modes as a training target.
562
+
563
+ GOOD NEWS: the CURRENT generator-response line uses NO oracle quantities. It
564
+ supervises against local_cov / cross_cov / rmsf, which are the ordinary MD
565
+ targets the core method has always used (computed from each TRAINING
566
+ protein's own MD). Keep it that way - it is a genuine advantage of this
567
+ design over pca_align.
568
+
569
+
570
+ ================================================================================
571
+ 13. INFRASTRUCTURE: THE OOM AND SPEED SAGA (so you don't repeat it)
572
+ ================================================================================
573
+
574
+ THE MEMORY WALL
575
+ Version A already ran at ~76 GB / 79 GB. There were only ~3 GB of headroom.
576
+ Adding ANY extra forwards OOMs. Two runs were destroyed learning this.
577
+ OOM site: gafl/models/gafl/cfa.py, the attention-like tensor
578
+ `a[..., None, :, :, None]` (a 7.85 GiB single allocation). GAFL's CFA
579
+ materializes a large intermediate; it is memory-bandwidth bound.
580
+
581
+ WHAT ACTUALLY FIXED IT (all four stacked)
582
+ 1. PRECISION=bf16-mixed (was 32-true - on an H100 that was throwing away
583
+ more than half the tensor-core throughput AND doubling activations).
584
+ The loss math is FP32-guarded, so this is safe.
585
+ 2. 2+2 chunking: merge ONE delta's +/- into a single 2x-batch forward and do
586
+ 2 such calls, instead of merging all 4 into one 4x-batch call. Halves the
587
+ attention peak. The statistical target is UNCHANGED (see section 7 - the
588
+ d_s are identical regardless of how the forwards are batched; only the
589
+ "combine C then normalize once" invariant matters).
590
+ 3. GENERATOR_COV_CHECKPOINT=true: gradient-checkpoint the extra forwards
591
+ (activations recomputed in backward instead of stored).
592
+ 4. MAX_NUM_RES_SQUARED 400000 -> 120000, MAX_BATCH_SIZE 32 -> 10.
593
+
594
+ MEMORY MEASUREMENT RULE (learned painfully)
595
+ A spot reading of 16 GB was a TROUGH, not the peak; the peak was ~70/80 GB.
596
+ Batch composition varies hugely with protein size. ALWAYS measure the peak:
597
+ nvidia-smi --query-gpu=memory.used --format=csv -l 5
598
+ over several minutes before concluding there is headroom.
599
+
600
+ SPEED FACTS
601
+ ~1h55m per epoch, 3147 batches/rank, ~0.44 it/s, 3 GPUs, 10 epochs ~19h.
602
+ examples_per_second only ~1.4-3.3 for a 19.8M-parameter model on 3 H100s -
603
+ the GPUs are STARVED (tiny batch + CFA memory-bandwidth bound), not
604
+ compute-limited.
605
+ Removing the teacher gave only ~15% (0.38 -> 0.44 it/s), because with
606
+ teacher_num_deltas=1 + reuse_student_delta the teacher was only ONE merged
607
+ 2x-batch no_grad call, not four forwards.
608
+
609
+ REMAINING SPEED LEVERS (in order)
610
+ 1. GENERATOR_COV_CHECKPOINT=false - saves recomputing 4 student forwards.
611
+ ONLY if the measured PEAK allows it. The teacher's removal freed a whole
612
+ 19.2M-param deepcopy plus its activations, so this may now fit. MEASURE
613
+ FIRST.
614
+ 2. Raise batch back up toward A's 400000/32 if peak allows - improves H100
615
+ utilization AND restores a cleaner comparison to A (the reduced batch is
616
+ currently a confound vs A).
617
+ 3. Remove NCCL_P2P_DISABLE=1 if it is set and P2P is healthy (it forces
618
+ allreduce through host memory).
619
+ 4. CFA query-dimension chunking to re-enable full 4x merging. This is a real
620
+ project (patching third-party gafl attention). Only worth it if the method
621
+ is validated and many runs are needed.
622
+
623
+ DDP NOTES
624
+ strategy: ddp (Lightning default => find_unused_parameters=False,
625
+ static_graph=False). Multiple forwards + a SINGLE backward is fine. The graph
626
+ is kept static on purpose (extra forwards run every step when enabled). Do not
627
+ make the extra forwards conditional per-step without handling DDP dynamic
628
+ graphs. If you ever see "mark a variable ready only once", suspect
629
+ checkpointing interactions.
630
+
631
+
632
+ ================================================================================
633
+ 14. HARD-WON PROCESS RULES
634
+ ================================================================================
635
+ 1. NEVER write a path/command from memory. Read the script or
636
+ ${RUN_DIR}/config.yaml first. This rule exists because it was broken
637
+ repeatedly (02_sample_test.sh ignores OUTPUT_DIR; 03_evaluate.sh needs
638
+ ATLAS_VIEW_ROOT; a hydra +ckpt_path override was silently ignored and a
639
+ "resume" started from scratch).
640
+ 2. config.yaml IS THE TRUTH. A stray LAMBDA_CONDITION_CYCLE=0.05 slipped into
641
+ a v2 command and was only caught by grepping config.yaml. Audit every run
642
+ before letting it burn hours.
643
+ 3. VERIFY RESUME by the loaded epoch/global_step in the first log lines, never
644
+ by the output directory name.
645
+ 4. THE LOCAL MACHINE CANNOT RUN ANYTHING. No python, no torch. Code you write
646
+ is unverified beyond careful reading. Say so plainly; do not hand over a
647
+ large untested training change and imply it is safe.
648
+ 5. Do not turn on several loss terms at once - attribution becomes impossible.
649
+ The local-shape-then-cross staging exists for this reason.
650
+ 6. Do not propose per-protein drilldowns as a default next step (the trace
651
+ explicitly bans this; they burned time without producing decisions).
652
+ 7. Watch the FIRST ~50 steps of any new run (gen_* finite and nonzero,
653
+ response nonzero). That costs nothing and catches silent no-ops.
654
+ 8. When a metric looks impossible (e.g. ratio = 4e6), check whether a
655
+ denominator is pinned at a clamp floor. Cross-check by seeing whether the
656
+ metric scales EXACTLY with the numerator across epochs.
657
+ 9. NEVER background a command with a bare `cmd &` in the interactive shell
658
+ when the user has to watch it. Bash job control prints `[1] <PID>` /
659
+ `[2] <PID>` the instant the job is launched, and that PID noise is the
660
+ one thing the user has said outright they never want to see. If
661
+ something must run in parallel, give it its own tmux window
662
+ (`tmux new-window` + `tmux send-keys`, see the K64/K4 inference launch
663
+ commands earlier in this doc's history for the pattern) so output
664
+ streams live to a pane instead of `cmd > log 2>&1 &` in the current
665
+ shell. If parallelism isn't actually needed, just run it in the
666
+ foreground with no `&` at all - simplest and zero risk of this.
667
+ 10. tmux multi-window parallel launch (`for GPU in 0 1 2; do tmux new-window
668
+ ...; tmux send-keys ...; done`) is NOT reliably safe against races.
669
+ Two failure modes hit in the same session: (a) `tmux new-window -t
670
+ "$SESSION"` with no trailing colon resolves to the CURRENT window's
671
+ index and fails with "create window failed: index N in use" if that
672
+ index is occupied - fix is `-t "$SESSION:"` (trailing colon = next free
673
+ index). (b) even with that fix, one run produced two windows whose
674
+ `tmux pipe-pane` log files ended up byte-identical (same "Saving
675
+ results to" path, same finish timestamp to the millisecond) - one
676
+ epoch's inference silently never ran while another epoch's job was
677
+ captured twice. Root cause not fully isolated (suspected race between
678
+ back-to-back `new-window`/`pipe-pane`/`send-keys` calls with no
679
+ confirmation step in between). RULE: after launching N parallel tmux
680
+ windows this way, verify each window's log independently shows a
681
+ DIFFERENT "Saving results to" path before trusting any of them - do not
682
+ assume N windows in == N distinct jobs out.
683
+
684
+
685
+ ================================================================================
686
+ 15. OPEN QUESTIONS / UNRESOLVED RISKS
687
+ ================================================================================
688
+ 1. ONE-STEP vs 20-STEP GAP. The response uses pred_trans, a single-step clean
689
+ prediction, not the 20-step ODE sampler's output. This is a known bias. The
690
+ defence is that a biased GENERATOR-AWARE signal beats the previous
691
+ GENERATOR-BLIND prior loss (whose bias was 100%). Unquantified.
692
+ 2. FIRST-ORDER / LINEARITY. +/-delta captures only the linear response. It can
693
+ be self-checked cheaply via the second difference
694
+ pred(+d)+pred(-d)-2*pred(0): small => linear regime holds. NEVER MEASURED.
695
+ Would cost one extra forward.
696
+ 3. c-INDUCED vs TOTAL VARIANCE (section 10 subtlety).
697
+ 4. NO DOWNSTREAM NUMBER EXISTS for ANY generator-response checkpoint. The
698
+ whole line is still validated only by training-side metrics. The first real
699
+ read must come from reproduction/02_sample_test.sh + 03_evaluate.sh.
700
+ 5. CROSS SHAPE IS UNTESTED. use_cross=true has never actually run. It is the
701
+ only component that can move PCA W2, and it is also the highest-variance,
702
+ N x N term - historically the seesaw's favourite.
703
+ 6. SIGNIFICANCE IS UNMEASURED (section 3). The 0.01-0.02 gaps may be noise.
704
+ 7. CACHE PATH DISCREPANCY (section 2) - /home/... vs ${REPRO}/... may not be
705
+ the same file as A used. Verify before claiming a clean A-vs-A+loss
706
+ ablation.
707
+ 8. BATCH SIZE CONFOUND. The current runs use 120000/10 while A used 400000/32.
708
+ Strictly this is not a clean ablation against A. Restore if memory permits.
709
+
710
+
711
+ ================================================================================
712
+ 16. IMMEDIATE NEXT STEPS
713
+ ================================================================================
714
+ 1. Launch the cross+anchor run (section 11). Audit config.yaml immediately.
715
+ 2. At epoch 0-1, confirm gen_cross_shape_loss exists and falls, and that the
716
+ ratio holds near 0.9-1.0. If not, stop and fix the anchor weight rather
717
+ than running 10 epochs.
718
+ 3. First real deliverable: take a checkpoint (epoch 4 or later) through
719
+ 02_sample_test.sh (250 samples, CONDITION_MODE=real) and 03_evaluate.sh,
720
+ and put the four official numbers next to the section 3 scoreboard. THIS
721
+ HAS NEVER BEEN DONE FOR THIS MECHANISM. Everything so far is training-side.
722
+ 4. Only after a downstream number exists should anyone invest in CFA tiling,
723
+ batch restoration, or further loss engineering.
724
+ 5. If the downstream number is flat: the honest options are (a) the one-step
725
+ proxy is too weak and a real ensemble-level objective is needed (expensive,
726
+ previously rejected), or (b) revisit whether the official metrics can
727
+ measure what this method improves at all (section 4, last paragraph).
728
+ ================================================================================
729
+
730
+
731
+ ================================================================================
732
+ 17. G-CALIBRATION + DIVERGENCE ROOT CAUSE + DIRECTION UPDATE (2026-07-18/19)
733
+ ================================================================================
734
+
735
+ WHERE A30 ACTUALLY STANDS (do not understate this again)
736
+ A30 = bbflow_base_energy_from_q_diag_orth1_recon0_30ep. Full 250-sample:
737
+ RMSF r 0.89 | RMSF MAE 0.45 | Pairwise 0.79 | PCA W2 1.35.
738
+ - It WINS RMSF MAE (0.45 vs 0.47-0.48, real repeated), TIES RMSF r, and is
739
+ within BBFlow's own record-to-record noise on Pairwise/PCA W2 (0.01-0.02).
740
+ - SHUFFLED-condition control: Pairwise 0.79->1.27, PCA W2 1.35->1.51. So the
741
+ condition carries real, protein-specific information. A30 is a genuine
742
+ partial success, NOT "= BBFlow". The missing piece is a BROAD win (also beat
743
+ Pairwise AND PCA W2), which A30's generator-BLIND prior supervision cannot
744
+ reach - it sits on a documented seesaw (push PCA W2, lose Pairwise).
745
+
746
+ WHAT THE CURRENT LINE CHANGES vs A30
747
+ - generator-BLIND -> generator-AWARE: instead of supervising the prior
748
+ covariance, perturb c by +/-delta and supervise the GENERATOR's actual
749
+ response covariance. Directly targets the generator output structure (PCA
750
+ W2), the thing A30 structurally cannot move.
751
+ - G-calibration: measure G = T_full/T_1step where T_full is the c-response
752
+ trace on the REAL sampler (shared prior noise x0, full linspace(min_t,1,20)
753
+ grid, no_grad), then anchor the single-step response to md_trace/G. Fixes the
754
+ single-step-vs-20-step amplitude gap (measured G ~6.5-10x, i.e. the old
755
+ single-step anchor over-shot ~6-10x -> that was the source of the RMSF-4.6
756
+ over-dispersion, NOT "unfrozen backbone").
757
+
758
+ BUGS FOUND AND FIXED THIS ROUND (all in the crash/over-disperse path)
759
+ - teacher anchor trained response to 0 -> replaced with md_trace reference.
760
+ - single-step vs 20-step 6.5x miscalibration -> G-calibration (rollout T_full
761
+ rewritten to start from shared prior noise x0 over the full grid; Codex's
762
+ first cut wrongly started from the training trans_t over 2 coarse steps).
763
+ - relative (LM) ridge in project_displacement_lstsq (absolute 1e-4 ridge was
764
+ swallowed in fp32 -> singular solve crash).
765
+ - THE DIVERGENCE ROOT CAUSE: mode normalization `u_global / mode_norm`
766
+ (latent.py ~469 and ~552) had NO stop-gradient. Backprop carries a
767
+ 1/mode_norm^2 term; once a mode collapses (norm -> the eps floor 1e-3) that
768
+ gradient explodes ~1e6x, burns the shared encoder to NaN (mixture logits NaN
769
+ -> Categorical crash at epoch 3). A positive feedback: shape loss nudges
770
+ modes collinear -> normalization amplifies the collapsed-mode gradient ->
771
+ more collapse. mode_orth (lambda 1) cannot beat a 1e6x amplified gradient.
772
+ FIX: detach mode_norm in both normalizations (forward identical, kills the
773
+ 1/c^2 path) + raise mode_norm_eps 1e-6 -> 1e-4. This is a real defect fix,
774
+ NOT gradient clipping (clipping would mask the divergence, not cure it).
775
+
776
+ KEY DIRECTION UPDATE - RECONSIDER FREEZING
777
+ - Freezing the base was introduced to stop the cross-run over-dispersion. But
778
+ that over-dispersion was really the AMPLITUDE miscalibration, which G-cal now
779
+ fixes. A30 ran UNFROZEN and was stable + good, so "unfrozen" was never the
780
+ cause.
781
+ - Freezing also introduced the ADDITIVE CEILING: a frozen base can only ADD
782
+ motion, not REDISTRIBUTE it, and PCA W2 needs redistribution. So freezing
783
+ fights the actual goal.
784
+ - RECOMMENDED next run: UNFROZEN + G-cal + generator-aware response + anchor
785
+ warmup (0->target over ~3 epochs), NO gradient clipping (the mode_norm fix is
786
+ the real fix). This keeps A30's redistribution ability and adds generator-
787
+ aware targeting with the amplitude now calibrated. Watch official_loss (must
788
+ stay ~0.85, not rise = backbone degrading), mode_max_cosine_abs (<0.9),
789
+ cross_cov_far_corr (up = PCA proxy moving).
790
+ - Console epoch log was trimmed (bbflow_module.py on_train_epoch_end) to loss +
791
+ 5 tagged watch metrics, one per line. Full metrics remain in
792
+ latent_train_epoch_metrics.csv.
793
+
794
+ DECISION RULE
795
+ - Next clean run's downstream (250 samples, real condition) vs A30/BBFlow:
796
+ - PCA W2 moves below 1.34 WITHOUT losing Pairwise -> generator-aware breaks
797
+ the seesaw; push it (possibly toward a fully differentiable few-step
798
+ rollout objective on the whole ensemble = the only form that can truly
799
+ force redistribution).
800
+ - PCA W2 flat / seesaw persists -> the additive/response-shaping family is
801
+ exhausted; A30 remains the best banked result and the only remaining bet is
802
+ the differentiable rollout objective, not more anchor/scale tuning.
803
+ ================================================================================
804
+
805
+
806
+ ================================================================================
807
+ 18. ENDPOINT COVARIANCE TRANSPORT ROUTE (2026-07-19)
808
+ ================================================================================
809
+
810
+ WHY THIS ROUTE EXISTS
811
+ The additive / single-step generator-response family kept falling into the same
812
+ two endpoints:
813
+ - unfrozen/additive response -> over-dispersed endpoint ensembles;
814
+ - frozen/weak response -> inert, approximately BBFlow.
815
+
816
+ The new route does NOT retrain the generator and does NOT approximate 20-step
817
+ dynamics with fewer steps. It starts after true 20-step BBFlow sampling has
818
+ already produced endpoint structures. It then applies a cheap endpoint-level
819
+ covariance transport:
820
+
821
+ base stream : official BBFlow, eq -> individual endpoint frames;
822
+ ensemble stream : low-rank learned/oracle correlation structure, applied as
823
+ an endpoint redistribution transform.
824
+
825
+ The key constraint is marginal preservation:
826
+
827
+ C* = D_B^1/2 [(1-lambda) R_B + lambda R_target] D_B^1/2
828
+
829
+ D_B is the diagonal variance of the BBFlow endpoint ensemble. Therefore the
830
+ transform is intended to preserve BBFlow's per-coordinate fluctuation scale and
831
+ total trace while changing only correlation/PCA structure. This is the first
832
+ cheap route that directly acts on real 20-step endpoints and can redistribute
833
+ variance instead of adding extra variance.
834
+
835
+ IMPLEMENTED FILES
836
+ 1. scripts/covariance_transport_batch.py
837
+ - Batch transport for a standard ensemble directory.
838
+ - Inputs:
839
+ --ensemble_dir existing BBFlow sampled endpoint directory
840
+ --atlas_root ATLAS MD root with <name>/<name>.pdb and R1/R2/R3 xtc
841
+ --test_csv test CSV, normally dataset_csv/test/ATLAS_test.csv
842
+ --out_dir output directory with <name>/sampled_conformations.pdb
843
+ --mode oracle or a30
844
+ --lam global correlation mixing coefficient
845
+ - Output is CA-only multi-model sampled_conformations.pdb. This is enough
846
+ for the standard RMSF / Pairwise / PCA-W2 path because evaluation slices
847
+ both reference and model to CA for those metrics. Do NOT use CA-only output
848
+ to claim full backbone geometry quality.
849
+ - Uses sample-space whitening/coloring, not dense 3N x 3N eigendecomposition.
850
+ This keeps the cost bounded by the generated ensemble rank.
851
+
852
+ 2. scripts/export_condition_modes.py
853
+ - Exports A30 learned condition modes from a checkpoint:
854
+ <modes_dir>/<pdb_name>.npy with shape [N,K,3].
855
+ - Needed only for --mode a30. Oracle transport does not depend on A30.
856
+
857
+ DISCIPLINED EXECUTION ORDER
858
+ Step 1: ORACLE transport first.
859
+ Purpose: test whether the transport mechanism itself can improve PCA-W2 while
860
+ keeping RMSF/Pairwise clean. This separates "transport is flawed" from "A30
861
+ modes are not good enough".
862
+
863
+ Step 2: Only if oracle is clean, export A30 modes and run A30 transport.
864
+ Purpose: measure how much of the oracle gain the learned A30 mode subspace can
865
+ realize. A30 mode-PC overlap on test82 was only around 0.4, so expected gain is
866
+ small, not transformational.
867
+
868
+ Step 3: Evaluate with reproduction/03_evaluate.sh.
869
+ Required checks:
870
+ - RMSF MAE must not regress vs BBFlow/A30.
871
+ - Pairwise MAE must not regress.
872
+ - PCA W2 must improve below BBFlow's 1.34 to count as useful.
873
+ - If possible, add a separate structure-quality check before any paper claim,
874
+ because CA-only transport does not validate N/C/O geometry.
875
+
876
+ SERVER COMMAND TEMPLATE - ORACLE TRANSPORT
877
+ cd ~/LD-FPG-main/bbflow_base
878
+ export PYTHONPATH=$PWD:${PYTHONPATH:-}
879
+
880
+ REPRO_ROOT=/data/shared/wangyusong/atals/bbflow_official_reproduction
881
+ ENSEMBLE_DIR=$REPRO_ROOT/inference/checkpoints/<official_or_bbflow_ensemble_dir>
882
+ OUT_DIR=$REPRO_ROOT/inference/cov_transport_oracle_lam0p50
883
+
884
+ python scripts/covariance_transport_batch.py \
885
+ --ensemble_dir "$ENSEMBLE_DIR" \
886
+ --atlas_root "$REPRO_ROOT/datasets/ATLAS" \
887
+ --test_csv "$REPRO_ROOT/dataset_csv/test/ATLAS_test.csv" \
888
+ --out_dir "$OUT_DIR" \
889
+ --mode oracle \
890
+ --lam 0.50 \
891
+ --md_stride 1 \
892
+ --overwrite
893
+
894
+ ENSEMBLE_DIR="$OUT_DIR" \
895
+ METRICS_DIR="$REPRO_ROOT/metrics/cov_transport_oracle_lam0p50" \
896
+ METHOD_NAME="BBFlow-oracle-cov-transport-lam0p50" \
897
+ ATLAS_VIEW_ROOT="$REPRO_ROOT/datasets/ATLAS" \
898
+ TEST_CSV="$REPRO_ROOT/dataset_csv/test/ATLAS_test.csv" \
899
+ NUM_WORKERS=8 \
900
+ bash reproduction/03_evaluate.sh
901
+
902
+ SERVER COMMAND TEMPLATE - A30 MODE TRANSPORT
903
+ cd ~/LD-FPG-main/bbflow_base
904
+ export PYTHONPATH=$PWD:${PYTHONPATH:-}
905
+
906
+ REPRO_ROOT=/data/shared/wangyusong/atals/bbflow_official_reproduction
907
+ A30_CKPT=<path_to_A30_checkpoint>
908
+ MODES_DIR=$REPRO_ROOT/diagnostics/a30_condition_modes_test82
909
+ ENSEMBLE_DIR=$REPRO_ROOT/inference/checkpoints/<official_or_bbflow_ensemble_dir>
910
+ OUT_DIR=$REPRO_ROOT/inference/cov_transport_a30_lam0p50
911
+
912
+ python scripts/export_condition_modes.py \
913
+ --ckpt_path "$A30_CKPT" \
914
+ --csv_path "$REPRO_ROOT/dataset_csv/test/ATLAS_test.csv" \
915
+ --output_dir "$MODES_DIR" \
916
+ --overwrite
917
+
918
+ python scripts/covariance_transport_batch.py \
919
+ --ensemble_dir "$ENSEMBLE_DIR" \
920
+ --atlas_root "$REPRO_ROOT/datasets/ATLAS" \
921
+ --test_csv "$REPRO_ROOT/dataset_csv/test/ATLAS_test.csv" \
922
+ --out_dir "$OUT_DIR" \
923
+ --mode a30 \
924
+ --modes_dir "$MODES_DIR" \
925
+ --lam 0.50 \
926
+ --md_stride 1 \
927
+ --overwrite
928
+
929
+ ENSEMBLE_DIR="$OUT_DIR" \
930
+ METRICS_DIR="$REPRO_ROOT/metrics/cov_transport_a30_lam0p50" \
931
+ METHOD_NAME="BBFlow-A30-cov-transport-lam0p50" \
932
+ ATLAS_VIEW_ROOT="$REPRO_ROOT/datasets/ATLAS" \
933
+ TEST_CSV="$REPRO_ROOT/dataset_csv/test/ATLAS_test.csv" \
934
+ NUM_WORKERS=8 \
935
+ bash reproduction/03_evaluate.sh
936
+
937
+ FILES TO SYNC TO SERVER FOR THIS ROUTE
938
+ - scripts/covariance_transport_batch.py
939
+ - scripts/export_condition_modes.py
940
+ - docs/HANDOFF_2026-07-17.txt
941
+
942
+ DECISION RULE
943
+ - Oracle transport fails or breaks metrics -> stop this route. The endpoint
944
+ transport mechanism is not viable.
945
+ - Oracle wins but A30 does not -> mechanism is viable, but A30's learned mode
946
+ subspace lacks enough test-time correlation information.
947
+ - A30 transport improves PCA W2 while preserving RMSF/Pairwise -> this is the
948
+ cleanest current "dual-stream" story: BBFlow supplies individual frames and
949
+ learned low-rank modes reshape endpoint ensemble correlations.
950
+ ================================================================================
951
+
952
+
953
+ ================================================================================
954
+ 19. TWO-STAGE X_eq->U / U-frozen->q ROUTE + FULL K-SWEEP RESULTS (2026-07-20/21)
955
+ ================================================================================
956
+
957
+ STATUS OF THE THREE CANDIDATE ROUTES ON THE TABLE (read this first, don't get lost)
958
+ 1. Section 6-17's generator-response / G-calibration line: last known state is
959
+ "frozen + G-cal diverged to NaN (fixed, mode_norm bug), never re-run since".
960
+ Not touched this round.
961
+ 2. Section 18's endpoint covariance transport: designed, scripted
962
+ (scripts/covariance_transport.py + covariance_transport_batch.py +
963
+ export_condition_modes.py per section 18), NOT YET RUN. Still open.
964
+ 3. THIS SECTION's two-stage decomposition: this is what actually got built and
965
+ run this round. It is a NEW, SEPARATE route, not a continuation of #1 or #2.
966
+ A full ADJOINT-MATCHING / terminal-c-calibration design was explored via
967
+ literature review (Adjoint Matching ICLR2025, Deterministic/Truncated AM
968
+ 2605.06583, Reinforce AM 2605.10759) as a way to fix "requested c != c
969
+ recovered after 20 steps" -- then EXPLICITLY SET ASIDE in favor of the
970
+ simpler two-stage design below, which sidesteps the whole adjoint question
971
+ by never needing the generator to round-trip c at all during stage 1/2.
972
+
973
+ THE TWO-STAGE DESIGN AND WHY
974
+ Core insight: A30 trains U, q, and the generator's condition-injection adapters
975
+ ALL AT ONCE, with U's target (c* = Proj_U(D)) changing every step because U
976
+ itself is changing every step -- q is chasing a moving target. Split it:
977
+ STAGE 1: X_eq -> U only. Generator frozen (freeze_foundation=true). q NOT
978
+ trained (lambda_q=0). U supervised by DIRECT per-frame displacement
979
+ reconstruction (mode_recon: c* = ridge-lstsq-project real MD frame's
980
+ centered displacement onto predicted U, reconstruct, penalize relative
981
+ error) + mode_orth (keep modes from collapsing). NOT covariance regression
982
+ (lambda_motion=0) -- a deliberate simplification: this session concluded
983
+ `energy` is redundant once U+c (and q(c)) fully express direction+
984
+ magnitude+distribution, so ENERGY_FROM_Q=false throughout, energy plays NO
985
+ role in stage 1 (this differs from A30, which used energy_from_q=true to
986
+ weight covariance loss and scale generator condition amplitude).
987
+ GATE: evaluate stage-1 checkpoint's held-out reconstruction quality (see
988
+ script below) BEFORE proceeding. Do not skip this gate.
989
+ STAGE 2: freeze U completely (new flag, see below), train ONLY q on top of
990
+ the now-FIXED U. c* is always recomputed live from frame_condition_from_
991
+ projection using the current (now frozen) U -- it is never cached, so
992
+ "c* based on the final U" is automatic once U stops moving, no special
993
+ code needed. lambda_mode_recon=lambda_mode_orth=0 in stage 2 (U is frozen,
994
+ nothing to optimize there). NOTE: even with FREEZE_FOUNDATION=true, the 5
995
+ condition-injection adapters (z_node/z_edge/disp_node/disp_edge_adapter,
996
+ film_mlp) stay trainable per `_freeze_foundation_model`, and official_loss
997
+ (the primary flow-matching loss) is UNCONDITIONALLY part of train_loss --
998
+ so stage 2 also continues to adapt those 5 small adapters against the now-
999
+ stable U-derived oracle condition, not purely "q in isolation". This is
1000
+ believed benign/intentional (adapters finally see a non-moving target) but
1001
+ was not explicitly designed for -- flag if it causes surprises.
1002
+ STAGE 3 (NOT YET BUILT): actually exercising the trained q+adapters through
1003
+ the generator to produce a downstream-evaluable ensemble (02_sample_test.sh
1004
+ + 03_evaluate.sh). Nothing in stages 1-2 produces an RMSF/Pairwise/PCA-W2
1005
+ number by itself -- do not compare stage-1/2 gate numbers to the section 3
1006
+ scoreboard, they are not the same kind of measurement.
1007
+
1008
+ CODE CHANGES MADE THIS ROUND (sync ALL of these to a new machine)
1009
+ - bbflow/models/latent.py:
1010
+ * `freeze_prior_backbone()` / `set_frozen_prior_backbone_eval()` /
1011
+ `prior_backbone_grad_check()` on LatentEncoder. Freezes the U-producing
1012
+ pathway = prior_node_mlp, prior_pair_mlp, prior_message_passing_layers,
1013
+ prior_update, template_center_logits/omega_logits/velocity_logits/
1014
+ participation/residual. Leaves mixture_logits_out/mixture_mu_out/
1015
+ mixture_tril_out/energy_out trainable. IMPORTANT: freezing only the
1016
+ template_* heads is NOT enough -- the shared trunk (prior_node_mlp etc.)
1017
+ must also be frozen, else h drifts under q's gradient and U drifts with it
1018
+ even with template_* frozen. This function freezes the whole pathway.
1019
+ - bbflow/models/bbflow_module.py:
1020
+ * `self.freeze_mode_head` wired from `latent.freeze_mode_head` config,
1021
+ calls `latent_encoder.freeze_prior_backbone()` in __init__, prints a
1022
+ runtime-verifiable line: `[freeze-mode-head] u_pathway_trainable=X (want 0)
1023
+ q_head_trainable=Y (want >0)`. Also calls
1024
+ `set_frozen_prior_backbone_eval()` in `on_train_epoch_start` alongside the
1025
+ existing `_set_frozen_foundation_eval`.
1026
+ * `_condition_usage_ranking_loss` (contrastive: correct c vs a wrong-batch-
1027
+ item's c on the same X_t, margin loss forcing the flow loss to actually
1028
+ prefer the correct c) -- implemented, wired via `lambda_condition_usage`
1029
+ (default 0, OFF). Built for a LATER stage (after stage 2, to fix "c is
1030
+ inert" if it turns out to be), never actually enabled/tested this round.
1031
+ * console epoch log already trimmed (section 17); unchanged this round.
1032
+ - configs/train.yaml: added `freeze_mode_head: false` under `latent:` (Hydra
1033
+ struct mode rejects an undeclared key -- this bit us once: all 3 GPUs died
1034
+ instantly on first launch with "Could not override 'latent.freeze_mode_head'"
1035
+ until this was added).
1036
+ - base_stages/00_train_final_mog_ddp.sh: added `FREEZE_MODE_HEAD` env var ->
1037
+ `latent.freeze_mode_head`; added `LAMBDA_SHAPE` env var (was HARDCODED to
1038
+ `experiment.training.lambda_shape=1.0` -- same class of bug as the old
1039
+ `freeze_foundation=false` hardcode). NOTE: `lambda_shape` ALSO gates whether
1040
+ the motion-target cache is looked up at all (`motion_loss_enabled := lambda_
1041
+ shape != 0`), independent of `LAMBDA_MOTION` -- and `frame_condition_from_
1042
+ projection` HARD-RAISES if `mean_disp` (from the cache) is None. So stage 1
1043
+ needs `LAMBDA_SHAPE=1.0` (default, do NOT set to 0) even though `LAMBDA_
1044
+ MOTION=0.0` zeroes out the old covariance-regression loss itself. The cache's
1045
+ local_cov/cross_cov/rmsf/oracle_mean_disp fields are K-INDEPENDENT ground
1046
+ truth (built from raw MD displacement, not mode-projected) -- the existing
1047
+ k8 cache (`atlas_full_md_motion_targets_k8_kabsch_v1.pt`) was reused
1048
+ unmodified for ALL K in {4,8,16,32,64,128}, no per-K cache regeneration
1049
+ needed, since lambda_pca_align=0 means oracle_modes/oracle_energy (the only
1050
+ K-dependent fields) are never touched.
1051
+ - scripts/eval_held_out_mode_recon.py (NEW): standalone offline gate-metric
1052
+ tool, deliberately NOT hooked into the live Lightning validation_step (that
1053
+ loop does full 20-step sampling on a DIFFERENT dataset class with no MD
1054
+ frame available, can't compute this; a bug here also can't break training).
1055
+ Loads a checkpoint + config.yaml, builds u_global from X_eq via `latent_
1056
+ encoder.forward_prior`, ridge-lstsq-projects real sampled MD frames onto it,
1057
+ reports rel_error r and energy-explained 1-r^2 (Pythagorean identity for an
1058
+ orthogonal/ridge-lstsq projection: energy = 1 - r^2 EXACTLY, not an
1059
+ approximation). Caches all protein data (MD frames via mdtraj, eq structure)
1060
+ ONCE per CSV so `--all_epochs` and multi-baseline runs don't re-read
1061
+ trajectories per checkpoint. Flags:
1062
+ --csv_path REQUIRED, no default (no-leakage contract: pass exactly
1063
+ one split; train vs validation vs test CSV schemas differ
1064
+ -- train has folder+name+pdb_path, val/test have only
1065
+ name+pdb_path; dirname(pdb_path)==folder in both, script
1066
+ handles both schemas)
1067
+ --cache_path motion-target cache, only used for oracle_mean_disp
1068
+ --frames_per_protein default 20, evenly spaced via mdtraj.open()+linspace
1069
+ --all_epochs sweep every epoch:*.ckpt in run_dir, reusing cached data
1070
+ --baseline {trained,untrained,random}
1071
+ trained = loaded checkpoint's u_global (default)
1072
+ untrained = a FRESH same-K LatentEncoder, never loaded
1073
+ any checkpoint (floor: does the architecture alone,
1074
+ unlearned, already capture something just from
1075
+ structural priors?)
1076
+ random = K random QR-orthonormalized directions in the
1077
+ full 3N-dim displacement space, no network/no X_eq at
1078
+ all (absolute floor: what any random K-dim subspace
1079
+ captures by dimension-counting alone)
1080
+ NEVER ACTUALLY RUN THIS ROUND -- user chose to conclude
1081
+ without them. This is the single most important gap left
1082
+ for whoever picks this up: we do not know whether 81.4%
1083
+ energy at K=64 is "the network learned something real"
1084
+ or "any 64-dim subspace would do about this well". RUN
1085
+ THIS FIRST if continuing this route.
1086
+ --max_proteins N --random_seed S
1087
+ For train-split sanity checks: .iloc[:N] (default, no
1088
+ seed) is ORDER-BIASED (first N CSV rows, not random).
1089
+ Pass --random_seed for a real `csv.sample(n=N,
1090
+ random_state=S)` draw. This bit us once: an unseeded
1091
+ 39-protein train draw happened to include a cluster of
1092
+ intrinsically-hard proteins (see below), making train
1093
+ look WORSE than held-out at K=32/64 -- do not read that
1094
+ as "validation generalizes better than training fit",
1095
+ it's a small-n sampling artifact, not a real signal.
1096
+
1097
+ METHODOLOGY LESSON -- DO NOT REPEAT THIS MISTAKE
1098
+ Early in this round, the live training-loop's `mode_recon_rel_error` column
1099
+ (in latent_train_epoch_metrics.csv, ~0.17-0.20 for K=16's last few epochs) was
1100
+ compared directly against this offline script's held-out number (0.66) and
1101
+ read as "3-4x gap = severe overfitting, consider stopping". THIS WAS WRONG and
1102
+ was retracted. The two numbers use DIFFERENT statistical bases (live-loop is a
1103
+ per-training-BATCH aggregate under whatever frame sampling the length-batcher
1104
+ used; the offline script is a per-protein, full-evenly-sampled-trajectory
1105
+ aggregate) and are NOT comparable. When re-measured with the SAME script on
1106
+ BOTH splits (same-gate protocol), K=16 gave train=0.6068 (energy 61.7%) vs
1107
+ held-out=0.6621 (energy 56.2%) -- a MILD ~5.5pp gap, not severe overfitting.
1108
+ RULE: never compare the live training log's recon metric to this script's
1109
+ output. Always use the same script, same protocol, for any train-vs-held-out
1110
+ comparison.
1111
+
1112
+ FULL K-SWEEP RESULTS (held-out = ATLAS_validation.csv, all 39 proteins, fixed
1113
+ set, NOT sampled -- this series is the reliable, apples-to-apples one)
1114
+ K held-out rel_error r energy explained (1-r^2)
1115
+ 4 0.8700 24.3%
1116
+ 8 0.7815 38.9%
1117
+ 16 0.6621 56.2%
1118
+ 32 0.5079 72.5%
1119
+ 64 0.4133 81.4%
1120
+ 128 NEVER COMPLETED (see below)
1121
+
1122
+ Reading: MONOTONIC, still-increasing at K=64, deltas per doubling are
1123
+ DECELERATING (K4->8 +14.6pp, K8->16 +17.3pp, K16->32 +16.3pp, K32->64 +8.9pp)
1124
+ but have not plateaued or turned over. NO EVIDENCE was found supporting the
1125
+ hypothesis (raised mid-session) that a too-free per-residue residual branch
1126
+ (`template_residual`, tanh-bounded, scale 0.1) causes overfitting that gets
1127
+ worse with K -- if that were true, held-out should degrade at some K; instead
1128
+ it kept improving through K=64. Do NOT restrict/shrink the residual branch
1129
+ based on that hypothesis without new evidence; it is currently unsupported.
1130
+
1131
+ SYSTEMATIC HARD-PROTEIN CLUSTERS (real signal, not noise -- verified by exact
1132
+ repetition across independent K runs, worth investigating separately: chain
1133
+ length, conformational multi-basin heterogeneity, raw displacement amplitude):
1134
+ held-out (same 5, in some order, across K=4/8/16 and overlapping at K=32/64):
1135
+ 6a9aA, 5z1nA, 5zlqA, 5w4aB, 5ydnA (K=32/64 also surface 6dnmA, 6hemA,
1136
+ 6mbgA as new worst-performers, i.e. the hard cluster partially shifts as K
1137
+ grows -- not identical across all 5 K values, only exactly identical
1138
+ across K=4/8/16).
1139
+ train (39-random-sample, seed=0, repeated across K=16/32/64):
1140
+ 1q8fA, 2wnpF, 3h2dB, 1zosC, 3g5tA / 3holA
1141
+
1142
+ STAGE 1 CHECKPOINT LOCATIONS (all under
1143
+ ${ATLAS_REPRO_ROOT}/outputs/checkpoints/, ATLAS_REPRO_ROOT=
1144
+ /data/shared/wangyusong/atals/bbflow_official_reproduction)
1145
+ K=4: stage1_eq2U_K4_20260720_022436 (15/15 epochs, DONE)
1146
+ K=8: stage1_eq2U_K8_20260720_022436 (15/15 epochs, DONE)
1147
+ K=16: stage1_eq2U_K16_20260720_022436 (15/15 epochs, DONE)
1148
+ K=32: stage1_eq2U_K32_20260720_114656 (15/15 epochs, DONE)
1149
+ K=64: stage1_eq2U_K64_20260720_111914 (14/14 epochs i.e. epoch:013.ckpt is
1150
+ the last one, DONE -- this is the checkpoint used for the stage-2
1151
+ launch attempt below)
1152
+ K=128: stage1_eq2U_K128_* (TWO attempts: first with default batch settings,
1153
+ stalled for hours at low throughput because of unused DDP/single-GPU
1154
+ port contention issues fixed along the way; relaunched with
1155
+ MAX_NUM_RES_SQUARED=240000/MAX_BATCH_SIZE=24 on GPU2 alone and was
1156
+ training healthily at 45GB/89% util -- then KILLED to free GPU2 for the
1157
+ 3-GPU stage-2 launch (user's explicit choice: "杀掉 K=128,三卡一起跑
1158
+ 阶段2"). K=128 WAS NEVER GATE-EVALUATED. If GPU budget allows on the
1159
+ new machine, re-running K=128 (and running the random/untrained
1160
+ baselines at whichever K matters most) are the two highest-value gaps
1161
+ to close before trusting this route's ceiling.
1162
+
1163
+ STAGE 1 LAUNCH COMMAND TEMPLATE (single GPU, K swept via NUM_MODES; the k8
1164
+ cache is reused for every K, see cache note above)
1165
+ pkill -u wangyusong -9 -f experiments/train.py; sleep 3
1166
+ cd ~/LD-FPG-main/bbflow_base
1167
+ export PYTHONPATH=$PWD:${PYTHONPATH:-}
1168
+ export MASTER_ADDR=127.0.0.1
1169
+ export MASTER_PORT=<pick a free port, e.g. 29500>
1170
+ K=<4|8|16|32|64|128>
1171
+ FINGERPRINT_CACHE=/home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
1172
+ ATLAS_REPRO_ROOT=/data/shared/wangyusong/atals/bbflow_official_reproduction
1173
+ RUN_DIR=${ATLAS_REPRO_ROOT}/outputs/checkpoints/stage1_eq2U_K${K}_$(date +%Y%m%d_%H%M%S) \
1174
+ ATLAS_REPRO_ROOT=${ATLAS_REPRO_ROOT} \
1175
+ FINGERPRINT_CACHE=${FINGERPRINT_CACHE} \
1176
+ GPU_IDS=<0|1|2> NUM_DEVICES=1 MAX_EPOCHS=15 \
1177
+ CHECKPOINT_EVERY_N_EPOCHS=1 CHECKPOINT_SAVE_LAST=true CHECKPOINT_SAVE_TOP_K=-1 \
1178
+ PRECISION=bf16-mixed MAX_NUM_RES_SQUARED=120000 MAX_BATCH_SIZE=10 \
1179
+ FREEZE_FOUNDATION=true FREEZE_MODE_HEAD=false \
1180
+ NUM_MODES=${K} \
1181
+ LAMBDA_SHAPE=1.0 LAMBDA_MOTION=0.0 LAMBDA_Q=0.0 ENERGY_FROM_Q=false \
1182
+ LAMBDA_MODE_RECON=1.0 LAMBDA_MODE_ORTH=1.0 LAMBDA_PCA_ALIGN=0.0 \
1183
+ LAMBDA_GENERATOR_COV=0.0 GENERATOR_COV_ROLLOUT_CALIBRATION=false LAMBDA_CONDITION_CYCLE=0.0 \
1184
+ bash base_stages/00_train_final_mog_ddp.sh
1185
+ (For K=128 specifically, larger batch helped GPU utilization -- consider
1186
+ MAX_NUM_RES_SQUARED=240000 MAX_BATCH_SIZE=24 as a starting point, verify no OOM.)
1187
+
1188
+ STAGE 1 GATE-EVAL COMMAND TEMPLATE
1189
+ FINGERPRINT_CACHE=/home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
1190
+ ATLAS_REPRO_ROOT=/data/shared/wangyusong/atals/bbflow_official_reproduction
1191
+ RUN=<stage1 run dir>
1192
+ python scripts/eval_held_out_mode_recon.py --run_dir "$RUN" \
1193
+ --csv_path ${ATLAS_REPRO_ROOT}/dataset_csv/validation/ATLAS_validation.csv \
1194
+ --cache_path $FINGERPRINT_CACHE --frames_per_protein 20
1195
+ # same-gate train sanity (random sample, not first-N):
1196
+ python scripts/eval_held_out_mode_recon.py --run_dir "$RUN" \
1197
+ --csv_path ${ATLAS_REPRO_ROOT}/dataset_csv/train/ATLAS_train.csv \
1198
+ --cache_path $FINGERPRINT_CACHE --frames_per_protein 20 --max_proteins 39 --random_seed 0
1199
+ # STILL-NEEDED baselines (never run this round):
1200
+ python scripts/eval_held_out_mode_recon.py --run_dir "$RUN" --csv_path <val csv> \
1201
+ --cache_path $FINGERPRINT_CACHE --frames_per_protein 20 --baseline random
1202
+ python scripts/eval_held_out_mode_recon.py --run_dir "$RUN" --csv_path <val csv> \
1203
+ --cache_path $FINGERPRINT_CACHE --frames_per_protein 20 --baseline untrained
1204
+
1205
+ STAGE 2 LAUNCH COMMAND (K=64, the current best point; THIS IS WHAT WAS RUNNING
1206
+ WHEN THE MACHINE DIED -- verbatim, ready to re-run on the new machine)
1207
+ pkill -u wangyusong -9 -f experiments/train.py; sleep 3
1208
+ cd ~/LD-FPG-main/bbflow_base
1209
+ export PYTHONPATH=$PWD:${PYTHONPATH:-}
1210
+ K=64
1211
+ STAGE1_RUN=/data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/stage1_eq2U_K64_20260720_111914
1212
+ STAGE1_CKPT=$(ls -t "$STAGE1_RUN"/epoch:*.ckpt | head -1)
1213
+ FINGERPRINT_CACHE=/home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
1214
+ ATLAS_REPRO_ROOT=/data/shared/wangyusong/atals/bbflow_official_reproduction
1215
+ EXTRA_HYDRA_ARGS="experiment.trainer.strategy=ddp" \
1216
+ BASE_CKPT="$STAGE1_CKPT" \
1217
+ RUN_DIR=${ATLAS_REPRO_ROOT}/outputs/checkpoints/stage2_qtrain_K64_$(date +%Y%m%d_%H%M%S) \
1218
+ ATLAS_REPRO_ROOT=${ATLAS_REPRO_ROOT} \
1219
+ FINGERPRINT_CACHE=${FINGERPRINT_CACHE} \
1220
+ GPU_IDS=0,1,2 NUM_DEVICES=3 MAX_EPOCHS=10 \
1221
+ CHECKPOINT_EVERY_N_EPOCHS=2 CHECKPOINT_SAVE_LAST=true CHECKPOINT_SAVE_TOP_K=-1 \
1222
+ PRECISION=bf16-mixed MAX_NUM_RES_SQUARED=400000 MAX_BATCH_SIZE=32 \
1223
+ RESET_EPOCH=true RESET_OPTIMIZER_ON_LOAD=true \
1224
+ FREEZE_FOUNDATION=true FREEZE_MODE_HEAD=true \
1225
+ NUM_MODES=64 \
1226
+ LAMBDA_SHAPE=1.0 LAMBDA_MOTION=0.0 LAMBDA_MODE_RECON=0.0 LAMBDA_MODE_ORTH=0.0 \
1227
+ LAMBDA_Q=1.0 ENERGY_FROM_Q=false \
1228
+ LAMBDA_PCA_ALIGN=0.0 LAMBDA_GENERATOR_COV=0.0 LAMBDA_CONDITION_CYCLE=0.0 \
1229
+ bash base_stages/00_train_final_mog_ddp.sh
1230
+ NOTE: MAX_NUM_RES_SQUARED=400000/MAX_BATCH_SIZE=32 matches A30's original
1231
+ batch scale (user request, for closer comparability) -- larger than stage 1's
1232
+ 120000/10. Since both the generator AND U are frozen here (only q's small
1233
+ mixture heads + the 5 injection adapters train), this is far cheaper than
1234
+ A30's full unfrozen run, so this batch size should NOT OOM, but was never
1235
+ actually confirmed running (see blocker below).
1236
+ BASE_CKPT points at STAGE 1's Lightning checkpoint (not the official
1237
+ bbflow-0.1.ckpt) with RESET_EPOCH=true RESET_OPTIMIZER_ON_LOAD=true so
1238
+ train.py's `on_load_checkpoint` hook (bbflow_module.py ~667-703) takes the
1239
+ FULL-RESUME branch (loads latent_encoder too, not just self.model) but resets
1240
+ epoch/global_step/optimizer to fresh.
1241
+ FIRST THING TO CHECK after launch (this code path -- freeze_mode_head=true --
1242
+ had NEVER been exercised before this attempt):
1243
+ grep freeze-mode-head <log>
1244
+ MUST show: u_pathway_trainable=0 (want 0) q_head_trainable=<N> (want >0)
1245
+ This line WAS observed correctly on the one attempt that got far enough:
1246
+ [freeze-mode-head] u_pathway_params=613312 u_pathway_trainable=0 (want 0) q_head_trainable=578178 (want >0)
1247
+ So the freeze-mode-head code itself is CONFIRMED WORKING. The failure that
1248
+ followed was unrelated to this code (see below).
1249
+
1250
+ CURRENT BLOCKER -- WHY THE MACHINE IS BEING SWITCHED (node-level CUDA fault,
1251
+ NOT a code/config problem)
1252
+ The stage-2 K=64 launch above got past module construction, checkpoint
1253
+ loading, and the freeze-mode-head check successfully (all on CPU, no CUDA
1254
+ needed yet), then crashed at the first real CUDA touch:
1255
+ File "experiments/train.py", line 104, in train
1256
+ device_names = [torch.cuda.get_device_name(i) for i in devices]
1257
+ RuntimeError: CUDA unknown error - this may be due to an incorrectly set up
1258
+ environment... Setting the available devices to be zero.
1259
+ Full diagnostic trail (in order, all confirmed on gn14):
1260
+ 1. `nvidia-smi` works perfectly: driver 595.71.05, all 3 GPUs healthy,
1261
+ 0MiB/0% used, "No running processes found". Rules out driver/hardware
1262
+ fault and zombie-process-holding-the-GPU.
1263
+ 2. `echo $CUDA_VISIBLE_DEVICES` was found SET TO EMPTY STRING (not unset) --
1264
+ matches the error text ("available devices to be zero") exactly. `unset
1265
+ CUDA_VISIBLE_DEVICES` was tried -- did NOT fix it.
1266
+ 3. `LD_LIBRARY_PATH=/usr/local/cuda/lib64:/usr/local/cuda/lib64:` (duplicated,
1267
+ points at a SYSTEM cuda install rather than the conda env's own CUDA
1268
+ runtime) was suspected -- `LD_LIBRARY_PATH="" python -c "torch.cuda..."`
1269
+ was tried -- did NOT fix it either.
1270
+ 4. Tested each GPU individually via `CUDA_VISIBLE_DEVICES=0/1/2` in
1271
+ isolation -- ALL THREE fail identically (`torch.cuda.is_available()` ->
1272
+ False, same "unknown error"). Rules out a single-card hardware fault.
1273
+ 5. Opened a COMPLETELY FRESH SSH session (new login shell, ruling out any
1274
+ accumulated state in the old multi-hour terminal) -- SAME failure,
1275
+ identical error text, even a bare `python -c "import torch;
1276
+ torch.cuda.is_available()"` with no training code involved at all.
1277
+ CONCLUSION: this is a node-level fault where NVML (what nvidia-smi uses)
1278
+ reports healthy GPUs but the CUDA Runtime/Driver API (`cuInit`) fails for any
1279
+ user process, on any GPU, in any shell. This combination typically needs a
1280
+ driver reset / kernel module reload / node reboot -- root access, which this
1281
+ session does not have. NOT fixable by us. This is why the user is switching
1282
+ machines. On the new machine: confirm `python -c "import torch;
1283
+ print(torch.cuda.is_available())"` returns True BEFORE attempting to relaunch
1284
+ anything.
1285
+
1286
+ FILES TO SYNC TO THE NEW MACHINE (all of section 19's changes)
1287
+ - bbflow/models/latent.py
1288
+ - bbflow/models/bbflow_module.py
1289
+ - configs/train.yaml
1290
+ - base_stages/00_train_final_mog_ddp.sh
1291
+ - scripts/eval_held_out_mode_recon.py
1292
+ (docs/HANDOFF_2026-07-17.txt itself, obviously, for context)
1293
+
1294
+ IMMEDIATE NEXT STEPS ON THE NEW MACHINE
1295
+ 1. Sync the 5 files above. Verify CUDA works (see blocker section) before
1296
+ anything else.
1297
+ 2. python -m py_compile bbflow/models/latent.py bbflow/models/bbflow_module.py
1298
+ 3. Launch the STAGE 2 K=64 command verbatim (above). Check the
1299
+ [freeze-mode-head] line immediately.
1300
+ 4. While stage 2 trains, if GPU budget allows: (a) run the random/untrained
1301
+ baselines at K=64 -- the single most important missing number, (b)
1302
+ consider re-running K=128 stage 1 to complete the sweep and see if the
1303
+ K=32->64 deceleration (+16.3pp -> +8.9pp) continues toward a plateau.
1304
+ 5. Once stage 2 (K=64) finishes: this is STILL not a downstream number. Next
1305
+ step after that is sampling+evaluating through 02_sample_test.sh +
1306
+ 03_evaluate.sh (same as every other route in this doc) to get RMSF/
1307
+ Pairwise/PCA-W2 numbers comparable to the section 3 scoreboard and to A30.
1308
+ Nothing produced this round is comparable to that scoreboard yet.
1309
+ ================================================================================
bbflow_base/docs/cmfm_failure_localization.md ADDED
@@ -0,0 +1,138 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # CMFM gradient collapse: localization and fixes
2
+
3
+ Two things live here: the instrumentation that names the first non-finite
4
+ operator, and the fixes to the two operators that could produce one. Nothing
5
+ clips gradients, skips a sample, adds jitter, or lowers a loss weight — the
6
+ fixes change the operators themselves so their backwards are bounded.
7
+
8
+ The instrumentation stays on. The fixes are argued from the code, not yet
9
+ confirmed against the failing microbatch, so the replay is still worth running.
10
+
11
+ ## The fixes
12
+
13
+ | what | where | change |
14
+ | --- | --- | --- |
15
+ | covariance normalizer | `collective.py` | per-mode denominator `std_i * std_j` replaced by the single scalar `trace(group_target_cov) / rank`. The element-wise form was not invariant under a rotation of the collective basis (which is only defined up to one) and gave the least-observed direction a `1/var**2` weight. `collective_variance_rel_floor` existed only to cap that amplification and is removed. |
16
+ | mode gauge | `latent.py` | `torch.linalg.qr` replaced by ridge-regularised Cholesky-QR (`latent.mode_gauge_ridge`, default `1e-6`), which yields the same positive-diagonal factor but bounds `‖L⁻¹‖` at `1/sqrt(ridge)` instead of `1/r_ii` |
17
+ | orthogonality pressure | `bbflow_module.py` | `mode_orth_loss` and the Gram diagnostics moved from the post-gauge `u_global` (orthonormal by construction, so ~0 always) onto the pre-gauge `raw_modes_global` |
18
+
19
+ Two consequences worth expecting:
20
+
21
+ - `mode_orth_loss` was effectively zero and is now a real term. With
22
+ `LAMBDA_MODE_ORTH=1.0` the latent regularizer's scale will change.
23
+ - `mode_max_cosine_abs` / `mode_gram_condition` now describe the raw mode head,
24
+ so they will no longer read as perfectly conditioned. That is the point.
25
+
26
+ ## What the failure looks like today
27
+
28
+ Training dies at `rank=1, epoch=0, global_step=170`. The forward `train_loss` is
29
+ finite; ~600 parameter gradients are non-finite at the optimizer step, spanning
30
+ the BBFlow embedder, the backbone, the condition adapters, the latent prior and
31
+ the collective controller. So a finite forward objective produced a non-finite
32
+ backward.
33
+
34
+ Two operators could do that while passing every forward guard:
35
+
36
+ 1. **Empirical covariance normalization**, [`collective.py`](../bbflow/models/collective.py).
37
+ `covariance_scale = (target_std ⊗ target_std).clamp_min(1e-6)` with
38
+ `target_std = sqrt(observed target variance)`. The guard only rejected
39
+ `target_variance <= 1e-6`, so a variance of, say, `1.4e-6` was accepted and
40
+ `d loss / d pred_trans` picked up a factor of `1 / covariance_scale²` ≈ `1e12`.
41
+ The loss itself stays small — only the gradient explodes. The collective basis
42
+ comes from the q-implied physical covariance and is under no obligation to
43
+ align with what 8 sampled MD frames actually do, so a retained mode having
44
+ near-zero observed variance is expected, not exotic.
45
+ The `target_var=[...]` field in the old log is the *q-implied physical*
46
+ variance from `physical_low_rank_target`, **not** this denominator; the real
47
+ suspect was never logged.
48
+ 2. **Differentiable masked QR**, [`latent.py`](../bbflow/models/latent.py)
49
+ `_masked_orthonormalize_modes`. QR backward scales like `1/r_ii` while the
50
+ guard only rejected `|r_ii| / scale <= 1e-6`. Worse, `mode_orth_loss` ran on
51
+ the QR *output*, which is orthonormal by construction, so it reported ~0 and
52
+ could not constrain a collapsing raw mode head — nothing kept the QR input
53
+ away from rank deficiency.
54
+
55
+ `tests/test_cmfm_failure_localization.py` pins both the fixed behaviour and,
56
+ with the bound disabled, the original explosion.
57
+
58
+ ## Step 1-3: capture the failing microbatch
59
+
60
+ These are on by default whenever `latent.collective_enable=true`:
61
+
62
+ | flag (`experiment.training.*`) | default | effect |
63
+ | --- | --- | --- |
64
+ | `cmfm_numerics_log_interval` | 50 | console cadence for the numerics line |
65
+ | `cmfm_grad_guard` | true | check grads after **every** microbatch on **every** rank |
66
+ | `cmfm_capture_failure` | true | keep a CPU copy of the current microbatch |
67
+ | `cmfm_dump_state_dict` | true | include pre-step weights in the dump |
68
+
69
+ Every rank now appends one row per **microbatch** to
70
+ `<default_root_dir>/cmfm_numerics_rank{r}.csv`, carrying the quantities that
71
+ were missing before:
72
+
73
+ - `collective_observed_target_variance_min` / `_max` (how degenerate the group
74
+ really was), `collective_covariance_scale_min` (the scalar normalizer actually
75
+ used), `collective_covariance_inverse_scale_max`
76
+ - `collective_target_cov_rate_absmax`, `collective_predicted_cov_rate_absmax`,
77
+ `collective_covariance_error_absmax`
78
+ - `prior_qr_diag_abs_min`, `prior_qr_rel_diag_min`, `prior_qr_condition_max`
79
+ - `collective_update_abs`, `collective_update_absmax`
80
+ - batch identity: `rank`, `epoch`, `global_step`, `microbatch`, `pdb_name`,
81
+ `num_res`, `num_particles`, `t_min`, `t_max`, `num_groups`
82
+
83
+ `_cmfm_grad_guard` runs in `on_after_backward`, i.e. **before** accumulation can
84
+ smear the first bad microbatch across the window. When it trips it writes
85
+
86
+ ```
87
+ <default_root_dir>/cmfm_failure_dumps/rank{r}_epoch{e}_step{s}_micro{m}.pt
88
+ <default_root_dir>/cmfm_failure_dumps/rank{r}_epoch{e}_step{s}_micro{m}.json
89
+ ```
90
+
91
+ The `.json` is readable immediately: protein name, `N`, the shared `t`, the
92
+ per-particle `trajectory_idx`/`conformation_idx` (the 8 MD frames), the group
93
+ ids, the per-group collective diagnostics, and a per-parameter gradient summary.
94
+ The `.pt` additionally holds the full corrupted batch (including `trans_sc`) and
95
+ the pre-step weights, which is what makes the replay exact — the group sampler
96
+ uses unseeded `np.random.choice`, so the frame indices alone cannot reproduce it.
97
+
98
+ Note: the guard raises on whichever rank fails, which will take down the other
99
+ ranks. That is the same behaviour as the existing optimizer-step guard.
100
+
101
+ ## Step 4: attribute the component, then compare bf16 against fp32
102
+
103
+ ```bash
104
+ python scripts/cmfm_replay_failure.py \
105
+ --dump outputs/.../cmfm_failure_dumps/rank1_epoch0_step170_micro3.pt \
106
+ --config outputs/ckpt/.../config.yaml \
107
+ --precision both
108
+ ```
109
+
110
+ The script rebuilds `BBFlowModule` from the config, loads the pre-step weights,
111
+ runs one forward on the captured microbatch, and backpropagates `official`,
112
+ `latent` and `collective` **separately** with `torch.autograd.grad`, so the
113
+ buffers never mix. For each it reports the loss, the norm and max of the finite
114
+ part of the gradient, and the parameters that came back non-finite. It then
115
+ repeats the whole thing in pure fp32.
116
+
117
+ Read the verdict as:
118
+
119
+ - only `collective` non-finite, in both precisions → the covariance target is
120
+ mathematically singular on this microbatch;
121
+ - only `collective` non-finite in bf16, finite in fp32 → bf16 amplification of an
122
+ already-huge but representable gradient;
123
+ - `latent` non-finite → the QR/prior path, not the covariance normalizer;
124
+ - `official` non-finite → the failure is not CMFM-specific at all.
125
+
126
+ Run the replay on a single GPU. Component-wise `autograd.grad` under DDP would
127
+ fire the reducer hooks more than once.
128
+
129
+ ## Step 5: what still must not be done
130
+
131
+ Do not add gradient clipping, sample skipping, jitter, or a lower
132
+ `lambda_collective_measure`. Each of those turns a reproducible failure into a
133
+ silent one. The two fixes above are not of that kind: they replace an unbounded
134
+ operator with a bounded one and leave the forward value unchanged wherever the
135
+ input is well conditioned.
136
+
137
+ If training still dies, the dump plus the replay verdict is the evidence to act
138
+ on — not a new bound.
bbflow_base/docs/cmfm_handoff_2026-07-31.md ADDED
@@ -0,0 +1,534 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # CMFM handoff — 2026-07-31
2
+
3
+ Session covering the CMFM (collective measure flow matching) debugging run from the
4
+ `cmfm_k8_r4_rootfix_probe_20260729_185258` failure, through a stable 26-epoch run that
5
+ lost to the baseline, to a diagnosis of why and a redesign now training.
6
+
7
+ ## Reading order
8
+
9
+ 1. **Bottom line** and **Evaluation** — the 26-epoch run, and that it lost.
10
+ 2. **Why the surrogate lied**, **Where the error actually is**, **Ceilings** — the
11
+ measurements that explain the loss.
12
+ 3. **What is running now** — the redesign, what it changes and what it deliberately does
13
+ not, and the one number that decides whether it worked.
14
+ 4. Everything between the bottom line and the evaluation is the debugging chain that made
15
+ a valid measurement possible at all. It is history, but each entry is a live trap.
16
+
17
+ ## Bottom line
18
+
19
+ **Freezing the stage-1 mode head is the change that made CMFM work.** Every prior CMFM
20
+ run trained the mode head from random initialisation, because the official BBFlow
21
+ checkpoint contains no latent-encoder weights and the warm-start loader silently dropped
22
+ the ones that were supplied.
23
+
24
+ It was not enough: the run still lost to the baseline. The collective objective was then
25
+ measured to be structurally incapable of helping, and has been rebuilt — see
26
+ **What is running now**.
27
+
28
+ | | old probe (random U) | warm-start, U trainable | **U frozen (current)** |
29
+ | --- | --- | --- | --- |
30
+ | `cross_cov_far_corr` (PCA-W2 proxy, want 0.1–0.2) | 0.042 | 0.2356 → 0.021 after 1 epoch | **0.37 mean, held 26 epochs** |
31
+ | `mode_max_cosine_abs` (want < 0.9) | 0.9367 | 0.8711 → 0.98 | **0.76 mean** |
32
+ | `official_loss` (want ~0.85) | 0.557 | 0.50 → 0.94 | **0.80 mean** |
33
+
34
+ `cross_cov_far_corr` is ~9x the old baseline and above the target band. It has
35
+ **plateaued** — thirds of the 26 epochs average 0.366 / 0.368 / 0.384, against a
36
+ per-epoch spread of 0.15–0.56. The gain came from the structural fixes, not from
37
+ continued training.
38
+
39
+ ## Findings, in order of discovery
40
+
41
+ ### 1. The frame sampler was unseeded
42
+
43
+ `_get_group_indices` drew MD frames from the process-global `np.random`; `seed` only
44
+ controlled the protein permutation (a `torch.Generator` feeding `randperm`). Two runs
45
+ with identical configs trained on different frames, so every loss-weight comparison was
46
+ confounded by a sampling lottery that nothing recorded.
47
+
48
+ Fixed with a `(seed, epoch, rank, draw)`-keyed `np.random.default_rng`. `draw`
49
+ distinguishes the augmentation rounds of `_create_batches`, which calls back into the
50
+ epoch builder until it has `_num_batches` — without it every round replays the same
51
+ frames. A dedicated Generator is required rather than seeding the global state, because
52
+ `__init__` pre-scans every rank to count batches and would otherwise consume the global
53
+ stream before epoch 0 starts.
54
+
55
+ The frames themselves were never a short window — the sampler draws uniformly over all
56
+ three trajectories and the full conformation range. An earlier hypothesis that the 8
57
+ group frames came from a short window was wrong.
58
+
59
+ ### 2. The collective covariance normalizer was not basis invariant
60
+
61
+ `collective_measure_dynamics_loss` divided the error matrix element-wise by
62
+ `std_i * std_j`. Under an orthogonal rotation of the collective basis the error matrix
63
+ transforms as `E -> R E R^T`, so `||E||_F^2 / trace(C)^2` is invariant but
64
+ `E_ij/(s_i s_j)` is not — the loss encoded a preference for whichever basis the SVD
65
+ happened to return. It also gave the least-observed direction a `1/var^2` weight, and
66
+ that direction is routinely the one estimated from almost no signal.
67
+
68
+ Replaced with the scalar `trace(group_target_cov) / rank`. `collective_variance_rel_floor`
69
+ existed only to cap the amplification and was removed. A rotation-invariance test was
70
+ added.
71
+
72
+ ### 3. The mode gauge needed float64
73
+
74
+ Cholesky-QR forms `A^T A`, squaring the condition number. A mode head aligned to MD's
75
+ steep spectrum reaches `cond(A) ~ 2e3` in normal operation, so `cond(A^T A) ~ 4e6`.
76
+ Forming that in float32 carries a rounding error of ~`eps * lambda_max = 1.2e-7 *
77
+ lambda_max`, only ~8x below the relative ridge of `1e-6 * lambda_max`; once it crosses,
78
+ the smallest eigenvalue goes negative and `cholesky` fails on a Gram that is
79
+ mathematically positive definite.
80
+
81
+ `_masked_orthonormalize_modes` now runs the K×K factorization in float64. Note this made
82
+ the rank-deficiency guard honest: under float32 a ridge below ~1e-12 was masked by
83
+ rounding noise of ~1e-7 and slipped past the `relative_diagonal <= 1e-6` check.
84
+
85
+ This crash only appeared **after** warm-start started working — the random-init mode head
86
+ never had a steep enough spectrum to reach `qr_cond` 2000.
87
+
88
+ ### 4. The warm-start loader silently dropped the mode head
89
+
90
+ `experiments/train.py` filtered the checkpoint against `self._model.model.state_dict()`
91
+ and stripped a `model.` prefix. But `bbflow_module.py` builds `self.model` and
92
+ `self.latent_encoder` **side by side** — `latent_encoder.*` keys carry no `model.`
93
+ prefix, so all 81 of them were dropped while the 532 foundation tensors still produced a
94
+ healthy-looking count.
95
+
96
+ Now filtered against the full LightningModule state and reported per top-level submodule:
97
+
98
+ ```
99
+ Loaded warm start weights into model only: 613 tensors {'model': 532, 'latent_encoder': 81}
100
+ ```
101
+
102
+ The per-submodule breakdown is the point — an all-or-nothing total is exactly what hid
103
+ this for a full experiment cycle.
104
+
105
+ ### 5. Every CMFM run had been training U from scratch
106
+
107
+ The official BBFlow checkpoint contains **0** latent/template keys — the latent encoder is
108
+ this project's own addition. Combined with (4), no CMFM run had ever used stage-1's
109
+ trained U.
110
+
111
+ ### 6. stage-1 learns U; CMFM destroys it
112
+
113
+ Measured with `scripts/diagnose_mode_pca_alignment.py`, subspace overlap between the 8
114
+ learned modes and the MD top-2 PCs (random baseline for N=176 is 8/528 = 0.0152):
115
+
116
+ | run | epoch | `all_learned_vs_md_top2_subspace_mean_sq_cos` |
117
+ | --- | --- | --- |
118
+ | `stage1_eq2U_K8_20260720_022436` | 0 | 0.106 |
119
+ | | 4 | 0.184 |
120
+ | | 9 | 0.324 |
121
+ | | 14 / last | **0.353** |
122
+ | `cmfm_k8_r4_fp32prior_20260727_172311` | last (~17) | **0.055** |
123
+
124
+ stage-1 (motion loss only, no collective) reaches 23x chance. A 17-epoch CMFM run sits at
125
+ 3.6x chance — worse than stage-1 after a single epoch.
126
+
127
+ With warm-start working, the 100-epoch run reproduced the destruction directly:
128
+ `cross_cov_far_corr` 0.2356 at epoch 0 → 0.021 at epoch 1 (11x drop), bottoming at 0.0012
129
+ by epoch 7, slowly re-learning to 0.068 by epoch 15 — still under a third of the start.
130
+
131
+ The mechanism is visible in `[grad-flow-check]`: `prior_template_head` took a gradient
132
+ norm of **8194 on 10 tensors** against the backbone's 403 on 540.
133
+
134
+ ### 7. `freeze_mode_head` was rejected by a guard that had a real reason
135
+
136
+ `create_model` raised `"CMFM requires the mode/q pathway to be unfrozen"`. The reason: when
137
+ `collective_enabled`, a blanket `requires_grad_(True)` over `model` **and**
138
+ `latent_encoder` ran *after* `freeze_prior_backbone()` and silently undid it. Erroring out
139
+ was better than a silent no-op.
140
+
141
+ The blanket unfreeze now re-applies the freeze and prints the check, so the guard was
142
+ dropped. Verified at runtime:
143
+
144
+ ```
145
+ [freeze-mode-head] after collective unfreeze: u_pathway_trainable=0 (want 0) q_head_trainable=29154 (want >0)
146
+ [grad-flow-check] prior_template_head:grad_norm=0:params_with_grad=0
147
+ ```
148
+
149
+ ### 8. `rots_vf_loss` produced non-finite gradients under bf16
150
+
151
+ With U frozen the run still died at step 784 with 534 non-finite parameter grads, all in
152
+ `model.*`. `scripts/cmfm_replay_failure.py` was extended to split `official` into its
153
+ sub-losses, which localised it exactly:
154
+
155
+ | component | bf16 nonfinite | fp32 nonfinite |
156
+ | --- | --- | --- |
157
+ | `official:rots_vf_loss` | **534** | 0 |
158
+ | `official:trans_loss` | 0 | 0 |
159
+ | `official:bb_atom_loss` | 0 | 0 |
160
+ | `official:dist_mat_loss` | 0 | 0 |
161
+ | `latent` | 0 | 0 |
162
+ | `collective` | 0 | 0 |
163
+
164
+ `calc_rot_vf` is the SO(3) log map; `d/dx arccos(x) = -1/sqrt(1-x^2)` diverges as the
165
+ relative rotation approaches 0 or π, and bf16's 8-bit mantissa rounds `x` to exactly ±1
166
+ there. The forward value stays finite (0.1927), only the backward blows up — which is why
167
+ the loss curves showed nothing.
168
+
169
+ **Casting the inputs to float32 was a no-op**: autocast re-casts the matmuls *inside*
170
+ `calc_rot_vf` to bf16 regardless of input dtype. The fix has to disable autocast around
171
+ the call. After the fix, bf16 matches fp32:
172
+
173
+ | | grad norm | absmax | nonfinite |
174
+ | --- | --- | --- | --- |
175
+ | before, bf16 | 0.593 | 0.159 | 534 |
176
+ | fp32 reference | 2.664 | 0.417 | 0 |
177
+ | after, bf16 | 2.621 | 0.400 | 0 |
178
+
179
+ The pre-fix "finite" gradient of 0.593 was itself wrong, not merely incomplete.
180
+
181
+ This is upstream BBFlow code, untouched by this project. It surfaced only once U was
182
+ frozen and the conditioning fed to the generator changed.
183
+
184
+ ## Files changed
185
+
186
+ In `bbflow_base` (synced to the cluster):
187
+
188
+ - `bbflow/data/pdb_dataloader_bbflow.py` — `_frame_rng(rank, draw)`; `_get_indices` /
189
+ `_get_group_indices` take an rng; all global `np.random` calls removed
190
+ - `bbflow/models/collective.py` — scalar trace normalizer; `variance_rel_floor` and the
191
+ `covariance_scale_raw_min` / `_floored` diagnostics removed; `target_covariance` and
192
+ `rate_weighted` arguments added for the redesign
193
+ - `bbflow/models/latent.py` — float64 Cholesky-QR with a one-shot ridge escalation;
194
+ diagnostics cast back to float32
195
+ - `bbflow/models/bbflow_module.py` — `freeze_mode_head` guard removed and the freeze
196
+ re-applied after the collective unfreeze; `cmfm_debug_losses` exposes
197
+ `official:<subloss>`; numerics log line reports `obs_target_var=[min,max]`;
198
+ `collective_basis_from_data` overrides the basis and target covariance from the cache
199
+ - `configs/train.yaml` — `collective_basis_from_data`, `collective_rate_weighted`
200
+ - `base_stages/10_train_cmfm_ddp.sh` — `COLLECTIVE_BASIS_FROM_DATA`,
201
+ `COLLECTIVE_RATE_WEIGHTED` passthrough
202
+ - `base_stages/10_train_cmfm_ddp.sh` — `FREEZE_MODE_HEAD` and `FREEZE_FOUNDATION` made
203
+ overridable (`${VAR:-false}`)
204
+ - `configs/experiment/default.yaml` — `collective_variance_rel_floor` removed
205
+ - `experiments/train.py` — warm-start loads into the full LightningModule, reports per
206
+ submodule
207
+ - `scripts/cmfm_replay_failure.py` — replays `official:<subloss>` components
208
+ - `scripts/surrogate_validation.py` — new. Ranks candidate covariance statistics against
209
+ the evaluation metric across systems, offline, no GPU. Run this *before* putting any
210
+ statistic in a loss.
211
+ - `scripts/scale_calibration_sweep.py` — new. Exact closed-form decomposition of the
212
+ ensemble error into scale, eigenvalue and eigenvector parts.
213
+ - `tests/test_sampler_frame_determinism.py` — new, 8 tests
214
+ - `tests/test_cmfm_failure_localization.py` — scalar-normalizer tests, basis-rotation
215
+ invariance test, `ridge=1e-14` → `1e-10` (below ~1e-12 the float64 gauge now correctly
216
+ raises)
217
+
218
+ Outside `bbflow_base`, **cluster-only, not in the Windows tree**:
219
+
220
+ - `/home/wangyusong/LD-FPG-main/gafl/gafl/models/flow_module.py` — both `calc_rot_vf`
221
+ calls wrapped in `torch.autocast(..., enabled=False)` with float32 inputs
222
+
223
+ Tests: `30 passed, 1 skipped`.
224
+
225
+ ## Evaluation: the method loses to the baseline
226
+
227
+ Training run `cmfm_frozen_20260731_022730` was stopped at epoch 24 of 100 because the
228
+ tracked metrics had plateaued. Inference on `epoch:024.ckpt` completed for all 82 held-out
229
+ proteins, 250 conformations each. `scripts/analysis_script.py` against the reference
230
+ trajectories gives:
231
+
232
+ ```
233
+ RMSF r RMSF MAE RMSF PW RMSD MAE PW RMSD PCA-W2 time
234
+ Med Med
235
+ BBFlow (Ours) 0.89 0.47 (0.01) 1.48 0.78 (0.01) 2.76 1.34 0.9
236
+ CMFM-frozen-ep24 0.84 0.55 1.51 1.17 2.47 1.57 -
237
+ ```
238
+
239
+ CORRECTION (2026-08-04): this header previously read `col4(PCA-W2)`. Column 4 is
240
+ Pairwise RMSD MAE; PCA-W2 is column 6. The decision rule below inherits the error.
241
+
242
+ Worse than the baseline on essentially every column, and 50% worse on the PCA-W2 column
243
+ that the collective term exists to control. Meanwhile `cross_cov_far_corr` had improved
244
+ 9x and held for 26 epochs.
245
+
246
+ ## Why the surrogate lied
247
+
248
+ `cross_cov_far_corr` is a Pearson correlation between covariance entries. Pearson
249
+ correlation is invariant under a positive affine transform, so multiplying every
250
+ displacement by a constant leaves it *exactly* unchanged while the evaluation metric moves
251
+ freely. `scripts/scale_calibration_sweep.py` checks this numerically rather than asserting
252
+ it: doubling every displacement on all 82 proteins gives
253
+
254
+ ```
255
+ max | rho(2x) - rho(1x) | = 0.00e+00
256
+ ```
257
+
258
+ Bit-identical. Twenty-six epochs of a rising curve measured something that cannot see the
259
+ direction the model actually moved in.
260
+
261
+ The correlation is not *useless* — across the 82 proteins it rank-correlates -0.600
262
+ (p = 3e-9) with the metric, so it ranks systems informatively. The precise statement is:
263
+ **valid as a cross-sectional ranking statistic, invalid as an optimization target, because
264
+ the model can move in its null space and did.** An earlier draft of this document said it
265
+ "was never a surrogate"; that was too strong.
266
+
267
+ ## Where the error actually is
268
+
269
+ `scripts/surrogate_validation.py` ranks candidate statistics against the metric across the
270
+ 82 systems (Spearman):
271
+
272
+ ```
273
+ abs_log_spectrum_err 0.883 cov_fro_rel 0.532
274
+ cross_cov_far_corr -0.600 abs_log_trace_ratio 0.506
275
+ rmsf_corr -0.565 abs_log_rmsf_ratio 0.458
276
+ top2_subspace_overlap -0.551 far_block_rel_err 0.547
277
+ ```
278
+
279
+ So the metric *is* determined by second moments — second-moment regularisation is not
280
+ hopeless in principle. `abs_log_spectrum_err` at 0.883 is partly tautological (it and the
281
+ metric are computed from the same projected matrices) and should not be read as a clean
282
+ 0.88.
283
+
284
+ `scripts/scale_calibration_sweep.py` then decomposes the error exactly. For zero-mean
285
+ Gaussians the squared Bures distance under a dilation `s` is a parabola,
286
+ `s^2 tr(A) + tr(B) - 2 s T`, minimised in closed form at `s* = T/tr(A)`; and over all
287
+ orthogonal alignments of `A` the minimum is `sum_i (sqrt(alpha_i) - sqrt(beta_i))^2` on the
288
+ sorted spectra. Both bounds are exact, no grid search:
289
+
290
+ ```
291
+ mean metric, as generated 0.5846
292
+ mean metric, one global scale = 1.080 0.5819 ( +0.4%)
293
+ mean metric, per-system optimal scale 0.5193 (+11.2%) oracle, not deployable
294
+ mean metric, eigenvectors made perfect 0.3817 (+34.7%)
295
+
296
+ of the squared error, the spectrum accounts for a median of 42%
297
+ log-spectrum slope, generated vs reference: median 1.12 (1.0 = correct shape)
298
+ optimal scale: median 1.175, IQR [1.000, 1.563], range [0.626, 3.368]
299
+ ```
300
+
301
+ **Direction error dominates: 58% of the squared error, and making the eigenvectors perfect
302
+ is worth three times any scale fix.** This matches the mode audit — U's 8-dimensional span
303
+ overlaps MD's top-2 principal directions at 0.353, which is 23x chance but far from 1.
304
+
305
+ The slope of 1.12 refutes a hypothesis that looked compelling: the amplitude head
306
+ `energy_out` outputs near-uniform values (0.7213 vs 0.7044 for the top two modes), and it
307
+ seemed to follow that the generated spectrum would be too flat. It is not — the slope
308
+ scatters 0.68 to 1.59 with median above 1. The generated ensemble comes out of the flow
309
+ conditioned on the latent, not from `U diag(energy) U^T`, so a uniform amplitude head does
310
+ not directly set the generated spectrum. That causal chain does not hold.
311
+
312
+ ## Ceilings, measured
313
+
314
+ | fix | ceiling | deployable |
315
+ | --- | --- | --- |
316
+ | one global scale | +0.4% | yes, and useless |
317
+ | per-system scale | +11.2% | no — needs the reference ensemble at test time |
318
+ | perfect eigenvectors | +34.7% | requires improving U, already at its stage-1 best |
319
+
320
+ No cheap entry point. The collective term targets neither of these: expanded, its numerator
321
+ is `2 Sym(z̃ᵀ r̃)/(G−1)` with `r` the endpoint residual — the shared `z̃` cancels, so it is a
322
+ reweighted duplicate of the objective that already has the correct minimiser, with a
323
+ self-normalising denominator, a `1/τ²` weight putting 53% of its mass where the rate signal
324
+ vanishes, and a null space along which the endpoint variance can only grow.
325
+
326
+ ## Settled
327
+
328
+ 1. `cross_cov_far_corr` is exactly scale invariant (measured: 0.00e+00 over 82 systems).
329
+ It cannot be an optimization target.
330
+ 2. The collective term is a noisy, biased, ratchet-carrying duplicate of the flow
331
+ objective, not a rate constraint.
332
+ 3. The evaluation metric is second-moment determined, so the general approach is not
333
+ ruled out — the specific objective is.
334
+ 4. The error is 58% eigenvector, 42% eigenvalue. Scale is 11%.
335
+ 5. Freezing the stage-1 mode head is the only change in this whole cycle that improved
336
+ anything measurable, and it was not enough.
337
+
338
+ ## Still open
339
+
340
+ 1. **`accumulate_grad_batches` changed from 4 to 1** between runs (`step=250 micro=1000`
341
+ vs `step=784 micro=784`), unexplained. Effective batch size differs 4x.
342
+ 2. **q is trained from scratch inside CMFM.** stage-1 trains only U; stage-2 (`qtrain`)
343
+ trains q, but no K=8 stage-2 checkpoint exists (only K=64 and K=4).
344
+ 3. **Two independent amplitude models coexist.** With `energy_from_q=false`, `energy`
345
+ comes from a softplus MLP head and feeds `local_cov_pred` / `cross_cov_pred` / the
346
+ displacement field, while the collective basis comes from the GMM's `Q`. Nothing ties
347
+ them together.
348
+ 4. **The Windows tree and the cluster tree are out of sync.** `scripts/cmfm_replay_failure.py`
349
+ existed only on Windows; `gafl/` exists only on the cluster.
350
+ 5. `mode_max_cosine_abs` is a data-dependent aggregate over the epoch, not a function of
351
+ the weights — with U frozen it still varies 0.70–0.83 with protein sampling.
352
+
353
+ The mathematical form of what would have to be solved is in
354
+ `docs/cmfm_problem_statement_2026-07-31.md`.
355
+
356
+ ## The three measurements that decided the redesign
357
+
358
+ Run with `scripts/scale_calibration_sweep.py` on the 82 evaluated systems, no GPU.
359
+
360
+ **Null.** The reference ensemble split against itself at matched sample sizes reads
361
+ `0.0429` against `0.3811` for the model — 11%. The eigenvalue residual is real, not a
362
+ finite-sample artefact. (The aligned bound carries a truncation floor, since projecting
363
+ onto the reference's top-k does not commute with a rotation; the null is exactly what
364
+ measures that floor, which is why it is the necessary control.)
365
+
366
+ **Ceiling.** Median `lambda_top = 321.6`, `lambda_bulk = 0.0181`, so the spike ratio is
367
+ ~17800 and `beta/(beta+gamma) = 0.996` at `G = 8`. **Eight samples carry essentially
368
+ perfect information about the leading eigenvector.** This is robust: pushing the ceiling
369
+ below 0.5 would need `lambda_bulk > 4.2`, i.e. a median per-direction RMS fluctuation of
370
+ 2 Angstrom across all ~600 directions, which is not the case. Even a 100x error in
371
+ `lambda_bulk` leaves the ceiling at 0.70.
372
+
373
+ So the group size was never the constraint. The barrier is that the objective's gradient
374
+ `d J2 / d x_hat` lies in `span(B)` — rank-4 support in a basis the model chose and which
375
+ walks. Corrections toward true directions outside that slice are geometrically
376
+ unreachable, not statistically unavailable.
377
+
378
+ **Water level.** Over-inflated directions sit at `10^-0.15` of the model's own rank-4
379
+ eigenvalue, on 39 of 82 systems. The sliding-mode picture holds: a blind direction
380
+ inflates until it would enter the basis, at which point it is pushed back. That single
381
+ mechanism accounts for both halves of the old anomaly — true top directions suppressed
382
+ (ratio 1–4) and blind directions inflated to the level (ratio 2–800).
383
+
384
+ ## What is running now
385
+
386
+ `COLLECTIVE_BASIS_FROM_DATA=true COLLECTIVE_RATE_WEIGHTED=false FREEZE_MODE_HEAD=true`,
387
+ warm-started from stage 1, 100 epochs, `RUN_DIR=.../cmfm_databasis_*`.
388
+
389
+ Three changes to the collective objective, all opt-in and defaulting to the old behaviour:
390
+
391
+ **1. The basis comes from the data** (`latent.collective_basis_from_data`). `B` is the
392
+ top-R of the cached `oracle_modes` — the right singular vectors of the centred MD
393
+ displacements, already unit norm in the flattened 3N space and sorted by variance, so it
394
+ is a drop-in for the q-derived basis. Cache coverage verified: 2780/2780 entries carry
395
+ `oracle_modes` and `oracle_energy`.
396
+
397
+ This removes the self-reference, and with it the walking basis and the ratchet. It also
398
+ changes what the objective can reach: a random 4-plane inside the mode span controls ~18%
399
+ of the reference variance, the data's top-4 controls the top-4 share.
400
+
401
+ **2. The normaliser is the population covariance.** With a data basis,
402
+ `collective_target_covariance = diag(oracle_energy[:R])` is exact, not estimated. The old
403
+ denominator was built from the same 8 endpoints as the numerator, which breaks the
404
+ conditional orthogonality that makes the objective unbiased and contracts the target
405
+ second moment by `O(1/(G-1))` ~ 14%.
406
+
407
+ **3. The `1/tau` weight is gone** (`latent.collective_rate_weighted=false`). It put 53% of
408
+ the integrated loss mass in `t > 0.9`, where the bridge has converged and the true rate is
409
+ zero. Expanding the objective shows the shared `z_t` cancels — it is an endpoint statistic,
410
+ so the `t` weighting was always free to choose.
411
+
412
+ ### Deliberately not done
413
+
414
+ **Cross-batch accumulation of the second moments.** With a data basis the *target* side is
415
+ already a cached constant, so the per-batch estimation noise there is gone. What remains is
416
+ in `C_dot_pred`, which is the model's own output; an EMA over that changes the gradient
417
+ semantics and is a larger change. It is the next candidate if this run also loses.
418
+
419
+ **The two amplitude models.** With `energy_from_q=false`, `energy` comes from a softplus
420
+ MLP head and feeds `local_cov_pred` / `cross_cov_pred` / the displacement field, while the
421
+ collective side now uses the cached MD energies. Nothing ties them together. Untouched.
422
+
423
+ ### The check that the basis actually took effect
424
+
425
+ In the first `cmfm-numerics` lines, `q_target_var` is now `oracle_energy[:R]` (population
426
+ MD variance) and `obs_target_var` is the 8-frame estimate in the same basis. **Both are now
427
+ MD quantities and should agree to within 8-sample noise, a relative standard deviation of
428
+ `sqrt(2/7) ~ 53%`.** Anything like the old 2–800x gap means the data basis did not take.
429
+
430
+ ### What decides whether it worked
431
+
432
+ Not `cross_cov_far_corr` — measured exactly scale invariant, it cannot see the failure
433
+ mode. The only judge is PCA-W2 from `scripts/analysis_script.py` after inference, against
434
+ the baseline's `0.78`. The previous run read `1.17`.
435
+
436
+ CORRECTION (2026-08-04): `0.78` and `1.17` are Pairwise RMSD MAE, not PCA-W2. The
437
+ corresponding PCA-W2 values are `1.34` (baseline) and `1.57` (previous run). Steering by
438
+ this paragraph as written selects on the wrong column; it cost one full evaluation cycle
439
+ before the mismatch was noticed. See `mdsubspace_handoff_2026-08-04.md` §6.
440
+
441
+ If this run also loses, the measured ceilings say what is left: scale is worth 11%, perfect
442
+ eigenvectors 35%, and the information to reach the latter is present in the data at
443
+ `G = 8`. What would remain untried is cross-batch accumulation, and reconciling the two
444
+ amplitude models.
445
+
446
+ ## Paths
447
+
448
+ ```
449
+ repo (cluster) ~/LD-FPG-main/bbflow_base
450
+ gafl (cluster only) /home/wangyusong/LD-FPG-main/gafl
451
+ repo (windows) D:\acltitlegeneration\abcd\protein\LD-FPG-main\protein\bbflow_base
452
+ checkpoints /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints
453
+ base BBFlow ckpt /home/wangyusong/LD-FPG-main/bbflow_base/models/bbflow-0.1/bbflow-0.1.ckpt
454
+ motion cache /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
455
+ ATLAS data /data/shared/wangyusong/Atlas
456
+ dataset CSVs /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/
457
+ stage-1 U <checkpoints>/stage1_eq2U_K8_20260720_022436/last.ckpt
458
+ current run <checkpoints>/cmfm_frozen_20260731_022730/
459
+ ```
460
+
461
+ Note the three different roots: checkpoints under `/data/shared/.../atals/`, the motion
462
+ cache under `/home/.../LD-FPG-main/`, ATLAS trajectories under `/data/shared/.../Atlas`
463
+ (capital A, distinct from the `atals` directory).
464
+
465
+ ## Commands
466
+
467
+ Training, frozen U, warm-started from stage 1:
468
+
469
+ ```bash
470
+ cd ~/LD-FPG-main/bbflow_base && FREEZE_MODE_HEAD=true PYTORCH_CUDA_ALLOC_CONF=expandable_segments:True MAX_STEPS=-1 MAX_EPOCHS=100 CMFM_NUMERICS_LOG_INTERVAL=200 DIAGNOSTIC_INTERVAL_STEPS=200 EXTRA_HYDRA_ARGS="experiment.use_tqdm=false" BASE_CKPT=/data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/stage1_eq2U_K8_20260720_022436/last.ckpt FINGERPRINT_CACHE=/home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt RUN_DIR=/data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/cmfm_frozen_$(date +%Y%m%d_%H%M%S) nohup bash base_stages/10_train_cmfm_ddp.sh > /tmp/cmfm_frozen.log 2>&1 &
471
+ ```
472
+
473
+ `experiment.use_tqdm=false` is the progress-bar switch — `+experiment.trainer.enable_progress_bar`
474
+ collides with a keyword `train.py` already passes. `CMFM_NUMERICS_LOG_INTERVAL` counts
475
+ **microbatches**, so it equals steps only when `accumulate_grad_batches=1`.
476
+
477
+ Startup verification (all three must appear):
478
+
479
+ ```bash
480
+ grep -nE "Loaded warm start|freeze-mode-head|grad-flow-check" /tmp/cmfm_frozen.log
481
+ ```
482
+
483
+ Metric trend:
484
+
485
+ ```bash
486
+ grep -E "cross_cov_far_corr|mode_max_cosine_abs|official_loss" /tmp/cmfm_frozen.log
487
+ ```
488
+
489
+ Step progress (the CSV is written every microbatch, independent of the print interval):
490
+
491
+ ```bash
492
+ RUN=$(ls -dt /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/cmfm_frozen_*/ | head -1); n=$(( $(wc -l < $RUN/cmfm_numerics_rank0.csv) - 1 )); echo "step=$n / 828 per epoch"
493
+ ```
494
+
495
+ Mode/MD alignment audit (`--atlas_root` triggers a full-trajectory MD PCA, which is more
496
+ trustworthy than the cached oracle modes):
497
+
498
+ ```bash
499
+ cd ~/LD-FPG-main/bbflow_base && python scripts/diagnose_mode_pca_alignment.py --ckpt_path <ckpt> --csv_path /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/cmfm_k8_r4_rootfix_probe_20260729_185258/valid.csv --motion_target_cache_path /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt --atlas_root /data/shared/wangyusong/Atlas --output_dir /tmp/audit --num_proteins 5 --num_md_pcs 8 --device cuda
500
+ ```
501
+
502
+ Failure replay with sub-loss attribution:
503
+
504
+ ```bash
505
+ cd ~/LD-FPG-main/bbflow_base && CUDA_VISIBLE_DEVICES=0 python scripts/cmfm_replay_failure.py --dump <run>/cmfm_failure_dumps/rank<N>_epoch<E>_step<S>_micro<M>.pt --precision both --device cuda
506
+ ```
507
+
508
+ Replay each rank's dump separately: DDP all-reduces gradients during backward, so one
509
+ rank's inf poisons all of them and every rank writes a dump. The replay is single-process
510
+ and only tests that rank's own data — a clean replay on one rank does not clear the step.
511
+
512
+ Inference:
513
+
514
+ ```bash
515
+ cd ~/LD-FPG-main/bbflow_base && CKPT="<checkpoints>/cmfm_frozen_20260731_022730/epoch:024.ckpt" RUN_NAME=cmfm_frozen_ep24 nohup bash base_stages/11_infer_cmfm.sh > /tmp/cmfm_infer.log 2>&1 &
516
+ ```
517
+
518
+ Before any relaunch, confirm the GPUs are actually free — a killed DDP run holds memory
519
+ for a while and the next launch OOMs:
520
+
521
+ ```bash
522
+ pkill -9 -u $USER -f experiments/train.py; sleep 12; nvidia-smi --query-gpu=index,memory.used --format=csv
523
+ ```
524
+
525
+ ## Practical notes
526
+
527
+ - `CUDA_VISIBLE_DEVICES` gets left over in the shell from launcher runs; standalone
528
+ scripts need it set explicitly (`CUDA_VISIBLE_DEVICES=0 python ...`).
529
+ - `MAX_STEPS` may be exported in the shell from earlier debugging; pass `MAX_STEPS=-1`
530
+ explicitly or a 100-epoch run silently stops at 220 steps.
531
+ - Checkpoint filenames contain a colon (`epoch:024.ckpt`); quote them.
532
+ - `ls *.ckpt | head -1` returns the **earliest** epoch. Use `ls -v ... | tail -1`.
533
+ - Diagnostics added by this project use `print(..., flush=True)` rather than `logging`,
534
+ so they survive `nohup` redirects regardless of how Hydra reconfigures the handlers.
bbflow_base/docs/cmfm_problem_statement_2026-07-31.md ADDED
@@ -0,0 +1,169 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Open problems, in mathematical form
2
+
3
+ Stated entirely in terms of probability measures on a Euclidean space, their second
4
+ moments, and estimators thereof. No domain background is needed or used.
5
+
6
+ ## Setting
7
+
8
+ Fix `d` (here `d ≈ 3·10^2` to `2·10^3`). For each index `p` in a finite set of size 82
9
+ there is an unknown probability measure `ν_p` on `R^d` with finite second moment; write
10
+ `Σ_p = Cov(ν_p)`. We have `~10^4` i.i.d. draws from each.
11
+
12
+ A parametric family `(P_θ)` of measures on `R^d` is available, together with a sampler.
13
+ Write `Ĉ_p(θ) = Cov(P_θ^{(p)})`.
14
+
15
+ **Discrepancy.** Let `V_p ∈ R^{d×k}` (`k = 10`) hold the leading eigenvectors of `Σ_p`.
16
+ Define, with `A = V_pᵀ Ĉ_p V_p` and `B = V_pᵀ Σ_p V_p`,
17
+
18
+ ```
19
+ D_p(θ) = W₂( N(0,A), N(0,B) ) / sqrt( tr B )
20
+ = sqrt( tr A + tr B − 2 tr( (B^{1/2} A B^{1/2})^{1/2} ) ) / sqrt( tr B )
21
+ ```
22
+
23
+ the Bures–Wasserstein distance, made dimensionless by the reference scale. The goal is to
24
+ choose `θ` minimising `D̄ = (1/82) Σ_p D_p`.
25
+
26
+ **Constraint.** During minimisation, `D_p` is not available. What is available at each step
27
+ is `G = 8` draws from `P_θ^{(p)}` and `G` matched draws from `ν_p`, for one `p` at a time.
28
+ Any objective must be a function of those `2G` points.
29
+
30
+ ## Measured facts
31
+
32
+ Let `T_s` denote the dilation `x ↦ x₀ + s(x − x₀)` and let `O(k)` act on `A` by
33
+ conjugation. On a particular `θ`, over the 82 instances:
34
+
35
+ ```
36
+ D̄(θ) = 0.5846
37
+ min over one common s>0 of D̄(T_s # P_θ) = 0.5819 ( 0.4% )
38
+ mean over p of min over s>0 of D_p(T_s#P_θ) = 0.5193 (11.2% )
39
+ mean over p of min over Q∈O(k) of D_p(Q·A·Qᵀ)= 0.3817 (34.7% )
40
+ ```
41
+
42
+ The third line is an oracle: the minimising `s` differs per instance, median `1.175`,
43
+ interquartile range `[1.000, 1.563]`, full range `[0.626, 3.368]`. The fourth line is the
44
+ exact bound `min_Q W₂²(QAQᵀ, B) = Σ_i (√α_i − √β_i)²` on the sorted spectra of `A` and `B`.
45
+
46
+ Median over `p` of `[min_Q W₂²] / [W₂²]` is `0.42`. So **58% of the squared discrepancy is
47
+ attributable to misalignment of eigenvectors and 42% to the eigenvalues**, and dilation
48
+ accounts for only 11%.
49
+
50
+ The slope of `log α_i` regressed on `log β_i` has median `1.12` over instances, with
51
+ per-instance values from `0.68` to `1.59`: the eigenvalue error is not a systematic
52
+ flattening or steepening.
53
+
54
+ Separately, a functional `ρ(P, ν)` — the Pearson correlation between corresponding
55
+ long-range entries of the two covariance matrices — was used as the optimisation signal. It
56
+ satisfies `ρ(T_s # P, ν) = ρ(P, ν)` identically (verified numerically to `0.00e+00` on all
57
+ 82 instances at `s = 2`), while `D` varies freely along that orbit. Across instances at
58
+ fixed `θ`, `ρ` rank-correlates `−0.600` with `D`.
59
+
60
+ ## P1. Admissible surrogates
61
+
62
+ A functional `S(P, ν)` used as an optimisation target induces a group
63
+ `Γ_S = { g : S(g#P, ν) = S(P, ν) for all P }`. Minimising `S` places no constraint on the
64
+ `Γ_S`-orbit of `P`.
65
+
66
+ > **Problem.** Characterise the functionals of `(Cov P, Cov ν)` that are (i) estimable from
67
+ > `G` samples per side with bias `o(1)` and variance `O(1/G)`, and (ii) satisfy
68
+ > `Γ_S ∩ { g : D(g#P, ν) ≢ D(P, ν) } = {id}`.
69
+ >
70
+ > Is `Γ_S` trivial achievable at all under (i)? Every scale-sensitive statistic requires
71
+ > estimating a magnitude, whose relative error from `G` samples is `Θ(1/√G)`; every
72
+ > scale-free statistic has the dilation group in its kernel. Quantify the trade-off: for a
73
+ > target accuracy `ε` in `D`, what is the minimum `G`?
74
+
75
+ The observed failure is the case `Γ_S ⊇ {T_s}` with the minimising trajectory travelling
76
+ along that orbit. A criterion that would have rejected `ρ` a priori is the deliverable.
77
+
78
+ ## P2. Can `G = 8` constrain eigenvectors at all?
79
+
80
+ This is the decisive question, since eigenvector error is 58% of the discrepancy.
81
+
82
+ The empirical covariance of `G = 8` points in `R^d` has rank `≤ 7`, against `d ≥ 300`. In
83
+ the spiked model `Σ = I + Σ_j h_j u_j u_jᵀ`, the leading sample eigenvector `û` of an
84
+ `n`-sample covariance satisfies, as `d, n → ∞` with `d/n → γ`,
85
+
86
+ ```
87
+ |⟨û, u⟩|² → 0 if h ≤ √γ
88
+ |⟨û, u⟩|² → (1 − γ/h²)/(1 + γ/h) if h > √γ
89
+ ```
90
+
91
+ Here `γ = d/G ≈ 40` to `250`, so `√γ ≈ 6` to `16`.
92
+
93
+ > **Problem.** For `n = G` fixed and small (not `n → ∞`), determine whether *any* statistic
94
+ > of the two `G`-sample empirical covariances carries information about the angle between
95
+ > the population eigenvectors, and if so give the minimax rate. Equivalently: is there a
96
+ > function `f` of `2G` points in `R^d` with
97
+ > `E f > 0` when the population leading eigenvectors are aligned and `E f = 0` when they
98
+ > are orthogonal, whose variance does not swamp the gap at `G = 8`, `d ≈ 500`?
99
+ >
100
+ > If not, then **no objective computable from groups of 8 can address the 58% term**,
101
+ > independently of how it is designed, and the group size is the binding constraint rather
102
+ > than the choice of functional.
103
+
104
+ A negative answer here settles the whole approach. A positive answer must come with the
105
+ required `G`.
106
+
107
+ ## P3. Estimating `D` itself
108
+
109
+ `D` is a Bures distance between two covariances, each estimated from samples. For
110
+ `Ĉ` from `n` and `Σ̂` from `m` samples, `W₂(N(0,Ĉ), N(0,Σ̂))` is a biased estimator of
111
+ `W₂(N(0,C), N(0,Σ))` — the matrix square root is concave in the Loewner order, so the
112
+ trace term is systematically over- or under-estimated depending on the regime.
113
+
114
+ > **Problem.** Give the bias of `tr((Σ̂^{1/2} Ĉ Σ̂^{1/2})^{1/2})` to first order in `1/n`,
115
+ > `1/m` for `Ĉ`, `Σ̂` Wishart with `n, m` degrees of freedom in dimension `k`, and construct
116
+ > a debiased estimator. In the regime of interest `k = 10`, `n = 8`: `Ĉ` is singular. Does
117
+ > a useful estimator exist when `n < k`, or must the objective be restricted to
118
+ > `R ≤ n − 1` dimensions?
119
+
120
+ The implementation used `R = 4 < G − 1 = 7`, which is consistent with the second option but
121
+ was not derived.
122
+
123
+ ## P4. Propagation from a subspace
124
+
125
+ The objective constrained a projection onto a fixed `R = 4` dimensional subspace `B` of
126
+ `R^d`, while `D` is measured on a `k = 10` dimensional subspace `V`, and both sit inside
127
+ `R^d`.
128
+
129
+ > **Problem.** Bound `D` in terms of a discrepancy measured only on `span(B)`, as a
130
+ > function of the principal angles between `span(B)` and `span(V)` and of the spectral
131
+ > decay of `Σ`. Given `G`, and hence a maximum usable `R` from P3, what is the optimal
132
+ > choice of `span(B)`, and how much of `D` is reachable at all?
133
+
134
+ Note the subspace actually used was the leading eigenspace of the model's *own* implied
135
+ covariance, i.e. a function of `θ`, not of the data — so the discrepancy was measured in a
136
+ basis chosen by the object being measured. Whether that is admissible is a sub-question:
137
+ characterise the fixed points of `θ ↦ argmin_θ S(θ; B(θ))` and whether the degenerate ones
138
+ (`B(θ)` pointing where `ν` has no variance, making `S ≈ 0` vacuously) are attracting.
139
+
140
+ ## P5. The residual eigenvalue error
141
+
142
+ Even with eigenvectors made perfect the discrepancy is `0.3817`, and the eigenvalue error
143
+ is not a systematic distortion: the `log α` vs `log β` slope has median `1.12` and spread
144
+ `0.68`–`1.59` across instances.
145
+
146
+ > **Problem.** Characterise this error. Is it consistent with the sampling noise of
147
+ > estimating `A` from finitely many draws of `P_θ` (i.e. not a modelling error at all), or
148
+ > is there a systematic component? Give a test that separates the two using the available
149
+ > `250` draws per instance, and if systematic, the functional form.
150
+
151
+ If it is sampling noise, the `42%` term is an artefact of finite generation and the true
152
+ decomposition is even more dominated by direction error.
153
+
154
+ ## What an answer looks like
155
+
156
+ In descending order of what it would settle:
157
+
158
+ 1. **P2 negative** — no statistic of `G = 8` samples constrains eigenvectors at
159
+ `d ≈ 500`. Then the group-based construction is dead regardless of the objective, and
160
+ the only remaining levers act on the representation, not the loss.
161
+ 2. **P2 positive with a required `G`** — gives the group size at which the approach becomes
162
+ viable, and the cost is then a straightforward compute question.
163
+ 3. **P1 criterion** — a test applicable to any proposed statistic before any minimisation
164
+ is run. This is the cheap general safeguard; the failure recorded here cost two days and
165
+ would have been caught by one dilation.
166
+ 4. **P5 resolution** — decides whether `42%` is real or an artefact, and hence whether the
167
+ eigenvalue term is worth attacking at all.
168
+ 5. **P3, P4** — needed to design a replacement objective, but only after P2 says one can
169
+ exist.
bbflow_base/docs/covariance_matching_problem.md ADDED
@@ -0,0 +1,209 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Matching covariances in high dimension under a small-sample constraint
2
+
3
+ Self-contained. Stated entirely in terms of probability measures on a Euclidean space,
4
+ their second moments, and estimators thereof. No application background is needed.
5
+
6
+ ## 1. Setting
7
+
8
+ Fix `d`, with `d` ranging over `[3·10², 2·10³]` across instances.
9
+
10
+ Let `P` be an index set, `|P| = 82`. For each `p ∈ P` there is an unknown probability
11
+ measure `ν_p` on `R^d` with finite second moment; write `Σ_p = Cov(ν_p)`. Available:
12
+ `N ≈ 10⁴` i.i.d. draws from each `ν_p`.
13
+
14
+ A parametric family `(P_θ)` of measures on `R^d` is available together with a sampler.
15
+ Write `Ĉ_p(θ) = Cov(P_θ^{(p)})`. Available at evaluation time: `n = 250` draws per `p`.
16
+
17
+ **Discrepancy.** Let `V_p ∈ R^{d×k}`, `k = 10`, have as columns the leading `k`
18
+ eigenvectors of `Σ_p` (orthonormal). Put
19
+
20
+ ```
21
+ A_p = V_pᵀ Ĉ_p V_p , B_p = V_pᵀ Σ_p V_p (k×k, PSD)
22
+
23
+ D_p = W₂( N(0,A_p), N(0,B_p) ) / (tr B_p)^{1/2}
24
+ = [ tr A + tr B − 2 tr( (B^{1/2} A B^{1/2})^{1/2} ) ]^{1/2} / (tr B)^{1/2}
25
+ ```
26
+
27
+ the Bures–Wasserstein distance, made dimensionless by the reference scale.
28
+
29
+ **Objective.** Choose `θ` minimising `D̄(θ) = (1/82) Σ_p D_p(θ)`.
30
+
31
+ **Optimisation constraint.** During minimisation `D_p` is not available. What is available
32
+ at each step is `G = 8` draws from `P_θ^{(p)}` and `G` matched draws from `ν_p`, for one
33
+ `p` at a time. Any objective must be a function of those `2G` points.
34
+
35
+ **Structure of the family.** A draw from `P_θ^{(p)}` has the form
36
+
37
+ ```
38
+ x = μ_p + U_p(θ) c + ε , c ~ q_θ^{(p)} on R^K , K = 8 , ε ⊥ c
39
+ ```
40
+
41
+ with `U_p(θ) ∈ R^{d×K}`. Hence
42
+
43
+ ```
44
+ Ĉ_p(θ) = U_p Γ U_pᵀ + Ψ_p , Γ = Cov(c) ⪰ 0 , Ψ_p = Cov(ε) ⪰ 0
45
+ ```
46
+
47
+ so the part of `Ĉ_p` controlled by `Γ` has rank at most `K = 8`, while `D_p` is measured
48
+ on a `k = 10` dimensional subspace. Both `U_p` and `q_θ` are functions of `θ`; `Ψ_p` is
49
+ the covariance of the sampler's residual noise and is not directly parametrised.
50
+
51
+ ## 2. Measurements
52
+
53
+ At one particular `θ`, over the 82 instances. `T_s` denotes the dilation
54
+ `x ↦ x₀ + s(x − x₀)`; `O(k)` acts on `A` by conjugation.
55
+
56
+ ```
57
+ D̄(θ) = 0.5846
58
+ min over one common s>0 of D̄(T_s # P_θ) = 0.5819 ( 0.4% )
59
+ mean_p min_{s>0} D_p(T_s # P_θ) = 0.5193 (11.2% )
60
+ mean_p min_{Q∈O(k)} D_p(Q A_p Qᵀ) = 0.3817 (34.7% )
61
+ ```
62
+
63
+ The third line is an oracle: the minimising `s` differs per instance, median `1.175`,
64
+ interquartile range `[1.000, 1.563]`, full range `[0.626, 3.368]`. The fourth line uses the
65
+ exact identity `min_{Q∈O(k)} W₂²(QAQᵀ, B) = Σ_i (√α_i − √β_i)²` on the sorted spectra
66
+ `α` of `A` and `β` of `B`.
67
+
68
+ Median over `p` of `[min_Q W₂²] / [W₂²]` is `0.42`. Hence **58% of the squared discrepancy
69
+ is attributable to misalignment of eigenvectors and 42% to the eigenvalues**, while
70
+ dilation accounts for 11%.
71
+
72
+ The slope of `log α_i` regressed on `log β_i` has median `1.12` over instances, with
73
+ per-instance values from `0.68` to `1.59`: the eigenvalue error is not a systematic
74
+ flattening or steepening.
75
+
76
+ **A surrogate that failed.** A functional `ρ(P, ν)` — the Pearson correlation between
77
+ corresponding entries of the two covariance matrices, restricted to an index set of
78
+ widely separated coordinate pairs — was used as the optimisation signal. It satisfies
79
+ `ρ(T_s # P, ν) = ρ(P, ν)` identically (verified numerically to `0.00e+00` on all 82
80
+ instances at `s = 2`), while `D` varies freely along that orbit. Across instances at
81
+ fixed `θ`, `ρ` rank-correlates `−0.600` with `D`. Optimising `ρ` improved it by a factor
82
+ of 9 and held for 26 optimisation epochs while `D` did not improve.
83
+
84
+ ## 3. Questions
85
+
86
+ ### Q1. The floor imposed by the family
87
+
88
+ Let `U ∈ R^{d×K}` and `V ∈ R^{d×k}` have orthonormal columns, `K = 8 < k = 10`. Put
89
+ `M = VᵀU ∈ R^{k×K}`, whose singular values are the cosines of the principal angles
90
+ `φ_1 ≤ … ≤ φ_K` between `span(U)` and `span(V)`. For `Ψ ⪰ 0` fixed,
91
+
92
+ ```
93
+ A(Γ) = Vᵀ( U Γ Uᵀ + Ψ ) V = M Γ Mᵀ + VᵀΨV , Γ ⪰ 0
94
+ ```
95
+
96
+ > Determine
97
+ > ```
98
+ > F = inf_{Γ ⪰ 0} D( A(Γ), B )
99
+ > ```
100
+ > as a function of `{φ_i}`, the spectrum of `B`, and `VᵀΨV`. Closed form, or a bound
101
+ > tight enough to evaluate numerically at `k = 10`.
102
+ >
103
+ > The case `Ψ = 0` reduces to: what is the Bures distance from `B` to the set
104
+ > `{ M Γ Mᵀ : Γ ⪰ 0 }`, i.e. to the PSD matrices whose column space lies in `range(M)`?
105
+
106
+ `F` depends only on the family and the target, not on the choice of objective function.
107
+ Both `U` and `V` are computable in the application, so a formula for `F` is directly
108
+ evaluable.
109
+
110
+ ### Q2. Which statistics are admissible as optimisation targets
111
+
112
+ A functional `S(P, ν)` used as an optimisation target induces a group
113
+
114
+ ```
115
+ Γ_S = { g : S(g#P, ν) = S(P, ν) for all P }.
116
+ ```
117
+
118
+ Minimising `S` places no constraint on the `Γ_S`-orbit of `P`. The failure recorded in
119
+ §2 is the case `Γ_S ⊇ { T_s }` with the minimising trajectory travelling along that orbit.
120
+
121
+ > Characterise the functionals of `(Cov P, Cov ν)` that are
122
+ > **(i)** estimable from `G` samples per side with bias `o(1)` and variance `O(1/G)`, and
123
+ > **(ii)** satisfy `Γ_S ∩ { g : D(g#P, ν) ≢ D(P, ν) } = {id}`.
124
+ >
125
+ > Is (ii) achievable at all under (i)? Every scale-sensitive statistic requires estimating
126
+ > a magnitude, whose relative error from `G` samples is `Θ(1/√G)`; every scale-free
127
+ > statistic has the dilation group in its kernel. Quantify the trade-off: for a target
128
+ > accuracy `ε` in `D`, what is the minimum `G`?
129
+ >
130
+ > A criterion applicable to a candidate `S` *before* any minimisation is run would be the
131
+ > most useful form of answer.
132
+
133
+ **Sub-question (the regime `G < k`).** The empirical covariance of `G = 8` points in `R^d`
134
+ has rank `≤ 7`, against `k = 10`, so the sample `Â` is singular.
135
+
136
+ > Give the bias of `tr( (Σ̂^{1/2} Ĉ Σ̂^{1/2})^{1/2} )` to first order in `1/n`, `1/m`,
137
+ > for `Ĉ`, `Σ̂` Wishart with `n`, `m` degrees of freedom in dimension `k`, and construct a
138
+ > debiased estimator. Does a useful estimator exist when `n < k`, or must the objective be
139
+ > restricted to `R ≤ n − 1` dimensions?
140
+
141
+ **Sub-question (eigenvector information at small `G`).** In the spiked model
142
+ `Σ = I + Σ_j h_j u_j u_jᵀ`, the leading sample eigenvector `û` from `n` samples satisfies,
143
+ as `d, n → ∞` with `d/n → γ`,
144
+
145
+ ```
146
+ |⟨û, u⟩|² → 0 if h ≤ √γ
147
+ |⟨û, u⟩|² → (1 − γ/h²)/(1 + γ/h) if h > √γ
148
+ ```
149
+
150
+ Here `γ = d/G ≈ 40` to `250`, so `√γ ≈ 6` to `16`. This is an asymptotic statement; the
151
+ regime of interest has `n = G = 8` fixed and small.
152
+
153
+ > For `n = G` fixed and small, determine whether *any* statistic of the two `G`-sample
154
+ > empirical covariances carries information about the angle between the population
155
+ > eigenvectors, and if so give the minimax rate. Equivalently: is there a function `f` of
156
+ > `2G` points in `R^d` with `E f > 0` when the population leading eigenvectors are aligned
157
+ > and `E f = 0` when they are orthogonal, whose variance does not swamp the gap at
158
+ > `G = 8`, `d ≈ 500`?
159
+
160
+ ### Q3. Power of the comparison
161
+
162
+ Six parameter values `θ_1 … θ_6` were compared by their reported aggregate. The reported
163
+ values span a range of about `0.26` in the units of the reported metric, with a bootstrap
164
+ standard error of about `0.03` on each; the three best lie within one standard error of
165
+ each other.
166
+
167
+ > **(a)** Give `Var(D̂_p)` for `D̂_p` built from `n = 250` draws of `P_θ` and `m ≈ 10⁴`
168
+ > draws of `ν_p`, and `Var(D̄̂)` for the mean over 82 instances.
169
+ >
170
+ > **(b)** The comparisons across `θ` are currently made on the aggregate, unpaired.
171
+ > Consider instead the paired differences `Δ_p = D_p(θ) − D_p(θ′)`. Since `D_p` is
172
+ > expected to be strongly correlated across `θ` (instance difficulty dominating the
173
+ > variance), `Var(Δ) ≪ 2 Var(D_p)`. Give the minimum detectable difference for both the
174
+ > paired and unpaired comparison at 82 instances, and state which of the observed
175
+ > differences are resolvable under each.
176
+
177
+ ## 4. Known unknowns
178
+
179
+ Two things are **not** established and should not be assumed by a reader:
180
+
181
+ 1. **Normalisation consistency.** The quantity `D̄ = 0.5846` in §2 is normalised by
182
+ `(tr B)^{1/2}`. The six aggregate values referred to in Q3 come from a separate
183
+ evaluation routine and lie in the range `1.31`–`1.57`. These cannot be the same
184
+ functional. Whether the 58% / 42% / 11% decomposition of §2 transfers to the quantity
185
+ used in Q3 has not been verified. Q1 and Q3 are individually well posed regardless;
186
+ only a claim linking them would require this to be settled first.
187
+
188
+ 2. **Which `θ` the §2 measurements were taken at.** The decomposition in §2 was computed at
189
+ one parameter value. Whether it is stable across the six `θ` in Q3 has not been checked.
190
+
191
+ ## 5. Form of a useful answer
192
+
193
+ In descending order of what it would settle:
194
+
195
+ 1. **Q1 with a formula for `F`.** Evaluating it on the available `U` and `V` decides
196
+ whether the family or the objective is the binding constraint. This is the only
197
+ question whose answer immediately changes what is worth attempting.
198
+ 2. **Q2, the eigenvector sub-question, negative.** If no statistic of `2G` points
199
+ constrains eigenvector angle at `d ≈ 500`, then no objective computable from groups of
200
+ 8 can address the 58% term, and `G` rather than the choice of functional is the binding
201
+ constraint.
202
+ 3. **Q2, the eigenvector sub-question, positive with a required `G`.** Gives the group
203
+ size at which the construction becomes viable.
204
+ 4. **Q2, the admissibility criterion.** A test applicable to any proposed statistic before
205
+ any minimisation is run.
206
+ 5. **Q3.** Determines whether the observed differences between parameter values are real,
207
+ and hence whether the comparisons made so far carry information at all.
208
+ 6. **Q2, the `G < k` estimator sub-question.** Needed to design a replacement objective,
209
+ but only after the eigenvector sub-question says one can exist.
bbflow_base/docs/experiment_trace_2026-07-05.md ADDED
@@ -0,0 +1,1367 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # BBFlow / Latent Motion Experiments Trace
2
+
3
+ Date: 2026-07-05
4
+ Scope: local record of experiments, code changes, key configs, what each run tried to prove, and what it actually proved.
5
+
6
+ This document is a working memory file. It should be updated whenever a run is launched, evaluated, killed, or reinterpreted.
7
+
8
+ ## Core Goal
9
+
10
+ We are trying to improve BBFlow downstream ensemble quality on ATLAS test proteins, especially:
11
+
12
+ - RMSF correlation / MAE
13
+ - Pairwise RMSD MAE
14
+ - PCA W2
15
+
16
+ The central scientific question became:
17
+
18
+ > The latent condition/prior can improve some covariance/proxy statistics, but does that improvement actually transfer through the generator into saved conformations and downstream metrics?
19
+
20
+ So far, multiple proxy metrics have failed to directly predict downstream performance. This motivated the current emphasis on mini-downstream validation and saved-conformation evaluation.
21
+
22
+ ## Important Code Files
23
+
24
+ Core model/training:
25
+
26
+ - `bbflow/models/latent.py`
27
+ - Latent motion prior.
28
+ - MoG coefficient prior.
29
+ - Motion target reconstruction losses.
30
+ - Added `pca_alignment_loss`.
31
+
32
+ - `bbflow/models/bbflow_module.py`
33
+ - Integrates latent prior into training/inference.
34
+ - Looks up motion targets by current batch `pdb_name`.
35
+ - Added `lambda_pca_align` handling and PCA alignment logging.
36
+
37
+ - `base_stages/00_train_final_mog_ddp.sh`
38
+ - Main 3/2-GPU latent training launcher.
39
+ - Supports `LAMBDA_MODE_ORTH`, `LAMBDA_MODE_RECON`, `LAMBDA_PCA_ALIGN`, `PCA_ALIGN_TOP_M`.
40
+ - Uses `experiment.warm_start` for official/model warm start or Lightning resume depending on checkpoint type.
41
+
42
+ Downstream / inference:
43
+
44
+ - `reproduction/02_sample_test.sh`
45
+ - Standard inference.
46
+ - Saves conformations as `sampled_conformations.pdb`.
47
+ - Supports `CONDITION_MODE`, `CONDITION_SCALE`, `POSTPROCESS_BFACTORS`, `SAMPLE_BATCH_SIZE`, `MAX_NUM_RES_SQUARED`.
48
+
49
+ - `reproduction/03_evaluate.sh`
50
+ - Standard downstream evaluation on saved conformations.
51
+ - Computes RMSD/RMSF/PCA-W2.
52
+
53
+ Analysis/diagnostics:
54
+
55
+ - `scripts/diagnose_mode_pca_alignment.py`
56
+ - Compares learned prior modes against MD PCA modes on a chosen CSV.
57
+ - Outputs `summary.json` and per-protein CSV.
58
+
59
+ - `scripts/evaluate_saved_condition_covariances.py`
60
+ - Evaluates generated/saved ensembles against MD covariance targets.
61
+
62
+ - `scripts/plot_epoch_metrics.py`
63
+ - Plots training metrics from `latent_train_epoch_metrics.csv`.
64
+
65
+ - `scripts/diagnose_training_contraction.py`
66
+ - Added after the PCA-align scale sweep.
67
+ - Reads existing epoch metrics and saved `sampled_conformations.pdb` files.
68
+ - Diagnoses whether downstream degradation is caused by ensemble amplitude contraction, MD-PC projection variance loss, or proxy/downstream mismatch.
69
+
70
+ - `scripts/extract_shape_fingerprints.py`
71
+ - Generates motion-target cache.
72
+ - Newer caches should include alignment version `row_kabsch_u_d_vh_v1`.
73
+ - Can store `oracle_modes`, `oracle_energy`, `oracle_mean_disp`.
74
+
75
+ - `scripts/validate_motion_target_cache.py`
76
+ - Checks required cache fields before expensive training.
77
+
78
+ ## Important Data / Checkpoint Paths
79
+
80
+ Official BBFlow checkpoint:
81
+
82
+ ```text
83
+ /home/wangyusong/LD-FPG-main/bbflow/models/bbflow-0.1/bbflow-0.1.ckpt
84
+ ```
85
+
86
+ Official checkpoint rerun output:
87
+
88
+ ```text
89
+ /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/official_bbflow_rerun_250
90
+ ```
91
+
92
+ Main long finetune run:
93
+
94
+ ```text
95
+ /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_official_modelonly_long_finetune_orth1_recon0_100ep_3gpu_20260630_191404
96
+ ```
97
+
98
+ PCA-align 0.1 run:
99
+
100
+ ```text
101
+ /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_pca_align_orth1_recon0_30ep_3gpu_20260704_055826
102
+ ```
103
+
104
+ Scratch run currently being resumed:
105
+
106
+ ```text
107
+ /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_scratch_mog_k8_m2_orth1_recon0_30ep_2gpu_20260703_192644
108
+ ```
109
+
110
+ Motion target caches:
111
+
112
+ ```text
113
+ /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
114
+ /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1_oracle.pt
115
+ ```
116
+
117
+ Notes:
118
+
119
+ - `_kabsch_v1.pt` is the non-oracle cache used by scratch run.
120
+ - `_kabsch_v1_oracle.pt` includes oracle PCA fields and was used for PCA-align training/diagnostics.
121
+ - Cache containing test entries is not automatically leakage. Leakage only happens if test proteins enter the training dataloader. The training dataloader uses `train_csv_path`; lookup into cache only happens for batch `pdb_name`.
122
+
123
+ ## Confirmed Code Behavior
124
+
125
+ ### Training Split vs Cache
126
+
127
+ `PdbDataModuleBBFlow` reads:
128
+
129
+ ```text
130
+ data.dataset.train_csv_path
131
+ ```
132
+
133
+ The train dataloader uses only `_train_dataset`. The motion target cache is a dictionary; `_lookup_motion_targets` only retrieves entries for the current batch `pdb_name`.
134
+
135
+ Therefore:
136
+
137
+ ```text
138
+ cache contains test82 != test82 used in training
139
+ ```
140
+
141
+ Actual leakage criterion:
142
+
143
+ ```text
144
+ train_csv names intersect test_csv names
145
+ ```
146
+
147
+ User confirmed there was no train/test overlap.
148
+
149
+ ### Checkpoint Saving
150
+
151
+ Current BBFlow training uses Lightning `ModelCheckpoint`:
152
+
153
+ ```yaml
154
+ save_last: True
155
+ save_on_train_epoch_end: True
156
+ filename: "epoch:{epoch:03d}"
157
+ every_n_epochs: 1
158
+ save_top_k: -1
159
+ ```
160
+
161
+ Meaning:
162
+
163
+ - Saves every epoch.
164
+ - Updates `last.ckpt`.
165
+ - Does not choose best checkpoint by validation metric.
166
+ - Base stage scripts set `experiment.first_val_epoch=inf`, so training does not run real validation/downstream.
167
+
168
+ Current downstream commands usually test:
169
+
170
+ ```text
171
+ CKPT_PATH="$RUN_DIR/last.ckpt"
172
+ ```
173
+
174
+ So by default we evaluate the final epoch, not best-val.
175
+
176
+ ## Experiment Log
177
+
178
+ ### 1. Official BBFlow Rerun
179
+
180
+ Purpose:
181
+
182
+ Prove that the evaluation pipeline and official checkpoint are correct.
183
+
184
+ Checkpoint:
185
+
186
+ ```text
187
+ /home/wangyusong/LD-FPG-main/bbflow/models/bbflow-0.1/bbflow-0.1.ckpt
188
+ ```
189
+
190
+ Output:
191
+
192
+ ```text
193
+ /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/official_bbflow_rerun_250
194
+ ```
195
+
196
+ Result:
197
+
198
+ ```text
199
+ BBFlow-official-rerun-250:
200
+ RMSF r 0.89
201
+ RMSF MAE 0.48
202
+ Pairwise RMSD MAE 0.77
203
+ PCA W2 1.34
204
+ ```
205
+
206
+ Conclusion:
207
+
208
+ The checkpoint and downstream evaluation process are sound. The official result is reproducible enough. Any poorer latent-finetune result is probably real, not a pipeline artifact.
209
+
210
+ ### 2. Long Finetune, Official Warm Start, Orth1/ReCon0, 100 Epochs
211
+
212
+ Run:
213
+
214
+ ```text
215
+ bbflow_base_official_modelonly_long_finetune_orth1_recon0_100ep_3gpu_20260630_191404
216
+ ```
217
+
218
+ Purpose:
219
+
220
+ Test whether latent condition with orthogonal mode regularization and no mode recon loss improves standard downstream.
221
+
222
+ Core config:
223
+
224
+ ```text
225
+ official BBFlow model-only warm start
226
+ 3 GPU
227
+ 100 epochs
228
+ lambda_mode_orth=1
229
+ lambda_mode_recon=0
230
+ sample_coefficients=true
231
+ freeze_foundation=false
232
+ condition_mode=real for inference
233
+ ```
234
+
235
+ Downstream real result:
236
+
237
+ ```text
238
+ BBFlow-long-ft-orth1-recon0-real:
239
+ RMSF r 0.88
240
+ RMSF MAE 0.48
241
+ Pairwise RMSD MAE 0.81
242
+ PCA W2 1.35
243
+ ```
244
+
245
+ Official rerun baseline:
246
+
247
+ ```text
248
+ RMSF r 0.89
249
+ RMSF MAE 0.48
250
+ Pairwise RMSD MAE 0.77
251
+ PCA W2 1.34
252
+ ```
253
+
254
+ Conclusion:
255
+
256
+ Long finetune did not beat official BBFlow. It is slightly worse, especially Pairwise RMSD.
257
+
258
+ ### 3. Shuffled Condition Downstream
259
+
260
+ Purpose:
261
+
262
+ Check whether real condition actually matters relative to a corrupted condition.
263
+
264
+ Result:
265
+
266
+ ```text
267
+ BBFlow-long-ft-orth1-recon0-shuffled:
268
+ RMSF r 0.89
269
+ RMSF MAE 0.48
270
+ Pairwise RMSD MAE 1.27
271
+ PCA W2 1.51
272
+ ```
273
+
274
+ Conclusion:
275
+
276
+ Real condition is much better than shuffled for Pairwise/PCA. However, user judged shuffled/zero comparisons as non-substantive because official BBFlow still outperforms the real condition. Do not keep focusing on zero/shuffled unless specifically needed.
277
+
278
+ ### 4. Probe: Real vs Zero/Shuffled Covariance
279
+
280
+ Purpose:
281
+
282
+ Mechanistic check whether condition affects covariance/cross-covariance statistics.
283
+
284
+ Key result:
285
+
286
+ Real condition improved far cross-covariance correlation over zero/shuffled in probe.
287
+
288
+ Representative deltas:
289
+
290
+ ```text
291
+ real - zero far_cross_cov_corr delta ≈ +0.045
292
+ real - shuffled far_cross_cov_corr delta ≈ +0.029
293
+ ```
294
+
295
+ But rel_loss often got worse:
296
+
297
+ ```text
298
+ far_cross_cov_rel_loss delta worse by ~0.36-0.38
299
+ ```
300
+
301
+ Conclusion:
302
+
303
+ Condition can improve some correlation structure, but scale/amplitude can be wrong. Also, probe statistics do not automatically transfer to saved-conformation downstream metrics.
304
+
305
+ ### 5. Mode-PCA Alignment Diagnosis on Long Finetune
306
+
307
+ Purpose:
308
+
309
+ Test whether learned prior modes align with MD principal motion directions.
310
+
311
+ Command used `scripts/diagnose_mode_pca_alignment.py` on test82.
312
+
313
+ Old long-finetune values:
314
+
315
+ ```text
316
+ all_learned_vs_md_top2_subspace_mean_sq_cos: 0.4848
317
+ all_learned_vs_md_top2_subspace_min_sq_cos: 0.3500
318
+ best_abs_cos_to_md_pc1: 0.5149
319
+ best_abs_cos_to_md_pc2: 0.5416
320
+ top_energy_abs_cos_to_md_pc1: 0.3302
321
+ top_energy_abs_cos_to_md_pc2: 0.3461
322
+ top2_energy_vs_md_top2_subspace_mean_sq_cos: 0.3086
323
+ top2_energy_vs_md_top2_subspace_min_sq_cos: 0.1185
324
+ ```
325
+
326
+ Interpretation at the time:
327
+
328
+ The learned mode set contains directions that partially align with MD PCs, but the energy-ranked top modes are not the best-aligned modes. This suggested an energy ranking/allocation problem.
329
+
330
+ ### 6. PCA Alignment Loss Added
331
+
332
+ Purpose:
333
+
334
+ Directly train energy-weighted learned modes to align with MD top PCA subspace.
335
+
336
+ Code:
337
+
338
+ - Added `LatentEncoder.pca_alignment_loss`.
339
+ - Added `lambda_pca_align`.
340
+ - Added metrics:
341
+ - `pca_align_loss`
342
+ - `pca_align_weighted_overlap`
343
+ - `pca_align_best_overlap`
344
+ - `pca_align_top_energy_overlap`
345
+ - `pca_align_top_energy_subspace_overlap`
346
+
347
+ Loss idea:
348
+
349
+ ```text
350
+ learned modes U
351
+ MD oracle top PC1/PC2
352
+ mode_overlap = squared projection of each learned mode into MD top-PC subspace
353
+ energy weights = predicted mode energy / total energy
354
+ loss = 1 - sum_k energy_weight_k * mode_overlap_k
355
+ ```
356
+
357
+ This is not inference-time PCA. PCA is only used as training supervision where enabled.
358
+
359
+ ### 7. PCA-Align 0.1 Run, 30 Epochs, 3 GPU
360
+
361
+ Run:
362
+
363
+ ```text
364
+ bbflow_base_pca_align_orth1_recon0_30ep_3gpu_20260704_055826
365
+ ```
366
+
367
+ Core config:
368
+
369
+ ```text
370
+ official BBFlow model-only warm start
371
+ 3 GPU
372
+ 30 epochs
373
+ lambda_mode_orth=1
374
+ lambda_mode_recon=0
375
+ lambda_pca_align=0.1
376
+ pca_align_top_m=2
377
+ condition real for inference
378
+ ```
379
+
380
+ Training behavior:
381
+
382
+ Metrics improved in train:
383
+
384
+ ```text
385
+ pca_align_weighted_overlap:
386
+ epoch 6 ≈ 0.0567
387
+ epoch 17 ≈ 0.0799
388
+ epoch 28 ≈ 0.1114
389
+
390
+ pca_align_top_energy_overlap:
391
+ epoch 6 ≈ 0.0969
392
+ epoch 17 ≈ 0.1374
393
+ epoch 28 ≈ 0.2160
394
+
395
+ mode_max_cosine_abs:
396
+ epoch 6 ≈ 0.6512
397
+ epoch 17 ≈ 0.4076
398
+ epoch 28 ≈ 0.3673
399
+
400
+ mode_gram_condition:
401
+ epoch 6 ≈ 809.9
402
+ epoch 17 ≈ 4.297
403
+ epoch 28 ≈ 3.758
404
+
405
+ cross_cov_far_corr:
406
+ epoch 6 ≈ 0.1811
407
+ epoch 17 ≈ 0.2663
408
+ epoch 28 ≈ 0.3009
409
+ ```
410
+
411
+ Initial interpretation:
412
+
413
+ Training dynamics looked healthy. Alignment improved without mode collapse.
414
+
415
+ Test82 mode-PCA diagnosis:
416
+
417
+ ```text
418
+ all_learned_vs_md_top2_subspace_mean_sq_cos: 0.3420
419
+ best_abs_cos_to_md_pc1: 0.3997
420
+ best_abs_cos_to_md_pc2: 0.4432
421
+ top_energy_abs_cos_to_md_pc1: 0.2613
422
+ top_energy_abs_cos_to_md_pc2: 0.2992
423
+ top2_energy_vs_md_top2_subspace_mean_sq_cos: 0.2408
424
+ ```
425
+
426
+ Compared to old long-finetune diagnosis, all key alignment values decreased.
427
+
428
+ Conclusion:
429
+
430
+ `lambda_pca_align=0.1` improves training proxy metrics but does not generalize to held-out test82 mode-PCA alignment. It may overfit train proteins or distort the learned prior mode subspace. This checkpoint should not be treated as a positive result without downstream evidence.
431
+
432
+ ### 8. Leakage Clarification for PCA Oracle Cache
433
+
434
+ Concern:
435
+
436
+ The oracle cache included train/val/test entries:
437
+
438
+ ```text
439
+ atlas_full_md_motion_targets_k8_kabsch_v1_oracle.pt
440
+ ```
441
+
442
+ At first, this was incorrectly called leakage.
443
+
444
+ Corrected reasoning:
445
+
446
+ - Cache can contain many proteins.
447
+ - Training only looks up current batch names.
448
+ - Current batch names come from train CSV.
449
+ - Therefore leakage only happens if test proteins are present in train CSV.
450
+
451
+ User confirmed no train/test overlap.
452
+
453
+ Conclusion:
454
+
455
+ The test82 mode-PCA drop for PCA-align 0.1 is a clean negative result, not explained by train/test leakage.
456
+
457
+ ### 9. Scratch Run
458
+
459
+ Run:
460
+
461
+ ```text
462
+ bbflow_base_scratch_mog_k8_m2_orth1_recon0_30ep_2gpu_20260703_192644
463
+ ```
464
+
465
+ Config from `config.yaml`:
466
+
467
+ ```text
468
+ warm_start: null
469
+ num_devices: 2
470
+ lambda_mode_orth: 1.0
471
+ lambda_mode_recon: 0.0
472
+ lambda_pca_align: not present / 0
473
+ num_modes: 8
474
+ mixture_components: 2
475
+ freeze_foundation: false
476
+ sample_coefficients: true
477
+ motion_target_cache_path:
478
+ /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
479
+ ```
480
+
481
+ Important correction:
482
+
483
+ Resume should use the cache from this config:
484
+
485
+ ```text
486
+ atlas_full_md_motion_targets_k8_kabsch_v1.pt
487
+ ```
488
+
489
+ Not the old default:
490
+
491
+ ```text
492
+ atlas_full_md_motion_targets_k8.pt
493
+ ```
494
+
495
+ If resume is done with a Lightning checkpoint:
496
+
497
+ ```text
498
+ BASE_CKPT="$SCRATCH_RUN/last.ckpt"
499
+ RUN_DIR="$SCRATCH_RUN"
500
+ ```
501
+
502
+ Then Lightning should restore epoch/optimizer/scheduler state.
503
+
504
+ ## Current Pending / Running Items
505
+
506
+ ### PCA-align 0.1 Downstream
507
+
508
+ Purpose:
509
+
510
+ Even though test82 mode-PCA alignment dropped, run full downstream to see whether this diagnosis correlates with saved-conformation metrics.
511
+
512
+ Command intent:
513
+
514
+ ```text
515
+ single GPU
516
+ 82 proteins
517
+ 250 conformations/protein
518
+ SAMPLE_BATCH_SIZE=20
519
+ MAX_NUM_RES_SQUARED=400000
520
+ CONDITION_MODE=real
521
+ save sampled_conformations.pdb
522
+ evaluate RMSF / Pairwise RMSD / PCA W2
523
+ ```
524
+
525
+ Question to answer:
526
+
527
+ ```text
528
+ Does poorer mode-PCA alignment imply poorer downstream?
529
+ ```
530
+
531
+ If yes:
532
+
533
+ Mode-PCA diagnosis is useful as a negative filter.
534
+
535
+ If no:
536
+
537
+ Mode-PCA diagnosis is not reliable enough as a checkpoint selector.
538
+
539
+ ### Scratch Resume
540
+
541
+ Purpose:
542
+
543
+ Continue scratch training on GPUs 1,2 while GPU 0 can run downstream.
544
+
545
+ Must use:
546
+
547
+ ```text
548
+ RUN_DIR = scratch run directory
549
+ BASE_CKPT = scratch last.ckpt
550
+ FINGERPRINT_CACHE = atlas_full_md_motion_targets_k8_kabsch_v1.pt
551
+ GPU_IDS=1,2
552
+ NUM_DEVICES=2
553
+ ```
554
+
555
+ Do not accidentally resume scratch with oracle PCA cache or old non-versioned cache.
556
+
557
+ ## Lessons Learned
558
+
559
+ ### Proxy metrics are not enough
560
+
561
+ The following are useful but not sufficient:
562
+
563
+ - `cross_cov_far_corr`
564
+ - `cross_cov_far_loss`
565
+ - `pca_align_*`
566
+ - `mode_max_cosine_abs`
567
+ - `mode_gram_condition`
568
+
569
+ They can improve in training while downstream or test82 diagnosis fails.
570
+
571
+ ### Need mini-downstream validation
572
+
573
+ Current BBFlow saves every epoch but chooses `last.ckpt`, not best-val. This is weak model selection.
574
+
575
+ Recommended next system:
576
+
577
+ ```text
578
+ Every N epochs or selected checkpoints:
579
+ sample 5-10 validation proteins
580
+ 50-100 conformations/protein
581
+ compute real downstream-like metrics:
582
+ RMSF
583
+ Pairwise RMSD
584
+ PCA W2
585
+ generated covariance metrics
586
+ use this to choose checkpoint
587
+ ```
588
+
589
+ This is not a training loss, but it is much closer to downstream than current proxy metrics.
590
+
591
+ ### Downstream tests must save conformations
592
+
593
+ User requirement:
594
+
595
+ > During testing/evaluation, always save conformations. Downstream metrics are first priority.
596
+
597
+ Probe-only statistics do not replace standard downstream.
598
+
599
+ ### Checkpoint path discipline
600
+
601
+ Never guess checkpoint paths. Confirm with:
602
+
603
+ ```bash
604
+ test -f "$CKPT_PATH"
605
+ grep relevant fields "$RUN_DIR/config.yaml"
606
+ ```
607
+
608
+ Official checkpoint:
609
+
610
+ ```text
611
+ /home/wangyusong/LD-FPG-main/bbflow/models/bbflow-0.1/bbflow-0.1.ckpt
612
+ ```
613
+
614
+ Do not invent:
615
+
616
+ ```text
617
+ /data/.../bbflow_official_atlas/last.ckpt
618
+ models/bbflow-0.1/... under bbflow_base if absent
619
+ ```
620
+
621
+ ### Cache path discipline
622
+
623
+ There are multiple caches with similar names:
624
+
625
+ ```text
626
+ atlas_full_md_motion_targets_k8.pt
627
+ atlas_full_md_motion_targets_k8_kabsch_v1.pt
628
+ atlas_full_md_motion_targets_k8_kabsch_v1_oracle.pt
629
+ ```
630
+
631
+ Using the wrong one can cause:
632
+
633
+ ```text
634
+ alignment_version mismatch
635
+ missing oracle_modes/oracle_energy
636
+ changed training target
637
+ ```
638
+
639
+ Before resume, read the run config and reuse the original cache unless intentionally changing the experiment.
640
+
641
+ ## Recommended Next Steps
642
+
643
+ 1. Do not keep trying to rescue the 60-epoch PCA-align checkpoint with a global scale.
644
+ 2. Run the scale-group diagnosis:
645
+ - low group: proteins whose oracle best scale is `scale12`
646
+ - high group: proteins whose oracle best scale is `scale30`
647
+ - mid group: all remaining best scales
648
+ 3. Compare low vs high groups using existing features:
649
+ - learned mode energies
650
+ - mode-PCA alignment diagnostics
651
+ - MD pairwise RMSD / PCA W2
652
+ - generated amplitude and MD-PC variance diagnostics
653
+ 4. Inspect the two extreme failure examples:
654
+ - `6qj0A`: over-spread at all scales
655
+ - `7c45A`: under-spread at all scales
656
+ 5. If low/high groups separate cleanly by available inference-time features, test a per-protein scale rule.
657
+ 6. If low/high groups do not separate, treat oracle per-protein scale as an upper bound that is not currently usable.
658
+ 7. Implement mini-downstream validation so checkpoint selection is based on actual validation metrics, not only proxy losses.
659
+ 8. If trying PCA-align again, lower `LAMBDA_PCA_ALIGN` such as `0.03` and early-stop by mini-downstream metrics.
660
+ 9. Resume scratch only with the exact scratch config/cache and verify Lightning restore.
661
+
662
+ ## Claims We Can Make Now
663
+
664
+ Safe claims:
665
+
666
+ - Official BBFlow checkpoint and downstream evaluation pipeline are reproduced.
667
+ - Long latent finetune did not beat official BBFlow on standard downstream.
668
+ - Real condition is better than shuffled condition, but that is not sufficient because official BBFlow still wins.
669
+ - Probe/covariance improvements do not automatically imply downstream gains.
670
+ - PCA-align loss with `lambda=0.1` improves training alignment metrics but worsens held-out test82 mode-PCA diagnosis.
671
+ - Current BBFlow checkpoint selection is last-epoch, not best-validation.
672
+ - PCA-align `lambda=0.1` at 30 epochs can improve PCA W2 slightly under selected inference scales, but the standard downstream tradeoff is not a broad win because Pairwise RMSD MAE remains worse than official BBFlow.
673
+ - Continuing the same PCA-align run from 30 to 60 epochs improves proxy losses but degrades downstream, especially Pairwise RMSD and many scale settings.
674
+ - Global `condition_scale` cannot solve the 60-epoch checkpoint: median statistics can be moved, but per-protein Pairwise MAE remains poor.
675
+ - Per-protein oracle scale selection over the existing scale grid has a strong upper bound (`Pairwise RMSD MAE = 0.5583`), proving the scale issue is heterogeneous across proteins.
676
+ - Protein length alone does not explain the per-protein best scale split.
677
+
678
+ Unsafe claims:
679
+
680
+ - PCA-align improves downstream.
681
+ - Mode-PCA alignment is a reliable downstream predictor.
682
+ - Current PCA-align checkpoint is useful for final paper claims.
683
+ - Test leakage occurred just because cache contained test entries.
684
+ - A practical per-protein scale rule has been found.
685
+ - The oracle per-protein scale result is usable at inference time without a predictor.
686
+
687
+ ## 2026-07-07 Update: PCA-Align 30->60, Scale Sweep, and Per-Protein Scale
688
+
689
+ ### Runs / Outputs
690
+
691
+ Main run:
692
+
693
+ ```text
694
+ /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_pca_align_orth1_recon0_30ep_3gpu_20260704_055826
695
+ ```
696
+
697
+ Important generated/evaluation directories:
698
+
699
+ ```text
700
+ standard_downstream_extend60_scale05_250
701
+ standard_downstream_extend60_scale07_250
702
+ standard_downstream_extend60_scale10_250
703
+ standard_downstream_extend60_scale_gt1_grid_250
704
+ contraction_diagnostics_30to60
705
+ per_protein_scale_error_analysis
706
+ scale_group_diagnosis
707
+ ```
708
+
709
+ ### 30->60 Training Metrics
710
+
711
+ The 30-epoch checkpoint was resumed to epoch 59/60 with Lightning optimizer state preserved. Training proxy metrics continued to improve:
712
+
713
+ ```text
714
+ motion_loss 1.664174 -> 1.323183 (-0.340991)
715
+ local_cov_loss 0.707414 -> 0.567489 (-0.139924)
716
+ cross_cov_loss 0.792517 -> 0.623544 (-0.168973)
717
+ cross_cov_far_corr 0.320930 -> 0.472915 (+0.151985)
718
+ cross_cov_far_loss 0.964359 -> 0.818648 (-0.145711)
719
+ rmsf_loss 0.302754 -> 0.203370 (-0.099384)
720
+ pca_align_loss 0.885546 -> 0.813072 (-0.072474)
721
+ pca_align_weighted_overlap 0.114454 -> 0.186928 (+0.072474)
722
+ pca_align_top_energy_overlap 0.207225 -> 0.310178 (+0.102954)
723
+ mode_coeff_abs 0.305543 -> 0.355761 (+0.050217)
724
+ mode_coeff_std 0.451974 -> 0.535341 (+0.083367)
725
+ q_nll_per_dim 0.099669 -> 0.184764 (+0.085096)
726
+ ```
727
+
728
+ Interpretation:
729
+
730
+ - The condition coefficient magnitude did not collapse; it increased.
731
+ - The model became better at the proxy losses.
732
+ - Downstream got worse anyway, proving the proxy/downstream gap is real.
733
+
734
+ ### 60-Epoch Global Scale Sweep
735
+
736
+ Downstream for 60-epoch PCA-align checkpoint:
737
+
738
+ ```text
739
+ Official BBFlow: Pairwise MAE 0.78, Pairwise median 2.76, PCA W2 1.34, RMSF MAE 0.47
740
+
741
+ scale10: Pairwise MAE 0.88, Pairwise median 2.52, PCA W2 1.31, RMSF MAE 0.48
742
+ scale12: Pairwise MAE 0.87, Pairwise median 2.74, PCA W2 1.39, RMSF MAE 0.49
743
+ scale14: Pairwise MAE 0.92, Pairwise median 2.91, PCA W2 1.41, RMSF MAE 0.49
744
+ scale16: Pairwise MAE 0.95, Pairwise median 3.05, PCA W2 1.39, RMSF MAE 0.52
745
+ scale18: Pairwise MAE 0.98, Pairwise median 3.23, PCA W2 1.39, RMSF MAE 0.54
746
+ scale20: Pairwise MAE 1.06, Pairwise median 3.33, PCA W2 1.45, RMSF MAE 0.58
747
+ scale30: Pairwise MAE 1.49, Pairwise median 3.99, PCA W2 1.52, RMSF MAE 0.74
748
+ ```
749
+
750
+ Interpretation:
751
+
752
+ - Increasing scale fixes the global Pairwise median around `scale12` to `scale14`.
753
+ - It does not fix Pairwise MAE.
754
+ - PCA W2 is best around `scale10`; larger scales damage PCA W2.
755
+ - Global `condition_scale` only moves overall amplitude; it cannot fix per-protein distribution shape.
756
+ - The 60-epoch checkpoint has no globally good scale.
757
+
758
+ ### Amplitude / Direction Diagnosis
759
+
760
+ `diagnose_training_contraction.py` compared generated ensembles with MD amplitude and MD top-PC projection.
761
+
762
+ For 60-epoch scales:
763
+
764
+ ```text
765
+ gen_amp_median/MD gen_amp_q90/MD PC1 var/MD PC2 var/MD residue RMS ratio
766
+ scale05 0.7112 0.7253 0.3385 0.5951 0.7260
767
+ scale07 0.7458 0.7697 0.4147 0.7216 0.7620
768
+ scale10 0.7947 0.8402 0.5364 0.9140 0.8208
769
+ ```
770
+
771
+ Interpretation:
772
+
773
+ - Generated ensembles are too small at scales <= 1.0.
774
+ - PC1 variance is especially under-dispersed.
775
+ - But increasing global scale later showed that amplitude correction alone does not recover Pairwise MAE or PCA W2.
776
+
777
+ ### Per-Protein Scale Oracle
778
+
779
+ Existing scale grid:
780
+
781
+ ```text
782
+ scale12, scale14, scale16, scale18, scale20, scale30
783
+ ```
784
+
785
+ For each protein, choosing the best scale by Pairwise RMSD absolute error gives:
786
+
787
+ ```text
788
+ oracle_pairwise_mae: 0.5583
789
+ oracle_model_pairwise_median: 2.8824
790
+ md_pairwise_median: 2.8905
791
+ oracle_md_pca_w2_median: 1.346
792
+ oracle_joint_pca_w2_median: 1.8231
793
+ ```
794
+
795
+ This is much better than:
796
+
797
+ ```text
798
+ official Pairwise MAE: 0.78
799
+ best global 60ep scale Pairwise MAE: ~0.87
800
+ ```
801
+
802
+ Interpretation:
803
+
804
+ - The 6-way discrete oracle is a strong signal, not a tiny tuning artifact.
805
+ - Different proteins need very different scales.
806
+ - The oracle is not usable directly because it uses MD ground truth to choose scale.
807
+ - It provides an upper bound and motivates a per-protein scale predictor/classifier.
808
+
809
+ Best scale distribution:
810
+
811
+ ```text
812
+ scale12 31 proteins
813
+ scale30 27 proteins
814
+ scale18 9 proteins
815
+ scale20 7 proteins
816
+ scale14 7 proteins
817
+ scale16 1 protein
818
+ ```
819
+
820
+ Interpretation:
821
+
822
+ - The distribution is bimodal/extreme-heavy.
823
+ - This looks more like a classification problem than a continuous scale-regression problem.
824
+ - A simple global scale or simple length-based formula is unlikely to work.
825
+
826
+ Length correlation:
827
+
828
+ ```text
829
+ corr(length, signed_error): about -0.10 to -0.12 across scales
830
+ corr(length, abs_error): about -0.03 to +0.04
831
+ ```
832
+
833
+ Interpretation:
834
+
835
+ - Protein length alone does not explain whether a protein needs low or high scale.
836
+
837
+ ### Extreme Failure Examples
838
+
839
+ Over-spread at all scales:
840
+
841
+ ```text
842
+ 6qj0A
843
+ scale12: MD 3.4330, model 10.4792, diff +7.0462
844
+ scale30: MD 3.4776, model 16.8809, diff +13.4032
845
+ ```
846
+
847
+ Under-spread at all scales:
848
+
849
+ ```text
850
+ 7c45A
851
+ scale12: MD 9.6570, model 4.2683, diff -5.3888
852
+ scale30: MD 9.6113, model 6.6184, diff -2.9929
853
+ ```
854
+
855
+ Interpretation:
856
+
857
+ - These represent opposite failure modes.
858
+ - `6qj0A` is too mobile even at low scale.
859
+ - `7c45A` is too conservative even at extreme scale.
860
+ - This suggests that failure is not just a scalar amplitude problem; learned mode quality/energy or generator response differs qualitatively by protein.
861
+
862
+ ### Current Scientific Interpretation
863
+
864
+ The project has moved through these stages:
865
+
866
+ 1. Latent condition improves some proxy statistics.
867
+ 2. Standard downstream does not broadly improve over official BBFlow.
868
+ 3. PCA-align can move PCA-related metrics but hurts or fails Pairwise RMSD.
869
+ 4. More PCA-align training improves proxy losses but worsens downstream.
870
+ 5. Global inference scale cannot solve the 60-epoch checkpoint.
871
+ 6. Per-protein oracle scale has strong potential, but only if a non-oracle predictor can identify protein-specific scale needs.
872
+
873
+ Plain-language summary:
874
+
875
+ ```text
876
+ The method has signal, but different proteins fail in opposite ways.
877
+ Some are already too energetic and need low scale.
878
+ Some are too conservative and need high scale.
879
+ A single global scale averages these failures and cannot win.
880
+ The next useful question is whether the low-scale and high-scale proteins can be distinguished using features available at inference time.
881
+ ```
882
+
883
+ ### Immediate Next Analysis
884
+
885
+ Run the scale-group diagnosis:
886
+
887
+ ```text
888
+ low_scale12 = proteins whose oracle best scale is scale12
889
+ high_scale30 = proteins whose oracle best scale is scale30
890
+ mid_scale = all others
891
+ ```
892
+
893
+ Compare group features:
894
+
895
+ ```text
896
+ num_res
897
+ md_pairwise
898
+ md_pca_w2
899
+ joint_pca_w2
900
+ learned_energy_top0/top1
901
+ top_energy_abs_cos_to_md_pc1/pc2
902
+ top2_energy_vs_md_top2_subspace_mean_sq_cos
903
+ all_learned_vs_md_top2_subspace_mean_sq_cos
904
+ generated amplitude diagnostics if merged
905
+ ```
906
+
907
+ Important methodological point:
908
+
909
+ - Do not rely only on Pearson correlation with continuous scale.
910
+ - The best-scale distribution is bimodal.
911
+ - Use group comparison / classification-style diagnostics first.
912
+
913
+ Outcome criteria:
914
+
915
+ - If low/high groups separate by inference-time features, test a per-protein scale rule.
916
+ - If they only separate by MD-ground-truth features, the oracle is not deployable.
917
+ - If they do not separate, treat per-protein oracle scale as an informative upper bound but not a practical method yet.
918
+
919
+ ## 2026-07-08 Command/Path Failure Reflection
920
+
921
+ ### What Happened
922
+
923
+ During evaluation of the `energy_from_q_diag` 30-epoch run, I repeatedly gave wrong run/evaluation commands because I relied on memory of old command conventions instead of reading the current shell scripts first.
924
+
925
+ The concrete failures were:
926
+
927
+ 1. I assumed `reproduction/02_sample_test.sh` accepted an `OUTPUT_DIR` environment variable.
928
+ 2. In reality, `02_sample_test.sh` ignores `OUTPUT_DIR` and writes to:
929
+
930
+ ```text
931
+ ${REPRO_ROOT}/inference
932
+ ```
933
+
934
+ 3. I therefore looked for generated conformations under the checkpoint `RUN_DIR`, where they did not exist.
935
+ 4. I also assumed `reproduction/03_evaluate.sh` accepted `ATLAS_ROOT` and `OUT_DIR`.
936
+ 5. In reality, `03_evaluate.sh` uses:
937
+
938
+ ```text
939
+ ENSEMBLE_DIR
940
+ ATLAS_VIEW_ROOT
941
+ METRICS_DIR
942
+ TEST_CSV
943
+ METHOD_NAME
944
+ ```
945
+
946
+ 6. Because I used the wrong reference variable, evaluation fell back to the default:
947
+
948
+ ```text
949
+ bbflow_base/reproduction/outputs/data/ATLAS
950
+ ```
951
+
952
+ and produced repeated `No reference trajectory found` warnings.
953
+
954
+ ### Root Cause
955
+
956
+ The root cause was not a confusing directory structure. The root cause was a bad operating procedure:
957
+
958
+ ```text
959
+ I wrote commands from memory before checking the current script interfaces.
960
+ ```
961
+
962
+ This violated the project rule that paths and runtime commands must be checked against the actual code before being given.
963
+
964
+ ### Correct Script Interfaces
965
+
966
+ For sampling:
967
+
968
+ ```bash
969
+ reproduction/02_sample_test.sh
970
+ ```
971
+
972
+ uses:
973
+
974
+ ```text
975
+ REPRO_ROOT
976
+ METADATA_ROOT
977
+ CKPT_PATH
978
+ GPU_ID
979
+ SAMPLES_PER_PROTEIN
980
+ SAMPLE_BATCH_SIZE
981
+ MAX_NUM_RES_SQUARED
982
+ INFERENCE_NAME
983
+ CONDITION_MODE
984
+ CONDITION_SCALE
985
+ POSTPROCESS_BFACTORS
986
+ INFERENCE_NUM_WORKERS
987
+ ```
988
+
989
+ and writes to:
990
+
991
+ ```text
992
+ ${REPRO_ROOT}/inference
993
+ ```
994
+
995
+ For evaluation:
996
+
997
+ ```bash
998
+ reproduction/03_evaluate.sh
999
+ ```
1000
+
1001
+ uses:
1002
+
1003
+ ```text
1004
+ ENSEMBLE_DIR
1005
+ ATLAS_VIEW_ROOT
1006
+ METRICS_DIR
1007
+ TEST_CSV
1008
+ METHOD_NAME
1009
+ METHOD_TIME_SECONDS
1010
+ NUM_WORKERS
1011
+ ```
1012
+
1013
+ and passes the reference trajectory directory through:
1014
+
1015
+ ```text
1016
+ --md_dirs "${ATLAS_VIEW_ROOT}"
1017
+ ```
1018
+
1019
+ ### Correct Evaluation Command Pattern
1020
+
1021
+ For the `energy_from_q_diag` run, the correct structure is:
1022
+
1023
+ ```bash
1024
+ RUN_DIR=/data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_energy_from_q_diag_orth1_recon0_30ep_3gpu_20260707_165355
1025
+
1026
+ ENSEMBLE_DIR=/data/shared/wangyusong/atals/bbflow_official_reproduction/inference/checkpoints/bbflow_base_energy_from_q_diag_orth1_recon0_30ep_3gpu_20260707_165355/last/atlas_test_250_real \
1027
+ ATLAS_VIEW_ROOT=/data/shared/wangyusong/atals/bbflow_official_reproduction/datasets/ATLAS \
1028
+ METRICS_DIR="$RUN_DIR/standard_downstream_metrics_real_250" \
1029
+ METHOD_NAME="BBFlow-energy-from-q-diag-30ep-real-250" \
1030
+ TEST_CSV=/data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv \
1031
+ bash reproduction/03_evaluate.sh
1032
+ ```
1033
+
1034
+ ### Rule Going Forward
1035
+
1036
+ Before giving any command involving paths, output directories, or environment variables:
1037
+
1038
+ ```bash
1039
+ grep -n "VARIABLE_NAME\|script_argument" target_script.sh
1040
+ ```
1041
+
1042
+ or open the script directly.
1043
+
1044
+ No command should be given from memory when the script interface is available.
1045
+
1046
+ Minimum checklist:
1047
+
1048
+ 1. Read the sampling/evaluation script.
1049
+ 2. Confirm the exact environment variables it accepts.
1050
+ 3. Confirm where it writes outputs.
1051
+ 4. Confirm the real generated directory with `find`.
1052
+ 5. Only then provide the final command.
1053
+
1054
+ This is especially mandatory for:
1055
+
1056
+ ```text
1057
+ 02_sample_test.sh
1058
+ 03_evaluate.sh
1059
+ training scripts
1060
+ checkpoint resume commands
1061
+ cleanup commands
1062
+ ```
1063
+ # Non-negotiable oracle policy (2026-07-09)
1064
+
1065
+ - Oracle information is forbidden in training, checkpoint selection, inference,
1066
+ calibration, routing, gating, or any deployable method component.
1067
+ - This includes test/validation MD frames, projected per-frame oracle
1068
+ coefficients, oracle PCA modes/energies, oracle best scales, and any feature
1069
+ derived from the target ensemble.
1070
+ - Oracle quantities may only be used after generation as offline diagnostic
1071
+ labels or upper-bound analyses. They must never influence model parameters,
1072
+ hyperparameters selected on test data, or per-protein inference behavior.
1073
+ - Before every run, verify the effective config and cache path. A cache that
1074
+ contains oracle fields must not be used by a training or inference command,
1075
+ even if the current code path appears not to read those fields.
1076
+ - Any proposed experiment that conditions the generator on projected target
1077
+ coefficients is diagnostic-only and cannot be presented as an inference
1078
+ method or used to select a deployable checkpoint.
1079
+
1080
+ ## Inference performance lesson (2026-07-09)
1081
+
1082
+ - Do not call multi-GPU parallelism an algorithmic inference speedup. Report
1083
+ single-GPU latency separately from throughput scaling.
1084
+ - The old sampler performed avoidable work at every ODE step: it copied every
1085
+ clean prediction to CPU, retained the complete rigid trajectory, converted
1086
+ every step to atom37, recomputed equilibrium geometry, and reran condition
1087
+ adapter MLPs even though only the final frame was written.
1088
+ - The optimized path keeps only the current ODE state and final frame, caches
1089
+ equilibrium/condition features once per sample batch, and exposes the number
1090
+ of function evaluations explicitly.
1091
+ - A true order-of-magnitude latency reduction requires reducing ODE model
1092
+ evaluations (for example 20 to 5) in addition to removing implementation
1093
+ waste. Any lower-NFE preset must pass downstream-quality comparison before it
1094
+ replaces the 20-step reference.
1095
+
1096
+ ## Diagnostic script reliability lesson (2026-07-10)
1097
+
1098
+ - Do not assume metadata columns. The ATLAS test CSV used here contains only
1099
+ `name` and `pdb_path`; diagnostic scripts must derive the protein folder from
1100
+ `Path(pdb_path).parent` or fail loudly.
1101
+ - Do not use guessed MD frame indices. If `num_conformations` is absent, read
1102
+ the real frame count from the trajectory file. If the trajectory cannot be
1103
+ opened, stop the diagnostic instead of silently using early frames.
1104
+ - Do not rely on upstream device placement in diagnostic code. Any function that
1105
+ combines generated tensors with dataset frames must explicitly move all inputs
1106
+ to the generated tensor's device at the function boundary. This is mandatory
1107
+ for projection/cycle-consistency diagnostics where generated coordinates,
1108
+ equilibrium coordinates, mode tensors, and masks are mixed.
1109
+ - Before asking the user to rerun a new diagnostic script on the server, run a
1110
+ local syntax check and inspect every path where CPU/GPU tensors are mixed.
1111
+ Repeated server failures from avoidable metadata or device assumptions waste
1112
+ GPU time and user trust.
1113
+
1114
+ ## Checkpoint resume lesson (2026-07-11)
1115
+
1116
+ - Do not assume a Hydra override such as `+ckpt_path=...` will be consumed by a
1117
+ training wrapper. If the wrapper script does not explicitly forward that key
1118
+ to `Trainer.fit(ckpt_path=...)`, the run may silently start from scratch while
1119
+ still writing into the intended `RUN_DIR`.
1120
+ - Before giving any resume command, inspect the training wrapper for the exact
1121
+ resume variable/name it supports, then verify the command line printed by the
1122
+ script contains that value.
1123
+ - A resume command is not considered valid until the first log lines show the
1124
+ loaded checkpoint epoch/global_step or the next epoch continues after the
1125
+ checkpoint. If `last.ckpt` was epoch 15, seeing `Epoch 0/1/2` means the command
1126
+ failed and must be stopped immediately.
1127
+ - Never continue a suspected resume run just because the config path or `RUN_DIR`
1128
+ looks correct. Effective resume state is determined by loaded optimizer state
1129
+ and epoch/global_step, not by output directory names.
1130
+
1131
+ ## Evaluation reference path lesson (2026-07-11)
1132
+
1133
+ - Evaluation commands must explicitly set the real ATLAS reference trajectory
1134
+ directory. Do not allow `reproduction/03_evaluate.sh` or
1135
+ `scripts/analysis_script.py` to fall back to
1136
+ `reproduction/outputs/data/ATLAS`, because that local default does not contain
1137
+ the ATLAS trajectories used for these runs.
1138
+ - Before every evaluation, inspect `reproduction/03_evaluate.sh` and pass the
1139
+ exact reference variable it supports, pointing to:
1140
+ `/data/shared/wangyusong/atals/bbflow_official_reproduction/datasets/ATLAS`.
1141
+ - If warnings say `No reference trajectory found for ... in
1142
+ /home/wangyusong/LD-FPG-main/bbflow_base/reproduction/outputs/data/ATLAS`,
1143
+ stop the evaluation immediately. The generated ensembles may be correct, but
1144
+ the evaluation command is using the wrong reference path and the metrics are
1145
+ invalid.
1146
+
1147
+ ## Per-protein analysis lesson (2026-07-11)
1148
+
1149
+ - Do not propose per-protein drilldowns as the default next step. In this
1150
+ project, repeated per-protein analyses have consumed time without producing
1151
+ stable design decisions.
1152
+ - Avoid narratives based on a few named proteins or post-hoc per-protein
1153
+ examples unless the user explicitly asks for case studies.
1154
+ - Prefer mechanism-level diagnostics that aggregate over a fixed protein set:
1155
+ subspace vs residual decomposition, distribution-level statistics, paired
1156
+ checkpoint comparisons, and controlled ablations.
1157
+ - If a proposed analysis requires interpreting individual protein identities,
1158
+ treat it as low priority and do not use it to decide the next method change.
1159
+
1160
+ ## Code-inspection-before-guessing lesson (2026-07-13)
1161
+
1162
+ - If the answer is determined by repository code, generated configs, or wrapper
1163
+ scripts, inspect those files before advising the user. Do not answer with
1164
+ "probably", "likely", "should", or similar uncertainty when the code can give
1165
+ a concrete answer.
1166
+ - Before saying an inference job can resume, skip existing proteins, preserve
1167
+ partial outputs, or avoid overwriting, inspect the exact inference script and
1168
+ output-writing path. Do not infer skip/overwrite behavior from naming
1169
+ conventions or previous runs.
1170
+ - Before recommending checkpoint paths or checkpoint cadence, list the actual
1171
+ checkpoint files and read the saved run `config.yaml`. Log epochs are not
1172
+ checkpoint files, and `last.ckpt` only reflects the configured checkpoint
1173
+ trigger.
1174
+ - When a prior answer was based on an unchecked assumption, stop and correct the
1175
+ workflow by reading the relevant code/config first; do not ask the user to
1176
+ continue experiments based on that assumption.
1177
+
1178
+ ## Do-not-close-experiments lesson (2026-07-13)
1179
+
1180
+ - Do not declare an experiment line finished, archived, or ready to stop unless
1181
+ the user explicitly says to conclude it. A negative or mixed result should be
1182
+ recorded as a stage observation, not as a terminal decision.
1183
+ - Phrases like "archive this route", "stop this line", or "this is the final
1184
+ conclusion" require explicit user approval. Until then, continue treating the
1185
+ result as evidence for the next design decision.
1186
+ - When reporting a failed or mixed checkpoint, separate the measured fact from
1187
+ the decision: state what changed in the metrics, then propose next options
1188
+ without closing the project direction on the user's behalf.
1189
+
1190
+ ## Training launch lesson (2026-07-13)
1191
+
1192
+ - Do not start long training jobs with a trailing background `&` in commands
1193
+ given to the user unless the user explicitly asks for background execution.
1194
+ The shell job marker like `[1] 1350285` is not useful operational feedback and
1195
+ has repeatedly made process control harder.
1196
+ - Prefer foreground commands with `2>&1 | tee "$RUN_DIR/train_console.log"` so
1197
+ the user sees failures immediately while logs are still saved. Use `tmux`,
1198
+ `screen`, or an explicit scheduler only when the user requests detached runs.
1199
+ - If a previous command used background execution and must be stopped, give
1200
+ concrete `pkill`/`ps` checks before any new launch command.
1201
+
1202
+ ## DDP/NCCL launch stability lesson (2026-07-14)
1203
+
1204
+ - On `gn11`, do not "simplify" or delete the known-good DDP/NCCL environment
1205
+ block when only testing model, loss, or batch-size changes. This mistake has
1206
+ repeatedly produced startup hangs where both H100s show about 660 MiB memory
1207
+ and 100% GPU utilization before real training begins.
1208
+ - The current stable dual-GPU launch template for `00_train_final_mog_ddp.sh`
1209
+ must keep:
1210
+ - `NCCL_DEBUG=WARN`
1211
+ - `NCCL_ASYNC_ERROR_HANDLING=1`
1212
+ - `NCCL_IB_DISABLE=1`
1213
+ - `NCCL_P2P_DISABLE=1`
1214
+ - `NCCL_SOCKET_IFNAME=enp1s0`
1215
+ - `GLOO_SOCKET_IFNAME=enp1s0`
1216
+ - `MASTER_ADDR=127.0.0.1`
1217
+ - `MASTER_PORT=$((20000 + RANDOM % 20000))`
1218
+ - `EXTRA_HYDRA_ARGS="experiment.trainer.strategy=ddp"`
1219
+ - For controlled experiments, change only the intended experimental variables
1220
+ such as `MAX_NUM_RES_SQUARED`, `MAX_BATCH_SIZE`, loss weights, epoch counts,
1221
+ or generator-cov settings. Do not change communication variables at the same
1222
+ time; otherwise a hang cannot be attributed to the model change.
1223
+ - If `nvidia-smi` shows tiny memory use with 100% GPU utilization, treat it as a
1224
+ DDP/NCCL launch hang first. Kill the training PIDs, restore the known-good
1225
+ DDP/NCCL block above, and only then retry.
1226
+
1227
+ ## Generator-response downstream reckoning (2026-07-18)
1228
+
1229
+ This is the first session where the generator-response line was ever measured on
1230
+ DOWNSTREAM ensemble metrics (sampling + analysis_script), not just training-side
1231
+ proxies. Every conclusion below is grounded in a measured 5znjA/82-protein read.
1232
+
1233
+ ### 0. What was fixed at the start, and what it exposed
1234
+ - The `teacher_trace` anchor was diagnosed as a dead reference: the teacher is a
1235
+ `deepcopy` of the model at the first step, when all condition adapters are still
1236
+ zero-init, so its condition response is identically 0. `clamp_min(1e-8)` pinned
1237
+ `teacher_trace` to a constant, and `trace_loss=log(trace_sample/1e-8)^2` was
1238
+ actively training the student response TO ZERO. Confirmed by arithmetic on the
1239
+ logged `trace_mean`/`ratio` (ratio proportional to student trace; teacher const).
1240
+ - Fix applied: anchor reference switched teacher -> MD trace (`md_trace`, reuses
1241
+ `trace_target` already computed for shape normalization). Teacher forwards
1242
+ skipped entirely. `latent.py` `project_displacement_lstsq` also got a relative
1243
+ (Levenberg-Marquardt) ridge because the absolute 1e-4 ridge was swallowed in
1244
+ float32 once unnormalized-mode gram scale grew large -> `torch.linalg.solve`
1245
+ crashed mid-epoch (singular). Both are correct fixes, but see section 3.
1246
+
1247
+ ### 1. First downstream numbers (gen_cov + cross, md_trace anchor, UNFROZEN)
1248
+ 5znjA + full 82. BBFlow (Ours) reference row RMSF-MAE/Pairwise-MAE/PCA-W2 =
1249
+ 0.47 / 0.78 / 1.34. Measured `gen_cov_cross_ep{0,2,4}`:
1250
+ - RMSF MAE 6.04 / 6.97 / 5.19 (~10x worse)
1251
+ - Pairwise 7.34 / 8.83 / 6.40 (~8x worse)
1252
+ - PCA W2 3.12 / 1.70 / 1.58
1253
+ - RMSF r 0.06 / 0.59 / 0.70 (PATTERN is learned and improving)
1254
+ Scale-invariant metrics (r, PCA-W2) improve while absolute-A metrics are ~3x
1255
+ inflated -> "correct pattern, wrong magnitude" = over-dispersion, not garbage.
1256
+ 5znjA pseudo-RMSF mean 4.72, uniform (median 4.71, min 3.28), NO rigid core.
1257
+
1258
+ ### 2. Ruling out the pipeline and the config (both clean)
1259
+ - `analysis_script.py:31-37` the leaderboard rows (BBFlow 0.47 etc.) are HARDCODED
1260
+ paper constants, NOT recomputed. The table cannot validate the pipeline.
1261
+ - Kabsch-aligning the 100 samples: 4.72 -> 4.65. Superposition removes nothing ->
1262
+ the dispersion is genuine internal conformational spread, not a framing artifact.
1263
+ - `condition_scale` sweep on ep004: 1.0/0.5/0.25 -> 4.62/4.51/4.56. SCALE-INVARIANT
1264
+ -> the over-dispersion is in the BASE/backbone, not the condition. The condition
1265
+ is nearly inert at sampling; the backbone absorbed both the pattern (r up) and
1266
+ the diffuseness.
1267
+ - CONTROL: official `bbflow-0.1.ckpt` (latent OFF) through the SAME pipeline ->
1268
+ pseudo-RMSF 1.46 (matches MD median 1.48), 59% residues < 1.5 (proper rigid
1269
+ core). Pipeline + sampler are CORRECT. The problem is 100% our model.
1270
+ - Config-mismatch also ruled out: re-sampling ep004 with the checkpoint's exact
1271
+ latent config (`energy_from_q`, `sample_coefficients`, etc., which `inference.yaml`
1272
+ omits and would silently drop under `strict=False`) still gave 4.62.
1273
+
1274
+ ### 3. Root cause (corrected twice; final version)
1275
+ - `freeze_foundation` was ALWAYS false (backbone always trainable). It is NOT the
1276
+ differentiator vs older "comparable-at-best" runs. (First wrong hypothesis.)
1277
+ - The real change this session was teacher->md_trace, which flipped the condition
1278
+ from SUPPRESSED (teacher anchor trained response->0 => condition inert => model
1279
+ ~= base BBFlow => old runs looked "fine / slightly worse") to ALIVE for the
1280
+ first time. An alive condition whose amplitude is calibrated on the SINGLE-STEP
1281
+ `pred_trans` response (training `gen_trace_ratio ~= 1.0`) over-disperses ~3x once
1282
+ run through the real 20-step ODE sampler. official_loss rose 0.85 (no-cross) ->
1283
+ 1.5 (cross) and stayed elevated: aux losses degraded the trainable base.
1284
+ - `condition_scale`-invariance is the tell: the damage is baked into the backbone,
1285
+ not delivered by the condition at sample time.
1286
+
1287
+ ### 4. Frozen isolation run (freeze_foundation=true, trace_anchor=0, shape only)
1288
+ `_freeze_foundation_model` (bbflow_module.py:171) freezes all of `self.model`
1289
+ except 5 injection modules (z_node/z_edge/disp_node/disp_edge adapters + film_mlp);
1290
+ `_set_frozen_foundation_eval` re-applies eval() every epoch. Verified clean.
1291
+ - BASE PRESERVED: official_loss 0.88 -> 0.66 -> 0.44 (falling, not rising). Freeze
1292
+ protects marginals by construction. This half of the thesis WORKS.
1293
+ - CONDITION WENT INERT: gen_response_abs_mean 0.018 (vs 0.48), gen_trace_mean
1294
+ ~1.9 (vs 1103), gen_trace_ratio 0.0016 (~0.2% of MD). cross_cov_far_corr flat
1295
+ ~0.11. Reason: with trace_anchor=0 there is NOTHING driving condition amplitude,
1296
+ and the shape losses are SCALE-INVARIANT (indifferent to amplitude). Zero-init
1297
+ adapters + no amplitude driver => condition stays ~0, shaping a negligible signal.
1298
+ - Net: frozen+no-anchor -> ~= BBFlow (base preserved, no gain).
1299
+
1300
+ ### 5. The design box, and the fundamental diagnosis
1301
+ - trace_anchor ON at single-step MD -> 20-step overshoot ~3x (unfrozen: 4.6).
1302
+ - trace_anchor OFF -> condition starves to inert (frozen: ~BBFlow).
1303
+ - A scaled anchor target (e.g. md/9) would be a FUDGE FACTOR for the single-step
1304
+ vs 20-step gap -> parameter tuning, not a cure.
1305
+ - ROOT CAUSE of all of it: the objective measures the SINGLE-STEP `pred_trans`
1306
+ response, never the actual 20-step sampled ensemble. Amplitude is therefore
1307
+ miscalibrated by construction and every proxy (trace ratio, shape losses) is
1308
+ measured on the wrong quantity (generator-blind).
1309
+ - Additional structural limit: a FROZEN base can mostly only ADD motion, not
1310
+ REDISTRIBUTE it; improving PCA W2 requires redistribution (less motion in wrong
1311
+ directions, more in MD directions). So even a perfectly amplitude-calibrated
1312
+ frozen run likely has a PCA-W2 ceiling. (FiLM gives partial redistribution.)
1313
+ - FUNDAMENTAL CURE (not yet built): compute the objective on a differentiable
1314
+ FEW-STEP rollout of the real sampler and match MD ensemble statistics on it.
1315
+ Then amplitude is correct by construction, the signal is generator-aware, no
1316
+ per-protein fudge factor, and it works frozen or unfrozen. This is a real
1317
+ implementation (differentiable 2-4 step rollout + ensemble covariance), not a knob.
1318
+
1319
+ ### 6. Lessons
1320
+ - Training-side proxies on this line do NOT predict downstream and repeatedly
1321
+ misled (trace_ratio ~1 while the sampler was 3x over-dispersed). Always get a
1322
+ downstream read before concluding a generator-response run is good or bad.
1323
+ - The leaderboard table printed by `03_evaluate` is hardcoded reference values;
1324
+ never treat "BBFlow (Ours)" appearing next to your row as pipeline validation.
1325
+ - To sample a latent checkpoint, `experiments/inference.py` must be given the
1326
+ checkpoint's latent config explicitly (`+latent.energy_from_q`, `sample_coefficients`,
1327
+ `mixture_components`, ...). `inference.yaml` omits them; `strict=False` then
1328
+ silently loads a random q-head and produces garbage that looks like a model fail.
1329
+ - `00_train_final_mog_ddp.sh` hardcoded `latent.freeze_foundation=false`; it is now
1330
+ an env var (`FREEZE_FOUNDATION`). Verify freeze at runtime via the first
1331
+ `[grad-flow-check]` line: `bbflow_backbone ... params_with_grad` drops 534 -> ~20.
1332
+
1333
+ ## Rollout-aware G-calibration: works, then diverges (2026-07-18, later)
1334
+
1335
+ Built rollout amplitude calibration: measure G = T_full / T_1step where T_full is the
1336
+ c-response trace on the REAL sampler (shared prior noise x0, full linspace(min_t,1,20)
1337
+ grid, no_grad, few proteins, once per interval), then anchor the single-step response to
1338
+ md_trace * (1/G_ema). Fixes the single-step vs 20-step miscalibration WITHOUT a fudge
1339
+ factor. (Codex's first cut measured T_full from the training-time trans_t over 2 coarse
1340
+ steps -> silently wrong G; corrected to prior-noise + full grid in `_rollout_final_pred_trans`.)
1341
+
1342
+ RESULT of frozen + G-cal + anchor 0.3 (bbflow_frozen_Gcal, run 20260718_172144):
1343
+ - The mechanism WORKS. G measured ~6.5 -> 10.5 (EMA), empirically confirming the 20-step
1344
+ sampler amplifies the single-step response ~6-10x (bigger than the ~3x guessed earlier;
1345
+ this is exactly why the old single-step anchor over-dispersed). Condition went ALIVE:
1346
+ gen_response_abs_mean 0.16 (vs 0.018 inert / 0.48 over), gen_trace_ratio_to_anchor
1347
+ 0.63 -> 0.93 -> 0.99 converging to the calibrated target. First stable-ish "alive,
1348
+ calibrated" condition ever observed.
1349
+ - But it DIVERGED. Latent mode geometry collapsed monotonically from epoch 0:
1350
+ mode_max_cosine_abs 0.928 -> 0.987 -> 0.989, mode_gram_min_eig 1.14 -> 0.031,
1351
+ mode_gram_condition 2.8e5 -> 3.1e5 -> 5.4e13; official_loss 4.3 -> 5.7 (high, and the
1352
+ frozen backbone cannot be the cause). At epoch 3 step 220 (a NON-measure step, so the
1353
+ rollout is NOT in the crash path) the prior mixture head produced NaN logits ->
1354
+ Categorical crash in sample_coefficients_from_q. There is NO gradient clipping anywhere
1355
+ in the codebase.
1356
+ - Reading: the calibrated anchor driving the condition to MD amplitude, on a frozen base
1357
+ whose amplitude is already correct, fights the mode structure (mode_orth loss at 1.0 did
1358
+ not hold it) and collapses the latent to NaN. This is the "additive tension" made concrete
1359
+ as a divergence. Frozen+additive is now boxed both ways: no anchor -> inert; anchor -> diverge.
1360
+
1361
+ OPEN: is the divergence a maskable instability or a genuine defect? Decided NOT to paper it
1362
+ with gradient clipping (that hides the divergence signal instead of finding the root cause).
1363
+ Next when resumed: find the actual NaN source in the latent forward (mixture head / mode
1364
+ normalization / the near-degenerate-gram path) rather than clipping; and evaluate the
1365
+ pre-NaN checkpoint (epoch 1, condition alive, geometry not yet fully collapsed) downstream
1366
+ to see whether an alive-but-pre-collapse condition moved PCA W2 at all -- the only signal
1367
+ this run line can still yield.
bbflow_base/docs/gencov_handoff_2026-08-08.md ADDED
@@ -0,0 +1,168 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Generator-response objective — handoff, 2026-08-08
2
+
3
+ Continues `mdsubspace_handoff_2026-08-04.md`. Read that first for the setting, the
4
+ measurement problems, and the corrections to the 07-31 handoff.
5
+
6
+ ## Bottom line
7
+
8
+ Three loss designs have now been tried. None beats `PCA-W2 = 1.27`, which came from the
9
+ weakest of them applied briefly.
10
+
11
+ ```
12
+ design what it constrains PCA-W2 range
13
+ collective (G=8 sample covariance) an estimate that was unnecessary 1.31 – 1.57
14
+ md_subspace (align U) U, the internal decoder 1.27 – 1.42
15
+ gencov (response, local_cov) the flow's response, locally 1.40 – 1.46
16
+
17
+ baseline (no conditioning) 1.34
18
+ best ever: mdsubspace ep009 @ condition_scale 0.92 1.27
19
+ ```
20
+
21
+ ## 1. The decisive measurement of this cycle
22
+
23
+ `scripts/response_jacobian_audit.py` estimates `J = E[dPhi/dc]` by antithetic central
24
+ differences — perturb one coefficient by one standard deviation of `q`, re-integrate with
25
+ the initial noise held fixed, difference the endpoints. 6 proteins, medians:
26
+
27
+ ```
28
+ overlap(J, V_2) 0.576 the flow's actual response, against the two scored directions
29
+ overlap(U, V_2) 0.205 the decoder the objective had been aligning
30
+ overlap(J, U) 0.211 the two are largely different subspaces
31
+ ```
32
+
33
+ **Every alignment number previously reported — `span_overlap`, the reachable floors
34
+ `0.498` and `0.247` — was computed on `U`, an object that does not carry the conditioning
35
+ to the output.** Twenty integration steps through a nonlinear field sit between them.
36
+
37
+ This is the concrete form of the warning in `covariance_matching_problem.md` P1: *every
38
+ formula should use `J`, not `U`*. It also explains the anti-correlation recorded in the
39
+ previous handoff — the objective was rotating a subspace that does not propagate, so
40
+ `span_overlap` could rise monotonically while the evaluation degraded.
41
+
42
+ ## 2. What was run
43
+
44
+ `lambda_md_subspace = 0`, `lambda_md_subspace_trace = 0`, `lambda_generator_cov = 1.0`,
45
+ `template_residual_scale = 1.0`, k12 cache, 14 epochs completed of 20 requested.
46
+ Run: `mdsubspace_20260806_220254`.
47
+
48
+ `_generator_response_cov_loss` perturbs the mixture coefficients antithetically, forms the
49
+ generator's central-difference response, and matches the **trace-normalised** response
50
+ covariance shape. Cost: two extra forward passes per step, roughly a 3x slowdown once
51
+ `GENERATOR_COV_CHECKPOINT=true` and a smaller `MAX_NUM_RES_SQUARED` were added to fit
52
+ memory. Epoch time 39 min -> 2h10.
53
+
54
+ Training side, all healthy and monotone:
55
+
56
+ ```
57
+ epoch 0 2 4 6 8
58
+ gen_local_shape_loss 0.947 0.755 0.688 0.641 0.597
59
+ gen_trace_ratio 0.883 0.861 0.839 0.838 0.816
60
+ mode_max_cosine_abs 0.343 0.180 0.237 0.177 0.159
61
+ ```
62
+
63
+ `mode_max_cosine_abs = 0.159` is the best this project has recorded; earlier runs sat at
64
+ 0.62–0.94, close to collapse. With `lambda_md_subspace = 0` nothing pulls `U` toward the
65
+ reference subspace any more, so `mode_orth` alone shapes it and the frame becomes
66
+ well conditioned. This is incidental to the experiment but worth keeping.
67
+
68
+ ## 3. Result
69
+
70
+ ```
71
+ RMSF r RMSF MAE RMSF Med(1.48) PW MAE PW Med(~2.90) PCA-W2
72
+ baseline 0.89 0.47 1.48 0.78 2.76 1.34
73
+ gencov ep003 0.88 1.08 2.77 1.64 4.39 1.46
74
+ gencov ep007 0.89 0.61 1.93 0.94 3.45 1.40
75
+ gencov ep013 0.89 0.52 1.76 0.80 2.94 1.42
76
+ ```
77
+
78
+ **The amplitude story is unambiguous and monotone.** The run starts wildly over-dispersed —
79
+ `PW Med 4.39` against a target of 2.90 — because the objective is trace-normalised and the
80
+ trace anchor carries weight 0.05. Training pulls it back to 2.94, essentially on target,
81
+ and `PW MAE` from 1.64 to 0.80 against the baseline's 0.78. This objective calibrates.
82
+
83
+ **`PCA-W2` does not move: 1.46, 1.40, 1.42.** All three are worse than the baseline's 1.34.
84
+ Critically, at ep013 the amplitude is already right and `PCA-W2` is still 1.42 — so this is
85
+ not an over-dispersion artefact that more training would clear.
86
+
87
+ ## 4. Why it failed
88
+
89
+ ```
90
+ generator_cov_use_cross: false
91
+ ```
92
+
93
+ With cross-covariance disabled the objective matches only `local_cov`, the per-residue 3x3
94
+ covariance blocks. That is a **purely local** quantity. It has no cross-residue content at
95
+ all, and the leading principal directions are collective — they are defined by
96
+ correlations *between* residues.
97
+
98
+ So the objective improved exactly what it can see (per-residue fluctuation: RMSF MAE
99
+ 1.08 -> 0.52, PW MAE 1.64 -> 0.80) and had no purchase on the quantity being scored. The
100
+ loss worked; it was pointed at a local statistic while the metric measures a collective one.
101
+
102
+ ## 5. State of the three designs
103
+
104
+ | | constrains | operator | quantity | outcome |
105
+ | --- | --- | --- | --- | --- |
106
+ | collective | 8-sample covariance estimate | — | collective | premise unnecessary; 3 rounds of fixes moved nothing |
107
+ | md_subspace | `U Gamma U^T` | `U` (overlap 0.21 with `J`) | collective | best 1.27, but degrades monotonically with training |
108
+ | gencov | response covariance | `J` (overlap 0.576 with `V_2`) | **local only** | calibrates amplitude, cannot touch `PCA-W2` |
109
+
110
+ Each attempt has had one half right and one half wrong. No configuration has yet combined
111
+ the correct operator (the response) with a collective target.
112
+
113
+ ## 6. The untried combination
114
+
115
+ `generator_cov_use_cross = true` adds `cross_cov` to the response objective;
116
+ `lambda_gen_cross_shape = 1.0` is already wired and `cross_cov` is already in the cache.
117
+ That is the first configuration in which the objective would act on the response *and* on a
118
+ collective quantity.
119
+
120
+ Cost: about 30 hours for 13 epochs at the current step time.
121
+
122
+ Stated plainly: the reasoning behind this one is better supported than the previous three —
123
+ `J`'s overlap with the scored plane is measured at 0.576, and `cross_cov` is where
124
+ collective structure lives. But three prior cycles were also launched on "this time the
125
+ object is right" and all three failed. Treat the expectation accordingly.
126
+
127
+ ## 7. Data handling, re-verified
128
+
129
+ - Splits disjoint: train 1269, valid 39, test 82, all pairwise intersections empty.
130
+ - Training looks up motion targets only by names from the training loader; test entries in
131
+ the cache are never read. `oracle_condition = false`.
132
+ - No global statistics. `compute_motion_targets` runs per protein on that protein's own
133
+ frames. The only cross-split operation in `extract_shape_fingerprints.py` is a
134
+ `pd.concat` of the three CSVs followed by `drop_duplicates`, which builds a work list and
135
+ aggregates nothing. `rmsf.mean()/std()` in `summarize_target` are within-protein and are
136
+ written only to the `.tsv` summary. No dataset-level normalisation in the dataloader;
137
+ `trans_scale` and `bb_atom_scale` are fixed constants.
138
+ - The 39 validation proteins remain completely untouched — neither trained on nor used for
139
+ any selection.
140
+
141
+ **Selection, however, has been made against the test set throughout.** Checkpoints,
142
+ `condition_scale`, `gamma_trans`, the weighting exponent and the cache size were all chosen
143
+ by their test score — 20 to 30 comparisons at a per-configuration standard error of 0.030.
144
+ The optimism of a maximum over that many draws is 0.06–0.08, which is the size of the
145
+ entire 0.07 margin of `1.27` over the baseline's `1.34`. The margin is therefore not
146
+ currently supported by the reporting set. This is a judgement call the project has made
147
+ knowingly; the remedy, if it is ever wanted, is one paired comparison of a single
148
+ pre-committed configuration against the baseline on the 39 held-out proteins.
149
+
150
+ ## 8. Operational notes added this cycle
151
+
152
+ - **`13_train_md_subspace_ddp.sh` had hard assignments** (`export LAMBDA_GENERATOR_COV=0.0`)
153
+ which silently discarded the caller's environment. A run launched with
154
+ `LAMBDA_GENERATOR_COV=1.0` recorded `0.0` in its own `config.yaml` and trained with no
155
+ conditioning objective at all. All lambda exports are now `${VAR:-default}`.
156
+ **Verify every launch against the run's own `config.yaml` within ten seconds of starting**
157
+ — it is written immediately and is the only authority on what took effect.
158
+ - `_generator_response_cov_loss` has **three silent-return paths**: zero lambda, missing
159
+ `_gen_cov_targets` (which requires `lambda_motion > 0`), and a condition dict lacking
160
+ `u_global` / `mixture_logits` / `mixture_mu` / `mixture_scale_tril`. All three return
161
+ zero without raising. Confirm non-zero `gen_*` columns in
162
+ `latent_train_epoch_metrics.csv` after the first epoch or the run is a no-op.
163
+ - The generator-response path needs `GENERATOR_COV_CHECKPOINT=true` and
164
+ `MAX_NUM_RES_SQUARED=750000` to fit; together with the extra forwards this is roughly a
165
+ 3x slowdown.
166
+ - GPUs have been left held by zombie processes with an empty `nvidia-smi` process list.
167
+ Poll `memory.used` until it drops below 2 GB before launching, rather than sleeping a
168
+ fixed interval.
bbflow_base/docs/mdsubspace_handoff_2026-08-04.md ADDED
@@ -0,0 +1,262 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # MD-subspace conditioning — handoff, 2026-08-04
2
+
3
+ Supersedes `cmfm_handoff_2026-07-31.md`. That document contains a labelling error that
4
+ cost a full evaluation cycle; see §6.
5
+
6
+ ## Bottom line
7
+
8
+ The collective/CMFM construction was replaced by a closed-form comparison against
9
+ precomputed MD covariance statistics. The result beats the BBFlow baseline on two of the
10
+ six reported columns and loses on three; the remaining gap is entirely over-dispersion.
11
+
12
+ ```
13
+ RMSF r MAE RMSF Med PW MAE PW Med PCA-W2 (K=2, analysis_script)
14
+ BBFlow baseline 0.89 0.47 1.48 0.78 2.76 1.34
15
+ ep009_s0.92 0.89 0.51 1.69 0.75 3.06 1.27 <- best PCA-W2 in the table
16
+ ep004_s1.0 0.90 0.51 1.57 0.72 3.06 1.29 <- best PW MAE in the table
17
+ MD reference 1.48 2.91
18
+ ```
19
+
20
+ Paired at K=10 against the baseline, `mdsubspace_k12_ep014` reaches `-0.1166` at
21
+ `p = 0.0058` — the first result in this project that is unambiguously better than the
22
+ baseline under a properly powered comparison.
23
+
24
+ ## 1. What changed in the method
25
+
26
+ The collective objective estimated a covariance from `G = 8` generated conformations per
27
+ step. That estimate was unnecessary: 3003 MD frames per protein are on disk, so the
28
+ reference covariance and its eigenbasis are computable exactly, offline. Everything the
29
+ group structure existed to support — grouped batches, shared sampling time, backbone
30
+ chunking, the rank-4 restriction forced by `G < k`, and three rounds of fixes to the
31
+ normalizer, basis and bias — was serving an estimate that did not need to be made.
32
+
33
+ The replacement (`LatentEncoder.md_subspace_shape_loss`) is closed form:
34
+
35
+ ```
36
+ Γ_q = Cov_{c~q}(c) exact under the mixture
37
+ M = Vᵀ U V = cached MD eigenvectors, U = encoder modes
38
+ A = M Γ_q Mᵀ the model's covariance in the reference eigenbasis
39
+ B = diag(cached MD eigenvalues)
40
+
41
+ L_shape = ‖ B^{-1/4} (A − B) B^{-1/4} ‖_F² / 4
42
+ L_trace = ( tr(A)/tr(B) − 1 )²
43
+ ```
44
+
45
+ No sampling, so no `G`; no sample covariance is inverted or square-rooted, so the `G < k`
46
+ singularity never arises. It is scale sensitive, so it does not carry the dilation
47
+ invariance that made the covariance-entry correlation useless as a target.
48
+
49
+ Two supporting changes were required:
50
+
51
+ - **`FREEZE_MODE_HEAD=false`.** The previous run had `U` frozen; the modes were never
52
+ optimised at all.
53
+ - **`template_residual_scale` 0.1 → 1.0.** `u_global = participation·base + scale·residual`
54
+ with `base` drawn from a rigid screw field. Screw fields span 6 dimensions, so `K = 8`
55
+ modes built from them are necessarily dependent, and `_remove_rigid_component` then
56
+ subtracts the well-conditioned part. At scale 0.1 the residual — the only escape from
57
+ that 6-dimensional family — was suppressed tenfold. This is why `U` collapsed at every
58
+ λ that had been tried, including 1e-4: the collapse was structural, not loss-driven.
59
+ At scale 1.0, `mode_max_cosine_abs` holds at 0.76–0.84 over 19 epochs.
60
+
61
+ ## 2. What made no difference
62
+
63
+ - **Reference directions R = 8 vs 12.** No end-to-end difference at matched epochs.
64
+ - **λ_md_subspace 0.1 vs 0.2.** No difference.
65
+ - **The three CMFM fixes of 2026-07-31** (scalar normalizer, data-derived basis, removal
66
+ of the `1/τ` weighting). None moved the evaluation.
67
+
68
+ ## 3. Inference-time knobs are exhausted
69
+
70
+ Both available knobs were swept on the test set. Neither corrects the over-dispersion.
71
+
72
+ **`condition_scale`** (scales the latent condition):
73
+
74
+ ```
75
+ ep009 s=0.85 0.92 1.00 1.10 ep004 s=0.78 0.85 0.92 1.00
76
+ PW Med 3.00 3.06 3.16 3.19 3.04 3.11 3.10 3.06
77
+ PCA-W2 1.29 1.27 1.28 1.28 1.33 1.35 1.34 1.29
78
+ ```
79
+
80
+ Monotone and roughly free on ep009 (elasticity ≈ 0.34), absent and mildly harmful on
81
+ ep004. The two behaviours are not reconcilable at this precision — see §5.
82
+
83
+ **`gamma_trans`** (width of the conditional prior, i.e. how far the flow starts from
84
+ equilibrium — this reaches the whole ensemble, not only the 8-dimensional conditioned
85
+ subspace):
86
+
87
+ ```
88
+ ep004 g=0.11 0.14 0.17 0.20(default) ep009 g=0.11 0.14 0.20(default)
89
+ PW Med 3.19 3.17 3.15 3.06 3.14 3.12 3.16
90
+ PCA-W2 1.34 1.31 1.37 1.29 1.32 1.32 1.28
91
+ ```
92
+
93
+ Reducing the prior width does not reduce the ensemble spread, and PCA-W2 is uniformly
94
+ worse than at the default. After 20 integration steps the prior width has been forgotten;
95
+ the spread is set by the learned velocity field.
96
+
97
+ **Conclusion: the over-dispersion is produced during training and no sampling-time
98
+ setting corrects it.** This closes off the cheap class of fixes.
99
+
100
+ ## 4. Structural finding — capacity is not the constraint
101
+
102
+ With `R = 12` reference directions the family floor becomes measurable (it is identically
103
+ zero when `R = K`). Computed from the cached eigenvalues, the best any 8-dimensional
104
+ subspace could achieve is `√(Σ_{i>8} β_i / Σ β_i)`, median **0.247**. The trained `U`
105
+ reaches **0.498** and plateaus there from epoch 9.
106
+
107
+ So roughly 23 percentage points of the 29% unreachable variance are recoverable by
108
+ improving `U` alone. **Adding modes is not the lever; learning `U` better is.**
109
+
110
+ ## 5. Measurement — the part that changed how everything is read
111
+
112
+ **The reported PCA-W2 uses `K = 2`.** `analyse_bbflow._pca_w2(..., K=2)` projects onto the
113
+ top two principal components of the reference trajectory, out of `3N ≈ 10³`. A subspace
114
+ audit of the generated ensembles found the model places **25%** of its variance there
115
+ against MD's 55%, and **3.6×** MD's share outside the top ten directions. Three quarters
116
+ of what the model does is invisible to the score. This is the mechanism by which the most
117
+ over-dispersed run scored best.
118
+
119
+ **The aggregate comparison is badly underpowered.** Comparing medians over 82 proteins
120
+ carries between-protein variance; comparing per protein and pairing does not:
121
+
122
+ ```
123
+ K=10, vs baseline paired SE ≈ 0.04 unpaired SE ≈ 0.27 ρ = 0.98
124
+ ```
125
+
126
+ Minimum detectable difference falls from ≈ 0.77 to ≈ 0.12. The earlier conclusion that
127
+ five substantially different designs were indistinguishable was an artefact of the
128
+ comparison, not a property of the designs.
129
+
130
+ **Consequence for §3.** The `condition_scale` and `gamma_trans` sweeps were read off
131
+ unpaired medians whose run-to-run noise is ±0.03 (the MD reference itself printed as
132
+ 2.90 / 2.91 / 2.93 / 2.94 / 2.95 across runs). Differences of 0.02–0.06 were being ranked
133
+ inside that noise. The negative conclusion in §3 survives — no setting came close to
134
+ closing an 8–14% amplitude gap — but the fine ordering within each sweep does not.
135
+
136
+ **For publication**, `K = 2` must be reported: it is what BBFlow, AlphaFlow and ConfDiff
137
+ use, and a metric introduced by the authors that happens to favour them will not survive
138
+ review. The K=10 analysis and the pairing belong in a discussion section as a
139
+ methodological observation; the pairing in particular is a pure statistical improvement
140
+ that applies at any K.
141
+
142
+ ## 6. Errors in the superseded handoff
143
+
144
+ `cmfm_handoff_2026-07-31.md:233` labels the table's fourth column `col4(PCA-W2)`. Column 4
145
+ is **Pairwise RMSD MAE**; PCA-W2 is column 6. The stated decision rule — "the only judge
146
+ is PCA-W2 … against the baseline's `0.78`" — therefore steers by the wrong column. The
147
+ previous run's quoted `1.17` is likewise Pairwise RMSD MAE; its PCA-W2 was `1.57`.
148
+
149
+ Also note `cmfm_problem_statement_2026-07-31.md` states `N ≈ 10⁴` draws per instance. The
150
+ true figure is **3003** (1001 frames × 3 replicas, `num_conformations` in the training CSV
151
+ is constant at 1001). Any variance calculation that used `m ≈ 10⁴` is off by 3.3×.
152
+
153
+ ## 7. Training-time proxies do not predict the evaluation
154
+
155
+ Four have now failed, in this order:
156
+
157
+ | proxy | how it failed |
158
+ | --- | --- |
159
+ | `cross_cov_far_corr` | exactly dilation invariant; rose 9× over 26 epochs while the evaluation degraded |
160
+ | `md_subspace_offdiag_share` | a ratio — the trace term shrinks the denominator, so the share rises with the off-diagonal error flat |
161
+ | `md_subspace_floor` | plateaued at epoch 9 while end-to-end performance kept improving to epoch 14 |
162
+ | `md_subspace_span_overlap` | peaked at epoch 8 and declined, while ep014 turned out to be the best checkpoint at K=10 |
163
+
164
+ The common cause is not metric design. **Every training-time quantity measures the
165
+ conditioning-space covariance `U·Cov(c)·Uᵀ`; the evaluation measures the covariance of the
166
+ ensemble that comes out of the 20-step flow.** Nothing has ever validated the assumption
167
+ that the conditioning's covariance propagates through the flow. The direct evidence
168
+ against it: the training metric reported the model at 27% of the target variance while the
169
+ generated ensemble was over-dispersed.
170
+
171
+ Operational consequence: **checkpoint often and evaluate end-to-end.** Inference plus a
172
+ paired comparison costs about 70 minutes and is the only signal that has held up.
173
+
174
+ Replacement diagnostics were added but have not yet run a full training:
175
+ `md_subspace_diag_sq` / `md_subspace_offdiag_sq` (absolute, not a share),
176
+ `md_subspace_span_overlap` (principal angles, amplitude cannot move it), and
177
+ `md_subspace_floor`. They share the same conditioning-space limitation and should be read
178
+ as descriptions of `U`, not predictions of the evaluation.
179
+
180
+ ## 8. Next step — the generated-space objective
181
+
182
+ The only mechanism in the codebase that measures generated-space statistics is
183
+ `_generator_response_cov_loss` (`lambda_generator_cov`, currently `0.0`). It perturbs the
184
+ mixture coefficients antithetically and matches the generator's central-difference
185
+ response covariance.
186
+
187
+ **It will not fix over-dispersion on its own.** Its docstring is explicit: it matches "only
188
+ the **trace-normalized** response covariance shape … without rewarding global expansion".
189
+ It is deliberately scale-free, i.e. it constrains direction and ignores amplitude — which
190
+ is the half we already have covered.
191
+
192
+ The amplitude half is a separate, also-disabled mechanism:
193
+
194
+ ```
195
+ generator_cov_rollout_calibration = false # off
196
+ generator_cov_amplitude_anchor = md_trace # becomes rollout_trace when the above is on
197
+ generator_cov_rollout_steps = 2
198
+ generator_cov_rollout_num_deltas = 1
199
+ generator_cov_rollout_max_examples= 4
200
+ generator_cov_rollout_interval_steps = 200 # cost control: runs 1 step in 200
201
+ generator_cov_rollout_ema_decay = 0.9
202
+ lambda_gen_trace_anchor = 0.05
203
+ ```
204
+
205
+ This is the piece that constrains the amplitude of what the flow actually generates, on a
206
+ short rollout, amortised over 200 steps and smoothed by an EMA. It is the only candidate
207
+ that acts where §3 showed the problem lives.
208
+
209
+ Open before enabling it:
210
+
211
+ 1. Does it compose with `md_subspace_shape_loss`, or do they fight? Both constrain second
212
+ moments, one in conditioning space and one in generated space.
213
+ 2. What is the real step-time cost of a 2-step rollout on 4 examples every 200 steps?
214
+ 3. `amplitude_anchor = rollout_trace` anchors to the *initial* checkpoint's amplitude. The
215
+ initial checkpoint here is stock BBFlow, whose amplitude is correct (PW Med 2.76 against
216
+ 2.91) — so the anchor target is the right one, but this needs confirming in the code
217
+ rather than assumed.
218
+
219
+ None of this has been run. Do not report §8 as a result.
220
+
221
+ ## 9. Practical notes
222
+
223
+ - **DDP inference silently drops proteins.** With `num_gpus=3`, ranks 1 and 2 stop partway
224
+ through their shards and the launcher still exits 0. The missing indices are exactly the
225
+ tails of the `≡1` and `≡2 (mod 3)` interleaved shards. Single-GPU inference
226
+ (`num_gpus=1`) is correct; it needed one fix, since `interpolant_bbflow.py` called
227
+ `dist.get_rank()` unguarded in a progress-bar label.
228
+ - **Verify by model count, never by file count.** `predict_step` skips any protein whose
229
+ `sampled_conformations.pdb` exists, so a truncated file is treated as finished forever.
230
+ Re-running is a valid resume only after the short files are deleted.
231
+ - **`last.ckpt` used to duplicate the periodic checkpoint.** With `every_n_epochs=5` it was
232
+ refreshed only when the periodic save fired, so an interrupted run lost up to four
233
+ epochs. `experiments/train.py` now runs a second, epoch-by-epoch writer that owns
234
+ `last.ckpt` alone.
235
+ - **Stale exports.** A leftover `MAX_STEPS=220` and `RUN_DIR` in the shell silently
236
+ truncated one run at 220 steps and wrote its checkpoints into an unrelated run's
237
+ directory. `unset RUN_DIR MAX_STEPS MAX_EPOCHS EXTRA_HYDRA_ARGS` before launching.
238
+ - **`MAX_NUM_RES_SQUARED`.** The sampler takes
239
+ `min(max_batch_size, max_num_res_squared // seq_len² + 1)`; with `max_num_res: 750` this
240
+ value alone sets the batch at the longest proteins. `4500000 → 8`, `2250000 → 5`,
241
+ `1125000 → 3`. The CMFM run fitted in memory because the collective path chunked the
242
+ backbone to 4; disabling the collective objective removed that chunking, so `1125000`
243
+ plus `full_model_activation_checkpoint=true` is what reproduces the old envelope.
244
+
245
+ ## 10. Data handling
246
+
247
+ Splits verified disjoint: train 1269, validation 39, test 82, all pairwise intersections
248
+ empty. The motion-target cache covers all three splits, but training only ever looks up
249
+ names from the training loader, so test entries are never read. At inference the model
250
+ sees only the equilibrium structure. `oracle_condition` — the path that would build the
251
+ condition from the target frame — is `false`.
252
+
253
+ Using per-protein MD covariance statistics as training targets is not extra information
254
+ relative to the baseline: BBFlow's flow matching already trains on the individual MD frames
255
+ of the same proteins, and the covariance is a deterministic function of those frames. It is
256
+ the same data presented differently.
257
+
258
+ One caveat that does apply: **`condition_scale` and `gamma_trans` were swept on the test
259
+ set.** Selecting the best value there and reporting it is test-set tuning. Both sweeps came
260
+ out negative, so nothing currently rests on it — but if any inference-time setting is
261
+ adopted, the selection has to be redone on the 39 validation proteins and applied once to
262
+ test.
bbflow_base/docs/protein_project_conversation_record_2026-07-13.jsonl ADDED
@@ -0,0 +1,13 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {"type":"record_meta","project":"protein","date":"2026-07-13","note":"Curated JSONL transcript for the protein project conversation. Raw Codex session archives remain under C:\\Users\\wykstc\\.codex\\sessions and C:\\Users\\wykstc\\.codex\\archived_sessions."}
2
+ {"type":"event","date":"2026-07-09","topic":"A-cycle resume and checkpoint handling","summary":"We established that the resumed run needed exact checkpoint inspection, not guesswork from log epochs. The important lesson recorded was that resume state must be verified from the actual ckpt and config, especially epoch/global_step and optimizer state."}
3
+ {"type":"event","date":"2026-07-10","topic":"Inference and diagnostics reliability","summary":"Several diagnostics failed because of assumptions about metadata columns, reference paths, and device placement. Lessons were written into the project trace: read the code first, do not assume CSV schema, do not assume trajectory counts, and do not rely on default reference directories."}
4
+ {"type":"event","date":"2026-07-11","topic":"Condition and covariance analysis","summary":"The project established that condition signal is present, but standard downstream metrics still do not beat BBFlow. The working diagnosis shifted toward a generator-response gap and the fact that prior covariance supervision does not directly constrain the generator output ensemble."}
5
+ {"type":"event","date":"2026-07-12","topic":"q calibration and temperature sweep","summary":"We measured q as too wide relative to c* and tried condition temperature sweeps. Lowering tau improved some covariance/cross-cov signals but did not improve official Pairwise/PCA metrics enough to claim victory."}
6
+ {"type":"event","date":"2026-07-12","topic":"Generator-response loss direction","summary":"A new training direction was implemented in bbflow_module.py: sample c perturbations around q, run paired generator forwards, and use the response difference as a covariance-like signal that passes through the generator instead of only supervising the prior."}
7
+ {"type":"event","date":"2026-07-12","topic":"Training interruption","summary":"The gen-response run advanced through several epochs with internal metrics improving, then the host fan health alarms triggered and the run was killed before the later checkpoints were saved."}
8
+ {"type":"event","date":"2026-07-13","topic":"Checkpoint investigation","summary":"We checked the actual saved files and found only epoch:004.ckpt and last.ckpt, both at epoch=4/global_step=17995. That meant later epochs were not saved, because the active config had every_n_epochs=5."}
9
+ {"type":"event","date":"2026-07-13","topic":"Code fix","summary":"The local training launcher base_stages/00_train_base_ddp.sh was patched to make checkpoint cadence explicit via CHECKPOINT_EVERY_N_EPOCHS, CHECKPOINT_SAVE_LAST, and CHECKPOINT_SAVE_TOP_K, with the default set to save every epoch."}
10
+ {"type":"event","date":"2026-07-13","topic":"Inference run behavior","summary":"We verified in code that inference skips completed proteins when sampled_conformations.pdb already exists, but incomplete proteins are recomputed. That means rerunning the same inference name can continue from partial progress as long as the completed outputs remain intact."}
11
+ {"type":"event","date":"2026-07-13","topic":"Project lesson","summary":"A new note was added to docs/experiment_trace_2026-07-05.md: when code or config can answer a question, inspect it directly before advising the user. Do not guess checkpoint cadence, resume behavior, or inference skip behavior."}
12
+ {"type":"event","date":"2026-07-13","topic":"Current best recoverable checkpoint","summary":"The only recoverable checkpoint from the interrupted run is epoch:004.ckpt. That is the checkpoint to infer from or resume from, with explicit per-epoch saving enabled going forward."}
13
+ {"type":"event","date":"2026-07-13","topic":"Conversation archive location","summary":"The raw local Codex archives live under C:\\Users\\wykstc\\.codex\\sessions\\YYYY\\MM\\DD\\rollout-*.jsonl and C:\\Users\\wykstc\\.codex\\archived_sessions\\rollout-*.jsonl. The repo now also contains a curated project transcript in docs/ for quick reference."}
bbflow_base/docs/protein_project_conversation_record_2026-07-13.txt ADDED
@@ -0,0 +1,71 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ Protein Project Conversation Record
2
+ Date: 2026-07-13
3
+
4
+ Raw local Codex storage:
5
+ C:\Users\wykstc\.codex\sessions\2026\...
6
+ C:\Users\wykstc\.codex\archived_sessions\...
7
+
8
+ Project context:
9
+ - Workspace: D:\pycharm\pythonProject\protein
10
+ - Main repo discussed: bbflow_base
11
+ - Goal: improve BBFlow-like protein generation and evaluation, especially checkpoint handling, inference behavior, and post-training diagnosis.
12
+
13
+ Key conversation record:
14
+
15
+ 1. Training resume and checkpoint behavior
16
+ - We traced why a resumed run only had epoch:004.ckpt and last.ckpt, both at epoch=4/global_step=17995.
17
+ - The server run used a config with every_n_epochs: 5, so checkpoints were only written every five epochs.
18
+ - We added a project lesson that code/config must be inspected before claiming resume/skip/checkpoint behavior.
19
+ - We updated the local training launcher bbflow_base/base_stages/00_train_base_ddp.sh to expose checkpoint cadence explicitly through:
20
+ CHECKPOINT_EVERY_N_EPOCHS
21
+ CHECKPOINT_SAVE_LAST
22
+ CHECKPOINT_SAVE_TOP_K
23
+ - Default behavior in that script is now every epoch save, save_last=true, save_top_k=-1.
24
+
25
+ 2. Inference and resume lessons
26
+ - We confirmed that the inference pipeline can skip proteins that already have sampled_conformations.pdb, by checking the code path in bbflow_module.py.
27
+ - We added a lesson to the project trace: do not assume inference will skip or resume safely unless the code path is inspected.
28
+ - We confirmed that a killed inference run can be resumed with the same INFERENCE_NAME if complete protein outputs already exist; completed proteins are skipped, incomplete ones are recomputed.
29
+ - We recorded that the raw inference logs and outputs live under the shared reproduction tree, not in the repo itself.
30
+
31
+ 3. Generator-response training direction
32
+ - We introduced and implemented a generator-response covariance loss path in bbflow_module.py.
33
+ - The implementation samples a perturbation around q, forms c_plus and c_minus, runs two extra generator forwards, and uses their difference to compute a covariance-like training signal.
34
+ - The motivation was to make the covariance supervision pass through the generator instead of only living in the prior/q statistics.
35
+ - Internal metric trends during the run were promising:
36
+ - gen_response_abs_mean increased steadily.
37
+ - gen_rmsf_loss and gen_cov_loss decreased.
38
+ - cross_cov_far_corr improved.
39
+ - The run was interrupted by host fan warnings and SIGTERM.
40
+
41
+ 4. Inference run interruption and file protection
42
+ - We stopped an inference run when the host fan health alarms triggered.
43
+ - The run was started with:
44
+ INFERENCE_NAME=atlas_test_250_genresp_v1_epoch004_5ep_real
45
+ CKPT_PATH=.../epoch:004.ckpt
46
+ - We confirmed the inference code skips already-completed proteins based on the presence of sampled_conformations.pdb in the output directory.
47
+ - We recorded that partial outputs are not automatically guaranteed to be safely reused unless that file exists.
48
+
49
+ 5. Diagnostic rigor lessons
50
+ - We documented multiple times that code/config must be checked directly before claiming:
51
+ - checkpoint cadence
52
+ - resume behavior
53
+ - inference skip behavior
54
+ - device placement
55
+ - reference-path selection
56
+ - We explicitly recorded that the project should not rely on "probably" or "likely" when the repository code can determine the answer.
57
+ - We also recorded that per-protein drilldowns are low priority unless explicitly needed.
58
+
59
+ 6. Where the raw conversation is stored
60
+ - The Codex desktop app keeps its local session archive under:
61
+ C:\Users\wykstc\.codex\sessions\YYYY\MM\DD\rollout-*.jsonl
62
+ - Older archived sessions may also appear under:
63
+ C:\Users\wykstc\.codex\archived_sessions\rollout-*.jsonl
64
+ - The project repo itself does not store the raw full transcript automatically unless we write a copy into docs/.
65
+
66
+ 7. Working conclusion at the end of this thread
67
+ - The current best recoverable checkpoint from the interrupted run is epoch:004.ckpt.
68
+ - The correct next action is to infer from that checkpoint if needed, or resume from it with explicit checkpoint saving cadence set to every epoch.
69
+ - The repository now contains a direct note that checkpoint behavior must be verified from config.yaml and actual ckpt files rather than from log epoch labels.
70
+
71
+ End of record.
bbflow_base/docs/protein_project_full_chat_2026-07-13.jsonl ADDED
The diff for this file is too large to render. See raw diff
 
bbflow_base/docs/superpowers/plans/2026-06-28-kabsch-static-control.md ADDED
@@ -0,0 +1,53 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Kabsch and Static-Control Correction Implementation Plan
2
+
3
+ > **For agentic workers:** REQUIRED SUB-SKILL: Use superpowers:subagent-driven-development (recommended) or superpowers:executing-plans to implement this plan task-by-task. Steps use checkbox (`- [ ]`) syntax for tracking.
4
+
5
+ **Goal:** Correct row-vector Kabsch alignment and make static evaluation reuse one sampled coefficient through the real condition path.
6
+
7
+ **Architecture:** Add a small shared alignment utility consumed by the latent encoder and downstream probes. Change static-condition construction to sample one real condition and repeat it, with a stable seed across ensemble chunks.
8
+
9
+ **Tech Stack:** Python, PyTorch, pytest.
10
+
11
+ ---
12
+
13
+ ### Task 1: Shared Kabsch Regression
14
+
15
+ **Files:**
16
+ - Create: `bbflow/data/alignment.py`
17
+ - Create: `tests/test_alignment.py`
18
+ - Modify: `bbflow/models/latent.py`
19
+ - Modify: `scripts/probe_condition_ensemble_cov.py`
20
+
21
+ - [ ] Write a known-rotation test where `moving = reference @ R0 + translation` and aligned coordinates equal reference.
22
+ - [ ] Run the focused test and verify the current implementation fails on a nonsymmetric rotation.
23
+ - [ ] Implement shared row-vector Kabsch as `U @ D @ Vh`.
24
+ - [ ] Route latent and probe alignment through the shared function.
25
+ - [ ] Run the focused test and existing motion diagnostic tests.
26
+
27
+ ### Task 2: Fixed-C Static Control
28
+
29
+ **Files:**
30
+ - Modify: `scripts/probe_condition_quality_vs_md.py`
31
+ - Modify: `tests/test_condition_quality_probe.py`
32
+
33
+ - [ ] Write a test requiring static to call `sample_prior_z` on one row and repeat the resulting coefficient and condition tensors.
34
+ - [ ] Write a test requiring static to remain identical when ensemble generation crosses chunk boundaries.
35
+ - [ ] Run both tests and verify the current `forward_prior` implementation fails them.
36
+ - [ ] Implement one-sample static construction using `sample_prior_z` and `repeat_condition`.
37
+ - [ ] Keep the static condition seed fixed across chunks while preserving per-chunk seeds for real/zero/shuffled.
38
+ - [ ] Run focused condition tests.
39
+
40
+ ### Task 3: Condition-Path Audit and Verification
41
+
42
+ **Files:**
43
+ - Inspect: `bbflow/models/bbflow_model.py`
44
+ - Inspect: `bbflow/models/embedder.py`
45
+ - Inspect: `bbflow/models/latent.py`
46
+ - Inspect: `scripts/probe_condition_quality_vs_md.py`
47
+
48
+ - [ ] Enumerate every model-side `z` consumer and confirm the four injected keys cover them.
49
+ - [ ] Trace coefficient detach and normalization operations from training projection and inference sampling.
50
+ - [ ] Verify real, zero, shuffled, and static seed relationships.
51
+ - [ ] Run `py_compile` on changed Python files.
52
+ - [ ] Run focused pytest files and report any environment limitation without claiming unrun tests pass.
53
+
bbflow_base/docs/superpowers/specs/2026-06-28-kabsch-static-control-design.md ADDED
@@ -0,0 +1,28 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Kabsch and Static-Control Correction Design
2
+
3
+ ## Scope
4
+
5
+ Correct the coordinate-alignment convention used by motion targets and downstream ensemble metrics, and make the static condition a true fixed-coefficient control. Do not change the learned prior, MoG objective, generator architecture, or loss weights.
6
+
7
+ ## Alignment
8
+
9
+ Provide one shared Torch implementation for row-vector coordinates. For centered moving coordinates `X`, centered target coordinates `Y`, and `H = X^T Y`, use `R = U D Vh` where `H = U S Vh` and `D` corrects reflections. Both `LatentEncoder.align_to_reference` and downstream probes must call this implementation.
10
+
11
+ Known-answer behavior: if `moving = centered_reference @ R0 + translation`, aligning moving to reference must recover the reference to numerical precision. Masks and batches remain supported.
12
+
13
+ ## Static Condition
14
+
15
+ The static group must use the same `sample_prior_z -> condition_from_mode_coefficients` path as the real group. It samples one coefficient vector for a protein and repeats the resulting condition over every generated conformation. The same coefficient is reused across sampling chunks. Real continues to sample one coefficient per conformation; zero and shuffled remain matched transformations of real.
16
+
17
+ ## Audit Boundary
18
+
19
+ Inspect all model-side consumers of `z`, all detach operations on coefficients and modes, and all seed/chunk handling in the downstream probe. Report additional defects but do not change unrelated architecture in this patch.
20
+
21
+ ## Verification
22
+
23
+ - Known rotation, translation, mask, and reflection-safe Kabsch tests.
24
+ - Generated and motion-target alignment paths resolve to the shared implementation.
25
+ - Static coefficients are identical across batch rows and repeated calls/chunks.
26
+ - Real coefficients remain independent across rows.
27
+ - Zero and shuffled controls retain their existing matched semantics.
28
+
bbflow_base/lightning_logs/version_10/hparams.yaml ADDED
@@ -0,0 +1,264 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_official_modelonly_long_finetune_orth1_recon0_100ep_3gpu_20260630_191404
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/datasets/ATLAS
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 32
39
+ max_num_res_squared: 400000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /home/wangyusong/LD-FPG-main/bbflow/models/bbflow-0.1/bbflow-0.1.ckpt
48
+ warm_start_cfg_override: false
49
+ use_swa: false
50
+ first_val_epoch: .inf
51
+ reset_epoch: false
52
+ batch_ot:
53
+ enabled: true
54
+ cost: kabsch
55
+ noise_per_sample: 1
56
+ training:
57
+ min_plddt_mask: null
58
+ loss: se3_vf_loss
59
+ bb_atom_scale: 0.1
60
+ trans_scale: 0.1
61
+ translation_loss_weight: 2.0
62
+ t_normalize_clip: 0.9
63
+ rotation_loss_weights: 1.0
64
+ aux_loss_weight: 1.0
65
+ aux_loss_t_pass: 0.75
66
+ t_bins: 4
67
+ ca_distmat_loss_weight: 0.0
68
+ ensemble_group_size: 0
69
+ force_grouped_batch: false
70
+ lambda_shape: 1.0
71
+ lambda_local_cov: 1.0
72
+ lambda_cross_cov: 1.0
73
+ lambda_rmsf: 0.25
74
+ lambda_mode_recon: 0.0
75
+ enm_warmup_epochs: 0
76
+ lambda_enm_warmup: 1.0
77
+ log_latent_batch_debug: false
78
+ epoch_condition_probe: false
79
+ condition_probe_scale: 2.0
80
+ diagnostic_interval_steps: 50
81
+ per_frame_coeff_condition: true
82
+ lambda_motion: 1.0
83
+ lambda_q: 1.0
84
+ lambda_mode_orth: 1.0
85
+ oracle_condition: false
86
+ grad_flow_check: true
87
+ log_optimizer_coverage: true
88
+ wandb:
89
+ name: bbflow_base_official_modelonly_long_finetune_orth1_recon0_100ep_3gpu_20260630_191404
90
+ project: bbflow
91
+ save_dir: outputs/
92
+ tags: []
93
+ optimizer:
94
+ lr: 0.0001
95
+ reset_optimizer_on_load: false
96
+ warmup_lr: false
97
+ warmup_lr_factor: 0.01
98
+ trainer:
99
+ overfit_batches: 0
100
+ min_epochs: 1
101
+ max_epochs: 100
102
+ accelerator: gpu
103
+ precision: 32-true
104
+ log_every_n_steps: 50
105
+ deterministic: false
106
+ strategy: ddp
107
+ check_val_every_n_epoch: 1
108
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_official_modelonly_long_finetune_orth1_recon0_100ep_3gpu_20260630_191404
109
+ accumulate_grad_batches: 1
110
+ max_steps: -1
111
+ profiler: null
112
+ num_sanity_val_steps: 0
113
+ checkpointer:
114
+ dirpath: ./
115
+ save_last: true
116
+ save_on_train_epoch_end: true
117
+ filename: epoch:{epoch:03d}
118
+ every_n_epochs: 1
119
+ save_top_k: -1
120
+ auto_insert_metric_name: false
121
+ checkpointer2: null
122
+ profiler:
123
+ enabled: false
124
+ modules: null
125
+ profile:
126
+ use_cuda: true
127
+ with_stack: false
128
+ stats:
129
+ group_by_stack_n: 0
130
+ group_by_input_shapes: false
131
+ prefixes:
132
+ - 'layer_0::'
133
+ - 'layer_1::'
134
+ sort_by: cpu_time_total
135
+ scheduler:
136
+ enabled: false
137
+ interpolant:
138
+ use_tqdm: true
139
+ batch_ot: intra
140
+ prior: conditional
141
+ prior_conditional:
142
+ gamma_trans: 0.2
143
+ gamma_rots: 0.2
144
+ min_t: 0.01
145
+ t_interval:
146
+ - 0.0
147
+ - 1.0
148
+ rots:
149
+ distribution: uniform
150
+ train_schedule: linear
151
+ sample_schedule: exp
152
+ exp_rate: 10
153
+ linear_scaling: 1
154
+ trans:
155
+ train_schedule: linear
156
+ sample_schedule: linear
157
+ sampling:
158
+ num_timesteps: 20
159
+ self_condition: true
160
+ noise_res_scaling_power: 0.0
161
+ noise_scale: 1.0
162
+ t_sampling_focus: 0.0
163
+ model:
164
+ node_embed_size: 240
165
+ edge_embed_size: 120
166
+ embed:
167
+ index_embed_type: full
168
+ index_embed_dim: 128
169
+ time_embed_dim: 128
170
+ embed_aatype: true
171
+ aatype_embed_dim: 128
172
+ length_embed_dim: 16
173
+ embed_self_conditioning: true
174
+ num_bins_distance: 22
175
+ min_bin_distance: 1.0e-05
176
+ max_bin_distance: 20.0
177
+ embed_distogram: true
178
+ embed_direction: false
179
+ embed_direction_cutoff: 5
180
+ edge_features:
181
+ self_condition: true
182
+ gfa:
183
+ c_s: 240
184
+ c_z: 120
185
+ c_hidden: 120
186
+ no_heads: 8
187
+ no_qk_points: 8
188
+ no_v_points: 8
189
+ seq_tfmr_num_heads: 4
190
+ seq_tfmr_num_layers: 2
191
+ num_blocks: 6
192
+ latent:
193
+ enable: true
194
+ dim: 16
195
+ num_modes: 8
196
+ motion_message_passing_layers: 4
197
+ cross_cov_near_distance: 12.0
198
+ template_residual_scale: 0.1
199
+ template_remove_rotation: true
200
+ use_enm_features: false
201
+ enm_num_modes: 8
202
+ enm_cutoff: 12.0
203
+ enm_eps: 1.0e-06
204
+ node_cond_dim: 8
205
+ edge_cond_dim: 8
206
+ freeze_foundation: false
207
+ inject_embedder: true
208
+ inject_film: true
209
+ activation_checkpoint: true
210
+ shape_fingerprint_k: 5
211
+ shape_fingerprint_cache_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
212
+ motion_target_cache_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
213
+ z_stochastic: false
214
+ track_condition_debug: false
215
+ mixture_components: 2
216
+ q_lstsq_ridge: 0.0001
217
+ q_cholesky_jitter: 0.0001
218
+ q_detach_projection: true
219
+ q_detach_shared_encoder: false
220
+ sample_coefficients: true
221
+ inference:
222
+ name: atlas_test_250_shuffled
223
+ seed: 123
224
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_official_modelonly_long_finetune_orth1_recon0_100ep_3gpu_20260630_191404/last.ckpt
225
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_official_modelonly_long_finetune_orth1_recon0_100ep_3gpu_20260630_191404/standard_downstream_fast/inference
226
+ use_ckpt_name_in_outpath: true
227
+ use_gpu: true
228
+ num_gpus: 1
229
+ use_tqdm: true
230
+ log_times: true
231
+ z_per_sample: false
232
+ condition_mode: shuffled
233
+ condition_scale: 1.0
234
+ postprocess_bfactors: false
235
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
236
+ sort: false
237
+ num_proteins: null
238
+ min_length: null
239
+ max_length: null
240
+ save_traj: false
241
+ single_file: true
242
+ interpolant:
243
+ use_tqdm: true
244
+ min_t: 0.0
245
+ max_t: 0.99
246
+ rots:
247
+ distribution: uniform
248
+ sample_schedule: exp
249
+ exp_rate: 10
250
+ trans:
251
+ sample_schedule: linear
252
+ sampling:
253
+ num_timesteps: 20
254
+ self_condition: true
255
+ prior: conditional
256
+ prior_conditional:
257
+ gamma_trans: 0.2
258
+ gamma_rots: 0.2
259
+ batch_ot: intra
260
+ samples:
261
+ samples_per_protein: 250
262
+ batch_size: 20
263
+ num_res_squared: 4000000
264
+ folding_cfg: null
bbflow_base/lightning_logs/version_100/hparams.yaml ADDED
@@ -0,0 +1,314 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260805_113245
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/Atlas
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 8
39
+ max_num_res_squared: 1125000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /home/wangyusong/LD-FPG-main/bbflow_base/models/bbflow-0.1/bbflow-0.1.ckpt
48
+ model_only_warm_start: true
49
+ warm_start_cfg_override: false
50
+ use_swa: false
51
+ first_val_epoch: .inf
52
+ reset_epoch: false
53
+ batch_ot:
54
+ enabled: true
55
+ cost: kabsch
56
+ noise_per_sample: 1
57
+ training:
58
+ min_plddt_mask: null
59
+ loss: se3_vf_loss
60
+ bb_atom_scale: 0.1
61
+ trans_scale: 0.1
62
+ translation_loss_weight: 2.0
63
+ t_normalize_clip: 0.9
64
+ rotation_loss_weights: 1.0
65
+ aux_loss_weight: 1.0
66
+ aux_loss_t_pass: 0.75
67
+ t_bins: 4
68
+ ca_distmat_loss_weight: 0.0
69
+ ensemble_group_size: 0
70
+ force_grouped_batch: false
71
+ lambda_shape: 1.0
72
+ lambda_local_cov: 0.0
73
+ lambda_cross_cov: 0.0
74
+ lambda_rmsf: 1.0
75
+ lambda_mode_recon: 0.0
76
+ enm_warmup_epochs: 0
77
+ lambda_enm_warmup: 1.0
78
+ log_latent_batch_debug: false
79
+ full_model_activation_checkpoint: true
80
+ epoch_condition_probe: false
81
+ condition_probe_scale: 2.0
82
+ diagnostic_interval_steps: 50
83
+ lambda_generator_cov: 0.0
84
+ lambda_collective_measure: 0.0
85
+ lambda_md_subspace: 1.0
86
+ md_subspace_weight_exp: 0.0
87
+ lambda_md_subspace_trace: 1.0
88
+ cmfm_numerics_log_interval: 50
89
+ cmfm_grad_guard: true
90
+ cmfm_capture_failure: true
91
+ cmfm_dump_state_dict: true
92
+ generator_cov_use_cross: false
93
+ generator_cov_t_min: 0.1
94
+ generator_cov_t_max: 0.6
95
+ generator_cov_delta_scale: 1.0
96
+ generator_cov_num_deltas: 2
97
+ generator_cov_student_chunk_deltas: 1
98
+ generator_cov_teacher_num_deltas: 1
99
+ generator_cov_teacher_reuse_student_delta: true
100
+ generator_cov_teacher_trace_denominator: teacher
101
+ generator_cov_checkpoint: false
102
+ generator_cov_initial_trace_anchor: true
103
+ generator_cov_amplitude_anchor: md_trace
104
+ generator_cov_rollout_calibration: false
105
+ generator_cov_rollout_steps: 2
106
+ generator_cov_rollout_num_deltas: 1
107
+ generator_cov_rollout_max_examples: 4
108
+ generator_cov_rollout_interval_steps: 200
109
+ generator_cov_rollout_ema_decay: 0.9
110
+ lambda_gen_local_shape: 1.0
111
+ lambda_gen_cross_shape: 1.0
112
+ lambda_gen_trace_anchor: 0.05
113
+ per_frame_coeff_condition: true
114
+ lambda_motion: 1.0
115
+ lambda_q: 1.0
116
+ lambda_mode_orth: 1.0
117
+ lambda_pca_align: 0.0
118
+ lambda_condition_cycle: 0.0
119
+ oracle_condition: false
120
+ grad_flow_check: true
121
+ log_optimizer_coverage: true
122
+ wandb:
123
+ name: mdsubspace_20260805_113245
124
+ project: bbflow
125
+ save_dir: outputs/
126
+ tags: []
127
+ optimizer:
128
+ lr: 0.0001
129
+ reset_optimizer_on_load: false
130
+ warmup_lr: false
131
+ warmup_lr_factor: 0.01
132
+ trainer:
133
+ overfit_batches: 0
134
+ min_epochs: 1
135
+ max_epochs: 20
136
+ accelerator: gpu
137
+ precision: bf16-mixed
138
+ log_every_n_steps: 50
139
+ deterministic: false
140
+ strategy: ddp
141
+ check_val_every_n_epoch: 1
142
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260805_113245
143
+ accumulate_grad_batches: 1
144
+ max_steps: -1
145
+ profiler: null
146
+ num_sanity_val_steps: 0
147
+ checkpointer:
148
+ dirpath: ./
149
+ save_last: true
150
+ save_on_train_epoch_end: true
151
+ filename: epoch:{epoch:03d}
152
+ every_n_epochs: 2
153
+ save_top_k: -1
154
+ auto_insert_metric_name: false
155
+ checkpointer2: null
156
+ profiler:
157
+ enabled: false
158
+ modules: null
159
+ profile:
160
+ use_cuda: true
161
+ with_stack: false
162
+ stats:
163
+ group_by_stack_n: 0
164
+ group_by_input_shapes: false
165
+ prefixes:
166
+ - 'layer_0::'
167
+ - 'layer_1::'
168
+ sort_by: cpu_time_total
169
+ scheduler:
170
+ enabled: false
171
+ interpolant:
172
+ use_tqdm: true
173
+ batch_ot: intra
174
+ prior: conditional
175
+ prior_conditional:
176
+ gamma_trans: 0.2
177
+ gamma_rots: 0.2
178
+ min_t: 0.01
179
+ t_interval:
180
+ - 0.0
181
+ - 1.0
182
+ rots:
183
+ distribution: uniform
184
+ train_schedule: linear
185
+ sample_schedule: exp
186
+ exp_rate: 10
187
+ linear_scaling: 1
188
+ trans:
189
+ train_schedule: linear
190
+ sample_schedule: linear
191
+ sampling:
192
+ num_timesteps: 20
193
+ self_condition: true
194
+ noise_res_scaling_power: 0.0
195
+ noise_scale: 1.0
196
+ t_sampling_focus: 0.0
197
+ model:
198
+ node_embed_size: 240
199
+ edge_embed_size: 120
200
+ embed:
201
+ index_embed_type: full
202
+ index_embed_dim: 128
203
+ time_embed_dim: 128
204
+ embed_aatype: true
205
+ aatype_embed_dim: 128
206
+ length_embed_dim: 16
207
+ embed_self_conditioning: true
208
+ num_bins_distance: 22
209
+ min_bin_distance: 1.0e-05
210
+ max_bin_distance: 20.0
211
+ embed_distogram: true
212
+ embed_direction: false
213
+ embed_direction_cutoff: 5
214
+ edge_features:
215
+ self_condition: true
216
+ gfa:
217
+ c_s: 240
218
+ c_z: 120
219
+ c_hidden: 120
220
+ no_heads: 8
221
+ no_qk_points: 8
222
+ no_v_points: 8
223
+ seq_tfmr_num_heads: 4
224
+ seq_tfmr_num_layers: 2
225
+ num_blocks: 6
226
+ latent:
227
+ enable: true
228
+ dim: 16
229
+ num_modes: 8
230
+ motion_message_passing_layers: 4
231
+ cross_cov_near_distance: 12.0
232
+ template_residual_scale: 1.0
233
+ template_remove_rotation: true
234
+ use_enm_features: false
235
+ enm_num_modes: 8
236
+ enm_cutoff: 12.0
237
+ enm_eps: 1.0e-06
238
+ node_cond_dim: 8
239
+ edge_cond_dim: 8
240
+ freeze_foundation: false
241
+ inject_embedder: true
242
+ inject_film: true
243
+ activation_checkpoint: true
244
+ shape_fingerprint_k: 5
245
+ shape_fingerprint_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k12_kabsch_v1.pt
246
+ motion_target_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k12_kabsch_v1.pt
247
+ z_stochastic: false
248
+ collective_enable: false
249
+ collective_rank: 4
250
+ collective_hidden_dim: 128
251
+ collective_output_scale: 1.0
252
+ collective_spectrum_eps: 1.0e-06
253
+ mode_gauge_ridge: 1.0e-06
254
+ freeze_mode_head: false
255
+ track_condition_debug: false
256
+ collective_basis_from_data: false
257
+ collective_rate_weighted: true
258
+ mixture_components: 2
259
+ q_lstsq_ridge: 0.0001
260
+ q_cholesky_jitter: 0.0001
261
+ q_detach_projection: true
262
+ q_detach_shared_encoder: true
263
+ energy_from_q: false
264
+ energy_from_q_full_cov: false
265
+ sample_coefficients: true
266
+ pca_align_top_m: 2
267
+ inference:
268
+ name: w0_ep015
269
+ seed: 123
270
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260805_113245/epoch:015.ckpt
271
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference/cmfm
272
+ use_ckpt_name_in_outpath: true
273
+ use_gpu: true
274
+ num_gpus: 1
275
+ precision: 32-true
276
+ use_tqdm: true
277
+ log_times: false
278
+ z_per_sample: true
279
+ condition_mode: real
280
+ condition_scale: 1.0
281
+ postprocess_bfactors: true
282
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
283
+ sort: false
284
+ num_proteins: null
285
+ num_workers: 2
286
+ min_length: null
287
+ max_length: null
288
+ save_traj: false
289
+ final_only: true
290
+ cache_static_features: true
291
+ single_file: true
292
+ interpolant:
293
+ use_tqdm: true
294
+ min_t: 0.0
295
+ max_t: 0.99
296
+ rots:
297
+ distribution: uniform
298
+ sample_schedule: exp
299
+ exp_rate: 10
300
+ trans:
301
+ sample_schedule: linear
302
+ sampling:
303
+ num_timesteps: 20
304
+ self_condition: true
305
+ prior: conditional
306
+ prior_conditional:
307
+ gamma_trans: 0.2
308
+ gamma_rots: 0.2
309
+ batch_ot: intra
310
+ samples:
311
+ samples_per_protein: 250
312
+ batch_size: 10
313
+ num_res_squared: 6000000
314
+ folding_cfg: null
bbflow_base/lightning_logs/version_101/hparams.yaml ADDED
@@ -0,0 +1,314 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260805_113245
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/Atlas
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 8
39
+ max_num_res_squared: 1125000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /home/wangyusong/LD-FPG-main/bbflow_base/models/bbflow-0.1/bbflow-0.1.ckpt
48
+ model_only_warm_start: true
49
+ warm_start_cfg_override: false
50
+ use_swa: false
51
+ first_val_epoch: .inf
52
+ reset_epoch: false
53
+ batch_ot:
54
+ enabled: true
55
+ cost: kabsch
56
+ noise_per_sample: 1
57
+ training:
58
+ min_plddt_mask: null
59
+ loss: se3_vf_loss
60
+ bb_atom_scale: 0.1
61
+ trans_scale: 0.1
62
+ translation_loss_weight: 2.0
63
+ t_normalize_clip: 0.9
64
+ rotation_loss_weights: 1.0
65
+ aux_loss_weight: 1.0
66
+ aux_loss_t_pass: 0.75
67
+ t_bins: 4
68
+ ca_distmat_loss_weight: 0.0
69
+ ensemble_group_size: 0
70
+ force_grouped_batch: false
71
+ lambda_shape: 1.0
72
+ lambda_local_cov: 0.0
73
+ lambda_cross_cov: 0.0
74
+ lambda_rmsf: 1.0
75
+ lambda_mode_recon: 0.0
76
+ enm_warmup_epochs: 0
77
+ lambda_enm_warmup: 1.0
78
+ log_latent_batch_debug: false
79
+ full_model_activation_checkpoint: true
80
+ epoch_condition_probe: false
81
+ condition_probe_scale: 2.0
82
+ diagnostic_interval_steps: 50
83
+ lambda_generator_cov: 0.0
84
+ lambda_collective_measure: 0.0
85
+ lambda_md_subspace: 1.0
86
+ md_subspace_weight_exp: 0.0
87
+ lambda_md_subspace_trace: 1.0
88
+ cmfm_numerics_log_interval: 50
89
+ cmfm_grad_guard: true
90
+ cmfm_capture_failure: true
91
+ cmfm_dump_state_dict: true
92
+ generator_cov_use_cross: false
93
+ generator_cov_t_min: 0.1
94
+ generator_cov_t_max: 0.6
95
+ generator_cov_delta_scale: 1.0
96
+ generator_cov_num_deltas: 2
97
+ generator_cov_student_chunk_deltas: 1
98
+ generator_cov_teacher_num_deltas: 1
99
+ generator_cov_teacher_reuse_student_delta: true
100
+ generator_cov_teacher_trace_denominator: teacher
101
+ generator_cov_checkpoint: false
102
+ generator_cov_initial_trace_anchor: true
103
+ generator_cov_amplitude_anchor: md_trace
104
+ generator_cov_rollout_calibration: false
105
+ generator_cov_rollout_steps: 2
106
+ generator_cov_rollout_num_deltas: 1
107
+ generator_cov_rollout_max_examples: 4
108
+ generator_cov_rollout_interval_steps: 200
109
+ generator_cov_rollout_ema_decay: 0.9
110
+ lambda_gen_local_shape: 1.0
111
+ lambda_gen_cross_shape: 1.0
112
+ lambda_gen_trace_anchor: 0.05
113
+ per_frame_coeff_condition: true
114
+ lambda_motion: 1.0
115
+ lambda_q: 1.0
116
+ lambda_mode_orth: 1.0
117
+ lambda_pca_align: 0.0
118
+ lambda_condition_cycle: 0.0
119
+ oracle_condition: false
120
+ grad_flow_check: true
121
+ log_optimizer_coverage: true
122
+ wandb:
123
+ name: mdsubspace_20260805_113245
124
+ project: bbflow
125
+ save_dir: outputs/
126
+ tags: []
127
+ optimizer:
128
+ lr: 0.0001
129
+ reset_optimizer_on_load: false
130
+ warmup_lr: false
131
+ warmup_lr_factor: 0.01
132
+ trainer:
133
+ overfit_batches: 0
134
+ min_epochs: 1
135
+ max_epochs: 20
136
+ accelerator: gpu
137
+ precision: bf16-mixed
138
+ log_every_n_steps: 50
139
+ deterministic: false
140
+ strategy: ddp
141
+ check_val_every_n_epoch: 1
142
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260805_113245
143
+ accumulate_grad_batches: 1
144
+ max_steps: -1
145
+ profiler: null
146
+ num_sanity_val_steps: 0
147
+ checkpointer:
148
+ dirpath: ./
149
+ save_last: true
150
+ save_on_train_epoch_end: true
151
+ filename: epoch:{epoch:03d}
152
+ every_n_epochs: 2
153
+ save_top_k: -1
154
+ auto_insert_metric_name: false
155
+ checkpointer2: null
156
+ profiler:
157
+ enabled: false
158
+ modules: null
159
+ profile:
160
+ use_cuda: true
161
+ with_stack: false
162
+ stats:
163
+ group_by_stack_n: 0
164
+ group_by_input_shapes: false
165
+ prefixes:
166
+ - 'layer_0::'
167
+ - 'layer_1::'
168
+ sort_by: cpu_time_total
169
+ scheduler:
170
+ enabled: false
171
+ interpolant:
172
+ use_tqdm: true
173
+ batch_ot: intra
174
+ prior: conditional
175
+ prior_conditional:
176
+ gamma_trans: 0.2
177
+ gamma_rots: 0.2
178
+ min_t: 0.01
179
+ t_interval:
180
+ - 0.0
181
+ - 1.0
182
+ rots:
183
+ distribution: uniform
184
+ train_schedule: linear
185
+ sample_schedule: exp
186
+ exp_rate: 10
187
+ linear_scaling: 1
188
+ trans:
189
+ train_schedule: linear
190
+ sample_schedule: linear
191
+ sampling:
192
+ num_timesteps: 20
193
+ self_condition: true
194
+ noise_res_scaling_power: 0.0
195
+ noise_scale: 1.0
196
+ t_sampling_focus: 0.0
197
+ model:
198
+ node_embed_size: 240
199
+ edge_embed_size: 120
200
+ embed:
201
+ index_embed_type: full
202
+ index_embed_dim: 128
203
+ time_embed_dim: 128
204
+ embed_aatype: true
205
+ aatype_embed_dim: 128
206
+ length_embed_dim: 16
207
+ embed_self_conditioning: true
208
+ num_bins_distance: 22
209
+ min_bin_distance: 1.0e-05
210
+ max_bin_distance: 20.0
211
+ embed_distogram: true
212
+ embed_direction: false
213
+ embed_direction_cutoff: 5
214
+ edge_features:
215
+ self_condition: true
216
+ gfa:
217
+ c_s: 240
218
+ c_z: 120
219
+ c_hidden: 120
220
+ no_heads: 8
221
+ no_qk_points: 8
222
+ no_v_points: 8
223
+ seq_tfmr_num_heads: 4
224
+ seq_tfmr_num_layers: 2
225
+ num_blocks: 6
226
+ latent:
227
+ enable: true
228
+ dim: 16
229
+ num_modes: 8
230
+ motion_message_passing_layers: 4
231
+ cross_cov_near_distance: 12.0
232
+ template_residual_scale: 1.0
233
+ template_remove_rotation: true
234
+ use_enm_features: false
235
+ enm_num_modes: 8
236
+ enm_cutoff: 12.0
237
+ enm_eps: 1.0e-06
238
+ node_cond_dim: 8
239
+ edge_cond_dim: 8
240
+ freeze_foundation: false
241
+ inject_embedder: true
242
+ inject_film: true
243
+ activation_checkpoint: true
244
+ shape_fingerprint_k: 5
245
+ shape_fingerprint_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k12_kabsch_v1.pt
246
+ motion_target_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k12_kabsch_v1.pt
247
+ z_stochastic: false
248
+ collective_enable: false
249
+ collective_rank: 4
250
+ collective_hidden_dim: 128
251
+ collective_output_scale: 1.0
252
+ collective_spectrum_eps: 1.0e-06
253
+ mode_gauge_ridge: 1.0e-06
254
+ freeze_mode_head: false
255
+ track_condition_debug: false
256
+ collective_basis_from_data: false
257
+ collective_rate_weighted: true
258
+ mixture_components: 2
259
+ q_lstsq_ridge: 0.0001
260
+ q_cholesky_jitter: 0.0001
261
+ q_detach_projection: true
262
+ q_detach_shared_encoder: true
263
+ energy_from_q: false
264
+ energy_from_q_full_cov: false
265
+ sample_coefficients: true
266
+ pca_align_top_m: 2
267
+ inference:
268
+ name: w0_ep001
269
+ seed: 123
270
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260805_113245/epoch:001.ckpt
271
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference/cmfm
272
+ use_ckpt_name_in_outpath: true
273
+ use_gpu: true
274
+ num_gpus: 1
275
+ precision: 32-true
276
+ use_tqdm: true
277
+ log_times: false
278
+ z_per_sample: true
279
+ condition_mode: real
280
+ condition_scale: 1.0
281
+ postprocess_bfactors: true
282
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
283
+ sort: false
284
+ num_proteins: null
285
+ num_workers: 2
286
+ min_length: null
287
+ max_length: null
288
+ save_traj: false
289
+ final_only: true
290
+ cache_static_features: true
291
+ single_file: true
292
+ interpolant:
293
+ use_tqdm: true
294
+ min_t: 0.0
295
+ max_t: 0.99
296
+ rots:
297
+ distribution: uniform
298
+ sample_schedule: exp
299
+ exp_rate: 10
300
+ trans:
301
+ sample_schedule: linear
302
+ sampling:
303
+ num_timesteps: 20
304
+ self_condition: true
305
+ prior: conditional
306
+ prior_conditional:
307
+ gamma_trans: 0.2
308
+ gamma_rots: 0.2
309
+ batch_ot: intra
310
+ samples:
311
+ samples_per_protein: 250
312
+ batch_size: 10
313
+ num_res_squared: 6000000
314
+ folding_cfg: null
bbflow_base/lightning_logs/version_102/hparams.yaml ADDED
@@ -0,0 +1,314 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260806_220254
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/Atlas
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 8
39
+ max_num_res_squared: 750000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /home/wangyusong/LD-FPG-main/bbflow_base/models/bbflow-0.1/bbflow-0.1.ckpt
48
+ model_only_warm_start: true
49
+ warm_start_cfg_override: false
50
+ use_swa: false
51
+ first_val_epoch: .inf
52
+ reset_epoch: false
53
+ batch_ot:
54
+ enabled: true
55
+ cost: kabsch
56
+ noise_per_sample: 1
57
+ training:
58
+ min_plddt_mask: null
59
+ loss: se3_vf_loss
60
+ bb_atom_scale: 0.1
61
+ trans_scale: 0.1
62
+ translation_loss_weight: 2.0
63
+ t_normalize_clip: 0.9
64
+ rotation_loss_weights: 1.0
65
+ aux_loss_weight: 1.0
66
+ aux_loss_t_pass: 0.75
67
+ t_bins: 4
68
+ ca_distmat_loss_weight: 0.0
69
+ ensemble_group_size: 0
70
+ force_grouped_batch: false
71
+ lambda_shape: 1.0
72
+ lambda_local_cov: 0.0
73
+ lambda_cross_cov: 0.0
74
+ lambda_rmsf: 1.0
75
+ lambda_mode_recon: 0.0
76
+ enm_warmup_epochs: 0
77
+ lambda_enm_warmup: 1.0
78
+ log_latent_batch_debug: false
79
+ full_model_activation_checkpoint: true
80
+ epoch_condition_probe: false
81
+ condition_probe_scale: 2.0
82
+ diagnostic_interval_steps: 50
83
+ lambda_generator_cov: 1.0
84
+ lambda_collective_measure: 0.0
85
+ lambda_md_subspace: 0.0
86
+ md_subspace_weight_exp: 0.0
87
+ lambda_md_subspace_trace: 0.0
88
+ cmfm_numerics_log_interval: 50
89
+ cmfm_grad_guard: true
90
+ cmfm_capture_failure: true
91
+ cmfm_dump_state_dict: true
92
+ generator_cov_use_cross: false
93
+ generator_cov_t_min: 0.1
94
+ generator_cov_t_max: 0.6
95
+ generator_cov_delta_scale: 1.0
96
+ generator_cov_num_deltas: 2
97
+ generator_cov_student_chunk_deltas: 1
98
+ generator_cov_teacher_num_deltas: 1
99
+ generator_cov_teacher_reuse_student_delta: true
100
+ generator_cov_teacher_trace_denominator: teacher
101
+ generator_cov_checkpoint: true
102
+ generator_cov_initial_trace_anchor: true
103
+ generator_cov_amplitude_anchor: md_trace
104
+ generator_cov_rollout_calibration: false
105
+ generator_cov_rollout_steps: 2
106
+ generator_cov_rollout_num_deltas: 1
107
+ generator_cov_rollout_max_examples: 4
108
+ generator_cov_rollout_interval_steps: 200
109
+ generator_cov_rollout_ema_decay: 0.9
110
+ lambda_gen_local_shape: 1.0
111
+ lambda_gen_cross_shape: 1.0
112
+ lambda_gen_trace_anchor: 0.05
113
+ per_frame_coeff_condition: true
114
+ lambda_motion: 1.0
115
+ lambda_q: 1.0
116
+ lambda_mode_orth: 1.0
117
+ lambda_pca_align: 0.0
118
+ lambda_condition_cycle: 0.0
119
+ oracle_condition: false
120
+ grad_flow_check: true
121
+ log_optimizer_coverage: true
122
+ wandb:
123
+ name: mdsubspace_20260806_220254
124
+ project: bbflow
125
+ save_dir: outputs/
126
+ tags: []
127
+ optimizer:
128
+ lr: 0.0001
129
+ reset_optimizer_on_load: false
130
+ warmup_lr: false
131
+ warmup_lr_factor: 0.01
132
+ trainer:
133
+ overfit_batches: 0
134
+ min_epochs: 1
135
+ max_epochs: 20
136
+ accelerator: gpu
137
+ precision: bf16-mixed
138
+ log_every_n_steps: 50
139
+ deterministic: false
140
+ strategy: ddp
141
+ check_val_every_n_epoch: 1
142
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260806_220254
143
+ accumulate_grad_batches: 1
144
+ max_steps: -1
145
+ profiler: null
146
+ num_sanity_val_steps: 0
147
+ checkpointer:
148
+ dirpath: ./
149
+ save_last: true
150
+ save_on_train_epoch_end: true
151
+ filename: epoch:{epoch:03d}
152
+ every_n_epochs: 2
153
+ save_top_k: -1
154
+ auto_insert_metric_name: false
155
+ checkpointer2: null
156
+ profiler:
157
+ enabled: false
158
+ modules: null
159
+ profile:
160
+ use_cuda: true
161
+ with_stack: false
162
+ stats:
163
+ group_by_stack_n: 0
164
+ group_by_input_shapes: false
165
+ prefixes:
166
+ - 'layer_0::'
167
+ - 'layer_1::'
168
+ sort_by: cpu_time_total
169
+ scheduler:
170
+ enabled: false
171
+ interpolant:
172
+ use_tqdm: true
173
+ batch_ot: intra
174
+ prior: conditional
175
+ prior_conditional:
176
+ gamma_trans: 0.2
177
+ gamma_rots: 0.2
178
+ min_t: 0.01
179
+ t_interval:
180
+ - 0.0
181
+ - 1.0
182
+ rots:
183
+ distribution: uniform
184
+ train_schedule: linear
185
+ sample_schedule: exp
186
+ exp_rate: 10
187
+ linear_scaling: 1
188
+ trans:
189
+ train_schedule: linear
190
+ sample_schedule: linear
191
+ sampling:
192
+ num_timesteps: 20
193
+ self_condition: true
194
+ noise_res_scaling_power: 0.0
195
+ noise_scale: 1.0
196
+ t_sampling_focus: 0.0
197
+ model:
198
+ node_embed_size: 240
199
+ edge_embed_size: 120
200
+ embed:
201
+ index_embed_type: full
202
+ index_embed_dim: 128
203
+ time_embed_dim: 128
204
+ embed_aatype: true
205
+ aatype_embed_dim: 128
206
+ length_embed_dim: 16
207
+ embed_self_conditioning: true
208
+ num_bins_distance: 22
209
+ min_bin_distance: 1.0e-05
210
+ max_bin_distance: 20.0
211
+ embed_distogram: true
212
+ embed_direction: false
213
+ embed_direction_cutoff: 5
214
+ edge_features:
215
+ self_condition: true
216
+ gfa:
217
+ c_s: 240
218
+ c_z: 120
219
+ c_hidden: 120
220
+ no_heads: 8
221
+ no_qk_points: 8
222
+ no_v_points: 8
223
+ seq_tfmr_num_heads: 4
224
+ seq_tfmr_num_layers: 2
225
+ num_blocks: 6
226
+ latent:
227
+ enable: true
228
+ dim: 16
229
+ num_modes: 8
230
+ motion_message_passing_layers: 4
231
+ cross_cov_near_distance: 12.0
232
+ template_residual_scale: 1.0
233
+ template_remove_rotation: true
234
+ use_enm_features: false
235
+ enm_num_modes: 8
236
+ enm_cutoff: 12.0
237
+ enm_eps: 1.0e-06
238
+ node_cond_dim: 8
239
+ edge_cond_dim: 8
240
+ freeze_foundation: false
241
+ inject_embedder: true
242
+ inject_film: true
243
+ activation_checkpoint: true
244
+ shape_fingerprint_k: 5
245
+ shape_fingerprint_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k12_kabsch_v1.pt
246
+ motion_target_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k12_kabsch_v1.pt
247
+ z_stochastic: false
248
+ collective_enable: false
249
+ collective_rank: 4
250
+ collective_hidden_dim: 128
251
+ collective_output_scale: 1.0
252
+ collective_spectrum_eps: 1.0e-06
253
+ mode_gauge_ridge: 1.0e-06
254
+ freeze_mode_head: false
255
+ track_condition_debug: false
256
+ collective_basis_from_data: false
257
+ collective_rate_weighted: true
258
+ mixture_components: 2
259
+ q_lstsq_ridge: 0.0001
260
+ q_cholesky_jitter: 0.0001
261
+ q_detach_projection: true
262
+ q_detach_shared_encoder: true
263
+ energy_from_q: false
264
+ energy_from_q_full_cov: false
265
+ sample_coefficients: true
266
+ pca_align_top_m: 2
267
+ inference:
268
+ name: gencov_ep007
269
+ seed: 123
270
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260806_220254/epoch:007.ckpt
271
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference/cmfm
272
+ use_ckpt_name_in_outpath: true
273
+ use_gpu: true
274
+ num_gpus: 1
275
+ precision: 32-true
276
+ use_tqdm: true
277
+ log_times: false
278
+ z_per_sample: true
279
+ condition_mode: real
280
+ condition_scale: 1.0
281
+ postprocess_bfactors: true
282
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
283
+ sort: false
284
+ num_proteins: null
285
+ num_workers: 2
286
+ min_length: null
287
+ max_length: null
288
+ save_traj: false
289
+ final_only: true
290
+ cache_static_features: true
291
+ single_file: true
292
+ interpolant:
293
+ use_tqdm: true
294
+ min_t: 0.0
295
+ max_t: 0.99
296
+ rots:
297
+ distribution: uniform
298
+ sample_schedule: exp
299
+ exp_rate: 10
300
+ trans:
301
+ sample_schedule: linear
302
+ sampling:
303
+ num_timesteps: 20
304
+ self_condition: true
305
+ prior: conditional
306
+ prior_conditional:
307
+ gamma_trans: 0.2
308
+ gamma_rots: 0.2
309
+ batch_ot: intra
310
+ samples:
311
+ samples_per_protein: 250
312
+ batch_size: 10
313
+ num_res_squared: 6000000
314
+ folding_cfg: null
bbflow_base/lightning_logs/version_104/hparams.yaml ADDED
@@ -0,0 +1,314 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260806_220254
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/Atlas
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 8
39
+ max_num_res_squared: 750000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /home/wangyusong/LD-FPG-main/bbflow_base/models/bbflow-0.1/bbflow-0.1.ckpt
48
+ model_only_warm_start: true
49
+ warm_start_cfg_override: false
50
+ use_swa: false
51
+ first_val_epoch: .inf
52
+ reset_epoch: false
53
+ batch_ot:
54
+ enabled: true
55
+ cost: kabsch
56
+ noise_per_sample: 1
57
+ training:
58
+ min_plddt_mask: null
59
+ loss: se3_vf_loss
60
+ bb_atom_scale: 0.1
61
+ trans_scale: 0.1
62
+ translation_loss_weight: 2.0
63
+ t_normalize_clip: 0.9
64
+ rotation_loss_weights: 1.0
65
+ aux_loss_weight: 1.0
66
+ aux_loss_t_pass: 0.75
67
+ t_bins: 4
68
+ ca_distmat_loss_weight: 0.0
69
+ ensemble_group_size: 0
70
+ force_grouped_batch: false
71
+ lambda_shape: 1.0
72
+ lambda_local_cov: 0.0
73
+ lambda_cross_cov: 0.0
74
+ lambda_rmsf: 1.0
75
+ lambda_mode_recon: 0.0
76
+ enm_warmup_epochs: 0
77
+ lambda_enm_warmup: 1.0
78
+ log_latent_batch_debug: false
79
+ full_model_activation_checkpoint: true
80
+ epoch_condition_probe: false
81
+ condition_probe_scale: 2.0
82
+ diagnostic_interval_steps: 50
83
+ lambda_generator_cov: 1.0
84
+ lambda_collective_measure: 0.0
85
+ lambda_md_subspace: 0.0
86
+ md_subspace_weight_exp: 0.0
87
+ lambda_md_subspace_trace: 0.0
88
+ cmfm_numerics_log_interval: 50
89
+ cmfm_grad_guard: true
90
+ cmfm_capture_failure: true
91
+ cmfm_dump_state_dict: true
92
+ generator_cov_use_cross: false
93
+ generator_cov_t_min: 0.1
94
+ generator_cov_t_max: 0.6
95
+ generator_cov_delta_scale: 1.0
96
+ generator_cov_num_deltas: 2
97
+ generator_cov_student_chunk_deltas: 1
98
+ generator_cov_teacher_num_deltas: 1
99
+ generator_cov_teacher_reuse_student_delta: true
100
+ generator_cov_teacher_trace_denominator: teacher
101
+ generator_cov_checkpoint: true
102
+ generator_cov_initial_trace_anchor: true
103
+ generator_cov_amplitude_anchor: md_trace
104
+ generator_cov_rollout_calibration: false
105
+ generator_cov_rollout_steps: 2
106
+ generator_cov_rollout_num_deltas: 1
107
+ generator_cov_rollout_max_examples: 4
108
+ generator_cov_rollout_interval_steps: 200
109
+ generator_cov_rollout_ema_decay: 0.9
110
+ lambda_gen_local_shape: 1.0
111
+ lambda_gen_cross_shape: 1.0
112
+ lambda_gen_trace_anchor: 0.05
113
+ per_frame_coeff_condition: true
114
+ lambda_motion: 1.0
115
+ lambda_q: 1.0
116
+ lambda_mode_orth: 1.0
117
+ lambda_pca_align: 0.0
118
+ lambda_condition_cycle: 0.0
119
+ oracle_condition: false
120
+ grad_flow_check: true
121
+ log_optimizer_coverage: true
122
+ wandb:
123
+ name: mdsubspace_20260806_220254
124
+ project: bbflow
125
+ save_dir: outputs/
126
+ tags: []
127
+ optimizer:
128
+ lr: 0.0001
129
+ reset_optimizer_on_load: false
130
+ warmup_lr: false
131
+ warmup_lr_factor: 0.01
132
+ trainer:
133
+ overfit_batches: 0
134
+ min_epochs: 1
135
+ max_epochs: 20
136
+ accelerator: gpu
137
+ precision: bf16-mixed
138
+ log_every_n_steps: 50
139
+ deterministic: false
140
+ strategy: ddp
141
+ check_val_every_n_epoch: 1
142
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260806_220254
143
+ accumulate_grad_batches: 1
144
+ max_steps: -1
145
+ profiler: null
146
+ num_sanity_val_steps: 0
147
+ checkpointer:
148
+ dirpath: ./
149
+ save_last: true
150
+ save_on_train_epoch_end: true
151
+ filename: epoch:{epoch:03d}
152
+ every_n_epochs: 2
153
+ save_top_k: -1
154
+ auto_insert_metric_name: false
155
+ checkpointer2: null
156
+ profiler:
157
+ enabled: false
158
+ modules: null
159
+ profile:
160
+ use_cuda: true
161
+ with_stack: false
162
+ stats:
163
+ group_by_stack_n: 0
164
+ group_by_input_shapes: false
165
+ prefixes:
166
+ - 'layer_0::'
167
+ - 'layer_1::'
168
+ sort_by: cpu_time_total
169
+ scheduler:
170
+ enabled: false
171
+ interpolant:
172
+ use_tqdm: true
173
+ batch_ot: intra
174
+ prior: conditional
175
+ prior_conditional:
176
+ gamma_trans: 0.2
177
+ gamma_rots: 0.2
178
+ min_t: 0.01
179
+ t_interval:
180
+ - 0.0
181
+ - 1.0
182
+ rots:
183
+ distribution: uniform
184
+ train_schedule: linear
185
+ sample_schedule: exp
186
+ exp_rate: 10
187
+ linear_scaling: 1
188
+ trans:
189
+ train_schedule: linear
190
+ sample_schedule: linear
191
+ sampling:
192
+ num_timesteps: 20
193
+ self_condition: true
194
+ noise_res_scaling_power: 0.0
195
+ noise_scale: 1.0
196
+ t_sampling_focus: 0.0
197
+ model:
198
+ node_embed_size: 240
199
+ edge_embed_size: 120
200
+ embed:
201
+ index_embed_type: full
202
+ index_embed_dim: 128
203
+ time_embed_dim: 128
204
+ embed_aatype: true
205
+ aatype_embed_dim: 128
206
+ length_embed_dim: 16
207
+ embed_self_conditioning: true
208
+ num_bins_distance: 22
209
+ min_bin_distance: 1.0e-05
210
+ max_bin_distance: 20.0
211
+ embed_distogram: true
212
+ embed_direction: false
213
+ embed_direction_cutoff: 5
214
+ edge_features:
215
+ self_condition: true
216
+ gfa:
217
+ c_s: 240
218
+ c_z: 120
219
+ c_hidden: 120
220
+ no_heads: 8
221
+ no_qk_points: 8
222
+ no_v_points: 8
223
+ seq_tfmr_num_heads: 4
224
+ seq_tfmr_num_layers: 2
225
+ num_blocks: 6
226
+ latent:
227
+ enable: true
228
+ dim: 16
229
+ num_modes: 8
230
+ motion_message_passing_layers: 4
231
+ cross_cov_near_distance: 12.0
232
+ template_residual_scale: 1.0
233
+ template_remove_rotation: true
234
+ use_enm_features: false
235
+ enm_num_modes: 8
236
+ enm_cutoff: 12.0
237
+ enm_eps: 1.0e-06
238
+ node_cond_dim: 8
239
+ edge_cond_dim: 8
240
+ freeze_foundation: false
241
+ inject_embedder: true
242
+ inject_film: true
243
+ activation_checkpoint: true
244
+ shape_fingerprint_k: 5
245
+ shape_fingerprint_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k12_kabsch_v1.pt
246
+ motion_target_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k12_kabsch_v1.pt
247
+ z_stochastic: false
248
+ collective_enable: false
249
+ collective_rank: 4
250
+ collective_hidden_dim: 128
251
+ collective_output_scale: 1.0
252
+ collective_spectrum_eps: 1.0e-06
253
+ mode_gauge_ridge: 1.0e-06
254
+ freeze_mode_head: false
255
+ track_condition_debug: false
256
+ collective_basis_from_data: false
257
+ collective_rate_weighted: true
258
+ mixture_components: 2
259
+ q_lstsq_ridge: 0.0001
260
+ q_cholesky_jitter: 0.0001
261
+ q_detach_projection: true
262
+ q_detach_shared_encoder: true
263
+ energy_from_q: false
264
+ energy_from_q_full_cov: false
265
+ sample_coefficients: true
266
+ pca_align_top_m: 2
267
+ inference:
268
+ name: gencov_ep003
269
+ seed: 123
270
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260806_220254/epoch:003.ckpt
271
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference/cmfm
272
+ use_ckpt_name_in_outpath: true
273
+ use_gpu: true
274
+ num_gpus: 1
275
+ precision: 32-true
276
+ use_tqdm: true
277
+ log_times: false
278
+ z_per_sample: true
279
+ condition_mode: real
280
+ condition_scale: 1.0
281
+ postprocess_bfactors: true
282
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
283
+ sort: false
284
+ num_proteins: null
285
+ num_workers: 2
286
+ min_length: null
287
+ max_length: null
288
+ save_traj: false
289
+ final_only: true
290
+ cache_static_features: true
291
+ single_file: true
292
+ interpolant:
293
+ use_tqdm: true
294
+ min_t: 0.0
295
+ max_t: 0.99
296
+ rots:
297
+ distribution: uniform
298
+ sample_schedule: exp
299
+ exp_rate: 10
300
+ trans:
301
+ sample_schedule: linear
302
+ sampling:
303
+ num_timesteps: 20
304
+ self_condition: true
305
+ prior: conditional
306
+ prior_conditional:
307
+ gamma_trans: 0.2
308
+ gamma_rots: 0.2
309
+ batch_ot: intra
310
+ samples:
311
+ samples_per_protein: 250
312
+ batch_size: 10
313
+ num_res_squared: 6000000
314
+ folding_cfg: null
bbflow_base/lightning_logs/version_12/hparams.yaml ADDED
@@ -0,0 +1,266 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_pca_align_orth1_recon0_30ep_3gpu_20260704_055826
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/datasets/ATLAS
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 32
39
+ max_num_res_squared: 400000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /home/wangyusong/LD-FPG-main/bbflow/models/bbflow-0.1/bbflow-0.1.ckpt
48
+ warm_start_cfg_override: false
49
+ use_swa: false
50
+ first_val_epoch: .inf
51
+ reset_epoch: false
52
+ batch_ot:
53
+ enabled: true
54
+ cost: kabsch
55
+ noise_per_sample: 1
56
+ training:
57
+ min_plddt_mask: null
58
+ loss: se3_vf_loss
59
+ bb_atom_scale: 0.1
60
+ trans_scale: 0.1
61
+ translation_loss_weight: 2.0
62
+ t_normalize_clip: 0.9
63
+ rotation_loss_weights: 1.0
64
+ aux_loss_weight: 1.0
65
+ aux_loss_t_pass: 0.75
66
+ t_bins: 4
67
+ ca_distmat_loss_weight: 0.0
68
+ ensemble_group_size: 0
69
+ force_grouped_batch: false
70
+ lambda_shape: 1.0
71
+ lambda_local_cov: 1.0
72
+ lambda_cross_cov: 1.0
73
+ lambda_rmsf: 0.25
74
+ lambda_mode_recon: 0
75
+ enm_warmup_epochs: 0
76
+ lambda_enm_warmup: 1.0
77
+ log_latent_batch_debug: false
78
+ epoch_condition_probe: false
79
+ condition_probe_scale: 2.0
80
+ diagnostic_interval_steps: 50
81
+ per_frame_coeff_condition: true
82
+ lambda_motion: 1.0
83
+ lambda_q: 1.0
84
+ lambda_mode_orth: 1
85
+ lambda_pca_align: 0.1
86
+ oracle_condition: false
87
+ grad_flow_check: true
88
+ log_optimizer_coverage: true
89
+ wandb:
90
+ name: bbflow_base_pca_align_orth1_recon0_30ep_3gpu_20260704_055826
91
+ project: bbflow
92
+ save_dir: outputs/
93
+ tags: []
94
+ optimizer:
95
+ lr: 0.0001
96
+ reset_optimizer_on_load: false
97
+ warmup_lr: false
98
+ warmup_lr_factor: 0.01
99
+ trainer:
100
+ overfit_batches: 0
101
+ min_epochs: 1
102
+ max_epochs: 30
103
+ accelerator: gpu
104
+ precision: 32-true
105
+ log_every_n_steps: 50
106
+ deterministic: false
107
+ strategy: ddp
108
+ check_val_every_n_epoch: 1
109
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_pca_align_orth1_recon0_30ep_3gpu_20260704_055826
110
+ accumulate_grad_batches: 1
111
+ max_steps: -1
112
+ profiler: null
113
+ num_sanity_val_steps: 0
114
+ checkpointer:
115
+ dirpath: ./
116
+ save_last: true
117
+ save_on_train_epoch_end: true
118
+ filename: epoch:{epoch:03d}
119
+ every_n_epochs: 1
120
+ save_top_k: -1
121
+ auto_insert_metric_name: false
122
+ checkpointer2: null
123
+ profiler:
124
+ enabled: false
125
+ modules: null
126
+ profile:
127
+ use_cuda: true
128
+ with_stack: false
129
+ stats:
130
+ group_by_stack_n: 0
131
+ group_by_input_shapes: false
132
+ prefixes:
133
+ - 'layer_0::'
134
+ - 'layer_1::'
135
+ sort_by: cpu_time_total
136
+ scheduler:
137
+ enabled: false
138
+ interpolant:
139
+ use_tqdm: true
140
+ batch_ot: intra
141
+ prior: conditional
142
+ prior_conditional:
143
+ gamma_trans: 0.2
144
+ gamma_rots: 0.2
145
+ min_t: 0.01
146
+ t_interval:
147
+ - 0.0
148
+ - 1.0
149
+ rots:
150
+ distribution: uniform
151
+ train_schedule: linear
152
+ sample_schedule: exp
153
+ exp_rate: 10
154
+ linear_scaling: 1
155
+ trans:
156
+ train_schedule: linear
157
+ sample_schedule: linear
158
+ sampling:
159
+ num_timesteps: 20
160
+ self_condition: true
161
+ noise_res_scaling_power: 0.0
162
+ noise_scale: 1.0
163
+ t_sampling_focus: 0.0
164
+ model:
165
+ node_embed_size: 240
166
+ edge_embed_size: 120
167
+ embed:
168
+ index_embed_type: full
169
+ index_embed_dim: 128
170
+ time_embed_dim: 128
171
+ embed_aatype: true
172
+ aatype_embed_dim: 128
173
+ length_embed_dim: 16
174
+ embed_self_conditioning: true
175
+ num_bins_distance: 22
176
+ min_bin_distance: 1.0e-05
177
+ max_bin_distance: 20.0
178
+ embed_distogram: true
179
+ embed_direction: false
180
+ embed_direction_cutoff: 5
181
+ edge_features:
182
+ self_condition: true
183
+ gfa:
184
+ c_s: 240
185
+ c_z: 120
186
+ c_hidden: 120
187
+ no_heads: 8
188
+ no_qk_points: 8
189
+ no_v_points: 8
190
+ seq_tfmr_num_heads: 4
191
+ seq_tfmr_num_layers: 2
192
+ num_blocks: 6
193
+ latent:
194
+ enable: true
195
+ dim: 16
196
+ num_modes: 8
197
+ motion_message_passing_layers: 4
198
+ cross_cov_near_distance: 12.0
199
+ template_residual_scale: 0.1
200
+ template_remove_rotation: true
201
+ use_enm_features: false
202
+ enm_num_modes: 8
203
+ enm_cutoff: 12.0
204
+ enm_eps: 1.0e-06
205
+ node_cond_dim: 8
206
+ edge_cond_dim: 8
207
+ freeze_foundation: false
208
+ inject_embedder: true
209
+ inject_film: true
210
+ activation_checkpoint: true
211
+ shape_fingerprint_k: 5
212
+ shape_fingerprint_cache_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1_oracle.pt
213
+ motion_target_cache_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1_oracle.pt
214
+ z_stochastic: false
215
+ track_condition_debug: false
216
+ mixture_components: 2
217
+ q_lstsq_ridge: 0.0001
218
+ q_cholesky_jitter: 0.0001
219
+ q_detach_projection: true
220
+ q_detach_shared_encoder: false
221
+ sample_coefficients: true
222
+ pca_align_top_m: 2
223
+ inference:
224
+ name: atlas_test_250_real
225
+ seed: 123
226
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_pca_align_orth1_recon0_30ep_3gpu_20260704_055826/last.ckpt
227
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_pca_align_orth1_recon0_30ep_3gpu_20260704_055826/standard_downstream_real_250/inference
228
+ use_ckpt_name_in_outpath: true
229
+ use_gpu: true
230
+ num_gpus: 1
231
+ use_tqdm: true
232
+ log_times: true
233
+ z_per_sample: false
234
+ condition_mode: real
235
+ condition_scale: 1.0
236
+ postprocess_bfactors: false
237
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
238
+ sort: false
239
+ num_proteins: null
240
+ min_length: null
241
+ max_length: null
242
+ save_traj: false
243
+ single_file: true
244
+ interpolant:
245
+ use_tqdm: true
246
+ min_t: 0.0
247
+ max_t: 0.99
248
+ rots:
249
+ distribution: uniform
250
+ sample_schedule: exp
251
+ exp_rate: 10
252
+ trans:
253
+ sample_schedule: linear
254
+ sampling:
255
+ num_timesteps: 20
256
+ self_condition: true
257
+ prior: conditional
258
+ prior_conditional:
259
+ gamma_trans: 0.2
260
+ gamma_rots: 0.2
261
+ batch_ot: intra
262
+ samples:
263
+ samples_per_protein: 250
264
+ batch_size: 20
265
+ num_res_squared: 400000
266
+ folding_cfg: null
bbflow_base/lightning_logs/version_13/hparams.yaml ADDED
@@ -0,0 +1,267 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_pca_align_orth1_recon0_30ep_3gpu_20260704_055826
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/datasets/ATLAS
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 32
39
+ max_num_res_squared: 400000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /home/wangyusong/LD-FPG-main/bbflow/models/bbflow-0.1/bbflow-0.1.ckpt
48
+ warm_start_cfg_override: false
49
+ use_swa: false
50
+ first_val_epoch: .inf
51
+ reset_epoch: false
52
+ batch_ot:
53
+ enabled: true
54
+ cost: kabsch
55
+ noise_per_sample: 1
56
+ training:
57
+ min_plddt_mask: null
58
+ loss: se3_vf_loss
59
+ bb_atom_scale: 0.1
60
+ trans_scale: 0.1
61
+ translation_loss_weight: 2.0
62
+ t_normalize_clip: 0.9
63
+ rotation_loss_weights: 1.0
64
+ aux_loss_weight: 1.0
65
+ aux_loss_t_pass: 0.75
66
+ t_bins: 4
67
+ ca_distmat_loss_weight: 0.0
68
+ ensemble_group_size: 0
69
+ force_grouped_batch: false
70
+ lambda_shape: 1.0
71
+ lambda_local_cov: 1.0
72
+ lambda_cross_cov: 1.0
73
+ lambda_rmsf: 0.25
74
+ lambda_mode_recon: 0
75
+ enm_warmup_epochs: 0
76
+ lambda_enm_warmup: 1.0
77
+ log_latent_batch_debug: false
78
+ epoch_condition_probe: false
79
+ condition_probe_scale: 2.0
80
+ diagnostic_interval_steps: 50
81
+ per_frame_coeff_condition: true
82
+ lambda_motion: 1.0
83
+ lambda_q: 1.0
84
+ lambda_mode_orth: 1
85
+ lambda_pca_align: 0.1
86
+ oracle_condition: false
87
+ grad_flow_check: true
88
+ log_optimizer_coverage: true
89
+ wandb:
90
+ name: bbflow_base_pca_align_orth1_recon0_30ep_3gpu_20260704_055826
91
+ project: bbflow
92
+ save_dir: outputs/
93
+ tags: []
94
+ optimizer:
95
+ lr: 0.0001
96
+ reset_optimizer_on_load: false
97
+ warmup_lr: false
98
+ warmup_lr_factor: 0.01
99
+ trainer:
100
+ overfit_batches: 0
101
+ min_epochs: 1
102
+ max_epochs: 30
103
+ accelerator: gpu
104
+ precision: 32-true
105
+ log_every_n_steps: 50
106
+ deterministic: false
107
+ strategy: ddp
108
+ check_val_every_n_epoch: 1
109
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_pca_align_orth1_recon0_30ep_3gpu_20260704_055826
110
+ accumulate_grad_batches: 1
111
+ max_steps: -1
112
+ profiler: null
113
+ num_sanity_val_steps: 0
114
+ checkpointer:
115
+ dirpath: ./
116
+ save_last: true
117
+ save_on_train_epoch_end: true
118
+ filename: epoch:{epoch:03d}
119
+ every_n_epochs: 1
120
+ save_top_k: -1
121
+ auto_insert_metric_name: false
122
+ checkpointer2: null
123
+ profiler:
124
+ enabled: false
125
+ modules: null
126
+ profile:
127
+ use_cuda: true
128
+ with_stack: false
129
+ stats:
130
+ group_by_stack_n: 0
131
+ group_by_input_shapes: false
132
+ prefixes:
133
+ - 'layer_0::'
134
+ - 'layer_1::'
135
+ sort_by: cpu_time_total
136
+ scheduler:
137
+ enabled: false
138
+ interpolant:
139
+ use_tqdm: true
140
+ batch_ot: intra
141
+ prior: conditional
142
+ prior_conditional:
143
+ gamma_trans: 0.2
144
+ gamma_rots: 0.2
145
+ min_t: 0.01
146
+ t_interval:
147
+ - 0.0
148
+ - 1.0
149
+ rots:
150
+ distribution: uniform
151
+ train_schedule: linear
152
+ sample_schedule: exp
153
+ exp_rate: 10
154
+ linear_scaling: 1
155
+ trans:
156
+ train_schedule: linear
157
+ sample_schedule: linear
158
+ sampling:
159
+ num_timesteps: 20
160
+ self_condition: true
161
+ noise_res_scaling_power: 0.0
162
+ noise_scale: 1.0
163
+ t_sampling_focus: 0.0
164
+ model:
165
+ node_embed_size: 240
166
+ edge_embed_size: 120
167
+ embed:
168
+ index_embed_type: full
169
+ index_embed_dim: 128
170
+ time_embed_dim: 128
171
+ embed_aatype: true
172
+ aatype_embed_dim: 128
173
+ length_embed_dim: 16
174
+ embed_self_conditioning: true
175
+ num_bins_distance: 22
176
+ min_bin_distance: 1.0e-05
177
+ max_bin_distance: 20.0
178
+ embed_distogram: true
179
+ embed_direction: false
180
+ embed_direction_cutoff: 5
181
+ edge_features:
182
+ self_condition: true
183
+ gfa:
184
+ c_s: 240
185
+ c_z: 120
186
+ c_hidden: 120
187
+ no_heads: 8
188
+ no_qk_points: 8
189
+ no_v_points: 8
190
+ seq_tfmr_num_heads: 4
191
+ seq_tfmr_num_layers: 2
192
+ num_blocks: 6
193
+ latent:
194
+ enable: true
195
+ dim: 16
196
+ num_modes: 8
197
+ motion_message_passing_layers: 4
198
+ cross_cov_near_distance: 12.0
199
+ template_residual_scale: 0.1
200
+ template_remove_rotation: true
201
+ use_enm_features: false
202
+ enm_num_modes: 8
203
+ enm_cutoff: 12.0
204
+ enm_eps: 1.0e-06
205
+ node_cond_dim: 8
206
+ edge_cond_dim: 8
207
+ freeze_foundation: false
208
+ inject_embedder: true
209
+ inject_film: true
210
+ activation_checkpoint: true
211
+ shape_fingerprint_k: 5
212
+ shape_fingerprint_cache_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1_oracle.pt
213
+ motion_target_cache_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1_oracle.pt
214
+ z_stochastic: false
215
+ track_condition_debug: false
216
+ mixture_components: 2
217
+ q_lstsq_ridge: 0.0001
218
+ q_cholesky_jitter: 0.0001
219
+ q_detach_projection: true
220
+ q_detach_shared_encoder: false
221
+ sample_coefficients: true
222
+ pca_align_top_m: 2
223
+ inference:
224
+ name: atlas_test_250_real_scale05
225
+ seed: 123
226
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_pca_align_orth1_recon0_30ep_3gpu_20260704_055826/last.ckpt
227
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_pca_align_orth1_recon0_30ep_3gpu_20260704_055826/standard_downstream_scale05_250/inference
228
+ use_ckpt_name_in_outpath: true
229
+ use_gpu: true
230
+ num_gpus: 1
231
+ use_tqdm: true
232
+ log_times: true
233
+ z_per_sample: false
234
+ condition_mode: real
235
+ condition_scale: 0.5
236
+ postprocess_bfactors: false
237
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
238
+ sort: false
239
+ num_proteins: null
240
+ num_workers: 1
241
+ min_length: null
242
+ max_length: null
243
+ save_traj: false
244
+ single_file: true
245
+ interpolant:
246
+ use_tqdm: true
247
+ min_t: 0.0
248
+ max_t: 0.99
249
+ rots:
250
+ distribution: uniform
251
+ sample_schedule: exp
252
+ exp_rate: 10
253
+ trans:
254
+ sample_schedule: linear
255
+ sampling:
256
+ num_timesteps: 20
257
+ self_condition: true
258
+ prior: conditional
259
+ prior_conditional:
260
+ gamma_trans: 0.2
261
+ gamma_rots: 0.2
262
+ batch_ot: intra
263
+ samples:
264
+ samples_per_protein: 250
265
+ batch_size: 20
266
+ num_res_squared: 400000
267
+ folding_cfg: null
bbflow_base/lightning_logs/version_2/hparams.yaml ADDED
@@ -0,0 +1,256 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_k8_recon1_5ep_gpu2
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/datasets/ATLAS
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ sampler:
37
+ max_batch_size: 32
38
+ max_num_res_squared: 400000
39
+ max_conformations: 20
40
+ experiment:
41
+ debug: false
42
+ use_wandb: false
43
+ use_tqdm: true
44
+ seed: 123
45
+ num_devices: 1
46
+ warm_start: /home/wangyusong/LD-FPG-main/bbflow/models/bbflow-0.1/bbflow-0.1.ckpt
47
+ warm_start_cfg_override: false
48
+ use_swa: false
49
+ first_val_epoch: .inf
50
+ reset_epoch: false
51
+ batch_ot:
52
+ enabled: true
53
+ cost: kabsch
54
+ noise_per_sample: 1
55
+ training:
56
+ min_plddt_mask: null
57
+ loss: se3_vf_loss
58
+ bb_atom_scale: 0.1
59
+ trans_scale: 0.1
60
+ translation_loss_weight: 2.0
61
+ t_normalize_clip: 0.9
62
+ rotation_loss_weights: 1.0
63
+ aux_loss_weight: 1.0
64
+ aux_loss_t_pass: 0.75
65
+ t_bins: 4
66
+ ca_distmat_loss_weight: 0.0
67
+ ensemble_group_size: 0
68
+ force_grouped_batch: false
69
+ lambda_shape: 1.0
70
+ lambda_local_cov: 1.0
71
+ lambda_cross_cov: 1.0
72
+ lambda_rmsf: 0.25
73
+ lambda_mode_recon: 1.0
74
+ enm_warmup_epochs: 0
75
+ lambda_enm_warmup: 1.0
76
+ log_latent_batch_debug: false
77
+ epoch_condition_probe: true
78
+ condition_probe_scale: 2.0
79
+ per_frame_coeff_condition: true
80
+ lambda_motion: 1.0
81
+ lambda_q: 1.0
82
+ lambda_mode_orth: 1.0
83
+ oracle_condition: false
84
+ grad_flow_check: true
85
+ log_optimizer_coverage: true
86
+ wandb:
87
+ name: bbflow_base_k8_recon1_5ep_gpu2
88
+ project: bbflow
89
+ save_dir: outputs/
90
+ tags: []
91
+ optimizer:
92
+ lr: 0.0001
93
+ reset_optimizer_on_load: false
94
+ warmup_lr: false
95
+ warmup_lr_factor: 0.01
96
+ trainer:
97
+ overfit_batches: 0
98
+ min_epochs: 1
99
+ max_epochs: 5
100
+ accelerator: gpu
101
+ precision: 32-true
102
+ log_every_n_steps: 1
103
+ deterministic: false
104
+ strategy: ddp
105
+ check_val_every_n_epoch: 1
106
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_k8_recon1_5ep_gpu2
107
+ accumulate_grad_batches: 1
108
+ num_sanity_val_steps: 0
109
+ checkpointer:
110
+ dirpath: ./
111
+ save_last: true
112
+ save_on_train_epoch_end: true
113
+ filename: epoch:{epoch:03d}
114
+ every_n_epochs: 1
115
+ save_top_k: -1
116
+ auto_insert_metric_name: false
117
+ checkpointer2: null
118
+ profiler:
119
+ enabled: false
120
+ modules: null
121
+ profile:
122
+ use_cuda: true
123
+ with_stack: false
124
+ stats:
125
+ group_by_stack_n: 0
126
+ group_by_input_shapes: false
127
+ prefixes:
128
+ - 'layer_0::'
129
+ - 'layer_1::'
130
+ sort_by: cpu_time_total
131
+ scheduler:
132
+ enabled: false
133
+ interpolant:
134
+ use_tqdm: true
135
+ batch_ot: intra
136
+ prior: conditional
137
+ prior_conditional:
138
+ gamma_trans: 0.2
139
+ gamma_rots: 0.2
140
+ min_t: 0.01
141
+ t_interval:
142
+ - 0.0
143
+ - 1.0
144
+ rots:
145
+ distribution: uniform
146
+ train_schedule: linear
147
+ sample_schedule: exp
148
+ exp_rate: 10
149
+ linear_scaling: 1
150
+ trans:
151
+ train_schedule: linear
152
+ sample_schedule: linear
153
+ sampling:
154
+ num_timesteps: 20
155
+ self_condition: true
156
+ noise_res_scaling_power: 0.0
157
+ noise_scale: 1.0
158
+ t_sampling_focus: 0.0
159
+ model:
160
+ node_embed_size: 240
161
+ edge_embed_size: 120
162
+ embed:
163
+ index_embed_type: full
164
+ index_embed_dim: 128
165
+ time_embed_dim: 128
166
+ embed_aatype: true
167
+ aatype_embed_dim: 128
168
+ length_embed_dim: 16
169
+ embed_self_conditioning: true
170
+ num_bins_distance: 22
171
+ min_bin_distance: 1.0e-05
172
+ max_bin_distance: 20.0
173
+ embed_distogram: true
174
+ embed_direction: false
175
+ embed_direction_cutoff: 5
176
+ edge_features:
177
+ self_condition: true
178
+ gfa:
179
+ c_s: 240
180
+ c_z: 120
181
+ c_hidden: 120
182
+ no_heads: 8
183
+ no_qk_points: 8
184
+ no_v_points: 8
185
+ seq_tfmr_num_heads: 4
186
+ seq_tfmr_num_layers: 2
187
+ num_blocks: 6
188
+ latent:
189
+ enable: true
190
+ dim: 16
191
+ num_modes: 8
192
+ motion_message_passing_layers: 4
193
+ cross_cov_near_distance: 12.0
194
+ template_residual_scale: 0.1
195
+ template_remove_rotation: true
196
+ use_enm_features: false
197
+ enm_num_modes: 8
198
+ enm_cutoff: 12.0
199
+ enm_eps: 1.0e-06
200
+ node_cond_dim: 8
201
+ edge_cond_dim: 8
202
+ freeze_foundation: false
203
+ inject_embedder: true
204
+ inject_film: true
205
+ activation_checkpoint: true
206
+ shape_fingerprint_k: 5
207
+ shape_fingerprint_cache_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
208
+ motion_target_cache_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
209
+ z_stochastic: false
210
+ mixture_components: 2
211
+ q_lstsq_ridge: 0.0001
212
+ q_cholesky_jitter: 0.0001
213
+ q_detach_projection: true
214
+ q_detach_shared_encoder: true
215
+ sample_coefficients: true
216
+ inference:
217
+ name: atlas_test_250
218
+ seed: 123
219
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_k8_recon1_5ep_gpu2/last.ckpt
220
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/full_downstream_20p_250_20260628_203018/recon1/official
221
+ use_ckpt_name_in_outpath: false
222
+ use_gpu: true
223
+ num_gpus: 1
224
+ use_tqdm: true
225
+ log_times: true
226
+ z_per_sample: false
227
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/full_downstream_20p_250_20260628_203018/ATLAS_test_first20.csv
228
+ sort: false
229
+ num_proteins: null
230
+ min_length: null
231
+ max_length: null
232
+ save_traj: false
233
+ single_file: true
234
+ interpolant:
235
+ use_tqdm: true
236
+ min_t: 0.0
237
+ max_t: 0.99
238
+ rots:
239
+ distribution: uniform
240
+ sample_schedule: exp
241
+ exp_rate: 10
242
+ trans:
243
+ sample_schedule: linear
244
+ sampling:
245
+ num_timesteps: 20
246
+ self_condition: true
247
+ prior: conditional
248
+ prior_conditional:
249
+ gamma_trans: 0.2
250
+ gamma_rots: 0.2
251
+ batch_ot: intra
252
+ samples:
253
+ samples_per_protein: 250
254
+ batch_size: 10
255
+ num_res_squared: 2900000
256
+ folding_cfg: null
bbflow_base/lightning_logs/version_22/hparams.yaml ADDED
@@ -0,0 +1,269 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_energy_from_q_diag_orth1_recon0_30ep_3gpu_20260707_165355
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/datasets/ATLAS
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 32
39
+ max_num_res_squared: 400000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /home/wangyusong/LD-FPG-main/bbflow/models/bbflow-0.1/bbflow-0.1.ckpt
48
+ warm_start_cfg_override: false
49
+ use_swa: false
50
+ first_val_epoch: .inf
51
+ reset_epoch: false
52
+ batch_ot:
53
+ enabled: true
54
+ cost: kabsch
55
+ noise_per_sample: 1
56
+ training:
57
+ min_plddt_mask: null
58
+ loss: se3_vf_loss
59
+ bb_atom_scale: 0.1
60
+ trans_scale: 0.1
61
+ translation_loss_weight: 2.0
62
+ t_normalize_clip: 0.9
63
+ rotation_loss_weights: 1.0
64
+ aux_loss_weight: 1.0
65
+ aux_loss_t_pass: 0.75
66
+ t_bins: 4
67
+ ca_distmat_loss_weight: 0.0
68
+ ensemble_group_size: 0
69
+ force_grouped_batch: false
70
+ lambda_shape: 1.0
71
+ lambda_local_cov: 1.0
72
+ lambda_cross_cov: 1.0
73
+ lambda_rmsf: 0.25
74
+ lambda_mode_recon: 0.0
75
+ enm_warmup_epochs: 0
76
+ lambda_enm_warmup: 1.0
77
+ log_latent_batch_debug: false
78
+ epoch_condition_probe: false
79
+ condition_probe_scale: 2.0
80
+ diagnostic_interval_steps: 50
81
+ per_frame_coeff_condition: true
82
+ lambda_motion: 1.0
83
+ lambda_q: 1.0
84
+ lambda_mode_orth: 1.0
85
+ lambda_pca_align: 0.0
86
+ oracle_condition: false
87
+ grad_flow_check: true
88
+ log_optimizer_coverage: true
89
+ wandb:
90
+ name: bbflow_base_energy_from_q_diag_orth1_recon0_30ep_3gpu_20260707_165355
91
+ project: bbflow
92
+ save_dir: outputs/
93
+ tags: []
94
+ optimizer:
95
+ lr: 0.0001
96
+ reset_optimizer_on_load: false
97
+ warmup_lr: false
98
+ warmup_lr_factor: 0.01
99
+ trainer:
100
+ overfit_batches: 0
101
+ min_epochs: 1
102
+ max_epochs: 30
103
+ accelerator: gpu
104
+ precision: 32-true
105
+ log_every_n_steps: 50
106
+ deterministic: false
107
+ strategy: ddp
108
+ check_val_every_n_epoch: 1
109
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_energy_from_q_diag_orth1_recon0_30ep_3gpu_20260707_165355
110
+ accumulate_grad_batches: 1
111
+ max_steps: -1
112
+ profiler: null
113
+ num_sanity_val_steps: 0
114
+ checkpointer:
115
+ dirpath: ./
116
+ save_last: true
117
+ save_on_train_epoch_end: true
118
+ filename: epoch:{epoch:03d}
119
+ every_n_epochs: 1
120
+ save_top_k: -1
121
+ auto_insert_metric_name: false
122
+ checkpointer2: null
123
+ profiler:
124
+ enabled: false
125
+ modules: null
126
+ profile:
127
+ use_cuda: true
128
+ with_stack: false
129
+ stats:
130
+ group_by_stack_n: 0
131
+ group_by_input_shapes: false
132
+ prefixes:
133
+ - 'layer_0::'
134
+ - 'layer_1::'
135
+ sort_by: cpu_time_total
136
+ scheduler:
137
+ enabled: false
138
+ interpolant:
139
+ use_tqdm: true
140
+ batch_ot: intra
141
+ prior: conditional
142
+ prior_conditional:
143
+ gamma_trans: 0.2
144
+ gamma_rots: 0.2
145
+ min_t: 0.01
146
+ t_interval:
147
+ - 0.0
148
+ - 1.0
149
+ rots:
150
+ distribution: uniform
151
+ train_schedule: linear
152
+ sample_schedule: exp
153
+ exp_rate: 10
154
+ linear_scaling: 1
155
+ trans:
156
+ train_schedule: linear
157
+ sample_schedule: linear
158
+ sampling:
159
+ num_timesteps: 20
160
+ self_condition: true
161
+ noise_res_scaling_power: 0.0
162
+ noise_scale: 1.0
163
+ t_sampling_focus: 0.0
164
+ model:
165
+ node_embed_size: 240
166
+ edge_embed_size: 120
167
+ embed:
168
+ index_embed_type: full
169
+ index_embed_dim: 128
170
+ time_embed_dim: 128
171
+ embed_aatype: true
172
+ aatype_embed_dim: 128
173
+ length_embed_dim: 16
174
+ embed_self_conditioning: true
175
+ num_bins_distance: 22
176
+ min_bin_distance: 1.0e-05
177
+ max_bin_distance: 20.0
178
+ embed_distogram: true
179
+ embed_direction: false
180
+ embed_direction_cutoff: 5
181
+ edge_features:
182
+ self_condition: true
183
+ gfa:
184
+ c_s: 240
185
+ c_z: 120
186
+ c_hidden: 120
187
+ no_heads: 8
188
+ no_qk_points: 8
189
+ no_v_points: 8
190
+ seq_tfmr_num_heads: 4
191
+ seq_tfmr_num_layers: 2
192
+ num_blocks: 6
193
+ latent:
194
+ enable: true
195
+ dim: 16
196
+ num_modes: 8
197
+ motion_message_passing_layers: 4
198
+ cross_cov_near_distance: 12.0
199
+ template_residual_scale: 0.1
200
+ template_remove_rotation: true
201
+ use_enm_features: false
202
+ enm_num_modes: 8
203
+ enm_cutoff: 12.0
204
+ enm_eps: 1.0e-06
205
+ node_cond_dim: 8
206
+ edge_cond_dim: 8
207
+ freeze_foundation: false
208
+ inject_embedder: true
209
+ inject_film: true
210
+ activation_checkpoint: true
211
+ shape_fingerprint_k: 5
212
+ shape_fingerprint_cache_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
213
+ motion_target_cache_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
214
+ z_stochastic: false
215
+ track_condition_debug: false
216
+ mixture_components: 2
217
+ q_lstsq_ridge: 0.0001
218
+ q_cholesky_jitter: 0.0001
219
+ q_detach_projection: true
220
+ q_detach_shared_encoder: false
221
+ energy_from_q: true
222
+ energy_from_q_full_cov: false
223
+ sample_coefficients: true
224
+ pca_align_top_m: 2
225
+ inference:
226
+ name: atlas_test_250_real
227
+ seed: 123
228
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_energy_from_q_diag_orth1_recon0_30ep_3gpu_20260707_165355/last.ckpt
229
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference
230
+ use_ckpt_name_in_outpath: true
231
+ use_gpu: true
232
+ num_gpus: 1
233
+ use_tqdm: true
234
+ log_times: true
235
+ z_per_sample: false
236
+ condition_mode: real
237
+ condition_scale: 1.0
238
+ postprocess_bfactors: false
239
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
240
+ sort: false
241
+ num_proteins: null
242
+ num_workers: 0
243
+ min_length: null
244
+ max_length: null
245
+ save_traj: false
246
+ single_file: true
247
+ interpolant:
248
+ use_tqdm: true
249
+ min_t: 0.0
250
+ max_t: 0.99
251
+ rots:
252
+ distribution: uniform
253
+ sample_schedule: exp
254
+ exp_rate: 10
255
+ trans:
256
+ sample_schedule: linear
257
+ sampling:
258
+ num_timesteps: 20
259
+ self_condition: true
260
+ prior: conditional
261
+ prior_conditional:
262
+ gamma_trans: 0.2
263
+ gamma_rots: 0.2
264
+ batch_ot: intra
265
+ samples:
266
+ samples_per_protein: 250
267
+ batch_size: 20
268
+ num_res_squared: 4000000
269
+ folding_cfg: null
bbflow_base/lightning_logs/version_25/hparams.yaml ADDED
@@ -0,0 +1,269 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_energy_from_q_fullcov_orth1_recon0_30ep_2gpu_20260708_052300
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/datasets/ATLAS
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 32
39
+ max_num_res_squared: 400000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_energy_from_q_fullcov_orth1_recon0_30ep_2gpu_20260708_052300/last.ckpt
48
+ warm_start_cfg_override: false
49
+ use_swa: false
50
+ first_val_epoch: .inf
51
+ reset_epoch: false
52
+ batch_ot:
53
+ enabled: true
54
+ cost: kabsch
55
+ noise_per_sample: 1
56
+ training:
57
+ min_plddt_mask: null
58
+ loss: se3_vf_loss
59
+ bb_atom_scale: 0.1
60
+ trans_scale: 0.1
61
+ translation_loss_weight: 2.0
62
+ t_normalize_clip: 0.9
63
+ rotation_loss_weights: 1.0
64
+ aux_loss_weight: 1.0
65
+ aux_loss_t_pass: 0.75
66
+ t_bins: 4
67
+ ca_distmat_loss_weight: 0.0
68
+ ensemble_group_size: 0
69
+ force_grouped_batch: false
70
+ lambda_shape: 1.0
71
+ lambda_local_cov: 1.0
72
+ lambda_cross_cov: 1.0
73
+ lambda_rmsf: 0.25
74
+ lambda_mode_recon: 0.0
75
+ enm_warmup_epochs: 0
76
+ lambda_enm_warmup: 1.0
77
+ log_latent_batch_debug: false
78
+ epoch_condition_probe: false
79
+ condition_probe_scale: 2.0
80
+ diagnostic_interval_steps: 50
81
+ per_frame_coeff_condition: true
82
+ lambda_motion: 1.0
83
+ lambda_q: 1.0
84
+ lambda_mode_orth: 1.0
85
+ lambda_pca_align: 0.0
86
+ oracle_condition: false
87
+ grad_flow_check: true
88
+ log_optimizer_coverage: true
89
+ wandb:
90
+ name: bbflow_base_energy_from_q_fullcov_orth1_recon0_30ep_2gpu_20260708_052300
91
+ project: bbflow
92
+ save_dir: outputs/
93
+ tags: []
94
+ optimizer:
95
+ lr: 0.0001
96
+ reset_optimizer_on_load: false
97
+ warmup_lr: false
98
+ warmup_lr_factor: 0.01
99
+ trainer:
100
+ overfit_batches: 0
101
+ min_epochs: 1
102
+ max_epochs: 41
103
+ accelerator: gpu
104
+ precision: 32-true
105
+ log_every_n_steps: 50
106
+ deterministic: false
107
+ strategy: ddp_find_unused_parameters_true
108
+ check_val_every_n_epoch: 1
109
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_energy_from_q_fullcov_orth1_recon0_30ep_2gpu_20260708_052300
110
+ accumulate_grad_batches: 1
111
+ max_steps: -1
112
+ profiler: null
113
+ num_sanity_val_steps: 0
114
+ checkpointer:
115
+ dirpath: ./
116
+ save_last: true
117
+ save_on_train_epoch_end: true
118
+ filename: epoch:{epoch:03d}
119
+ every_n_epochs: 1
120
+ save_top_k: -1
121
+ auto_insert_metric_name: false
122
+ checkpointer2: null
123
+ profiler:
124
+ enabled: false
125
+ modules: null
126
+ profile:
127
+ use_cuda: true
128
+ with_stack: false
129
+ stats:
130
+ group_by_stack_n: 0
131
+ group_by_input_shapes: false
132
+ prefixes:
133
+ - 'layer_0::'
134
+ - 'layer_1::'
135
+ sort_by: cpu_time_total
136
+ scheduler:
137
+ enabled: false
138
+ interpolant:
139
+ use_tqdm: true
140
+ batch_ot: intra
141
+ prior: conditional
142
+ prior_conditional:
143
+ gamma_trans: 0.2
144
+ gamma_rots: 0.2
145
+ min_t: 0.01
146
+ t_interval:
147
+ - 0.0
148
+ - 1.0
149
+ rots:
150
+ distribution: uniform
151
+ train_schedule: linear
152
+ sample_schedule: exp
153
+ exp_rate: 10
154
+ linear_scaling: 1
155
+ trans:
156
+ train_schedule: linear
157
+ sample_schedule: linear
158
+ sampling:
159
+ num_timesteps: 20
160
+ self_condition: true
161
+ noise_res_scaling_power: 0.0
162
+ noise_scale: 1.0
163
+ t_sampling_focus: 0.0
164
+ model:
165
+ node_embed_size: 240
166
+ edge_embed_size: 120
167
+ embed:
168
+ index_embed_type: full
169
+ index_embed_dim: 128
170
+ time_embed_dim: 128
171
+ embed_aatype: true
172
+ aatype_embed_dim: 128
173
+ length_embed_dim: 16
174
+ embed_self_conditioning: true
175
+ num_bins_distance: 22
176
+ min_bin_distance: 1.0e-05
177
+ max_bin_distance: 20.0
178
+ embed_distogram: true
179
+ embed_direction: false
180
+ embed_direction_cutoff: 5
181
+ edge_features:
182
+ self_condition: true
183
+ gfa:
184
+ c_s: 240
185
+ c_z: 120
186
+ c_hidden: 120
187
+ no_heads: 8
188
+ no_qk_points: 8
189
+ no_v_points: 8
190
+ seq_tfmr_num_heads: 4
191
+ seq_tfmr_num_layers: 2
192
+ num_blocks: 6
193
+ latent:
194
+ enable: true
195
+ dim: 16
196
+ num_modes: 8
197
+ motion_message_passing_layers: 4
198
+ cross_cov_near_distance: 12.0
199
+ template_residual_scale: 0.1
200
+ template_remove_rotation: true
201
+ use_enm_features: false
202
+ enm_num_modes: 8
203
+ enm_cutoff: 12.0
204
+ enm_eps: 1.0e-06
205
+ node_cond_dim: 8
206
+ edge_cond_dim: 8
207
+ freeze_foundation: false
208
+ inject_embedder: true
209
+ inject_film: true
210
+ activation_checkpoint: true
211
+ shape_fingerprint_k: 5
212
+ shape_fingerprint_cache_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
213
+ motion_target_cache_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
214
+ z_stochastic: false
215
+ track_condition_debug: false
216
+ mixture_components: 2
217
+ q_lstsq_ridge: 0.0001
218
+ q_cholesky_jitter: 0.0001
219
+ q_detach_projection: true
220
+ q_detach_shared_encoder: false
221
+ energy_from_q: false
222
+ energy_from_q_full_cov: true
223
+ sample_coefficients: true
224
+ pca_align_top_m: 2
225
+ inference:
226
+ name: atlas_test_250_B_fullcov_epoch010_real
227
+ seed: 123
228
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_energy_from_q_fullcov_orth1_recon0_30ep_2gpu_20260708_052300/point_epoch010.ckpt
229
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference
230
+ use_ckpt_name_in_outpath: true
231
+ use_gpu: true
232
+ num_gpus: 1
233
+ use_tqdm: true
234
+ log_times: true
235
+ z_per_sample: false
236
+ condition_mode: real
237
+ condition_scale: 1.0
238
+ postprocess_bfactors: false
239
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_energy_from_q_fullcov_orth1_recon0_30ep_2gpu_20260708_052300/missing_epoch010_metadata/test/ATLAS_test.csv
240
+ sort: false
241
+ num_proteins: null
242
+ num_workers: 0
243
+ min_length: null
244
+ max_length: null
245
+ save_traj: false
246
+ single_file: true
247
+ interpolant:
248
+ use_tqdm: true
249
+ min_t: 0.0
250
+ max_t: 0.99
251
+ rots:
252
+ distribution: uniform
253
+ sample_schedule: exp
254
+ exp_rate: 10
255
+ trans:
256
+ sample_schedule: linear
257
+ sampling:
258
+ num_timesteps: 20
259
+ self_condition: true
260
+ prior: conditional
261
+ prior_conditional:
262
+ gamma_trans: 0.2
263
+ gamma_rots: 0.2
264
+ batch_ot: intra
265
+ samples:
266
+ samples_per_protein: 250
267
+ batch_size: 20
268
+ num_res_squared: 400000
269
+ folding_cfg: null
bbflow_base/lightning_logs/version_27/hparams.yaml ADDED
@@ -0,0 +1,273 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_energy_from_q_diag_cycle005_24ep_3gpu_20260709_173603
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/datasets/ATLAS
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 32
39
+ max_num_res_squared: 400000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 2
47
+ warm_start: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_energy_from_q_diag_cycle005_24ep_3gpu_20260709_173603/epoch:015.ckpt
48
+ warm_start_cfg_override: false
49
+ use_swa: false
50
+ first_val_epoch: .inf
51
+ reset_epoch: false
52
+ batch_ot:
53
+ enabled: true
54
+ cost: kabsch
55
+ noise_per_sample: 1
56
+ training:
57
+ min_plddt_mask: null
58
+ loss: se3_vf_loss
59
+ bb_atom_scale: 0.1
60
+ trans_scale: 0.1
61
+ translation_loss_weight: 2.0
62
+ t_normalize_clip: 0.9
63
+ rotation_loss_weights: 1.0
64
+ aux_loss_weight: 1.0
65
+ aux_loss_t_pass: 0.75
66
+ t_bins: 4
67
+ ca_distmat_loss_weight: 0.0
68
+ ensemble_group_size: 0
69
+ force_grouped_batch: false
70
+ lambda_shape: 1.0
71
+ lambda_local_cov: 1.0
72
+ lambda_cross_cov: 1.0
73
+ lambda_rmsf: 0.25
74
+ lambda_mode_recon: 0.0
75
+ enm_warmup_epochs: 0
76
+ lambda_enm_warmup: 1.0
77
+ log_latent_batch_debug: false
78
+ epoch_condition_probe: false
79
+ condition_probe_scale: 2.0
80
+ diagnostic_interval_steps: 50
81
+ per_frame_coeff_condition: true
82
+ lambda_motion: 1.0
83
+ lambda_q: 1.0
84
+ lambda_mode_orth: 1.0
85
+ lambda_pca_align: 0.0
86
+ lambda_condition_cycle: 0.05
87
+ oracle_condition: false
88
+ grad_flow_check: true
89
+ log_optimizer_coverage: true
90
+ wandb:
91
+ name: bbflow_base_energy_from_q_diag_cycle005_24ep_3gpu_20260709_173603
92
+ project: bbflow
93
+ save_dir: outputs/
94
+ tags: []
95
+ optimizer:
96
+ lr: 0.0001
97
+ reset_optimizer_on_load: false
98
+ warmup_lr: false
99
+ warmup_lr_factor: 0.01
100
+ trainer:
101
+ overfit_batches: 0
102
+ min_epochs: 1
103
+ max_epochs: 24
104
+ accelerator: gpu
105
+ precision: 32-true
106
+ log_every_n_steps: 50
107
+ deterministic: false
108
+ strategy: ddp_find_unused_parameters_true
109
+ check_val_every_n_epoch: 1
110
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_energy_from_q_diag_cycle005_24ep_3gpu_20260709_173603
111
+ accumulate_grad_batches: 1
112
+ max_steps: -1
113
+ profiler: null
114
+ num_sanity_val_steps: 0
115
+ checkpointer:
116
+ dirpath: ./
117
+ save_last: true
118
+ save_on_train_epoch_end: true
119
+ filename: epoch:{epoch:03d}
120
+ every_n_epochs: 1
121
+ save_top_k: -1
122
+ auto_insert_metric_name: false
123
+ checkpointer2: null
124
+ profiler:
125
+ enabled: false
126
+ modules: null
127
+ profile:
128
+ use_cuda: true
129
+ with_stack: false
130
+ stats:
131
+ group_by_stack_n: 0
132
+ group_by_input_shapes: false
133
+ prefixes:
134
+ - 'layer_0::'
135
+ - 'layer_1::'
136
+ sort_by: cpu_time_total
137
+ scheduler:
138
+ enabled: false
139
+ interpolant:
140
+ use_tqdm: true
141
+ batch_ot: intra
142
+ prior: conditional
143
+ prior_conditional:
144
+ gamma_trans: 0.2
145
+ gamma_rots: 0.2
146
+ min_t: 0.01
147
+ t_interval:
148
+ - 0.0
149
+ - 1.0
150
+ rots:
151
+ distribution: uniform
152
+ train_schedule: linear
153
+ sample_schedule: exp
154
+ exp_rate: 10
155
+ linear_scaling: 1
156
+ trans:
157
+ train_schedule: linear
158
+ sample_schedule: linear
159
+ sampling:
160
+ num_timesteps: 20
161
+ self_condition: true
162
+ noise_res_scaling_power: 0.0
163
+ noise_scale: 1.0
164
+ t_sampling_focus: 0.0
165
+ model:
166
+ node_embed_size: 240
167
+ edge_embed_size: 120
168
+ embed:
169
+ index_embed_type: full
170
+ index_embed_dim: 128
171
+ time_embed_dim: 128
172
+ embed_aatype: true
173
+ aatype_embed_dim: 128
174
+ length_embed_dim: 16
175
+ embed_self_conditioning: true
176
+ num_bins_distance: 22
177
+ min_bin_distance: 1.0e-05
178
+ max_bin_distance: 20.0
179
+ embed_distogram: true
180
+ embed_direction: false
181
+ embed_direction_cutoff: 5
182
+ edge_features:
183
+ self_condition: true
184
+ gfa:
185
+ c_s: 240
186
+ c_z: 120
187
+ c_hidden: 120
188
+ no_heads: 8
189
+ no_qk_points: 8
190
+ no_v_points: 8
191
+ seq_tfmr_num_heads: 4
192
+ seq_tfmr_num_layers: 2
193
+ num_blocks: 6
194
+ latent:
195
+ enable: true
196
+ dim: 16
197
+ num_modes: 8
198
+ motion_message_passing_layers: 4
199
+ cross_cov_near_distance: 12.0
200
+ template_residual_scale: 0.1
201
+ template_remove_rotation: true
202
+ use_enm_features: false
203
+ enm_num_modes: 8
204
+ enm_cutoff: 12.0
205
+ enm_eps: 1.0e-06
206
+ node_cond_dim: 8
207
+ edge_cond_dim: 8
208
+ freeze_foundation: false
209
+ inject_embedder: true
210
+ inject_film: true
211
+ activation_checkpoint: true
212
+ shape_fingerprint_k: 5
213
+ shape_fingerprint_cache_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
214
+ motion_target_cache_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
215
+ z_stochastic: false
216
+ track_condition_debug: false
217
+ mixture_components: 2
218
+ q_lstsq_ridge: 0.0001
219
+ q_cholesky_jitter: 0.0001
220
+ q_detach_projection: true
221
+ q_detach_shared_encoder: false
222
+ energy_from_q: true
223
+ energy_from_q_full_cov: false
224
+ sample_coefficients: true
225
+ pca_align_top_m: 2
226
+ inference:
227
+ name: atlas_test_250_A_cycle_epoch016_real
228
+ seed: 123
229
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_energy_from_q_diag_cycle005_24ep_3gpu_20260709_173603/epoch:015.ckpt
230
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference
231
+ use_ckpt_name_in_outpath: true
232
+ use_gpu: true
233
+ num_gpus: 1
234
+ precision: 32-true
235
+ use_tqdm: true
236
+ log_times: true
237
+ z_per_sample: false
238
+ condition_mode: real
239
+ condition_scale: 1.0
240
+ postprocess_bfactors: false
241
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
242
+ sort: false
243
+ num_proteins: null
244
+ num_workers: 0
245
+ min_length: null
246
+ max_length: null
247
+ save_traj: false
248
+ final_only: true
249
+ cache_static_features: true
250
+ single_file: true
251
+ interpolant:
252
+ use_tqdm: true
253
+ min_t: 0.0
254
+ max_t: 0.99
255
+ rots:
256
+ distribution: uniform
257
+ sample_schedule: exp
258
+ exp_rate: 10
259
+ trans:
260
+ sample_schedule: linear
261
+ sampling:
262
+ num_timesteps: 20
263
+ self_condition: true
264
+ prior: conditional
265
+ prior_conditional:
266
+ gamma_trans: 0.2
267
+ gamma_rots: 0.2
268
+ batch_ot: intra
269
+ samples:
270
+ samples_per_protein: 250
271
+ batch_size: 20
272
+ num_res_squared: 2900000
273
+ folding_cfg: null
bbflow_base/lightning_logs/version_33/hparams.yaml ADDED
@@ -0,0 +1,273 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_energy_from_q_diag_orth1_recon0_30ep_3gpu_20260707_165355
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/datasets/ATLAS
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 32
39
+ max_num_res_squared: 400000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_energy_from_q_diag_orth1_recon0_30ep_3gpu_20260707_165355/last.ckpt
48
+ warm_start_cfg_override: false
49
+ use_swa: false
50
+ first_val_epoch: .inf
51
+ reset_epoch: false
52
+ batch_ot:
53
+ enabled: true
54
+ cost: kabsch
55
+ noise_per_sample: 1
56
+ training:
57
+ min_plddt_mask: null
58
+ loss: se3_vf_loss
59
+ bb_atom_scale: 0.1
60
+ trans_scale: 0.1
61
+ translation_loss_weight: 2.0
62
+ t_normalize_clip: 0.9
63
+ rotation_loss_weights: 1.0
64
+ aux_loss_weight: 1.0
65
+ aux_loss_t_pass: 0.75
66
+ t_bins: 4
67
+ ca_distmat_loss_weight: 0.0
68
+ ensemble_group_size: 0
69
+ force_grouped_batch: false
70
+ lambda_shape: 1.0
71
+ lambda_local_cov: 1.0
72
+ lambda_cross_cov: 1.0
73
+ lambda_rmsf: 0.25
74
+ lambda_mode_recon: 0.0
75
+ enm_warmup_epochs: 0
76
+ lambda_enm_warmup: 1.0
77
+ log_latent_batch_debug: false
78
+ epoch_condition_probe: false
79
+ condition_probe_scale: 2.0
80
+ diagnostic_interval_steps: 50
81
+ per_frame_coeff_condition: true
82
+ lambda_motion: 1.0
83
+ lambda_q: 1.0
84
+ lambda_mode_orth: 1.0
85
+ lambda_pca_align: 0.0
86
+ oracle_condition: false
87
+ grad_flow_check: true
88
+ log_optimizer_coverage: true
89
+ wandb:
90
+ name: bbflow_base_energy_from_q_diag_orth1_recon0_30ep_3gpu_20260707_165355
91
+ project: bbflow
92
+ save_dir: outputs/
93
+ tags: []
94
+ optimizer:
95
+ lr: 0.0001
96
+ reset_optimizer_on_load: false
97
+ warmup_lr: false
98
+ warmup_lr_factor: 0.01
99
+ trainer:
100
+ overfit_batches: 0
101
+ min_epochs: 1
102
+ max_epochs: 40
103
+ accelerator: gpu
104
+ precision: 32-true
105
+ log_every_n_steps: 50
106
+ deterministic: false
107
+ strategy: ddp_find_unused_parameters_true
108
+ check_val_every_n_epoch: 1
109
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_energy_from_q_diag_orth1_recon0_30ep_3gpu_20260707_165355
110
+ accumulate_grad_batches: 1
111
+ max_steps: -1
112
+ profiler: null
113
+ num_sanity_val_steps: 0
114
+ checkpointer:
115
+ dirpath: ./
116
+ save_last: true
117
+ save_on_train_epoch_end: true
118
+ filename: epoch:{epoch:03d}
119
+ every_n_epochs: 1
120
+ save_top_k: -1
121
+ auto_insert_metric_name: false
122
+ checkpointer2: null
123
+ profiler:
124
+ enabled: false
125
+ modules: null
126
+ profile:
127
+ use_cuda: true
128
+ with_stack: false
129
+ stats:
130
+ group_by_stack_n: 0
131
+ group_by_input_shapes: false
132
+ prefixes:
133
+ - 'layer_0::'
134
+ - 'layer_1::'
135
+ sort_by: cpu_time_total
136
+ scheduler:
137
+ enabled: false
138
+ interpolant:
139
+ use_tqdm: true
140
+ batch_ot: intra
141
+ prior: conditional
142
+ prior_conditional:
143
+ gamma_trans: 0.2
144
+ gamma_rots: 0.2
145
+ min_t: 0.01
146
+ t_interval:
147
+ - 0.0
148
+ - 1.0
149
+ rots:
150
+ distribution: uniform
151
+ train_schedule: linear
152
+ sample_schedule: exp
153
+ exp_rate: 10
154
+ linear_scaling: 1
155
+ trans:
156
+ train_schedule: linear
157
+ sample_schedule: linear
158
+ sampling:
159
+ num_timesteps: 20
160
+ self_condition: true
161
+ noise_res_scaling_power: 0.0
162
+ noise_scale: 1.0
163
+ t_sampling_focus: 0.0
164
+ model:
165
+ node_embed_size: 240
166
+ edge_embed_size: 120
167
+ embed:
168
+ index_embed_type: full
169
+ index_embed_dim: 128
170
+ time_embed_dim: 128
171
+ embed_aatype: true
172
+ aatype_embed_dim: 128
173
+ length_embed_dim: 16
174
+ embed_self_conditioning: true
175
+ num_bins_distance: 22
176
+ min_bin_distance: 1.0e-05
177
+ max_bin_distance: 20.0
178
+ embed_distogram: true
179
+ embed_direction: false
180
+ embed_direction_cutoff: 5
181
+ edge_features:
182
+ self_condition: true
183
+ gfa:
184
+ c_s: 240
185
+ c_z: 120
186
+ c_hidden: 120
187
+ no_heads: 8
188
+ no_qk_points: 8
189
+ no_v_points: 8
190
+ seq_tfmr_num_heads: 4
191
+ seq_tfmr_num_layers: 2
192
+ num_blocks: 6
193
+ latent:
194
+ enable: true
195
+ dim: 16
196
+ num_modes: 8
197
+ motion_message_passing_layers: 4
198
+ cross_cov_near_distance: 12.0
199
+ template_residual_scale: 0.1
200
+ template_remove_rotation: true
201
+ use_enm_features: false
202
+ enm_num_modes: 8
203
+ enm_cutoff: 12.0
204
+ enm_eps: 1.0e-06
205
+ node_cond_dim: 8
206
+ edge_cond_dim: 8
207
+ freeze_foundation: false
208
+ inject_embedder: true
209
+ inject_film: true
210
+ activation_checkpoint: true
211
+ shape_fingerprint_k: 5
212
+ shape_fingerprint_cache_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
213
+ motion_target_cache_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
214
+ z_stochastic: false
215
+ q_sample_temperature: 0.4
216
+ track_condition_debug: false
217
+ mixture_components: 2
218
+ q_lstsq_ridge: 0.0001
219
+ q_cholesky_jitter: 0.0001
220
+ q_detach_projection: true
221
+ q_detach_shared_encoder: false
222
+ energy_from_q: true
223
+ energy_from_q_full_cov: false
224
+ sample_coefficients: true
225
+ pca_align_top_m: 2
226
+ inference:
227
+ name: atlas_test_250_A30_qtemp0p4_real
228
+ seed: 123
229
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_energy_from_q_diag_orth1_recon0_30ep_3gpu_20260707_165355/last.ckpt
230
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference
231
+ use_ckpt_name_in_outpath: true
232
+ use_gpu: true
233
+ num_gpus: 2
234
+ precision: 32-true
235
+ use_tqdm: true
236
+ log_times: true
237
+ z_per_sample: false
238
+ condition_mode: real
239
+ condition_scale: 1.0
240
+ postprocess_bfactors: false
241
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
242
+ sort: false
243
+ num_proteins: null
244
+ num_workers: 0
245
+ min_length: null
246
+ max_length: null
247
+ save_traj: false
248
+ final_only: true
249
+ cache_static_features: true
250
+ single_file: true
251
+ interpolant:
252
+ use_tqdm: true
253
+ min_t: 0.0
254
+ max_t: 0.99
255
+ rots:
256
+ distribution: uniform
257
+ sample_schedule: exp
258
+ exp_rate: 10
259
+ trans:
260
+ sample_schedule: linear
261
+ sampling:
262
+ num_timesteps: 20
263
+ self_condition: true
264
+ prior: conditional
265
+ prior_conditional:
266
+ gamma_trans: 0.2
267
+ gamma_rots: 0.2
268
+ batch_ot: intra
269
+ samples:
270
+ samples_per_protein: 250
271
+ batch_size: 20
272
+ num_res_squared: 2900000
273
+ folding_cfg: null
bbflow_base/lightning_logs/version_35/hparams.yaml ADDED
@@ -0,0 +1,273 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_energy_from_q_diag_orth1_recon0_30ep_3gpu_20260707_165355
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/datasets/ATLAS
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 32
39
+ max_num_res_squared: 400000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_energy_from_q_diag_orth1_recon0_30ep_3gpu_20260707_165355/last.ckpt
48
+ warm_start_cfg_override: false
49
+ use_swa: false
50
+ first_val_epoch: .inf
51
+ reset_epoch: false
52
+ batch_ot:
53
+ enabled: true
54
+ cost: kabsch
55
+ noise_per_sample: 1
56
+ training:
57
+ min_plddt_mask: null
58
+ loss: se3_vf_loss
59
+ bb_atom_scale: 0.1
60
+ trans_scale: 0.1
61
+ translation_loss_weight: 2.0
62
+ t_normalize_clip: 0.9
63
+ rotation_loss_weights: 1.0
64
+ aux_loss_weight: 1.0
65
+ aux_loss_t_pass: 0.75
66
+ t_bins: 4
67
+ ca_distmat_loss_weight: 0.0
68
+ ensemble_group_size: 0
69
+ force_grouped_batch: false
70
+ lambda_shape: 1.0
71
+ lambda_local_cov: 1.0
72
+ lambda_cross_cov: 1.0
73
+ lambda_rmsf: 0.25
74
+ lambda_mode_recon: 0.0
75
+ enm_warmup_epochs: 0
76
+ lambda_enm_warmup: 1.0
77
+ log_latent_batch_debug: false
78
+ epoch_condition_probe: false
79
+ condition_probe_scale: 2.0
80
+ diagnostic_interval_steps: 50
81
+ per_frame_coeff_condition: true
82
+ lambda_motion: 1.0
83
+ lambda_q: 1.0
84
+ lambda_mode_orth: 1.0
85
+ lambda_pca_align: 0.0
86
+ oracle_condition: false
87
+ grad_flow_check: true
88
+ log_optimizer_coverage: true
89
+ wandb:
90
+ name: bbflow_base_energy_from_q_diag_orth1_recon0_30ep_3gpu_20260707_165355
91
+ project: bbflow
92
+ save_dir: outputs/
93
+ tags: []
94
+ optimizer:
95
+ lr: 0.0001
96
+ reset_optimizer_on_load: false
97
+ warmup_lr: false
98
+ warmup_lr_factor: 0.01
99
+ trainer:
100
+ overfit_batches: 0
101
+ min_epochs: 1
102
+ max_epochs: 40
103
+ accelerator: gpu
104
+ precision: 32-true
105
+ log_every_n_steps: 50
106
+ deterministic: false
107
+ strategy: ddp_find_unused_parameters_true
108
+ check_val_every_n_epoch: 1
109
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_energy_from_q_diag_orth1_recon0_30ep_3gpu_20260707_165355
110
+ accumulate_grad_batches: 1
111
+ max_steps: -1
112
+ profiler: null
113
+ num_sanity_val_steps: 0
114
+ checkpointer:
115
+ dirpath: ./
116
+ save_last: true
117
+ save_on_train_epoch_end: true
118
+ filename: epoch:{epoch:03d}
119
+ every_n_epochs: 1
120
+ save_top_k: -1
121
+ auto_insert_metric_name: false
122
+ checkpointer2: null
123
+ profiler:
124
+ enabled: false
125
+ modules: null
126
+ profile:
127
+ use_cuda: true
128
+ with_stack: false
129
+ stats:
130
+ group_by_stack_n: 0
131
+ group_by_input_shapes: false
132
+ prefixes:
133
+ - 'layer_0::'
134
+ - 'layer_1::'
135
+ sort_by: cpu_time_total
136
+ scheduler:
137
+ enabled: false
138
+ interpolant:
139
+ use_tqdm: true
140
+ batch_ot: intra
141
+ prior: conditional
142
+ prior_conditional:
143
+ gamma_trans: 0.2
144
+ gamma_rots: 0.2
145
+ min_t: 0.01
146
+ t_interval:
147
+ - 0.0
148
+ - 1.0
149
+ rots:
150
+ distribution: uniform
151
+ train_schedule: linear
152
+ sample_schedule: exp
153
+ exp_rate: 10
154
+ linear_scaling: 1
155
+ trans:
156
+ train_schedule: linear
157
+ sample_schedule: linear
158
+ sampling:
159
+ num_timesteps: 20
160
+ self_condition: true
161
+ noise_res_scaling_power: 0.0
162
+ noise_scale: 1.0
163
+ t_sampling_focus: 0.0
164
+ model:
165
+ node_embed_size: 240
166
+ edge_embed_size: 120
167
+ embed:
168
+ index_embed_type: full
169
+ index_embed_dim: 128
170
+ time_embed_dim: 128
171
+ embed_aatype: true
172
+ aatype_embed_dim: 128
173
+ length_embed_dim: 16
174
+ embed_self_conditioning: true
175
+ num_bins_distance: 22
176
+ min_bin_distance: 1.0e-05
177
+ max_bin_distance: 20.0
178
+ embed_distogram: true
179
+ embed_direction: false
180
+ embed_direction_cutoff: 5
181
+ edge_features:
182
+ self_condition: true
183
+ gfa:
184
+ c_s: 240
185
+ c_z: 120
186
+ c_hidden: 120
187
+ no_heads: 8
188
+ no_qk_points: 8
189
+ no_v_points: 8
190
+ seq_tfmr_num_heads: 4
191
+ seq_tfmr_num_layers: 2
192
+ num_blocks: 6
193
+ latent:
194
+ enable: true
195
+ dim: 16
196
+ num_modes: 8
197
+ motion_message_passing_layers: 4
198
+ cross_cov_near_distance: 12.0
199
+ template_residual_scale: 0.1
200
+ template_remove_rotation: true
201
+ use_enm_features: false
202
+ enm_num_modes: 8
203
+ enm_cutoff: 12.0
204
+ enm_eps: 1.0e-06
205
+ node_cond_dim: 8
206
+ edge_cond_dim: 8
207
+ freeze_foundation: false
208
+ inject_embedder: true
209
+ inject_film: true
210
+ activation_checkpoint: true
211
+ shape_fingerprint_k: 5
212
+ shape_fingerprint_cache_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
213
+ motion_target_cache_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
214
+ z_stochastic: false
215
+ q_sample_temperature: 0.6
216
+ track_condition_debug: false
217
+ mixture_components: 2
218
+ q_lstsq_ridge: 0.0001
219
+ q_cholesky_jitter: 0.0001
220
+ q_detach_projection: true
221
+ q_detach_shared_encoder: false
222
+ energy_from_q: true
223
+ energy_from_q_full_cov: false
224
+ sample_coefficients: true
225
+ pca_align_top_m: 2
226
+ inference:
227
+ name: atlas_test_250_A30_qtemp0p6_real
228
+ seed: 123
229
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_energy_from_q_diag_orth1_recon0_30ep_3gpu_20260707_165355/last.ckpt
230
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference
231
+ use_ckpt_name_in_outpath: true
232
+ use_gpu: true
233
+ num_gpus: 2
234
+ precision: 32-true
235
+ use_tqdm: true
236
+ log_times: true
237
+ z_per_sample: false
238
+ condition_mode: real
239
+ condition_scale: 1.0
240
+ postprocess_bfactors: false
241
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
242
+ sort: false
243
+ num_proteins: null
244
+ num_workers: 0
245
+ min_length: null
246
+ max_length: null
247
+ save_traj: false
248
+ final_only: true
249
+ cache_static_features: true
250
+ single_file: true
251
+ interpolant:
252
+ use_tqdm: true
253
+ min_t: 0.0
254
+ max_t: 0.99
255
+ rots:
256
+ distribution: uniform
257
+ sample_schedule: exp
258
+ exp_rate: 10
259
+ trans:
260
+ sample_schedule: linear
261
+ sampling:
262
+ num_timesteps: 20
263
+ self_condition: true
264
+ prior: conditional
265
+ prior_conditional:
266
+ gamma_trans: 0.2
267
+ gamma_rots: 0.2
268
+ batch_ot: intra
269
+ samples:
270
+ samples_per_protein: 250
271
+ batch_size: 20
272
+ num_res_squared: 2900000
273
+ folding_cfg: null
bbflow_base/lightning_logs/version_39/hparams.yaml ADDED
@@ -0,0 +1,279 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_genresp_v1_efq_diag_orth1_30ep_20260712_090634
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/datasets/ATLAS
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 16
39
+ max_num_res_squared: 180000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 2
47
+ warm_start: /home/wangyusong/LD-FPG-main/bbflow/models/bbflow-0.1/bbflow-0.1.ckpt
48
+ warm_start_cfg_override: false
49
+ use_swa: false
50
+ first_val_epoch: .inf
51
+ reset_epoch: false
52
+ batch_ot:
53
+ enabled: true
54
+ cost: kabsch
55
+ noise_per_sample: 1
56
+ training:
57
+ min_plddt_mask: null
58
+ loss: se3_vf_loss
59
+ bb_atom_scale: 0.1
60
+ trans_scale: 0.1
61
+ translation_loss_weight: 2.0
62
+ t_normalize_clip: 0.9
63
+ rotation_loss_weights: 1.0
64
+ aux_loss_weight: 1.0
65
+ aux_loss_t_pass: 0.75
66
+ t_bins: 4
67
+ ca_distmat_loss_weight: 0.0
68
+ ensemble_group_size: 0
69
+ force_grouped_batch: false
70
+ lambda_shape: 1.0
71
+ lambda_local_cov: 1.0
72
+ lambda_cross_cov: 1.0
73
+ lambda_rmsf: 0.25
74
+ lambda_mode_recon: 0.0
75
+ enm_warmup_epochs: 0
76
+ lambda_enm_warmup: 1.0
77
+ log_latent_batch_debug: false
78
+ epoch_condition_probe: false
79
+ condition_probe_scale: 2.0
80
+ diagnostic_interval_steps: 50
81
+ per_frame_coeff_condition: true
82
+ lambda_motion: 1.0
83
+ lambda_q: 1.0
84
+ lambda_mode_orth: 1.0
85
+ lambda_pca_align: 0.0
86
+ lambda_condition_cycle: 0.0
87
+ oracle_condition: false
88
+ grad_flow_check: true
89
+ log_optimizer_coverage: true
90
+ lambda_generator_cov: 0.5
91
+ generator_cov_use_cross: false
92
+ generator_cov_t_min: 0.1
93
+ generator_cov_t_max: 0.6
94
+ generator_cov_checkpoint: true
95
+ wandb:
96
+ name: bbflow_base_genresp_v1_efq_diag_orth1_30ep_20260712_090634
97
+ project: bbflow
98
+ save_dir: outputs/
99
+ tags: []
100
+ optimizer:
101
+ lr: 0.0001
102
+ reset_optimizer_on_load: false
103
+ warmup_lr: false
104
+ warmup_lr_factor: 0.01
105
+ trainer:
106
+ overfit_batches: 0
107
+ min_epochs: 1
108
+ max_epochs: 30
109
+ accelerator: gpu
110
+ precision: 32-true
111
+ log_every_n_steps: 50
112
+ deterministic: false
113
+ strategy: ddp
114
+ check_val_every_n_epoch: 1
115
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_genresp_v1_efq_diag_orth1_30ep_20260712_090634
116
+ accumulate_grad_batches: 1
117
+ max_steps: -1
118
+ profiler: null
119
+ num_sanity_val_steps: 0
120
+ checkpointer:
121
+ dirpath: ./
122
+ save_last: true
123
+ save_on_train_epoch_end: true
124
+ filename: epoch:{epoch:03d}
125
+ every_n_epochs: 5
126
+ save_top_k: -1
127
+ auto_insert_metric_name: false
128
+ checkpointer2: null
129
+ profiler:
130
+ enabled: false
131
+ modules: null
132
+ profile:
133
+ use_cuda: true
134
+ with_stack: false
135
+ stats:
136
+ group_by_stack_n: 0
137
+ group_by_input_shapes: false
138
+ prefixes:
139
+ - 'layer_0::'
140
+ - 'layer_1::'
141
+ sort_by: cpu_time_total
142
+ scheduler:
143
+ enabled: false
144
+ interpolant:
145
+ use_tqdm: true
146
+ batch_ot: intra
147
+ prior: conditional
148
+ prior_conditional:
149
+ gamma_trans: 0.2
150
+ gamma_rots: 0.2
151
+ min_t: 0.01
152
+ t_interval:
153
+ - 0.0
154
+ - 1.0
155
+ rots:
156
+ distribution: uniform
157
+ train_schedule: linear
158
+ sample_schedule: exp
159
+ exp_rate: 10
160
+ linear_scaling: 1
161
+ trans:
162
+ train_schedule: linear
163
+ sample_schedule: linear
164
+ sampling:
165
+ num_timesteps: 20
166
+ self_condition: true
167
+ noise_res_scaling_power: 0.0
168
+ noise_scale: 1.0
169
+ t_sampling_focus: 0.0
170
+ model:
171
+ node_embed_size: 240
172
+ edge_embed_size: 120
173
+ embed:
174
+ index_embed_type: full
175
+ index_embed_dim: 128
176
+ time_embed_dim: 128
177
+ embed_aatype: true
178
+ aatype_embed_dim: 128
179
+ length_embed_dim: 16
180
+ embed_self_conditioning: true
181
+ num_bins_distance: 22
182
+ min_bin_distance: 1.0e-05
183
+ max_bin_distance: 20.0
184
+ embed_distogram: true
185
+ embed_direction: false
186
+ embed_direction_cutoff: 5
187
+ edge_features:
188
+ self_condition: true
189
+ gfa:
190
+ c_s: 240
191
+ c_z: 120
192
+ c_hidden: 120
193
+ no_heads: 8
194
+ no_qk_points: 8
195
+ no_v_points: 8
196
+ seq_tfmr_num_heads: 4
197
+ seq_tfmr_num_layers: 2
198
+ num_blocks: 6
199
+ latent:
200
+ enable: true
201
+ dim: 16
202
+ num_modes: 8
203
+ motion_message_passing_layers: 4
204
+ cross_cov_near_distance: 12.0
205
+ template_residual_scale: 0.1
206
+ template_remove_rotation: true
207
+ use_enm_features: false
208
+ enm_num_modes: 8
209
+ enm_cutoff: 12.0
210
+ enm_eps: 1.0e-06
211
+ node_cond_dim: 8
212
+ edge_cond_dim: 8
213
+ freeze_foundation: false
214
+ inject_embedder: true
215
+ inject_film: true
216
+ activation_checkpoint: true
217
+ shape_fingerprint_k: 5
218
+ shape_fingerprint_cache_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
219
+ motion_target_cache_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
220
+ z_stochastic: false
221
+ q_sample_temperature: 1.0
222
+ track_condition_debug: false
223
+ mixture_components: 2
224
+ q_lstsq_ridge: 0.0001
225
+ q_cholesky_jitter: 0.0001
226
+ q_detach_projection: true
227
+ q_detach_shared_encoder: false
228
+ energy_from_q: true
229
+ energy_from_q_full_cov: false
230
+ sample_coefficients: true
231
+ pca_align_top_m: 2
232
+ inference:
233
+ name: atlas_test_250_genresp_v1_epoch004_5ep_real
234
+ seed: 123
235
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_genresp_v1_efq_diag_orth1_30ep_20260712_090634/epoch:004.ckpt
236
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference
237
+ use_ckpt_name_in_outpath: true
238
+ use_gpu: true
239
+ num_gpus: 2
240
+ precision: 32-true
241
+ use_tqdm: true
242
+ log_times: true
243
+ z_per_sample: false
244
+ condition_mode: real
245
+ condition_scale: 1.0
246
+ postprocess_bfactors: false
247
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
248
+ sort: false
249
+ num_proteins: null
250
+ num_workers: 0
251
+ min_length: null
252
+ max_length: null
253
+ save_traj: false
254
+ final_only: true
255
+ cache_static_features: true
256
+ single_file: true
257
+ interpolant:
258
+ use_tqdm: true
259
+ min_t: 0.0
260
+ max_t: 0.99
261
+ rots:
262
+ distribution: uniform
263
+ sample_schedule: exp
264
+ exp_rate: 10
265
+ trans:
266
+ sample_schedule: linear
267
+ sampling:
268
+ num_timesteps: 20
269
+ self_condition: true
270
+ prior: conditional
271
+ prior_conditional:
272
+ gamma_trans: 0.2
273
+ gamma_rots: 0.2
274
+ batch_ot: intra
275
+ samples:
276
+ samples_per_protein: 250
277
+ batch_size: 20
278
+ num_res_squared: 2900000
279
+ folding_cfg: null
bbflow_base/lightning_logs/version_4/hparams.yaml ADDED
@@ -0,0 +1,261 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_official_modelonly_long_finetune_orth1_recon0_100ep_3gpu_20260630_191404
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/datasets/ATLAS
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 32
39
+ max_num_res_squared: 400000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /home/wangyusong/LD-FPG-main/bbflow/models/bbflow-0.1/bbflow-0.1.ckpt
48
+ warm_start_cfg_override: false
49
+ use_swa: false
50
+ first_val_epoch: .inf
51
+ reset_epoch: false
52
+ batch_ot:
53
+ enabled: true
54
+ cost: kabsch
55
+ noise_per_sample: 1
56
+ training:
57
+ min_plddt_mask: null
58
+ loss: se3_vf_loss
59
+ bb_atom_scale: 0.1
60
+ trans_scale: 0.1
61
+ translation_loss_weight: 2.0
62
+ t_normalize_clip: 0.9
63
+ rotation_loss_weights: 1.0
64
+ aux_loss_weight: 1.0
65
+ aux_loss_t_pass: 0.75
66
+ t_bins: 4
67
+ ca_distmat_loss_weight: 0.0
68
+ ensemble_group_size: 0
69
+ force_grouped_batch: false
70
+ lambda_shape: 1.0
71
+ lambda_local_cov: 1.0
72
+ lambda_cross_cov: 1.0
73
+ lambda_rmsf: 0.25
74
+ lambda_mode_recon: 0.0
75
+ enm_warmup_epochs: 0
76
+ lambda_enm_warmup: 1.0
77
+ log_latent_batch_debug: false
78
+ epoch_condition_probe: false
79
+ condition_probe_scale: 2.0
80
+ diagnostic_interval_steps: 50
81
+ per_frame_coeff_condition: true
82
+ lambda_motion: 1.0
83
+ lambda_q: 1.0
84
+ lambda_mode_orth: 1.0
85
+ oracle_condition: false
86
+ grad_flow_check: true
87
+ log_optimizer_coverage: true
88
+ wandb:
89
+ name: bbflow_base_official_modelonly_long_finetune_orth1_recon0_100ep_3gpu_20260630_191404
90
+ project: bbflow
91
+ save_dir: outputs/
92
+ tags: []
93
+ optimizer:
94
+ lr: 0.0001
95
+ reset_optimizer_on_load: false
96
+ warmup_lr: false
97
+ warmup_lr_factor: 0.01
98
+ trainer:
99
+ overfit_batches: 0
100
+ min_epochs: 1
101
+ max_epochs: 100
102
+ accelerator: gpu
103
+ precision: 32-true
104
+ log_every_n_steps: 50
105
+ deterministic: false
106
+ strategy: ddp
107
+ check_val_every_n_epoch: 1
108
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_official_modelonly_long_finetune_orth1_recon0_100ep_3gpu_20260630_191404
109
+ accumulate_grad_batches: 1
110
+ max_steps: -1
111
+ profiler: null
112
+ num_sanity_val_steps: 0
113
+ checkpointer:
114
+ dirpath: ./
115
+ save_last: true
116
+ save_on_train_epoch_end: true
117
+ filename: epoch:{epoch:03d}
118
+ every_n_epochs: 1
119
+ save_top_k: -1
120
+ auto_insert_metric_name: false
121
+ checkpointer2: null
122
+ profiler:
123
+ enabled: false
124
+ modules: null
125
+ profile:
126
+ use_cuda: true
127
+ with_stack: false
128
+ stats:
129
+ group_by_stack_n: 0
130
+ group_by_input_shapes: false
131
+ prefixes:
132
+ - 'layer_0::'
133
+ - 'layer_1::'
134
+ sort_by: cpu_time_total
135
+ scheduler:
136
+ enabled: false
137
+ interpolant:
138
+ use_tqdm: true
139
+ batch_ot: intra
140
+ prior: conditional
141
+ prior_conditional:
142
+ gamma_trans: 0.2
143
+ gamma_rots: 0.2
144
+ min_t: 0.01
145
+ t_interval:
146
+ - 0.0
147
+ - 1.0
148
+ rots:
149
+ distribution: uniform
150
+ train_schedule: linear
151
+ sample_schedule: exp
152
+ exp_rate: 10
153
+ linear_scaling: 1
154
+ trans:
155
+ train_schedule: linear
156
+ sample_schedule: linear
157
+ sampling:
158
+ num_timesteps: 20
159
+ self_condition: true
160
+ noise_res_scaling_power: 0.0
161
+ noise_scale: 1.0
162
+ t_sampling_focus: 0.0
163
+ model:
164
+ node_embed_size: 240
165
+ edge_embed_size: 120
166
+ embed:
167
+ index_embed_type: full
168
+ index_embed_dim: 128
169
+ time_embed_dim: 128
170
+ embed_aatype: true
171
+ aatype_embed_dim: 128
172
+ length_embed_dim: 16
173
+ embed_self_conditioning: true
174
+ num_bins_distance: 22
175
+ min_bin_distance: 1.0e-05
176
+ max_bin_distance: 20.0
177
+ embed_distogram: true
178
+ embed_direction: false
179
+ embed_direction_cutoff: 5
180
+ edge_features:
181
+ self_condition: true
182
+ gfa:
183
+ c_s: 240
184
+ c_z: 120
185
+ c_hidden: 120
186
+ no_heads: 8
187
+ no_qk_points: 8
188
+ no_v_points: 8
189
+ seq_tfmr_num_heads: 4
190
+ seq_tfmr_num_layers: 2
191
+ num_blocks: 6
192
+ latent:
193
+ enable: true
194
+ dim: 16
195
+ num_modes: 8
196
+ motion_message_passing_layers: 4
197
+ cross_cov_near_distance: 12.0
198
+ template_residual_scale: 0.1
199
+ template_remove_rotation: true
200
+ use_enm_features: false
201
+ enm_num_modes: 8
202
+ enm_cutoff: 12.0
203
+ enm_eps: 1.0e-06
204
+ node_cond_dim: 8
205
+ edge_cond_dim: 8
206
+ freeze_foundation: false
207
+ inject_embedder: true
208
+ inject_film: true
209
+ activation_checkpoint: true
210
+ shape_fingerprint_k: 5
211
+ shape_fingerprint_cache_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
212
+ motion_target_cache_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
213
+ z_stochastic: false
214
+ track_condition_debug: false
215
+ mixture_components: 2
216
+ q_lstsq_ridge: 0.0001
217
+ q_cholesky_jitter: 0.0001
218
+ q_detach_projection: true
219
+ q_detach_shared_encoder: false
220
+ sample_coefficients: true
221
+ inference:
222
+ name: atlas_test_250_zero
223
+ seed: 123
224
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_official_modelonly_long_finetune_orth1_recon0_100ep_3gpu_20260630_191404/last.ckpt
225
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_official_modelonly_long_finetune_orth1_recon0_100ep_3gpu_20260630_191404/standard_downstream/inference
226
+ use_ckpt_name_in_outpath: true
227
+ use_gpu: true
228
+ num_gpus: 1
229
+ use_tqdm: true
230
+ log_times: true
231
+ z_per_sample: false
232
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
233
+ sort: false
234
+ num_proteins: null
235
+ min_length: null
236
+ max_length: null
237
+ save_traj: false
238
+ single_file: true
239
+ interpolant:
240
+ use_tqdm: true
241
+ min_t: 0.0
242
+ max_t: 0.99
243
+ rots:
244
+ distribution: uniform
245
+ sample_schedule: exp
246
+ exp_rate: 10
247
+ trans:
248
+ sample_schedule: linear
249
+ sampling:
250
+ num_timesteps: 20
251
+ self_condition: true
252
+ prior: conditional
253
+ prior_conditional:
254
+ gamma_trans: 0.2
255
+ gamma_rots: 0.2
256
+ batch_ot: intra
257
+ samples:
258
+ samples_per_protein: 250
259
+ batch_size: 10
260
+ num_res_squared: 2900000
261
+ folding_cfg: null
bbflow_base/lightning_logs/version_43/hparams.yaml ADDED
@@ -0,0 +1,289 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/datasets/ATLAS
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 10
39
+ max_num_res_squared: 120000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /home/wangyusong/LD-FPG-main/bbflow/models/bbflow-0.1/bbflow-0.1.ckpt
48
+ warm_start_cfg_override: false
49
+ use_swa: false
50
+ first_val_epoch: .inf
51
+ reset_epoch: false
52
+ batch_ot:
53
+ enabled: true
54
+ cost: kabsch
55
+ noise_per_sample: 1
56
+ training:
57
+ min_plddt_mask: null
58
+ loss: se3_vf_loss
59
+ bb_atom_scale: 0.1
60
+ trans_scale: 0.1
61
+ translation_loss_weight: 2.0
62
+ t_normalize_clip: 0.9
63
+ rotation_loss_weights: 1.0
64
+ aux_loss_weight: 1.0
65
+ aux_loss_t_pass: 0.75
66
+ t_bins: 4
67
+ ca_distmat_loss_weight: 0.0
68
+ ensemble_group_size: 0
69
+ force_grouped_batch: false
70
+ lambda_shape: 1.0
71
+ lambda_local_cov: 1.0
72
+ lambda_cross_cov: 1.0
73
+ lambda_rmsf: 0.25
74
+ lambda_mode_recon: 0.0
75
+ enm_warmup_epochs: 0
76
+ lambda_enm_warmup: 1.0
77
+ log_latent_batch_debug: false
78
+ epoch_condition_probe: false
79
+ condition_probe_scale: 2.0
80
+ diagnostic_interval_steps: 50
81
+ lambda_generator_cov: 1.0
82
+ generator_cov_use_cross: true
83
+ generator_cov_t_min: 0.1
84
+ generator_cov_t_max: 0.6
85
+ generator_cov_delta_scale: 1.0
86
+ generator_cov_num_deltas: 2
87
+ generator_cov_student_chunk_deltas: 1
88
+ generator_cov_teacher_num_deltas: 1
89
+ generator_cov_teacher_reuse_student_delta: true
90
+ generator_cov_teacher_trace_denominator: teacher
91
+ generator_cov_checkpoint: true
92
+ generator_cov_initial_trace_anchor: true
93
+ lambda_gen_local_shape: 1.0
94
+ lambda_gen_cross_shape: 1.0
95
+ lambda_gen_trace_anchor: 0.3
96
+ per_frame_coeff_condition: true
97
+ lambda_motion: 1.0
98
+ lambda_q: 1.0
99
+ lambda_mode_orth: 1.0
100
+ lambda_pca_align: 0.0
101
+ lambda_condition_cycle: 0.0
102
+ oracle_condition: false
103
+ grad_flow_check: true
104
+ log_optimizer_coverage: true
105
+ wandb:
106
+ name: bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700
107
+ project: bbflow
108
+ save_dir: outputs/
109
+ tags: []
110
+ optimizer:
111
+ lr: 0.0001
112
+ reset_optimizer_on_load: false
113
+ warmup_lr: false
114
+ warmup_lr_factor: 0.01
115
+ trainer:
116
+ overfit_batches: 0
117
+ min_epochs: 1
118
+ max_epochs: 10
119
+ accelerator: gpu
120
+ precision: bf16-mixed
121
+ log_every_n_steps: 50
122
+ deterministic: false
123
+ strategy: ddp
124
+ check_val_every_n_epoch: 1
125
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700
126
+ accumulate_grad_batches: 1
127
+ max_steps: -1
128
+ profiler: null
129
+ num_sanity_val_steps: 0
130
+ checkpointer:
131
+ dirpath: ./
132
+ save_last: true
133
+ save_on_train_epoch_end: true
134
+ filename: epoch:{epoch:03d}
135
+ every_n_epochs: 1
136
+ save_top_k: -1
137
+ auto_insert_metric_name: false
138
+ checkpointer2: null
139
+ profiler:
140
+ enabled: false
141
+ modules: null
142
+ profile:
143
+ use_cuda: true
144
+ with_stack: false
145
+ stats:
146
+ group_by_stack_n: 0
147
+ group_by_input_shapes: false
148
+ prefixes:
149
+ - 'layer_0::'
150
+ - 'layer_1::'
151
+ sort_by: cpu_time_total
152
+ scheduler:
153
+ enabled: false
154
+ interpolant:
155
+ use_tqdm: true
156
+ batch_ot: intra
157
+ prior: conditional
158
+ prior_conditional:
159
+ gamma_trans: 0.2
160
+ gamma_rots: 0.2
161
+ min_t: 0.01
162
+ t_interval:
163
+ - 0.0
164
+ - 1.0
165
+ rots:
166
+ distribution: uniform
167
+ train_schedule: linear
168
+ sample_schedule: exp
169
+ exp_rate: 10
170
+ linear_scaling: 1
171
+ trans:
172
+ train_schedule: linear
173
+ sample_schedule: linear
174
+ sampling:
175
+ num_timesteps: 20
176
+ self_condition: true
177
+ noise_res_scaling_power: 0.0
178
+ noise_scale: 1.0
179
+ t_sampling_focus: 0.0
180
+ model:
181
+ node_embed_size: 240
182
+ edge_embed_size: 120
183
+ embed:
184
+ index_embed_type: full
185
+ index_embed_dim: 128
186
+ time_embed_dim: 128
187
+ embed_aatype: true
188
+ aatype_embed_dim: 128
189
+ length_embed_dim: 16
190
+ embed_self_conditioning: true
191
+ num_bins_distance: 22
192
+ min_bin_distance: 1.0e-05
193
+ max_bin_distance: 20.0
194
+ embed_distogram: true
195
+ embed_direction: false
196
+ embed_direction_cutoff: 5
197
+ edge_features:
198
+ self_condition: true
199
+ gfa:
200
+ c_s: 240
201
+ c_z: 120
202
+ c_hidden: 120
203
+ no_heads: 8
204
+ no_qk_points: 8
205
+ no_v_points: 8
206
+ seq_tfmr_num_heads: 4
207
+ seq_tfmr_num_layers: 2
208
+ num_blocks: 6
209
+ latent:
210
+ enable: true
211
+ dim: 16
212
+ num_modes: 8
213
+ motion_message_passing_layers: 4
214
+ cross_cov_near_distance: 12.0
215
+ template_residual_scale: 0.1
216
+ template_remove_rotation: true
217
+ use_enm_features: false
218
+ enm_num_modes: 8
219
+ enm_cutoff: 12.0
220
+ enm_eps: 1.0e-06
221
+ node_cond_dim: 8
222
+ edge_cond_dim: 8
223
+ freeze_foundation: false
224
+ inject_embedder: true
225
+ inject_film: true
226
+ activation_checkpoint: true
227
+ shape_fingerprint_k: 5
228
+ shape_fingerprint_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
229
+ motion_target_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
230
+ z_stochastic: false
231
+ q_sample_temperature: 1.0
232
+ track_condition_debug: false
233
+ mixture_components: 2
234
+ q_lstsq_ridge: 0.0001
235
+ q_cholesky_jitter: 0.0001
236
+ q_detach_projection: true
237
+ q_detach_shared_encoder: false
238
+ energy_from_q: true
239
+ energy_from_q_full_cov: false
240
+ sample_coefficients: true
241
+ pca_align_top_m: 2
242
+ inference:
243
+ name: sweep_ep004
244
+ seed: 123
245
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700/epoch:004.ckpt
246
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference
247
+ use_ckpt_name_in_outpath: true
248
+ use_gpu: true
249
+ num_gpus: 1
250
+ precision: bf16-mixed
251
+ use_tqdm: true
252
+ log_times: true
253
+ z_per_sample: false
254
+ condition_mode: real
255
+ condition_scale: 1.0
256
+ postprocess_bfactors: true
257
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
258
+ sort: false
259
+ num_proteins: null
260
+ num_workers: 0
261
+ min_length: null
262
+ max_length: null
263
+ save_traj: false
264
+ final_only: true
265
+ cache_static_features: true
266
+ single_file: true
267
+ interpolant:
268
+ use_tqdm: true
269
+ min_t: 0.0
270
+ max_t: 0.99
271
+ rots:
272
+ distribution: uniform
273
+ sample_schedule: exp
274
+ exp_rate: 10
275
+ trans:
276
+ sample_schedule: linear
277
+ sampling:
278
+ num_timesteps: 20
279
+ self_condition: true
280
+ prior: conditional
281
+ prior_conditional:
282
+ gamma_trans: 0.2
283
+ gamma_rots: 0.2
284
+ batch_ot: intra
285
+ samples:
286
+ samples_per_protein: 100
287
+ batch_size: 20
288
+ num_res_squared: 2900000
289
+ folding_cfg: null
bbflow_base/lightning_logs/version_45/hparams.yaml ADDED
@@ -0,0 +1,289 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/datasets/ATLAS
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 10
39
+ max_num_res_squared: 120000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /home/wangyusong/LD-FPG-main/bbflow/models/bbflow-0.1/bbflow-0.1.ckpt
48
+ warm_start_cfg_override: false
49
+ use_swa: false
50
+ first_val_epoch: .inf
51
+ reset_epoch: false
52
+ batch_ot:
53
+ enabled: true
54
+ cost: kabsch
55
+ noise_per_sample: 1
56
+ training:
57
+ min_plddt_mask: null
58
+ loss: se3_vf_loss
59
+ bb_atom_scale: 0.1
60
+ trans_scale: 0.1
61
+ translation_loss_weight: 2.0
62
+ t_normalize_clip: 0.9
63
+ rotation_loss_weights: 1.0
64
+ aux_loss_weight: 1.0
65
+ aux_loss_t_pass: 0.75
66
+ t_bins: 4
67
+ ca_distmat_loss_weight: 0.0
68
+ ensemble_group_size: 0
69
+ force_grouped_batch: false
70
+ lambda_shape: 1.0
71
+ lambda_local_cov: 1.0
72
+ lambda_cross_cov: 1.0
73
+ lambda_rmsf: 0.25
74
+ lambda_mode_recon: 0.0
75
+ enm_warmup_epochs: 0
76
+ lambda_enm_warmup: 1.0
77
+ log_latent_batch_debug: false
78
+ epoch_condition_probe: false
79
+ condition_probe_scale: 2.0
80
+ diagnostic_interval_steps: 50
81
+ lambda_generator_cov: 1.0
82
+ generator_cov_use_cross: true
83
+ generator_cov_t_min: 0.1
84
+ generator_cov_t_max: 0.6
85
+ generator_cov_delta_scale: 1.0
86
+ generator_cov_num_deltas: 2
87
+ generator_cov_student_chunk_deltas: 1
88
+ generator_cov_teacher_num_deltas: 1
89
+ generator_cov_teacher_reuse_student_delta: true
90
+ generator_cov_teacher_trace_denominator: teacher
91
+ generator_cov_checkpoint: true
92
+ generator_cov_initial_trace_anchor: true
93
+ lambda_gen_local_shape: 1.0
94
+ lambda_gen_cross_shape: 1.0
95
+ lambda_gen_trace_anchor: 0.3
96
+ per_frame_coeff_condition: true
97
+ lambda_motion: 1.0
98
+ lambda_q: 1.0
99
+ lambda_mode_orth: 1.0
100
+ lambda_pca_align: 0.0
101
+ lambda_condition_cycle: 0.0
102
+ oracle_condition: false
103
+ grad_flow_check: true
104
+ log_optimizer_coverage: true
105
+ wandb:
106
+ name: bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700
107
+ project: bbflow
108
+ save_dir: outputs/
109
+ tags: []
110
+ optimizer:
111
+ lr: 0.0001
112
+ reset_optimizer_on_load: false
113
+ warmup_lr: false
114
+ warmup_lr_factor: 0.01
115
+ trainer:
116
+ overfit_batches: 0
117
+ min_epochs: 1
118
+ max_epochs: 10
119
+ accelerator: gpu
120
+ precision: bf16-mixed
121
+ log_every_n_steps: 50
122
+ deterministic: false
123
+ strategy: ddp
124
+ check_val_every_n_epoch: 1
125
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700
126
+ accumulate_grad_batches: 1
127
+ max_steps: -1
128
+ profiler: null
129
+ num_sanity_val_steps: 0
130
+ checkpointer:
131
+ dirpath: ./
132
+ save_last: true
133
+ save_on_train_epoch_end: true
134
+ filename: epoch:{epoch:03d}
135
+ every_n_epochs: 1
136
+ save_top_k: -1
137
+ auto_insert_metric_name: false
138
+ checkpointer2: null
139
+ profiler:
140
+ enabled: false
141
+ modules: null
142
+ profile:
143
+ use_cuda: true
144
+ with_stack: false
145
+ stats:
146
+ group_by_stack_n: 0
147
+ group_by_input_shapes: false
148
+ prefixes:
149
+ - 'layer_0::'
150
+ - 'layer_1::'
151
+ sort_by: cpu_time_total
152
+ scheduler:
153
+ enabled: false
154
+ interpolant:
155
+ use_tqdm: true
156
+ batch_ot: intra
157
+ prior: conditional
158
+ prior_conditional:
159
+ gamma_trans: 0.2
160
+ gamma_rots: 0.2
161
+ min_t: 0.01
162
+ t_interval:
163
+ - 0.0
164
+ - 1.0
165
+ rots:
166
+ distribution: uniform
167
+ train_schedule: linear
168
+ sample_schedule: exp
169
+ exp_rate: 10
170
+ linear_scaling: 1
171
+ trans:
172
+ train_schedule: linear
173
+ sample_schedule: linear
174
+ sampling:
175
+ num_timesteps: 20
176
+ self_condition: true
177
+ noise_res_scaling_power: 0.0
178
+ noise_scale: 1.0
179
+ t_sampling_focus: 0.0
180
+ model:
181
+ node_embed_size: 240
182
+ edge_embed_size: 120
183
+ embed:
184
+ index_embed_type: full
185
+ index_embed_dim: 128
186
+ time_embed_dim: 128
187
+ embed_aatype: true
188
+ aatype_embed_dim: 128
189
+ length_embed_dim: 16
190
+ embed_self_conditioning: true
191
+ num_bins_distance: 22
192
+ min_bin_distance: 1.0e-05
193
+ max_bin_distance: 20.0
194
+ embed_distogram: true
195
+ embed_direction: false
196
+ embed_direction_cutoff: 5
197
+ edge_features:
198
+ self_condition: true
199
+ gfa:
200
+ c_s: 240
201
+ c_z: 120
202
+ c_hidden: 120
203
+ no_heads: 8
204
+ no_qk_points: 8
205
+ no_v_points: 8
206
+ seq_tfmr_num_heads: 4
207
+ seq_tfmr_num_layers: 2
208
+ num_blocks: 6
209
+ latent:
210
+ enable: true
211
+ dim: 16
212
+ num_modes: 8
213
+ motion_message_passing_layers: 4
214
+ cross_cov_near_distance: 12.0
215
+ template_residual_scale: 0.1
216
+ template_remove_rotation: true
217
+ use_enm_features: false
218
+ enm_num_modes: 8
219
+ enm_cutoff: 12.0
220
+ enm_eps: 1.0e-06
221
+ node_cond_dim: 8
222
+ edge_cond_dim: 8
223
+ freeze_foundation: false
224
+ inject_embedder: true
225
+ inject_film: true
226
+ activation_checkpoint: true
227
+ shape_fingerprint_k: 5
228
+ shape_fingerprint_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
229
+ motion_target_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
230
+ z_stochastic: false
231
+ q_sample_temperature: 1.0
232
+ track_condition_debug: false
233
+ mixture_components: 2
234
+ q_lstsq_ridge: 0.0001
235
+ q_cholesky_jitter: 0.0001
236
+ q_detach_projection: true
237
+ q_detach_shared_encoder: false
238
+ energy_from_q: true
239
+ energy_from_q_full_cov: false
240
+ sample_coefficients: true
241
+ pca_align_top_m: 2
242
+ inference:
243
+ name: sweep_ep000
244
+ seed: 123
245
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700/epoch:000.ckpt
246
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference
247
+ use_ckpt_name_in_outpath: true
248
+ use_gpu: true
249
+ num_gpus: 1
250
+ precision: bf16-mixed
251
+ use_tqdm: true
252
+ log_times: true
253
+ z_per_sample: false
254
+ condition_mode: real
255
+ condition_scale: 1.0
256
+ postprocess_bfactors: true
257
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
258
+ sort: false
259
+ num_proteins: null
260
+ num_workers: 0
261
+ min_length: null
262
+ max_length: null
263
+ save_traj: false
264
+ final_only: true
265
+ cache_static_features: true
266
+ single_file: true
267
+ interpolant:
268
+ use_tqdm: true
269
+ min_t: 0.0
270
+ max_t: 0.99
271
+ rots:
272
+ distribution: uniform
273
+ sample_schedule: exp
274
+ exp_rate: 10
275
+ trans:
276
+ sample_schedule: linear
277
+ sampling:
278
+ num_timesteps: 20
279
+ self_condition: true
280
+ prior: conditional
281
+ prior_conditional:
282
+ gamma_trans: 0.2
283
+ gamma_rots: 0.2
284
+ batch_ot: intra
285
+ samples:
286
+ samples_per_protein: 100
287
+ batch_size: 20
288
+ num_res_squared: 2900000
289
+ folding_cfg: null
bbflow_base/lightning_logs/version_47/hparams.yaml ADDED
@@ -0,0 +1,289 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/datasets/ATLAS
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 10
39
+ max_num_res_squared: 120000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /home/wangyusong/LD-FPG-main/bbflow/models/bbflow-0.1/bbflow-0.1.ckpt
48
+ warm_start_cfg_override: false
49
+ use_swa: false
50
+ first_val_epoch: .inf
51
+ reset_epoch: false
52
+ batch_ot:
53
+ enabled: true
54
+ cost: kabsch
55
+ noise_per_sample: 1
56
+ training:
57
+ min_plddt_mask: null
58
+ loss: se3_vf_loss
59
+ bb_atom_scale: 0.1
60
+ trans_scale: 0.1
61
+ translation_loss_weight: 2.0
62
+ t_normalize_clip: 0.9
63
+ rotation_loss_weights: 1.0
64
+ aux_loss_weight: 1.0
65
+ aux_loss_t_pass: 0.75
66
+ t_bins: 4
67
+ ca_distmat_loss_weight: 0.0
68
+ ensemble_group_size: 0
69
+ force_grouped_batch: false
70
+ lambda_shape: 1.0
71
+ lambda_local_cov: 1.0
72
+ lambda_cross_cov: 1.0
73
+ lambda_rmsf: 0.25
74
+ lambda_mode_recon: 0.0
75
+ enm_warmup_epochs: 0
76
+ lambda_enm_warmup: 1.0
77
+ log_latent_batch_debug: false
78
+ epoch_condition_probe: false
79
+ condition_probe_scale: 2.0
80
+ diagnostic_interval_steps: 50
81
+ lambda_generator_cov: 1.0
82
+ generator_cov_use_cross: true
83
+ generator_cov_t_min: 0.1
84
+ generator_cov_t_max: 0.6
85
+ generator_cov_delta_scale: 1.0
86
+ generator_cov_num_deltas: 2
87
+ generator_cov_student_chunk_deltas: 1
88
+ generator_cov_teacher_num_deltas: 1
89
+ generator_cov_teacher_reuse_student_delta: true
90
+ generator_cov_teacher_trace_denominator: teacher
91
+ generator_cov_checkpoint: true
92
+ generator_cov_initial_trace_anchor: true
93
+ lambda_gen_local_shape: 1.0
94
+ lambda_gen_cross_shape: 1.0
95
+ lambda_gen_trace_anchor: 0.3
96
+ per_frame_coeff_condition: true
97
+ lambda_motion: 1.0
98
+ lambda_q: 1.0
99
+ lambda_mode_orth: 1.0
100
+ lambda_pca_align: 0.0
101
+ lambda_condition_cycle: 0.0
102
+ oracle_condition: false
103
+ grad_flow_check: true
104
+ log_optimizer_coverage: true
105
+ wandb:
106
+ name: bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700
107
+ project: bbflow
108
+ save_dir: outputs/
109
+ tags: []
110
+ optimizer:
111
+ lr: 0.0001
112
+ reset_optimizer_on_load: false
113
+ warmup_lr: false
114
+ warmup_lr_factor: 0.01
115
+ trainer:
116
+ overfit_batches: 0
117
+ min_epochs: 1
118
+ max_epochs: 10
119
+ accelerator: gpu
120
+ precision: bf16-mixed
121
+ log_every_n_steps: 50
122
+ deterministic: false
123
+ strategy: ddp
124
+ check_val_every_n_epoch: 1
125
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700
126
+ accumulate_grad_batches: 1
127
+ max_steps: -1
128
+ profiler: null
129
+ num_sanity_val_steps: 0
130
+ checkpointer:
131
+ dirpath: ./
132
+ save_last: true
133
+ save_on_train_epoch_end: true
134
+ filename: epoch:{epoch:03d}
135
+ every_n_epochs: 1
136
+ save_top_k: -1
137
+ auto_insert_metric_name: false
138
+ checkpointer2: null
139
+ profiler:
140
+ enabled: false
141
+ modules: null
142
+ profile:
143
+ use_cuda: true
144
+ with_stack: false
145
+ stats:
146
+ group_by_stack_n: 0
147
+ group_by_input_shapes: false
148
+ prefixes:
149
+ - 'layer_0::'
150
+ - 'layer_1::'
151
+ sort_by: cpu_time_total
152
+ scheduler:
153
+ enabled: false
154
+ interpolant:
155
+ use_tqdm: true
156
+ batch_ot: intra
157
+ prior: conditional
158
+ prior_conditional:
159
+ gamma_trans: 0.2
160
+ gamma_rots: 0.2
161
+ min_t: 0.01
162
+ t_interval:
163
+ - 0.0
164
+ - 1.0
165
+ rots:
166
+ distribution: uniform
167
+ train_schedule: linear
168
+ sample_schedule: exp
169
+ exp_rate: 10
170
+ linear_scaling: 1
171
+ trans:
172
+ train_schedule: linear
173
+ sample_schedule: linear
174
+ sampling:
175
+ num_timesteps: 20
176
+ self_condition: true
177
+ noise_res_scaling_power: 0.0
178
+ noise_scale: 1.0
179
+ t_sampling_focus: 0.0
180
+ model:
181
+ node_embed_size: 240
182
+ edge_embed_size: 120
183
+ embed:
184
+ index_embed_type: full
185
+ index_embed_dim: 128
186
+ time_embed_dim: 128
187
+ embed_aatype: true
188
+ aatype_embed_dim: 128
189
+ length_embed_dim: 16
190
+ embed_self_conditioning: true
191
+ num_bins_distance: 22
192
+ min_bin_distance: 1.0e-05
193
+ max_bin_distance: 20.0
194
+ embed_distogram: true
195
+ embed_direction: false
196
+ embed_direction_cutoff: 5
197
+ edge_features:
198
+ self_condition: true
199
+ gfa:
200
+ c_s: 240
201
+ c_z: 120
202
+ c_hidden: 120
203
+ no_heads: 8
204
+ no_qk_points: 8
205
+ no_v_points: 8
206
+ seq_tfmr_num_heads: 4
207
+ seq_tfmr_num_layers: 2
208
+ num_blocks: 6
209
+ latent:
210
+ enable: true
211
+ dim: 16
212
+ num_modes: 8
213
+ motion_message_passing_layers: 4
214
+ cross_cov_near_distance: 12.0
215
+ template_residual_scale: 0.1
216
+ template_remove_rotation: true
217
+ use_enm_features: false
218
+ enm_num_modes: 8
219
+ enm_cutoff: 12.0
220
+ enm_eps: 1.0e-06
221
+ node_cond_dim: 8
222
+ edge_cond_dim: 8
223
+ freeze_foundation: false
224
+ inject_embedder: true
225
+ inject_film: true
226
+ activation_checkpoint: true
227
+ shape_fingerprint_k: 5
228
+ shape_fingerprint_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
229
+ motion_target_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
230
+ z_stochastic: false
231
+ q_sample_temperature: 1.0
232
+ track_condition_debug: false
233
+ mixture_components: 2
234
+ q_lstsq_ridge: 0.0001
235
+ q_cholesky_jitter: 0.0001
236
+ q_detach_projection: true
237
+ q_detach_shared_encoder: false
238
+ energy_from_q: true
239
+ energy_from_q_full_cov: false
240
+ sample_coefficients: true
241
+ pca_align_top_m: 2
242
+ inference:
243
+ name: sweep_ep004
244
+ seed: 123
245
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700/epoch:004.ckpt
246
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference
247
+ use_ckpt_name_in_outpath: true
248
+ use_gpu: true
249
+ num_gpus: 1
250
+ precision: bf16-mixed
251
+ use_tqdm: true
252
+ log_times: true
253
+ z_per_sample: false
254
+ condition_mode: real
255
+ condition_scale: 1.0
256
+ postprocess_bfactors: false
257
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
258
+ sort: false
259
+ num_proteins: null
260
+ num_workers: 0
261
+ min_length: null
262
+ max_length: null
263
+ save_traj: false
264
+ final_only: true
265
+ cache_static_features: true
266
+ single_file: true
267
+ interpolant:
268
+ use_tqdm: true
269
+ min_t: 0.0
270
+ max_t: 0.99
271
+ rots:
272
+ distribution: uniform
273
+ sample_schedule: exp
274
+ exp_rate: 10
275
+ trans:
276
+ sample_schedule: linear
277
+ sampling:
278
+ num_timesteps: 20
279
+ self_condition: true
280
+ prior: conditional
281
+ prior_conditional:
282
+ gamma_trans: 0.2
283
+ gamma_rots: 0.2
284
+ batch_ot: intra
285
+ samples:
286
+ samples_per_protein: 100
287
+ batch_size: 20
288
+ num_res_squared: 2900000
289
+ folding_cfg: null
bbflow_base/lightning_logs/version_51/hparams.yaml ADDED
@@ -0,0 +1,289 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/datasets/ATLAS
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 10
39
+ max_num_res_squared: 120000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /home/wangyusong/LD-FPG-main/bbflow/models/bbflow-0.1/bbflow-0.1.ckpt
48
+ warm_start_cfg_override: false
49
+ use_swa: false
50
+ first_val_epoch: .inf
51
+ reset_epoch: false
52
+ batch_ot:
53
+ enabled: true
54
+ cost: kabsch
55
+ noise_per_sample: 1
56
+ training:
57
+ min_plddt_mask: null
58
+ loss: se3_vf_loss
59
+ bb_atom_scale: 0.1
60
+ trans_scale: 0.1
61
+ translation_loss_weight: 2.0
62
+ t_normalize_clip: 0.9
63
+ rotation_loss_weights: 1.0
64
+ aux_loss_weight: 1.0
65
+ aux_loss_t_pass: 0.75
66
+ t_bins: 4
67
+ ca_distmat_loss_weight: 0.0
68
+ ensemble_group_size: 0
69
+ force_grouped_batch: false
70
+ lambda_shape: 1.0
71
+ lambda_local_cov: 1.0
72
+ lambda_cross_cov: 1.0
73
+ lambda_rmsf: 0.25
74
+ lambda_mode_recon: 0.0
75
+ enm_warmup_epochs: 0
76
+ lambda_enm_warmup: 1.0
77
+ log_latent_batch_debug: false
78
+ epoch_condition_probe: false
79
+ condition_probe_scale: 2.0
80
+ diagnostic_interval_steps: 50
81
+ lambda_generator_cov: 1.0
82
+ generator_cov_use_cross: true
83
+ generator_cov_t_min: 0.1
84
+ generator_cov_t_max: 0.6
85
+ generator_cov_delta_scale: 1.0
86
+ generator_cov_num_deltas: 2
87
+ generator_cov_student_chunk_deltas: 1
88
+ generator_cov_teacher_num_deltas: 1
89
+ generator_cov_teacher_reuse_student_delta: true
90
+ generator_cov_teacher_trace_denominator: teacher
91
+ generator_cov_checkpoint: true
92
+ generator_cov_initial_trace_anchor: true
93
+ lambda_gen_local_shape: 1.0
94
+ lambda_gen_cross_shape: 1.0
95
+ lambda_gen_trace_anchor: 0.3
96
+ per_frame_coeff_condition: true
97
+ lambda_motion: 1.0
98
+ lambda_q: 1.0
99
+ lambda_mode_orth: 1.0
100
+ lambda_pca_align: 0.0
101
+ lambda_condition_cycle: 0.0
102
+ oracle_condition: false
103
+ grad_flow_check: true
104
+ log_optimizer_coverage: true
105
+ wandb:
106
+ name: bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700
107
+ project: bbflow
108
+ save_dir: outputs/
109
+ tags: []
110
+ optimizer:
111
+ lr: 0.0001
112
+ reset_optimizer_on_load: false
113
+ warmup_lr: false
114
+ warmup_lr_factor: 0.01
115
+ trainer:
116
+ overfit_batches: 0
117
+ min_epochs: 1
118
+ max_epochs: 10
119
+ accelerator: gpu
120
+ precision: bf16-mixed
121
+ log_every_n_steps: 50
122
+ deterministic: false
123
+ strategy: ddp
124
+ check_val_every_n_epoch: 1
125
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700
126
+ accumulate_grad_batches: 1
127
+ max_steps: -1
128
+ profiler: null
129
+ num_sanity_val_steps: 0
130
+ checkpointer:
131
+ dirpath: ./
132
+ save_last: true
133
+ save_on_train_epoch_end: true
134
+ filename: epoch:{epoch:03d}
135
+ every_n_epochs: 1
136
+ save_top_k: -1
137
+ auto_insert_metric_name: false
138
+ checkpointer2: null
139
+ profiler:
140
+ enabled: false
141
+ modules: null
142
+ profile:
143
+ use_cuda: true
144
+ with_stack: false
145
+ stats:
146
+ group_by_stack_n: 0
147
+ group_by_input_shapes: false
148
+ prefixes:
149
+ - 'layer_0::'
150
+ - 'layer_1::'
151
+ sort_by: cpu_time_total
152
+ scheduler:
153
+ enabled: false
154
+ interpolant:
155
+ use_tqdm: true
156
+ batch_ot: intra
157
+ prior: conditional
158
+ prior_conditional:
159
+ gamma_trans: 0.2
160
+ gamma_rots: 0.2
161
+ min_t: 0.01
162
+ t_interval:
163
+ - 0.0
164
+ - 1.0
165
+ rots:
166
+ distribution: uniform
167
+ train_schedule: linear
168
+ sample_schedule: exp
169
+ exp_rate: 10
170
+ linear_scaling: 1
171
+ trans:
172
+ train_schedule: linear
173
+ sample_schedule: linear
174
+ sampling:
175
+ num_timesteps: 20
176
+ self_condition: true
177
+ noise_res_scaling_power: 0.0
178
+ noise_scale: 1.0
179
+ t_sampling_focus: 0.0
180
+ model:
181
+ node_embed_size: 240
182
+ edge_embed_size: 120
183
+ embed:
184
+ index_embed_type: full
185
+ index_embed_dim: 128
186
+ time_embed_dim: 128
187
+ embed_aatype: true
188
+ aatype_embed_dim: 128
189
+ length_embed_dim: 16
190
+ embed_self_conditioning: true
191
+ num_bins_distance: 22
192
+ min_bin_distance: 1.0e-05
193
+ max_bin_distance: 20.0
194
+ embed_distogram: true
195
+ embed_direction: false
196
+ embed_direction_cutoff: 5
197
+ edge_features:
198
+ self_condition: true
199
+ gfa:
200
+ c_s: 240
201
+ c_z: 120
202
+ c_hidden: 120
203
+ no_heads: 8
204
+ no_qk_points: 8
205
+ no_v_points: 8
206
+ seq_tfmr_num_heads: 4
207
+ seq_tfmr_num_layers: 2
208
+ num_blocks: 6
209
+ latent:
210
+ enable: true
211
+ dim: 16
212
+ num_modes: 8
213
+ motion_message_passing_layers: 4
214
+ cross_cov_near_distance: 12.0
215
+ template_residual_scale: 0.1
216
+ template_remove_rotation: true
217
+ use_enm_features: false
218
+ enm_num_modes: 8
219
+ enm_cutoff: 12.0
220
+ enm_eps: 1.0e-06
221
+ node_cond_dim: 8
222
+ edge_cond_dim: 8
223
+ freeze_foundation: false
224
+ inject_embedder: true
225
+ inject_film: true
226
+ activation_checkpoint: true
227
+ shape_fingerprint_k: 5
228
+ shape_fingerprint_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
229
+ motion_target_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
230
+ z_stochastic: false
231
+ q_sample_temperature: 1.0
232
+ track_condition_debug: false
233
+ mixture_components: 2
234
+ q_lstsq_ridge: 0.0001
235
+ q_cholesky_jitter: 0.0001
236
+ q_detach_projection: true
237
+ q_detach_shared_encoder: false
238
+ energy_from_q: true
239
+ energy_from_q_full_cov: false
240
+ sample_coefficients: true
241
+ pca_align_top_m: 2
242
+ inference:
243
+ name: sweep_ep004
244
+ seed: 123
245
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700/epoch:004.ckpt
246
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference
247
+ use_ckpt_name_in_outpath: true
248
+ use_gpu: true
249
+ num_gpus: 1
250
+ precision: bf16-mixed
251
+ use_tqdm: true
252
+ log_times: true
253
+ z_per_sample: false
254
+ condition_mode: real
255
+ condition_scale: 1.0
256
+ postprocess_bfactors: false
257
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
258
+ sort: false
259
+ num_proteins: null
260
+ num_workers: 0
261
+ min_length: null
262
+ max_length: null
263
+ save_traj: false
264
+ final_only: true
265
+ cache_static_features: true
266
+ single_file: true
267
+ interpolant:
268
+ use_tqdm: true
269
+ min_t: 0.0
270
+ max_t: 0.99
271
+ rots:
272
+ distribution: uniform
273
+ sample_schedule: exp
274
+ exp_rate: 10
275
+ trans:
276
+ sample_schedule: linear
277
+ sampling:
278
+ num_timesteps: 20
279
+ self_condition: true
280
+ prior: conditional
281
+ prior_conditional:
282
+ gamma_trans: 0.2
283
+ gamma_rots: 0.2
284
+ batch_ot: intra
285
+ samples:
286
+ samples_per_protein: 100
287
+ batch_size: 20
288
+ num_res_squared: 2900000
289
+ folding_cfg: null
bbflow_base/lightning_logs/version_55/hparams.yaml ADDED
@@ -0,0 +1,289 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/datasets/ATLAS
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 10
39
+ max_num_res_squared: 120000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /home/wangyusong/LD-FPG-main/bbflow/models/bbflow-0.1/bbflow-0.1.ckpt
48
+ warm_start_cfg_override: false
49
+ use_swa: false
50
+ first_val_epoch: .inf
51
+ reset_epoch: false
52
+ batch_ot:
53
+ enabled: true
54
+ cost: kabsch
55
+ noise_per_sample: 1
56
+ training:
57
+ min_plddt_mask: null
58
+ loss: se3_vf_loss
59
+ bb_atom_scale: 0.1
60
+ trans_scale: 0.1
61
+ translation_loss_weight: 2.0
62
+ t_normalize_clip: 0.9
63
+ rotation_loss_weights: 1.0
64
+ aux_loss_weight: 1.0
65
+ aux_loss_t_pass: 0.75
66
+ t_bins: 4
67
+ ca_distmat_loss_weight: 0.0
68
+ ensemble_group_size: 0
69
+ force_grouped_batch: false
70
+ lambda_shape: 1.0
71
+ lambda_local_cov: 1.0
72
+ lambda_cross_cov: 1.0
73
+ lambda_rmsf: 0.25
74
+ lambda_mode_recon: 0.0
75
+ enm_warmup_epochs: 0
76
+ lambda_enm_warmup: 1.0
77
+ log_latent_batch_debug: false
78
+ epoch_condition_probe: false
79
+ condition_probe_scale: 2.0
80
+ diagnostic_interval_steps: 50
81
+ lambda_generator_cov: 1.0
82
+ generator_cov_use_cross: true
83
+ generator_cov_t_min: 0.1
84
+ generator_cov_t_max: 0.6
85
+ generator_cov_delta_scale: 1.0
86
+ generator_cov_num_deltas: 2
87
+ generator_cov_student_chunk_deltas: 1
88
+ generator_cov_teacher_num_deltas: 1
89
+ generator_cov_teacher_reuse_student_delta: true
90
+ generator_cov_teacher_trace_denominator: teacher
91
+ generator_cov_checkpoint: true
92
+ generator_cov_initial_trace_anchor: true
93
+ lambda_gen_local_shape: 1.0
94
+ lambda_gen_cross_shape: 1.0
95
+ lambda_gen_trace_anchor: 0.3
96
+ per_frame_coeff_condition: true
97
+ lambda_motion: 1.0
98
+ lambda_q: 1.0
99
+ lambda_mode_orth: 1.0
100
+ lambda_pca_align: 0.0
101
+ lambda_condition_cycle: 0.0
102
+ oracle_condition: false
103
+ grad_flow_check: true
104
+ log_optimizer_coverage: true
105
+ wandb:
106
+ name: bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700
107
+ project: bbflow
108
+ save_dir: outputs/
109
+ tags: []
110
+ optimizer:
111
+ lr: 0.0001
112
+ reset_optimizer_on_load: false
113
+ warmup_lr: false
114
+ warmup_lr_factor: 0.01
115
+ trainer:
116
+ overfit_batches: 0
117
+ min_epochs: 1
118
+ max_epochs: 10
119
+ accelerator: gpu
120
+ precision: bf16-mixed
121
+ log_every_n_steps: 50
122
+ deterministic: false
123
+ strategy: ddp
124
+ check_val_every_n_epoch: 1
125
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700
126
+ accumulate_grad_batches: 1
127
+ max_steps: -1
128
+ profiler: null
129
+ num_sanity_val_steps: 0
130
+ checkpointer:
131
+ dirpath: ./
132
+ save_last: true
133
+ save_on_train_epoch_end: true
134
+ filename: epoch:{epoch:03d}
135
+ every_n_epochs: 1
136
+ save_top_k: -1
137
+ auto_insert_metric_name: false
138
+ checkpointer2: null
139
+ profiler:
140
+ enabled: false
141
+ modules: null
142
+ profile:
143
+ use_cuda: true
144
+ with_stack: false
145
+ stats:
146
+ group_by_stack_n: 0
147
+ group_by_input_shapes: false
148
+ prefixes:
149
+ - 'layer_0::'
150
+ - 'layer_1::'
151
+ sort_by: cpu_time_total
152
+ scheduler:
153
+ enabled: false
154
+ interpolant:
155
+ use_tqdm: true
156
+ batch_ot: intra
157
+ prior: conditional
158
+ prior_conditional:
159
+ gamma_trans: 0.2
160
+ gamma_rots: 0.2
161
+ min_t: 0.01
162
+ t_interval:
163
+ - 0.0
164
+ - 1.0
165
+ rots:
166
+ distribution: uniform
167
+ train_schedule: linear
168
+ sample_schedule: exp
169
+ exp_rate: 10
170
+ linear_scaling: 1
171
+ trans:
172
+ train_schedule: linear
173
+ sample_schedule: linear
174
+ sampling:
175
+ num_timesteps: 20
176
+ self_condition: true
177
+ noise_res_scaling_power: 0.0
178
+ noise_scale: 1.0
179
+ t_sampling_focus: 0.0
180
+ model:
181
+ node_embed_size: 240
182
+ edge_embed_size: 120
183
+ embed:
184
+ index_embed_type: full
185
+ index_embed_dim: 128
186
+ time_embed_dim: 128
187
+ embed_aatype: true
188
+ aatype_embed_dim: 128
189
+ length_embed_dim: 16
190
+ embed_self_conditioning: true
191
+ num_bins_distance: 22
192
+ min_bin_distance: 1.0e-05
193
+ max_bin_distance: 20.0
194
+ embed_distogram: true
195
+ embed_direction: false
196
+ embed_direction_cutoff: 5
197
+ edge_features:
198
+ self_condition: true
199
+ gfa:
200
+ c_s: 240
201
+ c_z: 120
202
+ c_hidden: 120
203
+ no_heads: 8
204
+ no_qk_points: 8
205
+ no_v_points: 8
206
+ seq_tfmr_num_heads: 4
207
+ seq_tfmr_num_layers: 2
208
+ num_blocks: 6
209
+ latent:
210
+ enable: true
211
+ dim: 16
212
+ num_modes: 8
213
+ motion_message_passing_layers: 4
214
+ cross_cov_near_distance: 12.0
215
+ template_residual_scale: 0.1
216
+ template_remove_rotation: true
217
+ use_enm_features: false
218
+ enm_num_modes: 8
219
+ enm_cutoff: 12.0
220
+ enm_eps: 1.0e-06
221
+ node_cond_dim: 8
222
+ edge_cond_dim: 8
223
+ freeze_foundation: false
224
+ inject_embedder: true
225
+ inject_film: true
226
+ activation_checkpoint: true
227
+ shape_fingerprint_k: 5
228
+ shape_fingerprint_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
229
+ motion_target_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
230
+ z_stochastic: false
231
+ q_sample_temperature: 1.0
232
+ track_condition_debug: false
233
+ mixture_components: 2
234
+ q_lstsq_ridge: 0.0001
235
+ q_cholesky_jitter: 0.0001
236
+ q_detach_projection: true
237
+ q_detach_shared_encoder: false
238
+ energy_from_q: true
239
+ energy_from_q_full_cov: false
240
+ sample_coefficients: true
241
+ pca_align_top_m: 2
242
+ inference:
243
+ name: sweep_ep004
244
+ seed: 123
245
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700/epoch:004.ckpt
246
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference
247
+ use_ckpt_name_in_outpath: true
248
+ use_gpu: true
249
+ num_gpus: 1
250
+ precision: 32-true
251
+ use_tqdm: true
252
+ log_times: true
253
+ z_per_sample: false
254
+ condition_mode: real
255
+ condition_scale: 1.0
256
+ postprocess_bfactors: false
257
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
258
+ sort: false
259
+ num_proteins: null
260
+ num_workers: 0
261
+ min_length: null
262
+ max_length: null
263
+ save_traj: false
264
+ final_only: true
265
+ cache_static_features: true
266
+ single_file: true
267
+ interpolant:
268
+ use_tqdm: true
269
+ min_t: 0.0
270
+ max_t: 0.99
271
+ rots:
272
+ distribution: uniform
273
+ sample_schedule: exp
274
+ exp_rate: 10
275
+ trans:
276
+ sample_schedule: linear
277
+ sampling:
278
+ num_timesteps: 20
279
+ self_condition: true
280
+ prior: conditional
281
+ prior_conditional:
282
+ gamma_trans: 0.2
283
+ gamma_rots: 0.2
284
+ batch_ot: intra
285
+ samples:
286
+ samples_per_protein: 100
287
+ batch_size: 20
288
+ num_res_squared: 2900000
289
+ folding_cfg: null
bbflow_base/lightning_logs/version_56/hparams.yaml ADDED
@@ -0,0 +1,289 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/datasets/ATLAS
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 10
39
+ max_num_res_squared: 120000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /home/wangyusong/LD-FPG-main/bbflow/models/bbflow-0.1/bbflow-0.1.ckpt
48
+ warm_start_cfg_override: false
49
+ use_swa: false
50
+ first_val_epoch: .inf
51
+ reset_epoch: false
52
+ batch_ot:
53
+ enabled: true
54
+ cost: kabsch
55
+ noise_per_sample: 1
56
+ training:
57
+ min_plddt_mask: null
58
+ loss: se3_vf_loss
59
+ bb_atom_scale: 0.1
60
+ trans_scale: 0.1
61
+ translation_loss_weight: 2.0
62
+ t_normalize_clip: 0.9
63
+ rotation_loss_weights: 1.0
64
+ aux_loss_weight: 1.0
65
+ aux_loss_t_pass: 0.75
66
+ t_bins: 4
67
+ ca_distmat_loss_weight: 0.0
68
+ ensemble_group_size: 0
69
+ force_grouped_batch: false
70
+ lambda_shape: 1.0
71
+ lambda_local_cov: 1.0
72
+ lambda_cross_cov: 1.0
73
+ lambda_rmsf: 0.25
74
+ lambda_mode_recon: 0.0
75
+ enm_warmup_epochs: 0
76
+ lambda_enm_warmup: 1.0
77
+ log_latent_batch_debug: false
78
+ epoch_condition_probe: false
79
+ condition_probe_scale: 2.0
80
+ diagnostic_interval_steps: 50
81
+ lambda_generator_cov: 1.0
82
+ generator_cov_use_cross: true
83
+ generator_cov_t_min: 0.1
84
+ generator_cov_t_max: 0.6
85
+ generator_cov_delta_scale: 1.0
86
+ generator_cov_num_deltas: 2
87
+ generator_cov_student_chunk_deltas: 1
88
+ generator_cov_teacher_num_deltas: 1
89
+ generator_cov_teacher_reuse_student_delta: true
90
+ generator_cov_teacher_trace_denominator: teacher
91
+ generator_cov_checkpoint: true
92
+ generator_cov_initial_trace_anchor: true
93
+ lambda_gen_local_shape: 1.0
94
+ lambda_gen_cross_shape: 1.0
95
+ lambda_gen_trace_anchor: 0.3
96
+ per_frame_coeff_condition: true
97
+ lambda_motion: 1.0
98
+ lambda_q: 1.0
99
+ lambda_mode_orth: 1.0
100
+ lambda_pca_align: 0.0
101
+ lambda_condition_cycle: 0.0
102
+ oracle_condition: false
103
+ grad_flow_check: true
104
+ log_optimizer_coverage: true
105
+ wandb:
106
+ name: bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700
107
+ project: bbflow
108
+ save_dir: outputs/
109
+ tags: []
110
+ optimizer:
111
+ lr: 0.0001
112
+ reset_optimizer_on_load: false
113
+ warmup_lr: false
114
+ warmup_lr_factor: 0.01
115
+ trainer:
116
+ overfit_batches: 0
117
+ min_epochs: 1
118
+ max_epochs: 10
119
+ accelerator: gpu
120
+ precision: bf16-mixed
121
+ log_every_n_steps: 50
122
+ deterministic: false
123
+ strategy: ddp
124
+ check_val_every_n_epoch: 1
125
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700
126
+ accumulate_grad_batches: 1
127
+ max_steps: -1
128
+ profiler: null
129
+ num_sanity_val_steps: 0
130
+ checkpointer:
131
+ dirpath: ./
132
+ save_last: true
133
+ save_on_train_epoch_end: true
134
+ filename: epoch:{epoch:03d}
135
+ every_n_epochs: 1
136
+ save_top_k: -1
137
+ auto_insert_metric_name: false
138
+ checkpointer2: null
139
+ profiler:
140
+ enabled: false
141
+ modules: null
142
+ profile:
143
+ use_cuda: true
144
+ with_stack: false
145
+ stats:
146
+ group_by_stack_n: 0
147
+ group_by_input_shapes: false
148
+ prefixes:
149
+ - 'layer_0::'
150
+ - 'layer_1::'
151
+ sort_by: cpu_time_total
152
+ scheduler:
153
+ enabled: false
154
+ interpolant:
155
+ use_tqdm: true
156
+ batch_ot: intra
157
+ prior: conditional
158
+ prior_conditional:
159
+ gamma_trans: 0.2
160
+ gamma_rots: 0.2
161
+ min_t: 0.01
162
+ t_interval:
163
+ - 0.0
164
+ - 1.0
165
+ rots:
166
+ distribution: uniform
167
+ train_schedule: linear
168
+ sample_schedule: exp
169
+ exp_rate: 10
170
+ linear_scaling: 1
171
+ trans:
172
+ train_schedule: linear
173
+ sample_schedule: linear
174
+ sampling:
175
+ num_timesteps: 20
176
+ self_condition: true
177
+ noise_res_scaling_power: 0.0
178
+ noise_scale: 1.0
179
+ t_sampling_focus: 0.0
180
+ model:
181
+ node_embed_size: 240
182
+ edge_embed_size: 120
183
+ embed:
184
+ index_embed_type: full
185
+ index_embed_dim: 128
186
+ time_embed_dim: 128
187
+ embed_aatype: true
188
+ aatype_embed_dim: 128
189
+ length_embed_dim: 16
190
+ embed_self_conditioning: true
191
+ num_bins_distance: 22
192
+ min_bin_distance: 1.0e-05
193
+ max_bin_distance: 20.0
194
+ embed_distogram: true
195
+ embed_direction: false
196
+ embed_direction_cutoff: 5
197
+ edge_features:
198
+ self_condition: true
199
+ gfa:
200
+ c_s: 240
201
+ c_z: 120
202
+ c_hidden: 120
203
+ no_heads: 8
204
+ no_qk_points: 8
205
+ no_v_points: 8
206
+ seq_tfmr_num_heads: 4
207
+ seq_tfmr_num_layers: 2
208
+ num_blocks: 6
209
+ latent:
210
+ enable: true
211
+ dim: 16
212
+ num_modes: 8
213
+ motion_message_passing_layers: 4
214
+ cross_cov_near_distance: 12.0
215
+ template_residual_scale: 0.1
216
+ template_remove_rotation: true
217
+ use_enm_features: false
218
+ enm_num_modes: 8
219
+ enm_cutoff: 12.0
220
+ enm_eps: 1.0e-06
221
+ node_cond_dim: 8
222
+ edge_cond_dim: 8
223
+ freeze_foundation: false
224
+ inject_embedder: true
225
+ inject_film: true
226
+ activation_checkpoint: true
227
+ shape_fingerprint_k: 5
228
+ shape_fingerprint_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
229
+ motion_target_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
230
+ z_stochastic: false
231
+ q_sample_temperature: 1.0
232
+ track_condition_debug: false
233
+ mixture_components: 2
234
+ q_lstsq_ridge: 0.0001
235
+ q_cholesky_jitter: 0.0001
236
+ q_detach_projection: true
237
+ q_detach_shared_encoder: false
238
+ energy_from_q: true
239
+ energy_from_q_full_cov: false
240
+ sample_coefficients: true
241
+ pca_align_top_m: 2
242
+ inference:
243
+ name: sweep_ep000
244
+ seed: 123
245
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700/epoch:000.ckpt
246
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference
247
+ use_ckpt_name_in_outpath: true
248
+ use_gpu: true
249
+ num_gpus: 1
250
+ precision: 32-true
251
+ use_tqdm: true
252
+ log_times: true
253
+ z_per_sample: false
254
+ condition_mode: real
255
+ condition_scale: 1.0
256
+ postprocess_bfactors: false
257
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
258
+ sort: false
259
+ num_proteins: null
260
+ num_workers: 0
261
+ min_length: null
262
+ max_length: null
263
+ save_traj: false
264
+ final_only: true
265
+ cache_static_features: true
266
+ single_file: true
267
+ interpolant:
268
+ use_tqdm: true
269
+ min_t: 0.0
270
+ max_t: 0.99
271
+ rots:
272
+ distribution: uniform
273
+ sample_schedule: exp
274
+ exp_rate: 10
275
+ trans:
276
+ sample_schedule: linear
277
+ sampling:
278
+ num_timesteps: 20
279
+ self_condition: true
280
+ prior: conditional
281
+ prior_conditional:
282
+ gamma_trans: 0.2
283
+ gamma_rots: 0.2
284
+ batch_ot: intra
285
+ samples:
286
+ samples_per_protein: 100
287
+ batch_size: 20
288
+ num_res_squared: 2900000
289
+ folding_cfg: null
bbflow_base/lightning_logs/version_57/hparams.yaml ADDED
@@ -0,0 +1,289 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/datasets/ATLAS
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 10
39
+ max_num_res_squared: 120000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /home/wangyusong/LD-FPG-main/bbflow/models/bbflow-0.1/bbflow-0.1.ckpt
48
+ warm_start_cfg_override: false
49
+ use_swa: false
50
+ first_val_epoch: .inf
51
+ reset_epoch: false
52
+ batch_ot:
53
+ enabled: true
54
+ cost: kabsch
55
+ noise_per_sample: 1
56
+ training:
57
+ min_plddt_mask: null
58
+ loss: se3_vf_loss
59
+ bb_atom_scale: 0.1
60
+ trans_scale: 0.1
61
+ translation_loss_weight: 2.0
62
+ t_normalize_clip: 0.9
63
+ rotation_loss_weights: 1.0
64
+ aux_loss_weight: 1.0
65
+ aux_loss_t_pass: 0.75
66
+ t_bins: 4
67
+ ca_distmat_loss_weight: 0.0
68
+ ensemble_group_size: 0
69
+ force_grouped_batch: false
70
+ lambda_shape: 1.0
71
+ lambda_local_cov: 1.0
72
+ lambda_cross_cov: 1.0
73
+ lambda_rmsf: 0.25
74
+ lambda_mode_recon: 0.0
75
+ enm_warmup_epochs: 0
76
+ lambda_enm_warmup: 1.0
77
+ log_latent_batch_debug: false
78
+ epoch_condition_probe: false
79
+ condition_probe_scale: 2.0
80
+ diagnostic_interval_steps: 50
81
+ lambda_generator_cov: 1.0
82
+ generator_cov_use_cross: true
83
+ generator_cov_t_min: 0.1
84
+ generator_cov_t_max: 0.6
85
+ generator_cov_delta_scale: 1.0
86
+ generator_cov_num_deltas: 2
87
+ generator_cov_student_chunk_deltas: 1
88
+ generator_cov_teacher_num_deltas: 1
89
+ generator_cov_teacher_reuse_student_delta: true
90
+ generator_cov_teacher_trace_denominator: teacher
91
+ generator_cov_checkpoint: true
92
+ generator_cov_initial_trace_anchor: true
93
+ lambda_gen_local_shape: 1.0
94
+ lambda_gen_cross_shape: 1.0
95
+ lambda_gen_trace_anchor: 0.3
96
+ per_frame_coeff_condition: true
97
+ lambda_motion: 1.0
98
+ lambda_q: 1.0
99
+ lambda_mode_orth: 1.0
100
+ lambda_pca_align: 0.0
101
+ lambda_condition_cycle: 0.0
102
+ oracle_condition: false
103
+ grad_flow_check: true
104
+ log_optimizer_coverage: true
105
+ wandb:
106
+ name: bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700
107
+ project: bbflow
108
+ save_dir: outputs/
109
+ tags: []
110
+ optimizer:
111
+ lr: 0.0001
112
+ reset_optimizer_on_load: false
113
+ warmup_lr: false
114
+ warmup_lr_factor: 0.01
115
+ trainer:
116
+ overfit_batches: 0
117
+ min_epochs: 1
118
+ max_epochs: 10
119
+ accelerator: gpu
120
+ precision: bf16-mixed
121
+ log_every_n_steps: 50
122
+ deterministic: false
123
+ strategy: ddp
124
+ check_val_every_n_epoch: 1
125
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700
126
+ accumulate_grad_batches: 1
127
+ max_steps: -1
128
+ profiler: null
129
+ num_sanity_val_steps: 0
130
+ checkpointer:
131
+ dirpath: ./
132
+ save_last: true
133
+ save_on_train_epoch_end: true
134
+ filename: epoch:{epoch:03d}
135
+ every_n_epochs: 1
136
+ save_top_k: -1
137
+ auto_insert_metric_name: false
138
+ checkpointer2: null
139
+ profiler:
140
+ enabled: false
141
+ modules: null
142
+ profile:
143
+ use_cuda: true
144
+ with_stack: false
145
+ stats:
146
+ group_by_stack_n: 0
147
+ group_by_input_shapes: false
148
+ prefixes:
149
+ - 'layer_0::'
150
+ - 'layer_1::'
151
+ sort_by: cpu_time_total
152
+ scheduler:
153
+ enabled: false
154
+ interpolant:
155
+ use_tqdm: true
156
+ batch_ot: intra
157
+ prior: conditional
158
+ prior_conditional:
159
+ gamma_trans: 0.2
160
+ gamma_rots: 0.2
161
+ min_t: 0.01
162
+ t_interval:
163
+ - 0.0
164
+ - 1.0
165
+ rots:
166
+ distribution: uniform
167
+ train_schedule: linear
168
+ sample_schedule: exp
169
+ exp_rate: 10
170
+ linear_scaling: 1
171
+ trans:
172
+ train_schedule: linear
173
+ sample_schedule: linear
174
+ sampling:
175
+ num_timesteps: 20
176
+ self_condition: true
177
+ noise_res_scaling_power: 0.0
178
+ noise_scale: 1.0
179
+ t_sampling_focus: 0.0
180
+ model:
181
+ node_embed_size: 240
182
+ edge_embed_size: 120
183
+ embed:
184
+ index_embed_type: full
185
+ index_embed_dim: 128
186
+ time_embed_dim: 128
187
+ embed_aatype: true
188
+ aatype_embed_dim: 128
189
+ length_embed_dim: 16
190
+ embed_self_conditioning: true
191
+ num_bins_distance: 22
192
+ min_bin_distance: 1.0e-05
193
+ max_bin_distance: 20.0
194
+ embed_distogram: true
195
+ embed_direction: false
196
+ embed_direction_cutoff: 5
197
+ edge_features:
198
+ self_condition: true
199
+ gfa:
200
+ c_s: 240
201
+ c_z: 120
202
+ c_hidden: 120
203
+ no_heads: 8
204
+ no_qk_points: 8
205
+ no_v_points: 8
206
+ seq_tfmr_num_heads: 4
207
+ seq_tfmr_num_layers: 2
208
+ num_blocks: 6
209
+ latent:
210
+ enable: true
211
+ dim: 16
212
+ num_modes: 8
213
+ motion_message_passing_layers: 4
214
+ cross_cov_near_distance: 12.0
215
+ template_residual_scale: 0.1
216
+ template_remove_rotation: true
217
+ use_enm_features: false
218
+ enm_num_modes: 8
219
+ enm_cutoff: 12.0
220
+ enm_eps: 1.0e-06
221
+ node_cond_dim: 8
222
+ edge_cond_dim: 8
223
+ freeze_foundation: false
224
+ inject_embedder: true
225
+ inject_film: true
226
+ activation_checkpoint: true
227
+ shape_fingerprint_k: 5
228
+ shape_fingerprint_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
229
+ motion_target_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
230
+ z_stochastic: false
231
+ q_sample_temperature: 1.0
232
+ track_condition_debug: false
233
+ mixture_components: 2
234
+ q_lstsq_ridge: 0.0001
235
+ q_cholesky_jitter: 0.0001
236
+ q_detach_projection: true
237
+ q_detach_shared_encoder: false
238
+ energy_from_q: true
239
+ energy_from_q_full_cov: false
240
+ sample_coefficients: true
241
+ pca_align_top_m: 2
242
+ inference:
243
+ name: sweep_ep002
244
+ seed: 123
245
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700/epoch:002.ckpt
246
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference
247
+ use_ckpt_name_in_outpath: true
248
+ use_gpu: true
249
+ num_gpus: 1
250
+ precision: 32-true
251
+ use_tqdm: true
252
+ log_times: true
253
+ z_per_sample: false
254
+ condition_mode: real
255
+ condition_scale: 1.0
256
+ postprocess_bfactors: false
257
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
258
+ sort: false
259
+ num_proteins: null
260
+ num_workers: 0
261
+ min_length: null
262
+ max_length: null
263
+ save_traj: false
264
+ final_only: true
265
+ cache_static_features: true
266
+ single_file: true
267
+ interpolant:
268
+ use_tqdm: true
269
+ min_t: 0.0
270
+ max_t: 0.99
271
+ rots:
272
+ distribution: uniform
273
+ sample_schedule: exp
274
+ exp_rate: 10
275
+ trans:
276
+ sample_schedule: linear
277
+ sampling:
278
+ num_timesteps: 20
279
+ self_condition: true
280
+ prior: conditional
281
+ prior_conditional:
282
+ gamma_trans: 0.2
283
+ gamma_rots: 0.2
284
+ batch_ot: intra
285
+ samples:
286
+ samples_per_protein: 100
287
+ batch_size: 20
288
+ num_res_squared: 2900000
289
+ folding_cfg: null
bbflow_base/lightning_logs/version_58/hparams.yaml ADDED
@@ -0,0 +1,281 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 730
7
+ subset: null
8
+ split_path: ./
9
+ train_csv_path: ../datasets/BBFlow/train/alphaflow_atlas_train_full_traj.csv
10
+ valid_csv_paths:
11
+ - ../datasets/BBFlow/validation/ATLAS_valid.csv
12
+ valid_dataset_names:
13
+ - ATLAS_valid
14
+ test_csv_path: ../datasets/BBFlow/test/alphaflow_atlas_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - Ramachandran-W2
20
+ - DCCM
21
+ - RMWD
22
+ - PCA-W2
23
+ - Cosine Sim
24
+ - Weak Transient Contacts
25
+ valid_xtc_paths:
26
+ - ../datasets/ATLAS/ATLAS_valid_xtc/
27
+ alphaflow_valid_pdb_paths:
28
+ - ../datasets/ATLAS/alphaflow_valid_pdb/
29
+ alphaflow_valid_rmsf_path: .//alphaflow_rmsf.json
30
+ samples_per_valid_protein: 10
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ alphaflow_valid_local_rmsf_path: .//alphaflow_local_rmsf.json
34
+ loader:
35
+ num_workers: 8
36
+ prefetch_factor: 10
37
+ pin_memory: false
38
+ sampler:
39
+ max_batch_size: 100
40
+ max_num_res_squared: 250000
41
+ max_conformations: 20
42
+ experiment:
43
+ debug: false
44
+ use_wandb: true
45
+ use_tqdm: false
46
+ seed: 123
47
+ num_devices: 2
48
+ warm_start: null
49
+ warm_start_cfg_override: true
50
+ use_swa: false
51
+ first_val_epoch: 40
52
+ reset_epoch: false
53
+ batch_ot:
54
+ enabled: true
55
+ cost: kabsch
56
+ noise_per_sample: 1
57
+ training:
58
+ min_plddt_mask: null
59
+ loss: se3_vf_loss
60
+ bb_atom_scale: 0.1
61
+ trans_scale: 0.1
62
+ translation_loss_weight: 2.0
63
+ t_normalize_clip: 0.9
64
+ rotation_loss_weights: 1.0
65
+ aux_loss_weight: 1.0
66
+ aux_loss_t_pass: 0.25
67
+ t_bins: 4
68
+ ca_distmat_loss_weight: 0.0
69
+ ensemble_group_size: 0
70
+ force_grouped_batch: false
71
+ lambda_shape: 1.0
72
+ lambda_local_cov: 1.0
73
+ lambda_cross_cov: 1.0
74
+ lambda_rmsf: 0.25
75
+ lambda_mode_recon: 0.0
76
+ enm_warmup_epochs: 0
77
+ lambda_enm_warmup: 1.0
78
+ log_latent_batch_debug: false
79
+ epoch_condition_probe: true
80
+ condition_probe_scale: 2.0
81
+ diagnostic_interval_steps: 50
82
+ lambda_generator_cov: 0.0
83
+ generator_cov_use_cross: false
84
+ generator_cov_t_min: 0.1
85
+ generator_cov_t_max: 0.6
86
+ generator_cov_delta_scale: 1.0
87
+ generator_cov_num_deltas: 2
88
+ generator_cov_student_chunk_deltas: 1
89
+ generator_cov_teacher_num_deltas: 1
90
+ generator_cov_teacher_reuse_student_delta: true
91
+ generator_cov_teacher_trace_denominator: teacher
92
+ generator_cov_checkpoint: false
93
+ generator_cov_initial_trace_anchor: true
94
+ lambda_gen_local_shape: 1.0
95
+ lambda_gen_cross_shape: 1.0
96
+ lambda_gen_trace_anchor: 0.05
97
+ wandb:
98
+ name: rt02_noDir
99
+ project: bbflow
100
+ save_dir: outputs/
101
+ tags: []
102
+ optimizer:
103
+ lr: 0.0001
104
+ reset_optimizer_on_load: false
105
+ warmup_lr: false
106
+ warmup_lr_factor: 0.01
107
+ trainer:
108
+ overfit_batches: 0
109
+ min_epochs: 1
110
+ max_epochs: 250
111
+ accelerator: gpu
112
+ precision: bf16-mixed
113
+ log_every_n_steps: 1
114
+ deterministic: false
115
+ strategy: ddp
116
+ check_val_every_n_epoch: 1
117
+ default_root_dir: outputs/
118
+ accumulate_grad_batches: 1
119
+ checkpointer:
120
+ dirpath: ./
121
+ save_last: true
122
+ save_on_train_epoch_end: true
123
+ filename: epoch:{epoch:03d}
124
+ every_n_epochs: 1
125
+ save_top_k: -1
126
+ auto_insert_metric_name: false
127
+ checkpointer2: null
128
+ profiler:
129
+ enabled: false
130
+ modules: null
131
+ profile:
132
+ use_cuda: true
133
+ with_stack: false
134
+ stats:
135
+ group_by_stack_n: 0
136
+ group_by_input_shapes: false
137
+ prefixes:
138
+ - 'layer_0::'
139
+ - 'layer_1::'
140
+ sort_by: cpu_time_total
141
+ scheduler:
142
+ enabled: false
143
+ interpolant:
144
+ use_tqdm: false
145
+ batch_ot: intra
146
+ prior: conditional
147
+ prior_conditional:
148
+ gamma_trans: 0.2
149
+ gamma_rots: 0.2
150
+ min_t: 0.01
151
+ t_interval:
152
+ - 0.0
153
+ - 1.0
154
+ rots:
155
+ distribution: uniform
156
+ train_schedule: linear
157
+ sample_schedule: exp
158
+ exp_rate: 10
159
+ linear_scaling: 1
160
+ trans:
161
+ train_schedule: linear
162
+ sample_schedule: linear
163
+ sampling:
164
+ num_timesteps: 20
165
+ self_condition: true
166
+ noise_res_scaling_power: 0.0
167
+ noise_scale: 1.0
168
+ t_sampling_focus: 0.0
169
+ model:
170
+ node_embed_size: 240
171
+ edge_embed_size: 120
172
+ embed:
173
+ index_embed_dim: 128
174
+ time_embed_dim: 128
175
+ embed_aatype: true
176
+ aatype_embed_dim: 128
177
+ length_embed_dim: 16
178
+ embed_self_conditioning: true
179
+ num_bins_distance: 22
180
+ min_bin_distance: 1.0e-05
181
+ max_bin_distance: 20.0
182
+ embed_distogram: true
183
+ embed_direction: false
184
+ edge_features:
185
+ self_condition: true
186
+ single_bias_transition_n: 2
187
+ c_s: 240
188
+ c_p: 120
189
+ relpos_k: 64
190
+ use_rbf: true
191
+ num_rbf: 32
192
+ feat_dim: 64
193
+ num_bins: 22
194
+ embed_breaks: true
195
+ gfa:
196
+ c_s: 240
197
+ c_z: 120
198
+ c_hidden: 120
199
+ no_heads: 8
200
+ no_qk_points: 8
201
+ no_v_points: 8
202
+ seq_tfmr_num_heads: 4
203
+ seq_tfmr_num_layers: 2
204
+ num_blocks: 6
205
+ node_features:
206
+ c_s: 240
207
+ c_pos_emb: 120
208
+ c_timestep_emb: 120
209
+ embed_diffuse_mask: false
210
+ max_num_res: 2000
211
+ timestep_int: 1000
212
+ latent:
213
+ enable: false
214
+ dim: 16
215
+ num_modes: 8
216
+ motion_message_passing_layers: 4
217
+ cross_cov_near_distance: 12.0
218
+ template_residual_scale: 0.1
219
+ template_remove_rotation: true
220
+ use_enm_features: false
221
+ enm_num_modes: 8
222
+ enm_cutoff: 12.0
223
+ enm_eps: 1.0e-06
224
+ node_cond_dim: 8
225
+ edge_cond_dim: 8
226
+ freeze_foundation: true
227
+ inject_embedder: true
228
+ inject_film: true
229
+ activation_checkpoint: true
230
+ shape_fingerprint_k: 5
231
+ shape_fingerprint_cache_path: null
232
+ motion_target_cache_path: null
233
+ z_stochastic: false
234
+ inference:
235
+ name: control_official
236
+ seed: 123
237
+ ckpt_path: /home/wangyusong/LD-FPG-main/bbflow/models/bbflow-0.1/bbflow-0.1.ckpt
238
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference
239
+ use_ckpt_name_in_outpath: true
240
+ use_gpu: true
241
+ num_gpus: 1
242
+ precision: 32-true
243
+ use_tqdm: true
244
+ log_times: false
245
+ z_per_sample: false
246
+ condition_mode: real
247
+ condition_scale: 1.0
248
+ postprocess_bfactors: true
249
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
250
+ sort: false
251
+ num_proteins: null
252
+ num_workers: 2
253
+ min_length: null
254
+ max_length: null
255
+ save_traj: false
256
+ final_only: true
257
+ cache_static_features: true
258
+ single_file: true
259
+ interpolant:
260
+ use_tqdm: true
261
+ min_t: 0.0
262
+ max_t: 0.99
263
+ rots:
264
+ distribution: uniform
265
+ sample_schedule: exp
266
+ exp_rate: 10
267
+ trans:
268
+ sample_schedule: linear
269
+ sampling:
270
+ num_timesteps: 20
271
+ self_condition: true
272
+ prior: conditional
273
+ prior_conditional:
274
+ gamma_trans: 0.2
275
+ gamma_rots: 0.2
276
+ batch_ot: intra
277
+ samples:
278
+ samples_per_protein: 100
279
+ batch_size: 20
280
+ num_res_squared: 2900000
281
+ folding_cfg: null
bbflow_base/lightning_logs/version_59/hparams.yaml ADDED
@@ -0,0 +1,281 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 730
7
+ subset: null
8
+ split_path: ./
9
+ train_csv_path: ../datasets/BBFlow/train/alphaflow_atlas_train_full_traj.csv
10
+ valid_csv_paths:
11
+ - ../datasets/BBFlow/validation/ATLAS_valid.csv
12
+ valid_dataset_names:
13
+ - ATLAS_valid
14
+ test_csv_path: ../datasets/BBFlow/test/alphaflow_atlas_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - Ramachandran-W2
20
+ - DCCM
21
+ - RMWD
22
+ - PCA-W2
23
+ - Cosine Sim
24
+ - Weak Transient Contacts
25
+ valid_xtc_paths:
26
+ - ../datasets/ATLAS/ATLAS_valid_xtc/
27
+ alphaflow_valid_pdb_paths:
28
+ - ../datasets/ATLAS/alphaflow_valid_pdb/
29
+ alphaflow_valid_rmsf_path: .//alphaflow_rmsf.json
30
+ samples_per_valid_protein: 10
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ alphaflow_valid_local_rmsf_path: .//alphaflow_local_rmsf.json
34
+ loader:
35
+ num_workers: 8
36
+ prefetch_factor: 10
37
+ pin_memory: false
38
+ sampler:
39
+ max_batch_size: 100
40
+ max_num_res_squared: 250000
41
+ max_conformations: 20
42
+ experiment:
43
+ debug: false
44
+ use_wandb: true
45
+ use_tqdm: false
46
+ seed: 123
47
+ num_devices: 2
48
+ warm_start: null
49
+ warm_start_cfg_override: true
50
+ use_swa: false
51
+ first_val_epoch: 40
52
+ reset_epoch: false
53
+ batch_ot:
54
+ enabled: true
55
+ cost: kabsch
56
+ noise_per_sample: 1
57
+ training:
58
+ min_plddt_mask: null
59
+ loss: se3_vf_loss
60
+ bb_atom_scale: 0.1
61
+ trans_scale: 0.1
62
+ translation_loss_weight: 2.0
63
+ t_normalize_clip: 0.9
64
+ rotation_loss_weights: 1.0
65
+ aux_loss_weight: 1.0
66
+ aux_loss_t_pass: 0.25
67
+ t_bins: 4
68
+ ca_distmat_loss_weight: 0.0
69
+ ensemble_group_size: 0
70
+ force_grouped_batch: false
71
+ lambda_shape: 1.0
72
+ lambda_local_cov: 1.0
73
+ lambda_cross_cov: 1.0
74
+ lambda_rmsf: 0.25
75
+ lambda_mode_recon: 0.0
76
+ enm_warmup_epochs: 0
77
+ lambda_enm_warmup: 1.0
78
+ log_latent_batch_debug: false
79
+ epoch_condition_probe: true
80
+ condition_probe_scale: 2.0
81
+ diagnostic_interval_steps: 50
82
+ lambda_generator_cov: 0.0
83
+ generator_cov_use_cross: false
84
+ generator_cov_t_min: 0.1
85
+ generator_cov_t_max: 0.6
86
+ generator_cov_delta_scale: 1.0
87
+ generator_cov_num_deltas: 2
88
+ generator_cov_student_chunk_deltas: 1
89
+ generator_cov_teacher_num_deltas: 1
90
+ generator_cov_teacher_reuse_student_delta: true
91
+ generator_cov_teacher_trace_denominator: teacher
92
+ generator_cov_checkpoint: false
93
+ generator_cov_initial_trace_anchor: true
94
+ lambda_gen_local_shape: 1.0
95
+ lambda_gen_cross_shape: 1.0
96
+ lambda_gen_trace_anchor: 0.05
97
+ wandb:
98
+ name: rt02_noDir
99
+ project: bbflow
100
+ save_dir: outputs/
101
+ tags: []
102
+ optimizer:
103
+ lr: 0.0001
104
+ reset_optimizer_on_load: false
105
+ warmup_lr: false
106
+ warmup_lr_factor: 0.01
107
+ trainer:
108
+ overfit_batches: 0
109
+ min_epochs: 1
110
+ max_epochs: 250
111
+ accelerator: gpu
112
+ precision: bf16-mixed
113
+ log_every_n_steps: 1
114
+ deterministic: false
115
+ strategy: ddp
116
+ check_val_every_n_epoch: 1
117
+ default_root_dir: outputs/
118
+ accumulate_grad_batches: 1
119
+ checkpointer:
120
+ dirpath: ./
121
+ save_last: true
122
+ save_on_train_epoch_end: true
123
+ filename: epoch:{epoch:03d}
124
+ every_n_epochs: 1
125
+ save_top_k: -1
126
+ auto_insert_metric_name: false
127
+ checkpointer2: null
128
+ profiler:
129
+ enabled: false
130
+ modules: null
131
+ profile:
132
+ use_cuda: true
133
+ with_stack: false
134
+ stats:
135
+ group_by_stack_n: 0
136
+ group_by_input_shapes: false
137
+ prefixes:
138
+ - 'layer_0::'
139
+ - 'layer_1::'
140
+ sort_by: cpu_time_total
141
+ scheduler:
142
+ enabled: false
143
+ interpolant:
144
+ use_tqdm: false
145
+ batch_ot: intra
146
+ prior: conditional
147
+ prior_conditional:
148
+ gamma_trans: 0.2
149
+ gamma_rots: 0.2
150
+ min_t: 0.01
151
+ t_interval:
152
+ - 0.0
153
+ - 1.0
154
+ rots:
155
+ distribution: uniform
156
+ train_schedule: linear
157
+ sample_schedule: exp
158
+ exp_rate: 10
159
+ linear_scaling: 1
160
+ trans:
161
+ train_schedule: linear
162
+ sample_schedule: linear
163
+ sampling:
164
+ num_timesteps: 20
165
+ self_condition: true
166
+ noise_res_scaling_power: 0.0
167
+ noise_scale: 1.0
168
+ t_sampling_focus: 0.0
169
+ model:
170
+ node_embed_size: 240
171
+ edge_embed_size: 120
172
+ embed:
173
+ index_embed_dim: 128
174
+ time_embed_dim: 128
175
+ embed_aatype: true
176
+ aatype_embed_dim: 128
177
+ length_embed_dim: 16
178
+ embed_self_conditioning: true
179
+ num_bins_distance: 22
180
+ min_bin_distance: 1.0e-05
181
+ max_bin_distance: 20.0
182
+ embed_distogram: true
183
+ embed_direction: false
184
+ edge_features:
185
+ self_condition: true
186
+ single_bias_transition_n: 2
187
+ c_s: 240
188
+ c_p: 120
189
+ relpos_k: 64
190
+ use_rbf: true
191
+ num_rbf: 32
192
+ feat_dim: 64
193
+ num_bins: 22
194
+ embed_breaks: true
195
+ gfa:
196
+ c_s: 240
197
+ c_z: 120
198
+ c_hidden: 120
199
+ no_heads: 8
200
+ no_qk_points: 8
201
+ no_v_points: 8
202
+ seq_tfmr_num_heads: 4
203
+ seq_tfmr_num_layers: 2
204
+ num_blocks: 6
205
+ node_features:
206
+ c_s: 240
207
+ c_pos_emb: 120
208
+ c_timestep_emb: 120
209
+ embed_diffuse_mask: false
210
+ max_num_res: 2000
211
+ timestep_int: 1000
212
+ latent:
213
+ enable: false
214
+ dim: 16
215
+ num_modes: 8
216
+ motion_message_passing_layers: 4
217
+ cross_cov_near_distance: 12.0
218
+ template_residual_scale: 0.1
219
+ template_remove_rotation: true
220
+ use_enm_features: false
221
+ enm_num_modes: 8
222
+ enm_cutoff: 12.0
223
+ enm_eps: 1.0e-06
224
+ node_cond_dim: 8
225
+ edge_cond_dim: 8
226
+ freeze_foundation: true
227
+ inject_embedder: true
228
+ inject_film: true
229
+ activation_checkpoint: true
230
+ shape_fingerprint_k: 5
231
+ shape_fingerprint_cache_path: null
232
+ motion_target_cache_path: null
233
+ z_stochastic: false
234
+ inference:
235
+ name: control_official
236
+ seed: 123
237
+ ckpt_path: /home/wangyusong/LD-FPG-main/bbflow/models/bbflow-0.1/bbflow-0.1.ckpt
238
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference
239
+ use_ckpt_name_in_outpath: true
240
+ use_gpu: true
241
+ num_gpus: 1
242
+ precision: 32-true
243
+ use_tqdm: true
244
+ log_times: false
245
+ z_per_sample: false
246
+ condition_mode: real
247
+ condition_scale: 1.0
248
+ postprocess_bfactors: true
249
+ csv_path: /tmp/one_5znjA.csv
250
+ sort: false
251
+ num_proteins: null
252
+ num_workers: 2
253
+ min_length: null
254
+ max_length: null
255
+ save_traj: false
256
+ final_only: true
257
+ cache_static_features: true
258
+ single_file: true
259
+ interpolant:
260
+ use_tqdm: true
261
+ min_t: 0.0
262
+ max_t: 0.99
263
+ rots:
264
+ distribution: uniform
265
+ sample_schedule: exp
266
+ exp_rate: 10
267
+ trans:
268
+ sample_schedule: linear
269
+ sampling:
270
+ num_timesteps: 20
271
+ self_condition: true
272
+ prior: conditional
273
+ prior_conditional:
274
+ gamma_trans: 0.2
275
+ gamma_rots: 0.2
276
+ batch_ot: intra
277
+ samples:
278
+ samples_per_protein: 100
279
+ batch_size: 20
280
+ num_res_squared: 2900000
281
+ folding_cfg: null
bbflow_base/lightning_logs/version_62/hparams.yaml ADDED
@@ -0,0 +1,288 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/datasets/ATLAS
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 10
39
+ max_num_res_squared: 120000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /home/wangyusong/LD-FPG-main/bbflow/models/bbflow-0.1/bbflow-0.1.ckpt
48
+ warm_start_cfg_override: false
49
+ use_swa: false
50
+ first_val_epoch: .inf
51
+ reset_epoch: false
52
+ batch_ot:
53
+ enabled: true
54
+ cost: kabsch
55
+ noise_per_sample: 1
56
+ training:
57
+ min_plddt_mask: null
58
+ loss: se3_vf_loss
59
+ bb_atom_scale: 0.1
60
+ trans_scale: 0.1
61
+ translation_loss_weight: 2.0
62
+ t_normalize_clip: 0.9
63
+ rotation_loss_weights: 1.0
64
+ aux_loss_weight: 1.0
65
+ aux_loss_t_pass: 0.75
66
+ t_bins: 4
67
+ ca_distmat_loss_weight: 0.0
68
+ ensemble_group_size: 0
69
+ force_grouped_batch: false
70
+ lambda_shape: 1.0
71
+ lambda_local_cov: 1.0
72
+ lambda_cross_cov: 1.0
73
+ lambda_rmsf: 0.25
74
+ lambda_mode_recon: 0.0
75
+ enm_warmup_epochs: 0
76
+ lambda_enm_warmup: 1.0
77
+ log_latent_batch_debug: false
78
+ epoch_condition_probe: false
79
+ condition_probe_scale: 2.0
80
+ diagnostic_interval_steps: 50
81
+ lambda_generator_cov: 1.0
82
+ generator_cov_use_cross: true
83
+ generator_cov_t_min: 0.1
84
+ generator_cov_t_max: 0.6
85
+ generator_cov_delta_scale: 1.0
86
+ generator_cov_num_deltas: 2
87
+ generator_cov_student_chunk_deltas: 1
88
+ generator_cov_teacher_num_deltas: 1
89
+ generator_cov_teacher_reuse_student_delta: true
90
+ generator_cov_teacher_trace_denominator: teacher
91
+ generator_cov_checkpoint: true
92
+ generator_cov_initial_trace_anchor: true
93
+ lambda_gen_local_shape: 1.0
94
+ lambda_gen_cross_shape: 1.0
95
+ lambda_gen_trace_anchor: 0.3
96
+ per_frame_coeff_condition: true
97
+ lambda_motion: 1.0
98
+ lambda_q: 1.0
99
+ lambda_mode_orth: 1.0
100
+ lambda_pca_align: 0.0
101
+ lambda_condition_cycle: 0.0
102
+ oracle_condition: false
103
+ grad_flow_check: true
104
+ log_optimizer_coverage: true
105
+ wandb:
106
+ name: bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700
107
+ project: bbflow
108
+ save_dir: outputs/
109
+ tags: []
110
+ optimizer:
111
+ lr: 0.0001
112
+ reset_optimizer_on_load: false
113
+ warmup_lr: false
114
+ warmup_lr_factor: 0.01
115
+ trainer:
116
+ overfit_batches: 0
117
+ min_epochs: 1
118
+ max_epochs: 10
119
+ accelerator: gpu
120
+ precision: bf16-mixed
121
+ log_every_n_steps: 50
122
+ deterministic: false
123
+ strategy: ddp
124
+ check_val_every_n_epoch: 1
125
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700
126
+ accumulate_grad_batches: 1
127
+ max_steps: -1
128
+ profiler: null
129
+ num_sanity_val_steps: 0
130
+ checkpointer:
131
+ dirpath: ./
132
+ save_last: true
133
+ save_on_train_epoch_end: true
134
+ filename: epoch:{epoch:03d}
135
+ every_n_epochs: 1
136
+ save_top_k: -1
137
+ auto_insert_metric_name: false
138
+ checkpointer2: null
139
+ profiler:
140
+ enabled: false
141
+ modules: null
142
+ profile:
143
+ use_cuda: true
144
+ with_stack: false
145
+ stats:
146
+ group_by_stack_n: 0
147
+ group_by_input_shapes: false
148
+ prefixes:
149
+ - 'layer_0::'
150
+ - 'layer_1::'
151
+ sort_by: cpu_time_total
152
+ scheduler:
153
+ enabled: false
154
+ interpolant:
155
+ use_tqdm: true
156
+ batch_ot: intra
157
+ prior: conditional
158
+ prior_conditional:
159
+ gamma_trans: 0.2
160
+ gamma_rots: 0.2
161
+ min_t: 0.01
162
+ t_interval:
163
+ - 0.0
164
+ - 1.0
165
+ rots:
166
+ distribution: uniform
167
+ train_schedule: linear
168
+ sample_schedule: exp
169
+ exp_rate: 10
170
+ linear_scaling: 1
171
+ trans:
172
+ train_schedule: linear
173
+ sample_schedule: linear
174
+ sampling:
175
+ num_timesteps: 20
176
+ self_condition: true
177
+ noise_res_scaling_power: 0.0
178
+ noise_scale: 1.0
179
+ t_sampling_focus: 0.0
180
+ model:
181
+ node_embed_size: 240
182
+ edge_embed_size: 120
183
+ embed:
184
+ index_embed_type: full
185
+ index_embed_dim: 128
186
+ time_embed_dim: 128
187
+ embed_aatype: true
188
+ aatype_embed_dim: 128
189
+ length_embed_dim: 16
190
+ embed_self_conditioning: true
191
+ num_bins_distance: 22
192
+ min_bin_distance: 1.0e-05
193
+ max_bin_distance: 20.0
194
+ embed_distogram: true
195
+ embed_direction: false
196
+ embed_direction_cutoff: 5
197
+ edge_features:
198
+ self_condition: true
199
+ gfa:
200
+ c_s: 240
201
+ c_z: 120
202
+ c_hidden: 120
203
+ no_heads: 8
204
+ no_qk_points: 8
205
+ no_v_points: 8
206
+ seq_tfmr_num_heads: 4
207
+ seq_tfmr_num_layers: 2
208
+ num_blocks: 6
209
+ latent:
210
+ enable: true
211
+ dim: 16
212
+ num_modes: 8
213
+ motion_message_passing_layers: 4
214
+ cross_cov_near_distance: 12.0
215
+ template_residual_scale: 0.1
216
+ template_remove_rotation: true
217
+ use_enm_features: false
218
+ enm_num_modes: 8
219
+ enm_cutoff: 12.0
220
+ enm_eps: 1.0e-06
221
+ node_cond_dim: 8
222
+ edge_cond_dim: 8
223
+ freeze_foundation: false
224
+ inject_embedder: true
225
+ inject_film: true
226
+ activation_checkpoint: true
227
+ shape_fingerprint_k: 5
228
+ shape_fingerprint_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
229
+ motion_target_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
230
+ z_stochastic: false
231
+ energy_from_q: true
232
+ energy_from_q_full_cov: false
233
+ sample_coefficients: true
234
+ track_condition_debug: false
235
+ mixture_components: 2
236
+ q_lstsq_ridge: 0.0001
237
+ q_cholesky_jitter: 0.0001
238
+ q_detach_projection: true
239
+ q_detach_shared_encoder: false
240
+ pca_align_top_m: 2
241
+ inference:
242
+ name: scale_0.5
243
+ seed: 123
244
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_gen_cov_v2_mdtrace_cross_k8_10ep_3gpu_120k_bs10_20260717_125700/epoch:004.ckpt
245
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference
246
+ use_ckpt_name_in_outpath: true
247
+ use_gpu: true
248
+ num_gpus: 1
249
+ precision: 32-true
250
+ use_tqdm: true
251
+ log_times: false
252
+ z_per_sample: false
253
+ condition_mode: real
254
+ condition_scale: 0.5
255
+ postprocess_bfactors: true
256
+ csv_path: /tmp/one_5znjA.csv
257
+ sort: false
258
+ num_proteins: null
259
+ num_workers: 2
260
+ min_length: null
261
+ max_length: null
262
+ save_traj: false
263
+ final_only: true
264
+ cache_static_features: true
265
+ single_file: true
266
+ interpolant:
267
+ use_tqdm: true
268
+ min_t: 0.0
269
+ max_t: 0.99
270
+ rots:
271
+ distribution: uniform
272
+ sample_schedule: exp
273
+ exp_rate: 10
274
+ trans:
275
+ sample_schedule: linear
276
+ sampling:
277
+ num_timesteps: 20
278
+ self_condition: true
279
+ prior: conditional
280
+ prior_conditional:
281
+ gamma_trans: 0.2
282
+ gamma_rots: 0.2
283
+ batch_ot: intra
284
+ samples:
285
+ samples_per_protein: 100
286
+ batch_size: 20
287
+ num_res_squared: 2900000
288
+ folding_cfg: null
bbflow_base/lightning_logs/version_68/hparams.yaml ADDED
@@ -0,0 +1,297 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/stage2_qtrain_K4_unfrozen_20260722_214341
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/datasets/ATLAS
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 32
39
+ max_num_res_squared: 400000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/stage1_eq2U_K4_20260720_022436/epoch:014.ckpt
48
+ warm_start_cfg_override: false
49
+ use_swa: false
50
+ first_val_epoch: .inf
51
+ reset_epoch: true
52
+ batch_ot:
53
+ enabled: true
54
+ cost: kabsch
55
+ noise_per_sample: 1
56
+ training:
57
+ min_plddt_mask: null
58
+ loss: se3_vf_loss
59
+ bb_atom_scale: 0.1
60
+ trans_scale: 0.1
61
+ translation_loss_weight: 2.0
62
+ t_normalize_clip: 0.9
63
+ rotation_loss_weights: 1.0
64
+ aux_loss_weight: 1.0
65
+ aux_loss_t_pass: 0.75
66
+ t_bins: 4
67
+ ca_distmat_loss_weight: 0.0
68
+ ensemble_group_size: 0
69
+ force_grouped_batch: false
70
+ lambda_shape: 1.0
71
+ lambda_local_cov: 1.0
72
+ lambda_cross_cov: 1.0
73
+ lambda_rmsf: 0.25
74
+ lambda_mode_recon: 0.0
75
+ enm_warmup_epochs: 0
76
+ lambda_enm_warmup: 1.0
77
+ log_latent_batch_debug: false
78
+ epoch_condition_probe: false
79
+ condition_probe_scale: 2.0
80
+ diagnostic_interval_steps: 50
81
+ lambda_generator_cov: 0.0
82
+ generator_cov_use_cross: false
83
+ generator_cov_t_min: 0.1
84
+ generator_cov_t_max: 0.6
85
+ generator_cov_delta_scale: 1.0
86
+ generator_cov_num_deltas: 2
87
+ generator_cov_student_chunk_deltas: 1
88
+ generator_cov_teacher_num_deltas: 1
89
+ generator_cov_teacher_reuse_student_delta: true
90
+ generator_cov_teacher_trace_denominator: teacher
91
+ generator_cov_checkpoint: false
92
+ generator_cov_initial_trace_anchor: true
93
+ generator_cov_amplitude_anchor: md_trace
94
+ generator_cov_rollout_calibration: false
95
+ generator_cov_rollout_steps: 2
96
+ generator_cov_rollout_num_deltas: 1
97
+ generator_cov_rollout_max_examples: 4
98
+ generator_cov_rollout_interval_steps: 200
99
+ generator_cov_rollout_ema_decay: 0.9
100
+ lambda_gen_local_shape: 1.0
101
+ lambda_gen_cross_shape: 1.0
102
+ lambda_gen_trace_anchor: 0.05
103
+ per_frame_coeff_condition: true
104
+ lambda_motion: 0.0
105
+ lambda_q: 1.0
106
+ lambda_mode_orth: 0.0
107
+ lambda_pca_align: 0.0
108
+ lambda_condition_cycle: 0.0
109
+ oracle_condition: false
110
+ grad_flow_check: true
111
+ log_optimizer_coverage: true
112
+ wandb:
113
+ name: stage2_qtrain_K4_unfrozen_20260722_214341
114
+ project: bbflow
115
+ save_dir: outputs/
116
+ tags: []
117
+ optimizer:
118
+ lr: 0.0001
119
+ reset_optimizer_on_load: true
120
+ warmup_lr: false
121
+ warmup_lr_factor: 0.01
122
+ trainer:
123
+ overfit_batches: 0
124
+ min_epochs: 1
125
+ max_epochs: 9
126
+ accelerator: gpu
127
+ precision: bf16-mixed
128
+ log_every_n_steps: 50
129
+ deterministic: false
130
+ strategy: ddp
131
+ check_val_every_n_epoch: 1
132
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/stage2_qtrain_K4_unfrozen_20260722_214341
133
+ accumulate_grad_batches: 1
134
+ max_steps: -1
135
+ profiler: null
136
+ num_sanity_val_steps: 0
137
+ checkpointer:
138
+ dirpath: ./
139
+ save_last: true
140
+ save_on_train_epoch_end: true
141
+ filename: epoch:{epoch:03d}
142
+ every_n_epochs: 3
143
+ save_top_k: -1
144
+ auto_insert_metric_name: false
145
+ checkpointer2: null
146
+ profiler:
147
+ enabled: false
148
+ modules: null
149
+ profile:
150
+ use_cuda: true
151
+ with_stack: false
152
+ stats:
153
+ group_by_stack_n: 0
154
+ group_by_input_shapes: false
155
+ prefixes:
156
+ - 'layer_0::'
157
+ - 'layer_1::'
158
+ sort_by: cpu_time_total
159
+ scheduler:
160
+ enabled: false
161
+ interpolant:
162
+ use_tqdm: true
163
+ batch_ot: intra
164
+ prior: conditional
165
+ prior_conditional:
166
+ gamma_trans: 0.2
167
+ gamma_rots: 0.2
168
+ min_t: 0.01
169
+ t_interval:
170
+ - 0.0
171
+ - 1.0
172
+ rots:
173
+ distribution: uniform
174
+ train_schedule: linear
175
+ sample_schedule: exp
176
+ exp_rate: 10
177
+ linear_scaling: 1
178
+ trans:
179
+ train_schedule: linear
180
+ sample_schedule: linear
181
+ sampling:
182
+ num_timesteps: 20
183
+ self_condition: true
184
+ noise_res_scaling_power: 0.0
185
+ noise_scale: 1.0
186
+ t_sampling_focus: 0.0
187
+ model:
188
+ node_embed_size: 240
189
+ edge_embed_size: 120
190
+ embed:
191
+ index_embed_type: full
192
+ index_embed_dim: 128
193
+ time_embed_dim: 128
194
+ embed_aatype: true
195
+ aatype_embed_dim: 128
196
+ length_embed_dim: 16
197
+ embed_self_conditioning: true
198
+ num_bins_distance: 22
199
+ min_bin_distance: 1.0e-05
200
+ max_bin_distance: 20.0
201
+ embed_distogram: true
202
+ embed_direction: false
203
+ embed_direction_cutoff: 5
204
+ edge_features:
205
+ self_condition: true
206
+ gfa:
207
+ c_s: 240
208
+ c_z: 120
209
+ c_hidden: 120
210
+ no_heads: 8
211
+ no_qk_points: 8
212
+ no_v_points: 8
213
+ seq_tfmr_num_heads: 4
214
+ seq_tfmr_num_layers: 2
215
+ num_blocks: 6
216
+ latent:
217
+ enable: true
218
+ dim: 16
219
+ num_modes: 4
220
+ motion_message_passing_layers: 4
221
+ cross_cov_near_distance: 12.0
222
+ template_residual_scale: 0.1
223
+ template_remove_rotation: true
224
+ use_enm_features: false
225
+ enm_num_modes: 8
226
+ enm_cutoff: 12.0
227
+ enm_eps: 1.0e-06
228
+ node_cond_dim: 4
229
+ edge_cond_dim: 4
230
+ freeze_foundation: false
231
+ inject_embedder: true
232
+ inject_film: true
233
+ activation_checkpoint: true
234
+ shape_fingerprint_k: 5
235
+ shape_fingerprint_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
236
+ motion_target_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
237
+ z_stochastic: false
238
+ q_sample_temperature: 1.0
239
+ freeze_mode_head: true
240
+ track_condition_debug: false
241
+ mixture_components: 2
242
+ q_lstsq_ridge: 0.0001
243
+ q_cholesky_jitter: 0.0001
244
+ q_detach_projection: true
245
+ q_detach_shared_encoder: false
246
+ energy_from_q: false
247
+ energy_from_q_full_cov: false
248
+ sample_coefficients: true
249
+ pca_align_top_m: 2
250
+ inference:
251
+ name: stage2_K4_epoch9
252
+ seed: 123
253
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/stage2_qtrain_K4_unfrozen_20260722_214341/epoch:008.ckpt
254
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference
255
+ use_ckpt_name_in_outpath: true
256
+ use_gpu: true
257
+ num_gpus: 1
258
+ precision: 32-true
259
+ use_tqdm: true
260
+ log_times: true
261
+ z_per_sample: false
262
+ condition_mode: real
263
+ condition_scale: 1.0
264
+ postprocess_bfactors: true
265
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
266
+ sort: false
267
+ num_proteins: null
268
+ num_workers: 2
269
+ min_length: null
270
+ max_length: null
271
+ save_traj: false
272
+ final_only: true
273
+ cache_static_features: true
274
+ single_file: true
275
+ interpolant:
276
+ use_tqdm: true
277
+ min_t: 0.0
278
+ max_t: 0.99
279
+ rots:
280
+ distribution: uniform
281
+ sample_schedule: exp
282
+ exp_rate: 10
283
+ trans:
284
+ sample_schedule: linear
285
+ sampling:
286
+ num_timesteps: 20
287
+ self_condition: true
288
+ prior: conditional
289
+ prior_conditional:
290
+ gamma_trans: 0.2
291
+ gamma_rots: 0.2
292
+ batch_ot: intra
293
+ samples:
294
+ samples_per_protein: 250
295
+ batch_size: 20
296
+ num_res_squared: 2900000
297
+ folding_cfg: null
bbflow_base/lightning_logs/version_69/hparams.yaml ADDED
@@ -0,0 +1,311 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/cmfm_frozen_20260731_022730
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/datasets/ATLAS
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 8
39
+ max_num_res_squared: 4500000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: false
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/stage1_eq2U_K8_20260720_022436/last.ckpt
48
+ model_only_warm_start: true
49
+ warm_start_cfg_override: false
50
+ use_swa: false
51
+ first_val_epoch: .inf
52
+ reset_epoch: false
53
+ batch_ot:
54
+ enabled: true
55
+ cost: kabsch
56
+ noise_per_sample: 1
57
+ training:
58
+ min_plddt_mask: null
59
+ loss: se3_vf_loss
60
+ bb_atom_scale: 0.1
61
+ trans_scale: 0.1
62
+ translation_loss_weight: 2.0
63
+ t_normalize_clip: 0.9
64
+ rotation_loss_weights: 1.0
65
+ aux_loss_weight: 1.0
66
+ aux_loss_t_pass: 0.75
67
+ t_bins: 4
68
+ ca_distmat_loss_weight: 0.0
69
+ ensemble_group_size: 8
70
+ force_grouped_batch: true
71
+ lambda_shape: 1.0
72
+ lambda_local_cov: 1.0
73
+ lambda_cross_cov: 1.0
74
+ lambda_rmsf: 0.25
75
+ lambda_mode_recon: 0.0
76
+ enm_warmup_epochs: 0
77
+ lambda_enm_warmup: 1.0
78
+ log_latent_batch_debug: false
79
+ full_model_activation_checkpoint: false
80
+ epoch_condition_probe: false
81
+ condition_probe_scale: 2.0
82
+ diagnostic_interval_steps: 200
83
+ lambda_generator_cov: 0.0
84
+ lambda_collective_measure: 1.0
85
+ cmfm_numerics_log_interval: 200
86
+ cmfm_grad_guard: true
87
+ cmfm_capture_failure: true
88
+ cmfm_dump_state_dict: true
89
+ generator_cov_use_cross: false
90
+ generator_cov_t_min: 0.1
91
+ generator_cov_t_max: 0.6
92
+ generator_cov_delta_scale: 1.0
93
+ generator_cov_num_deltas: 2
94
+ generator_cov_student_chunk_deltas: 1
95
+ generator_cov_teacher_num_deltas: 1
96
+ generator_cov_teacher_reuse_student_delta: true
97
+ generator_cov_teacher_trace_denominator: teacher
98
+ generator_cov_checkpoint: false
99
+ generator_cov_initial_trace_anchor: true
100
+ generator_cov_amplitude_anchor: md_trace
101
+ generator_cov_rollout_calibration: false
102
+ generator_cov_rollout_steps: 2
103
+ generator_cov_rollout_num_deltas: 1
104
+ generator_cov_rollout_max_examples: 4
105
+ generator_cov_rollout_interval_steps: 200
106
+ generator_cov_rollout_ema_decay: 0.9
107
+ lambda_gen_local_shape: 1.0
108
+ lambda_gen_cross_shape: 1.0
109
+ lambda_gen_trace_anchor: 0.05
110
+ per_frame_coeff_condition: true
111
+ lambda_motion: 1.0
112
+ lambda_q: 1.0
113
+ lambda_mode_orth: 1.0
114
+ lambda_pca_align: 0.0
115
+ lambda_condition_cycle: 0.0
116
+ oracle_condition: false
117
+ grad_flow_check: true
118
+ log_optimizer_coverage: true
119
+ collective_backbone_chunk_size: 4
120
+ lambda_condition_usage: 0.0
121
+ wandb:
122
+ name: cmfm_frozen_20260731_022730
123
+ project: bbflow
124
+ save_dir: outputs/
125
+ tags: []
126
+ optimizer:
127
+ lr: 0.0001
128
+ reset_optimizer_on_load: false
129
+ warmup_lr: false
130
+ warmup_lr_factor: 0.01
131
+ trainer:
132
+ overfit_batches: 0
133
+ min_epochs: 1
134
+ max_epochs: 100
135
+ accelerator: gpu
136
+ precision: bf16-mixed
137
+ log_every_n_steps: 50
138
+ deterministic: false
139
+ strategy: ddp
140
+ check_val_every_n_epoch: 1
141
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/cmfm_frozen_20260731_022730
142
+ accumulate_grad_batches: 1
143
+ max_steps: -1
144
+ profiler: null
145
+ num_sanity_val_steps: 0
146
+ checkpointer:
147
+ dirpath: ./
148
+ save_last: true
149
+ save_on_train_epoch_end: true
150
+ filename: epoch:{epoch:03d}
151
+ every_n_epochs: 5
152
+ save_top_k: -1
153
+ auto_insert_metric_name: false
154
+ checkpointer2: null
155
+ profiler:
156
+ enabled: false
157
+ modules: null
158
+ profile:
159
+ use_cuda: true
160
+ with_stack: false
161
+ stats:
162
+ group_by_stack_n: 0
163
+ group_by_input_shapes: false
164
+ prefixes:
165
+ - 'layer_0::'
166
+ - 'layer_1::'
167
+ sort_by: cpu_time_total
168
+ scheduler:
169
+ enabled: false
170
+ interpolant:
171
+ use_tqdm: false
172
+ batch_ot: intra
173
+ prior: conditional
174
+ prior_conditional:
175
+ gamma_trans: 0.2
176
+ gamma_rots: 0.2
177
+ min_t: 0.01
178
+ t_interval:
179
+ - 0.0
180
+ - 1.0
181
+ rots:
182
+ distribution: uniform
183
+ train_schedule: linear
184
+ sample_schedule: exp
185
+ exp_rate: 10
186
+ linear_scaling: 1
187
+ trans:
188
+ train_schedule: linear
189
+ sample_schedule: linear
190
+ sampling:
191
+ num_timesteps: 20
192
+ self_condition: true
193
+ noise_res_scaling_power: 0.0
194
+ noise_scale: 1.0
195
+ t_sampling_focus: 0.0
196
+ model:
197
+ node_embed_size: 240
198
+ edge_embed_size: 120
199
+ embed:
200
+ index_embed_type: full
201
+ index_embed_dim: 128
202
+ time_embed_dim: 128
203
+ embed_aatype: true
204
+ aatype_embed_dim: 128
205
+ length_embed_dim: 16
206
+ embed_self_conditioning: true
207
+ num_bins_distance: 22
208
+ min_bin_distance: 1.0e-05
209
+ max_bin_distance: 20.0
210
+ embed_distogram: true
211
+ embed_direction: false
212
+ embed_direction_cutoff: 5
213
+ edge_features:
214
+ self_condition: true
215
+ gfa:
216
+ c_s: 240
217
+ c_z: 120
218
+ c_hidden: 120
219
+ no_heads: 8
220
+ no_qk_points: 8
221
+ no_v_points: 8
222
+ seq_tfmr_num_heads: 4
223
+ seq_tfmr_num_layers: 2
224
+ num_blocks: 6
225
+ latent:
226
+ enable: true
227
+ dim: 16
228
+ num_modes: 8
229
+ motion_message_passing_layers: 4
230
+ cross_cov_near_distance: 12.0
231
+ template_residual_scale: 0.1
232
+ template_remove_rotation: true
233
+ use_enm_features: false
234
+ enm_num_modes: 8
235
+ enm_cutoff: 12.0
236
+ enm_eps: 1.0e-06
237
+ node_cond_dim: 8
238
+ edge_cond_dim: 8
239
+ freeze_foundation: false
240
+ inject_embedder: true
241
+ inject_film: true
242
+ activation_checkpoint: true
243
+ shape_fingerprint_k: 5
244
+ shape_fingerprint_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
245
+ motion_target_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
246
+ z_stochastic: false
247
+ collective_enable: true
248
+ collective_rank: 4
249
+ collective_hidden_dim: 128
250
+ collective_output_scale: 1.0
251
+ collective_spectrum_eps: 1.0e-06
252
+ mode_gauge_ridge: 1.0e-06
253
+ freeze_mode_head: true
254
+ track_condition_debug: false
255
+ mixture_components: 2
256
+ q_lstsq_ridge: 0.0001
257
+ q_cholesky_jitter: 0.0001
258
+ q_detach_projection: true
259
+ q_detach_shared_encoder: true
260
+ energy_from_q: false
261
+ energy_from_q_full_cov: false
262
+ sample_coefficients: true
263
+ pca_align_top_m: 2
264
+ inference:
265
+ name: cmfm_frozen_ep24
266
+ seed: 123
267
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/cmfm_frozen_20260731_022730/epoch:024.ckpt
268
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference/cmfm
269
+ use_ckpt_name_in_outpath: true
270
+ use_gpu: true
271
+ num_gpus: 3
272
+ precision: 32-true
273
+ use_tqdm: true
274
+ log_times: false
275
+ z_per_sample: true
276
+ condition_mode: real
277
+ condition_scale: 1.0
278
+ postprocess_bfactors: true
279
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
280
+ sort: false
281
+ num_proteins: null
282
+ num_workers: 2
283
+ min_length: null
284
+ max_length: null
285
+ save_traj: false
286
+ final_only: true
287
+ cache_static_features: true
288
+ single_file: true
289
+ interpolant:
290
+ use_tqdm: true
291
+ min_t: 0.0
292
+ max_t: 0.99
293
+ rots:
294
+ distribution: uniform
295
+ sample_schedule: exp
296
+ exp_rate: 10
297
+ trans:
298
+ sample_schedule: linear
299
+ sampling:
300
+ num_timesteps: 20
301
+ self_condition: true
302
+ prior: conditional
303
+ prior_conditional:
304
+ gamma_trans: 0.2
305
+ gamma_rots: 0.2
306
+ batch_ot: intra
307
+ samples:
308
+ samples_per_protein: 250
309
+ batch_size: 10
310
+ num_res_squared: 6000000
311
+ folding_cfg: null
bbflow_base/lightning_logs/version_79/hparams.yaml ADDED
@@ -0,0 +1,313 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260803_002645
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/Atlas
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 8
39
+ max_num_res_squared: 1125000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /home/wangyusong/LD-FPG-main/bbflow_base/models/bbflow-0.1/bbflow-0.1.ckpt
48
+ model_only_warm_start: true
49
+ warm_start_cfg_override: false
50
+ use_swa: false
51
+ first_val_epoch: .inf
52
+ reset_epoch: false
53
+ batch_ot:
54
+ enabled: true
55
+ cost: kabsch
56
+ noise_per_sample: 1
57
+ training:
58
+ min_plddt_mask: null
59
+ loss: se3_vf_loss
60
+ bb_atom_scale: 0.1
61
+ trans_scale: 0.1
62
+ translation_loss_weight: 2.0
63
+ t_normalize_clip: 0.9
64
+ rotation_loss_weights: 1.0
65
+ aux_loss_weight: 1.0
66
+ aux_loss_t_pass: 0.75
67
+ t_bins: 4
68
+ ca_distmat_loss_weight: 0.0
69
+ ensemble_group_size: 0
70
+ force_grouped_batch: false
71
+ lambda_shape: 1.0
72
+ lambda_local_cov: 0.0
73
+ lambda_cross_cov: 0.0
74
+ lambda_rmsf: 1.0
75
+ lambda_mode_recon: 0.0
76
+ enm_warmup_epochs: 0
77
+ lambda_enm_warmup: 1.0
78
+ log_latent_batch_debug: false
79
+ full_model_activation_checkpoint: true
80
+ epoch_condition_probe: false
81
+ condition_probe_scale: 2.0
82
+ diagnostic_interval_steps: 50
83
+ lambda_generator_cov: 0.0
84
+ lambda_collective_measure: 0.0
85
+ lambda_md_subspace: 0.2
86
+ lambda_md_subspace_trace: 1.0
87
+ cmfm_numerics_log_interval: 50
88
+ cmfm_grad_guard: true
89
+ cmfm_capture_failure: true
90
+ cmfm_dump_state_dict: true
91
+ generator_cov_use_cross: false
92
+ generator_cov_t_min: 0.1
93
+ generator_cov_t_max: 0.6
94
+ generator_cov_delta_scale: 1.0
95
+ generator_cov_num_deltas: 2
96
+ generator_cov_student_chunk_deltas: 1
97
+ generator_cov_teacher_num_deltas: 1
98
+ generator_cov_teacher_reuse_student_delta: true
99
+ generator_cov_teacher_trace_denominator: teacher
100
+ generator_cov_checkpoint: false
101
+ generator_cov_initial_trace_anchor: true
102
+ generator_cov_amplitude_anchor: md_trace
103
+ generator_cov_rollout_calibration: false
104
+ generator_cov_rollout_steps: 2
105
+ generator_cov_rollout_num_deltas: 1
106
+ generator_cov_rollout_max_examples: 4
107
+ generator_cov_rollout_interval_steps: 200
108
+ generator_cov_rollout_ema_decay: 0.9
109
+ lambda_gen_local_shape: 1.0
110
+ lambda_gen_cross_shape: 1.0
111
+ lambda_gen_trace_anchor: 0.05
112
+ per_frame_coeff_condition: true
113
+ lambda_motion: 1.0
114
+ lambda_q: 1.0
115
+ lambda_mode_orth: 1.0
116
+ lambda_pca_align: 0.0
117
+ lambda_condition_cycle: 0.0
118
+ oracle_condition: false
119
+ grad_flow_check: true
120
+ log_optimizer_coverage: true
121
+ wandb:
122
+ name: mdsubspace_20260803_002645
123
+ project: bbflow
124
+ save_dir: outputs/
125
+ tags: []
126
+ optimizer:
127
+ lr: 0.0001
128
+ reset_optimizer_on_load: false
129
+ warmup_lr: false
130
+ warmup_lr_factor: 0.01
131
+ trainer:
132
+ overfit_batches: 0
133
+ min_epochs: 1
134
+ max_epochs: 30
135
+ accelerator: gpu
136
+ precision: bf16-mixed
137
+ log_every_n_steps: 50
138
+ deterministic: false
139
+ strategy: ddp
140
+ check_val_every_n_epoch: 1
141
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260803_002645
142
+ accumulate_grad_batches: 1
143
+ max_steps: -1
144
+ profiler: null
145
+ num_sanity_val_steps: 0
146
+ checkpointer:
147
+ dirpath: ./
148
+ save_last: true
149
+ save_on_train_epoch_end: true
150
+ filename: epoch:{epoch:03d}
151
+ every_n_epochs: 5
152
+ save_top_k: -1
153
+ auto_insert_metric_name: false
154
+ checkpointer2: null
155
+ profiler:
156
+ enabled: false
157
+ modules: null
158
+ profile:
159
+ use_cuda: true
160
+ with_stack: false
161
+ stats:
162
+ group_by_stack_n: 0
163
+ group_by_input_shapes: false
164
+ prefixes:
165
+ - 'layer_0::'
166
+ - 'layer_1::'
167
+ sort_by: cpu_time_total
168
+ scheduler:
169
+ enabled: false
170
+ interpolant:
171
+ use_tqdm: true
172
+ batch_ot: intra
173
+ prior: conditional
174
+ prior_conditional:
175
+ gamma_trans: 0.2
176
+ gamma_rots: 0.2
177
+ min_t: 0.01
178
+ t_interval:
179
+ - 0.0
180
+ - 1.0
181
+ rots:
182
+ distribution: uniform
183
+ train_schedule: linear
184
+ sample_schedule: exp
185
+ exp_rate: 10
186
+ linear_scaling: 1
187
+ trans:
188
+ train_schedule: linear
189
+ sample_schedule: linear
190
+ sampling:
191
+ num_timesteps: 20
192
+ self_condition: true
193
+ noise_res_scaling_power: 0.0
194
+ noise_scale: 1.0
195
+ t_sampling_focus: 0.0
196
+ model:
197
+ node_embed_size: 240
198
+ edge_embed_size: 120
199
+ embed:
200
+ index_embed_type: full
201
+ index_embed_dim: 128
202
+ time_embed_dim: 128
203
+ embed_aatype: true
204
+ aatype_embed_dim: 128
205
+ length_embed_dim: 16
206
+ embed_self_conditioning: true
207
+ num_bins_distance: 22
208
+ min_bin_distance: 1.0e-05
209
+ max_bin_distance: 20.0
210
+ embed_distogram: true
211
+ embed_direction: false
212
+ embed_direction_cutoff: 5
213
+ edge_features:
214
+ self_condition: true
215
+ gfa:
216
+ c_s: 240
217
+ c_z: 120
218
+ c_hidden: 120
219
+ no_heads: 8
220
+ no_qk_points: 8
221
+ no_v_points: 8
222
+ seq_tfmr_num_heads: 4
223
+ seq_tfmr_num_layers: 2
224
+ num_blocks: 6
225
+ latent:
226
+ enable: true
227
+ dim: 16
228
+ num_modes: 8
229
+ motion_message_passing_layers: 4
230
+ cross_cov_near_distance: 12.0
231
+ template_residual_scale: 1.0
232
+ template_remove_rotation: true
233
+ use_enm_features: false
234
+ enm_num_modes: 8
235
+ enm_cutoff: 12.0
236
+ enm_eps: 1.0e-06
237
+ node_cond_dim: 8
238
+ edge_cond_dim: 8
239
+ freeze_foundation: false
240
+ inject_embedder: true
241
+ inject_film: true
242
+ activation_checkpoint: true
243
+ shape_fingerprint_k: 5
244
+ shape_fingerprint_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k12_kabsch_v1.pt
245
+ motion_target_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k12_kabsch_v1.pt
246
+ z_stochastic: false
247
+ collective_enable: false
248
+ collective_rank: 4
249
+ collective_hidden_dim: 128
250
+ collective_output_scale: 1.0
251
+ collective_spectrum_eps: 1.0e-06
252
+ mode_gauge_ridge: 1.0e-06
253
+ freeze_mode_head: false
254
+ track_condition_debug: false
255
+ collective_basis_from_data: false
256
+ collective_rate_weighted: true
257
+ mixture_components: 2
258
+ q_lstsq_ridge: 0.0001
259
+ q_cholesky_jitter: 0.0001
260
+ q_detach_projection: true
261
+ q_detach_shared_encoder: true
262
+ energy_from_q: false
263
+ energy_from_q_full_cov: false
264
+ sample_coefficients: true
265
+ pca_align_top_m: 2
266
+ inference:
267
+ name: k12_ep004_s1.0
268
+ seed: 123
269
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260803_002645/epoch:004.ckpt
270
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference/cmfm
271
+ use_ckpt_name_in_outpath: true
272
+ use_gpu: true
273
+ num_gpus: 3
274
+ precision: 32-true
275
+ use_tqdm: true
276
+ log_times: false
277
+ z_per_sample: true
278
+ condition_mode: real
279
+ condition_scale: 1.0
280
+ postprocess_bfactors: true
281
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
282
+ sort: false
283
+ num_proteins: null
284
+ num_workers: 2
285
+ min_length: null
286
+ max_length: null
287
+ save_traj: false
288
+ final_only: true
289
+ cache_static_features: true
290
+ single_file: true
291
+ interpolant:
292
+ use_tqdm: true
293
+ min_t: 0.0
294
+ max_t: 0.99
295
+ rots:
296
+ distribution: uniform
297
+ sample_schedule: exp
298
+ exp_rate: 10
299
+ trans:
300
+ sample_schedule: linear
301
+ sampling:
302
+ num_timesteps: 20
303
+ self_condition: true
304
+ prior: conditional
305
+ prior_conditional:
306
+ gamma_trans: 0.2
307
+ gamma_rots: 0.2
308
+ batch_ot: intra
309
+ samples:
310
+ samples_per_protein: 250
311
+ batch_size: 10
312
+ num_res_squared: 6000000
313
+ folding_cfg: null
bbflow_base/lightning_logs/version_8/hparams.yaml ADDED
@@ -0,0 +1,264 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_official_modelonly_long_finetune_orth1_recon0_100ep_3gpu_20260630_191404
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/datasets/ATLAS
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 32
39
+ max_num_res_squared: 400000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /home/wangyusong/LD-FPG-main/bbflow/models/bbflow-0.1/bbflow-0.1.ckpt
48
+ warm_start_cfg_override: false
49
+ use_swa: false
50
+ first_val_epoch: .inf
51
+ reset_epoch: false
52
+ batch_ot:
53
+ enabled: true
54
+ cost: kabsch
55
+ noise_per_sample: 1
56
+ training:
57
+ min_plddt_mask: null
58
+ loss: se3_vf_loss
59
+ bb_atom_scale: 0.1
60
+ trans_scale: 0.1
61
+ translation_loss_weight: 2.0
62
+ t_normalize_clip: 0.9
63
+ rotation_loss_weights: 1.0
64
+ aux_loss_weight: 1.0
65
+ aux_loss_t_pass: 0.75
66
+ t_bins: 4
67
+ ca_distmat_loss_weight: 0.0
68
+ ensemble_group_size: 0
69
+ force_grouped_batch: false
70
+ lambda_shape: 1.0
71
+ lambda_local_cov: 1.0
72
+ lambda_cross_cov: 1.0
73
+ lambda_rmsf: 0.25
74
+ lambda_mode_recon: 0.0
75
+ enm_warmup_epochs: 0
76
+ lambda_enm_warmup: 1.0
77
+ log_latent_batch_debug: false
78
+ epoch_condition_probe: false
79
+ condition_probe_scale: 2.0
80
+ diagnostic_interval_steps: 50
81
+ per_frame_coeff_condition: true
82
+ lambda_motion: 1.0
83
+ lambda_q: 1.0
84
+ lambda_mode_orth: 1.0
85
+ oracle_condition: false
86
+ grad_flow_check: true
87
+ log_optimizer_coverage: true
88
+ wandb:
89
+ name: bbflow_base_official_modelonly_long_finetune_orth1_recon0_100ep_3gpu_20260630_191404
90
+ project: bbflow
91
+ save_dir: outputs/
92
+ tags: []
93
+ optimizer:
94
+ lr: 0.0001
95
+ reset_optimizer_on_load: false
96
+ warmup_lr: false
97
+ warmup_lr_factor: 0.01
98
+ trainer:
99
+ overfit_batches: 0
100
+ min_epochs: 1
101
+ max_epochs: 100
102
+ accelerator: gpu
103
+ precision: 32-true
104
+ log_every_n_steps: 50
105
+ deterministic: false
106
+ strategy: ddp
107
+ check_val_every_n_epoch: 1
108
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_official_modelonly_long_finetune_orth1_recon0_100ep_3gpu_20260630_191404
109
+ accumulate_grad_batches: 1
110
+ max_steps: -1
111
+ profiler: null
112
+ num_sanity_val_steps: 0
113
+ checkpointer:
114
+ dirpath: ./
115
+ save_last: true
116
+ save_on_train_epoch_end: true
117
+ filename: epoch:{epoch:03d}
118
+ every_n_epochs: 1
119
+ save_top_k: -1
120
+ auto_insert_metric_name: false
121
+ checkpointer2: null
122
+ profiler:
123
+ enabled: false
124
+ modules: null
125
+ profile:
126
+ use_cuda: true
127
+ with_stack: false
128
+ stats:
129
+ group_by_stack_n: 0
130
+ group_by_input_shapes: false
131
+ prefixes:
132
+ - 'layer_0::'
133
+ - 'layer_1::'
134
+ sort_by: cpu_time_total
135
+ scheduler:
136
+ enabled: false
137
+ interpolant:
138
+ use_tqdm: true
139
+ batch_ot: intra
140
+ prior: conditional
141
+ prior_conditional:
142
+ gamma_trans: 0.2
143
+ gamma_rots: 0.2
144
+ min_t: 0.01
145
+ t_interval:
146
+ - 0.0
147
+ - 1.0
148
+ rots:
149
+ distribution: uniform
150
+ train_schedule: linear
151
+ sample_schedule: exp
152
+ exp_rate: 10
153
+ linear_scaling: 1
154
+ trans:
155
+ train_schedule: linear
156
+ sample_schedule: linear
157
+ sampling:
158
+ num_timesteps: 20
159
+ self_condition: true
160
+ noise_res_scaling_power: 0.0
161
+ noise_scale: 1.0
162
+ t_sampling_focus: 0.0
163
+ model:
164
+ node_embed_size: 240
165
+ edge_embed_size: 120
166
+ embed:
167
+ index_embed_type: full
168
+ index_embed_dim: 128
169
+ time_embed_dim: 128
170
+ embed_aatype: true
171
+ aatype_embed_dim: 128
172
+ length_embed_dim: 16
173
+ embed_self_conditioning: true
174
+ num_bins_distance: 22
175
+ min_bin_distance: 1.0e-05
176
+ max_bin_distance: 20.0
177
+ embed_distogram: true
178
+ embed_direction: false
179
+ embed_direction_cutoff: 5
180
+ edge_features:
181
+ self_condition: true
182
+ gfa:
183
+ c_s: 240
184
+ c_z: 120
185
+ c_hidden: 120
186
+ no_heads: 8
187
+ no_qk_points: 8
188
+ no_v_points: 8
189
+ seq_tfmr_num_heads: 4
190
+ seq_tfmr_num_layers: 2
191
+ num_blocks: 6
192
+ latent:
193
+ enable: true
194
+ dim: 16
195
+ num_modes: 8
196
+ motion_message_passing_layers: 4
197
+ cross_cov_near_distance: 12.0
198
+ template_residual_scale: 0.1
199
+ template_remove_rotation: true
200
+ use_enm_features: false
201
+ enm_num_modes: 8
202
+ enm_cutoff: 12.0
203
+ enm_eps: 1.0e-06
204
+ node_cond_dim: 8
205
+ edge_cond_dim: 8
206
+ freeze_foundation: false
207
+ inject_embedder: true
208
+ inject_film: true
209
+ activation_checkpoint: true
210
+ shape_fingerprint_k: 5
211
+ shape_fingerprint_cache_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
212
+ motion_target_cache_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
213
+ z_stochastic: false
214
+ track_condition_debug: false
215
+ mixture_components: 2
216
+ q_lstsq_ridge: 0.0001
217
+ q_cholesky_jitter: 0.0001
218
+ q_detach_projection: true
219
+ q_detach_shared_encoder: false
220
+ sample_coefficients: true
221
+ inference:
222
+ name: atlas_test_250_real
223
+ seed: 123
224
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_official_modelonly_long_finetune_orth1_recon0_100ep_3gpu_20260630_191404/last.ckpt
225
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_official_modelonly_long_finetune_orth1_recon0_100ep_3gpu_20260630_191404/standard_downstream_fast/inference
226
+ use_ckpt_name_in_outpath: true
227
+ use_gpu: true
228
+ num_gpus: 1
229
+ use_tqdm: true
230
+ log_times: true
231
+ z_per_sample: false
232
+ condition_mode: real
233
+ condition_scale: 1.0
234
+ postprocess_bfactors: false
235
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
236
+ sort: false
237
+ num_proteins: null
238
+ min_length: null
239
+ max_length: null
240
+ save_traj: false
241
+ single_file: true
242
+ interpolant:
243
+ use_tqdm: true
244
+ min_t: 0.0
245
+ max_t: 0.99
246
+ rots:
247
+ distribution: uniform
248
+ sample_schedule: exp
249
+ exp_rate: 10
250
+ trans:
251
+ sample_schedule: linear
252
+ sampling:
253
+ num_timesteps: 20
254
+ self_condition: true
255
+ prior: conditional
256
+ prior_conditional:
257
+ gamma_trans: 0.2
258
+ gamma_rots: 0.2
259
+ batch_ot: intra
260
+ samples:
261
+ samples_per_protein: 250
262
+ batch_size: 20
263
+ num_res_squared: 4000000
264
+ folding_cfg: null
bbflow_base/lightning_logs/version_83/hparams.yaml ADDED
@@ -0,0 +1,313 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260803_002645
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/Atlas
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 8
39
+ max_num_res_squared: 1125000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /home/wangyusong/LD-FPG-main/bbflow_base/models/bbflow-0.1/bbflow-0.1.ckpt
48
+ model_only_warm_start: true
49
+ warm_start_cfg_override: false
50
+ use_swa: false
51
+ first_val_epoch: .inf
52
+ reset_epoch: false
53
+ batch_ot:
54
+ enabled: true
55
+ cost: kabsch
56
+ noise_per_sample: 1
57
+ training:
58
+ min_plddt_mask: null
59
+ loss: se3_vf_loss
60
+ bb_atom_scale: 0.1
61
+ trans_scale: 0.1
62
+ translation_loss_weight: 2.0
63
+ t_normalize_clip: 0.9
64
+ rotation_loss_weights: 1.0
65
+ aux_loss_weight: 1.0
66
+ aux_loss_t_pass: 0.75
67
+ t_bins: 4
68
+ ca_distmat_loss_weight: 0.0
69
+ ensemble_group_size: 0
70
+ force_grouped_batch: false
71
+ lambda_shape: 1.0
72
+ lambda_local_cov: 0.0
73
+ lambda_cross_cov: 0.0
74
+ lambda_rmsf: 1.0
75
+ lambda_mode_recon: 0.0
76
+ enm_warmup_epochs: 0
77
+ lambda_enm_warmup: 1.0
78
+ log_latent_batch_debug: false
79
+ full_model_activation_checkpoint: true
80
+ epoch_condition_probe: false
81
+ condition_probe_scale: 2.0
82
+ diagnostic_interval_steps: 50
83
+ lambda_generator_cov: 0.0
84
+ lambda_collective_measure: 0.0
85
+ lambda_md_subspace: 0.2
86
+ lambda_md_subspace_trace: 1.0
87
+ cmfm_numerics_log_interval: 50
88
+ cmfm_grad_guard: true
89
+ cmfm_capture_failure: true
90
+ cmfm_dump_state_dict: true
91
+ generator_cov_use_cross: false
92
+ generator_cov_t_min: 0.1
93
+ generator_cov_t_max: 0.6
94
+ generator_cov_delta_scale: 1.0
95
+ generator_cov_num_deltas: 2
96
+ generator_cov_student_chunk_deltas: 1
97
+ generator_cov_teacher_num_deltas: 1
98
+ generator_cov_teacher_reuse_student_delta: true
99
+ generator_cov_teacher_trace_denominator: teacher
100
+ generator_cov_checkpoint: false
101
+ generator_cov_initial_trace_anchor: true
102
+ generator_cov_amplitude_anchor: md_trace
103
+ generator_cov_rollout_calibration: false
104
+ generator_cov_rollout_steps: 2
105
+ generator_cov_rollout_num_deltas: 1
106
+ generator_cov_rollout_max_examples: 4
107
+ generator_cov_rollout_interval_steps: 200
108
+ generator_cov_rollout_ema_decay: 0.9
109
+ lambda_gen_local_shape: 1.0
110
+ lambda_gen_cross_shape: 1.0
111
+ lambda_gen_trace_anchor: 0.05
112
+ per_frame_coeff_condition: true
113
+ lambda_motion: 1.0
114
+ lambda_q: 1.0
115
+ lambda_mode_orth: 1.0
116
+ lambda_pca_align: 0.0
117
+ lambda_condition_cycle: 0.0
118
+ oracle_condition: false
119
+ grad_flow_check: true
120
+ log_optimizer_coverage: true
121
+ wandb:
122
+ name: mdsubspace_20260803_002645
123
+ project: bbflow
124
+ save_dir: outputs/
125
+ tags: []
126
+ optimizer:
127
+ lr: 0.0001
128
+ reset_optimizer_on_load: false
129
+ warmup_lr: false
130
+ warmup_lr_factor: 0.01
131
+ trainer:
132
+ overfit_batches: 0
133
+ min_epochs: 1
134
+ max_epochs: 30
135
+ accelerator: gpu
136
+ precision: bf16-mixed
137
+ log_every_n_steps: 50
138
+ deterministic: false
139
+ strategy: ddp
140
+ check_val_every_n_epoch: 1
141
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260803_002645
142
+ accumulate_grad_batches: 1
143
+ max_steps: -1
144
+ profiler: null
145
+ num_sanity_val_steps: 0
146
+ checkpointer:
147
+ dirpath: ./
148
+ save_last: true
149
+ save_on_train_epoch_end: true
150
+ filename: epoch:{epoch:03d}
151
+ every_n_epochs: 5
152
+ save_top_k: -1
153
+ auto_insert_metric_name: false
154
+ checkpointer2: null
155
+ profiler:
156
+ enabled: false
157
+ modules: null
158
+ profile:
159
+ use_cuda: true
160
+ with_stack: false
161
+ stats:
162
+ group_by_stack_n: 0
163
+ group_by_input_shapes: false
164
+ prefixes:
165
+ - 'layer_0::'
166
+ - 'layer_1::'
167
+ sort_by: cpu_time_total
168
+ scheduler:
169
+ enabled: false
170
+ interpolant:
171
+ use_tqdm: true
172
+ batch_ot: intra
173
+ prior: conditional
174
+ prior_conditional:
175
+ gamma_trans: 0.2
176
+ gamma_rots: 0.2
177
+ min_t: 0.01
178
+ t_interval:
179
+ - 0.0
180
+ - 1.0
181
+ rots:
182
+ distribution: uniform
183
+ train_schedule: linear
184
+ sample_schedule: exp
185
+ exp_rate: 10
186
+ linear_scaling: 1
187
+ trans:
188
+ train_schedule: linear
189
+ sample_schedule: linear
190
+ sampling:
191
+ num_timesteps: 20
192
+ self_condition: true
193
+ noise_res_scaling_power: 0.0
194
+ noise_scale: 1.0
195
+ t_sampling_focus: 0.0
196
+ model:
197
+ node_embed_size: 240
198
+ edge_embed_size: 120
199
+ embed:
200
+ index_embed_type: full
201
+ index_embed_dim: 128
202
+ time_embed_dim: 128
203
+ embed_aatype: true
204
+ aatype_embed_dim: 128
205
+ length_embed_dim: 16
206
+ embed_self_conditioning: true
207
+ num_bins_distance: 22
208
+ min_bin_distance: 1.0e-05
209
+ max_bin_distance: 20.0
210
+ embed_distogram: true
211
+ embed_direction: false
212
+ embed_direction_cutoff: 5
213
+ edge_features:
214
+ self_condition: true
215
+ gfa:
216
+ c_s: 240
217
+ c_z: 120
218
+ c_hidden: 120
219
+ no_heads: 8
220
+ no_qk_points: 8
221
+ no_v_points: 8
222
+ seq_tfmr_num_heads: 4
223
+ seq_tfmr_num_layers: 2
224
+ num_blocks: 6
225
+ latent:
226
+ enable: true
227
+ dim: 16
228
+ num_modes: 8
229
+ motion_message_passing_layers: 4
230
+ cross_cov_near_distance: 12.0
231
+ template_residual_scale: 1.0
232
+ template_remove_rotation: true
233
+ use_enm_features: false
234
+ enm_num_modes: 8
235
+ enm_cutoff: 12.0
236
+ enm_eps: 1.0e-06
237
+ node_cond_dim: 8
238
+ edge_cond_dim: 8
239
+ freeze_foundation: false
240
+ inject_embedder: true
241
+ inject_film: true
242
+ activation_checkpoint: true
243
+ shape_fingerprint_k: 5
244
+ shape_fingerprint_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k12_kabsch_v1.pt
245
+ motion_target_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k12_kabsch_v1.pt
246
+ z_stochastic: false
247
+ collective_enable: false
248
+ collective_rank: 4
249
+ collective_hidden_dim: 128
250
+ collective_output_scale: 1.0
251
+ collective_spectrum_eps: 1.0e-06
252
+ mode_gauge_ridge: 1.0e-06
253
+ freeze_mode_head: false
254
+ track_condition_debug: false
255
+ collective_basis_from_data: false
256
+ collective_rate_weighted: true
257
+ mixture_components: 2
258
+ q_lstsq_ridge: 0.0001
259
+ q_cholesky_jitter: 0.0001
260
+ q_detach_projection: true
261
+ q_detach_shared_encoder: true
262
+ energy_from_q: false
263
+ energy_from_q_full_cov: false
264
+ sample_coefficients: true
265
+ pca_align_top_m: 2
266
+ inference:
267
+ name: k12_ep004_s1.0
268
+ seed: 123
269
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260803_002645/epoch:004.ckpt
270
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference/cmfm
271
+ use_ckpt_name_in_outpath: true
272
+ use_gpu: true
273
+ num_gpus: 1
274
+ precision: 32-true
275
+ use_tqdm: true
276
+ log_times: false
277
+ z_per_sample: true
278
+ condition_mode: real
279
+ condition_scale: 1.0
280
+ postprocess_bfactors: true
281
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
282
+ sort: false
283
+ num_proteins: null
284
+ num_workers: 2
285
+ min_length: null
286
+ max_length: null
287
+ save_traj: false
288
+ final_only: true
289
+ cache_static_features: true
290
+ single_file: true
291
+ interpolant:
292
+ use_tqdm: true
293
+ min_t: 0.0
294
+ max_t: 0.99
295
+ rots:
296
+ distribution: uniform
297
+ sample_schedule: exp
298
+ exp_rate: 10
299
+ trans:
300
+ sample_schedule: linear
301
+ sampling:
302
+ num_timesteps: 20
303
+ self_condition: true
304
+ prior: conditional
305
+ prior_conditional:
306
+ gamma_trans: 0.2
307
+ gamma_rots: 0.2
308
+ batch_ot: intra
309
+ samples:
310
+ samples_per_protein: 250
311
+ batch_size: 10
312
+ num_res_squared: 6000000
313
+ folding_cfg: null
bbflow_base/lightning_logs/version_85/hparams.yaml ADDED
@@ -0,0 +1,313 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260803_002645
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/Atlas
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 8
39
+ max_num_res_squared: 1125000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /home/wangyusong/LD-FPG-main/bbflow_base/models/bbflow-0.1/bbflow-0.1.ckpt
48
+ model_only_warm_start: true
49
+ warm_start_cfg_override: false
50
+ use_swa: false
51
+ first_val_epoch: .inf
52
+ reset_epoch: false
53
+ batch_ot:
54
+ enabled: true
55
+ cost: kabsch
56
+ noise_per_sample: 1
57
+ training:
58
+ min_plddt_mask: null
59
+ loss: se3_vf_loss
60
+ bb_atom_scale: 0.1
61
+ trans_scale: 0.1
62
+ translation_loss_weight: 2.0
63
+ t_normalize_clip: 0.9
64
+ rotation_loss_weights: 1.0
65
+ aux_loss_weight: 1.0
66
+ aux_loss_t_pass: 0.75
67
+ t_bins: 4
68
+ ca_distmat_loss_weight: 0.0
69
+ ensemble_group_size: 0
70
+ force_grouped_batch: false
71
+ lambda_shape: 1.0
72
+ lambda_local_cov: 0.0
73
+ lambda_cross_cov: 0.0
74
+ lambda_rmsf: 1.0
75
+ lambda_mode_recon: 0.0
76
+ enm_warmup_epochs: 0
77
+ lambda_enm_warmup: 1.0
78
+ log_latent_batch_debug: false
79
+ full_model_activation_checkpoint: true
80
+ epoch_condition_probe: false
81
+ condition_probe_scale: 2.0
82
+ diagnostic_interval_steps: 50
83
+ lambda_generator_cov: 0.0
84
+ lambda_collective_measure: 0.0
85
+ lambda_md_subspace: 0.2
86
+ lambda_md_subspace_trace: 1.0
87
+ cmfm_numerics_log_interval: 50
88
+ cmfm_grad_guard: true
89
+ cmfm_capture_failure: true
90
+ cmfm_dump_state_dict: true
91
+ generator_cov_use_cross: false
92
+ generator_cov_t_min: 0.1
93
+ generator_cov_t_max: 0.6
94
+ generator_cov_delta_scale: 1.0
95
+ generator_cov_num_deltas: 2
96
+ generator_cov_student_chunk_deltas: 1
97
+ generator_cov_teacher_num_deltas: 1
98
+ generator_cov_teacher_reuse_student_delta: true
99
+ generator_cov_teacher_trace_denominator: teacher
100
+ generator_cov_checkpoint: false
101
+ generator_cov_initial_trace_anchor: true
102
+ generator_cov_amplitude_anchor: md_trace
103
+ generator_cov_rollout_calibration: false
104
+ generator_cov_rollout_steps: 2
105
+ generator_cov_rollout_num_deltas: 1
106
+ generator_cov_rollout_max_examples: 4
107
+ generator_cov_rollout_interval_steps: 200
108
+ generator_cov_rollout_ema_decay: 0.9
109
+ lambda_gen_local_shape: 1.0
110
+ lambda_gen_cross_shape: 1.0
111
+ lambda_gen_trace_anchor: 0.05
112
+ per_frame_coeff_condition: true
113
+ lambda_motion: 1.0
114
+ lambda_q: 1.0
115
+ lambda_mode_orth: 1.0
116
+ lambda_pca_align: 0.0
117
+ lambda_condition_cycle: 0.0
118
+ oracle_condition: false
119
+ grad_flow_check: true
120
+ log_optimizer_coverage: true
121
+ wandb:
122
+ name: mdsubspace_20260803_002645
123
+ project: bbflow
124
+ save_dir: outputs/
125
+ tags: []
126
+ optimizer:
127
+ lr: 0.0001
128
+ reset_optimizer_on_load: false
129
+ warmup_lr: false
130
+ warmup_lr_factor: 0.01
131
+ trainer:
132
+ overfit_batches: 0
133
+ min_epochs: 1
134
+ max_epochs: 30
135
+ accelerator: gpu
136
+ precision: bf16-mixed
137
+ log_every_n_steps: 50
138
+ deterministic: false
139
+ strategy: ddp
140
+ check_val_every_n_epoch: 1
141
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260803_002645
142
+ accumulate_grad_batches: 1
143
+ max_steps: -1
144
+ profiler: null
145
+ num_sanity_val_steps: 0
146
+ checkpointer:
147
+ dirpath: ./
148
+ save_last: true
149
+ save_on_train_epoch_end: true
150
+ filename: epoch:{epoch:03d}
151
+ every_n_epochs: 5
152
+ save_top_k: -1
153
+ auto_insert_metric_name: false
154
+ checkpointer2: null
155
+ profiler:
156
+ enabled: false
157
+ modules: null
158
+ profile:
159
+ use_cuda: true
160
+ with_stack: false
161
+ stats:
162
+ group_by_stack_n: 0
163
+ group_by_input_shapes: false
164
+ prefixes:
165
+ - 'layer_0::'
166
+ - 'layer_1::'
167
+ sort_by: cpu_time_total
168
+ scheduler:
169
+ enabled: false
170
+ interpolant:
171
+ use_tqdm: true
172
+ batch_ot: intra
173
+ prior: conditional
174
+ prior_conditional:
175
+ gamma_trans: 0.2
176
+ gamma_rots: 0.2
177
+ min_t: 0.01
178
+ t_interval:
179
+ - 0.0
180
+ - 1.0
181
+ rots:
182
+ distribution: uniform
183
+ train_schedule: linear
184
+ sample_schedule: exp
185
+ exp_rate: 10
186
+ linear_scaling: 1
187
+ trans:
188
+ train_schedule: linear
189
+ sample_schedule: linear
190
+ sampling:
191
+ num_timesteps: 20
192
+ self_condition: true
193
+ noise_res_scaling_power: 0.0
194
+ noise_scale: 1.0
195
+ t_sampling_focus: 0.0
196
+ model:
197
+ node_embed_size: 240
198
+ edge_embed_size: 120
199
+ embed:
200
+ index_embed_type: full
201
+ index_embed_dim: 128
202
+ time_embed_dim: 128
203
+ embed_aatype: true
204
+ aatype_embed_dim: 128
205
+ length_embed_dim: 16
206
+ embed_self_conditioning: true
207
+ num_bins_distance: 22
208
+ min_bin_distance: 1.0e-05
209
+ max_bin_distance: 20.0
210
+ embed_distogram: true
211
+ embed_direction: false
212
+ embed_direction_cutoff: 5
213
+ edge_features:
214
+ self_condition: true
215
+ gfa:
216
+ c_s: 240
217
+ c_z: 120
218
+ c_hidden: 120
219
+ no_heads: 8
220
+ no_qk_points: 8
221
+ no_v_points: 8
222
+ seq_tfmr_num_heads: 4
223
+ seq_tfmr_num_layers: 2
224
+ num_blocks: 6
225
+ latent:
226
+ enable: true
227
+ dim: 16
228
+ num_modes: 8
229
+ motion_message_passing_layers: 4
230
+ cross_cov_near_distance: 12.0
231
+ template_residual_scale: 1.0
232
+ template_remove_rotation: true
233
+ use_enm_features: false
234
+ enm_num_modes: 8
235
+ enm_cutoff: 12.0
236
+ enm_eps: 1.0e-06
237
+ node_cond_dim: 8
238
+ edge_cond_dim: 8
239
+ freeze_foundation: false
240
+ inject_embedder: true
241
+ inject_film: true
242
+ activation_checkpoint: true
243
+ shape_fingerprint_k: 5
244
+ shape_fingerprint_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k12_kabsch_v1.pt
245
+ motion_target_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k12_kabsch_v1.pt
246
+ z_stochastic: false
247
+ collective_enable: false
248
+ collective_rank: 4
249
+ collective_hidden_dim: 128
250
+ collective_output_scale: 1.0
251
+ collective_spectrum_eps: 1.0e-06
252
+ mode_gauge_ridge: 1.0e-06
253
+ freeze_mode_head: false
254
+ track_condition_debug: false
255
+ collective_basis_from_data: false
256
+ collective_rate_weighted: true
257
+ mixture_components: 2
258
+ q_lstsq_ridge: 0.0001
259
+ q_cholesky_jitter: 0.0001
260
+ q_detach_projection: true
261
+ q_detach_shared_encoder: true
262
+ energy_from_q: false
263
+ energy_from_q_full_cov: false
264
+ sample_coefficients: true
265
+ pca_align_top_m: 2
266
+ inference:
267
+ name: k12_ep009_s0.92
268
+ seed: 123
269
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260803_002645/epoch:009.ckpt
270
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference/cmfm
271
+ use_ckpt_name_in_outpath: true
272
+ use_gpu: true
273
+ num_gpus: 1
274
+ precision: 32-true
275
+ use_tqdm: true
276
+ log_times: false
277
+ z_per_sample: true
278
+ condition_mode: real
279
+ condition_scale: 0.92
280
+ postprocess_bfactors: true
281
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
282
+ sort: false
283
+ num_proteins: null
284
+ num_workers: 2
285
+ min_length: null
286
+ max_length: null
287
+ save_traj: false
288
+ final_only: true
289
+ cache_static_features: true
290
+ single_file: true
291
+ interpolant:
292
+ use_tqdm: true
293
+ min_t: 0.0
294
+ max_t: 0.99
295
+ rots:
296
+ distribution: uniform
297
+ sample_schedule: exp
298
+ exp_rate: 10
299
+ trans:
300
+ sample_schedule: linear
301
+ sampling:
302
+ num_timesteps: 20
303
+ self_condition: true
304
+ prior: conditional
305
+ prior_conditional:
306
+ gamma_trans: 0.2
307
+ gamma_rots: 0.2
308
+ batch_ot: intra
309
+ samples:
310
+ samples_per_protein: 250
311
+ batch_size: 10
312
+ num_res_squared: 6000000
313
+ folding_cfg: null
bbflow_base/lightning_logs/version_88/hparams.yaml ADDED
@@ -0,0 +1,313 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260803_002645
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/Atlas
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 8
39
+ max_num_res_squared: 1125000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /home/wangyusong/LD-FPG-main/bbflow_base/models/bbflow-0.1/bbflow-0.1.ckpt
48
+ model_only_warm_start: true
49
+ warm_start_cfg_override: false
50
+ use_swa: false
51
+ first_val_epoch: .inf
52
+ reset_epoch: false
53
+ batch_ot:
54
+ enabled: true
55
+ cost: kabsch
56
+ noise_per_sample: 1
57
+ training:
58
+ min_plddt_mask: null
59
+ loss: se3_vf_loss
60
+ bb_atom_scale: 0.1
61
+ trans_scale: 0.1
62
+ translation_loss_weight: 2.0
63
+ t_normalize_clip: 0.9
64
+ rotation_loss_weights: 1.0
65
+ aux_loss_weight: 1.0
66
+ aux_loss_t_pass: 0.75
67
+ t_bins: 4
68
+ ca_distmat_loss_weight: 0.0
69
+ ensemble_group_size: 0
70
+ force_grouped_batch: false
71
+ lambda_shape: 1.0
72
+ lambda_local_cov: 0.0
73
+ lambda_cross_cov: 0.0
74
+ lambda_rmsf: 1.0
75
+ lambda_mode_recon: 0.0
76
+ enm_warmup_epochs: 0
77
+ lambda_enm_warmup: 1.0
78
+ log_latent_batch_debug: false
79
+ full_model_activation_checkpoint: true
80
+ epoch_condition_probe: false
81
+ condition_probe_scale: 2.0
82
+ diagnostic_interval_steps: 50
83
+ lambda_generator_cov: 0.0
84
+ lambda_collective_measure: 0.0
85
+ lambda_md_subspace: 0.2
86
+ lambda_md_subspace_trace: 1.0
87
+ cmfm_numerics_log_interval: 50
88
+ cmfm_grad_guard: true
89
+ cmfm_capture_failure: true
90
+ cmfm_dump_state_dict: true
91
+ generator_cov_use_cross: false
92
+ generator_cov_t_min: 0.1
93
+ generator_cov_t_max: 0.6
94
+ generator_cov_delta_scale: 1.0
95
+ generator_cov_num_deltas: 2
96
+ generator_cov_student_chunk_deltas: 1
97
+ generator_cov_teacher_num_deltas: 1
98
+ generator_cov_teacher_reuse_student_delta: true
99
+ generator_cov_teacher_trace_denominator: teacher
100
+ generator_cov_checkpoint: false
101
+ generator_cov_initial_trace_anchor: true
102
+ generator_cov_amplitude_anchor: md_trace
103
+ generator_cov_rollout_calibration: false
104
+ generator_cov_rollout_steps: 2
105
+ generator_cov_rollout_num_deltas: 1
106
+ generator_cov_rollout_max_examples: 4
107
+ generator_cov_rollout_interval_steps: 200
108
+ generator_cov_rollout_ema_decay: 0.9
109
+ lambda_gen_local_shape: 1.0
110
+ lambda_gen_cross_shape: 1.0
111
+ lambda_gen_trace_anchor: 0.05
112
+ per_frame_coeff_condition: true
113
+ lambda_motion: 1.0
114
+ lambda_q: 1.0
115
+ lambda_mode_orth: 1.0
116
+ lambda_pca_align: 0.0
117
+ lambda_condition_cycle: 0.0
118
+ oracle_condition: false
119
+ grad_flow_check: true
120
+ log_optimizer_coverage: true
121
+ wandb:
122
+ name: mdsubspace_20260803_002645
123
+ project: bbflow
124
+ save_dir: outputs/
125
+ tags: []
126
+ optimizer:
127
+ lr: 0.0001
128
+ reset_optimizer_on_load: false
129
+ warmup_lr: false
130
+ warmup_lr_factor: 0.01
131
+ trainer:
132
+ overfit_batches: 0
133
+ min_epochs: 1
134
+ max_epochs: 30
135
+ accelerator: gpu
136
+ precision: bf16-mixed
137
+ log_every_n_steps: 50
138
+ deterministic: false
139
+ strategy: ddp
140
+ check_val_every_n_epoch: 1
141
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260803_002645
142
+ accumulate_grad_batches: 1
143
+ max_steps: -1
144
+ profiler: null
145
+ num_sanity_val_steps: 0
146
+ checkpointer:
147
+ dirpath: ./
148
+ save_last: true
149
+ save_on_train_epoch_end: true
150
+ filename: epoch:{epoch:03d}
151
+ every_n_epochs: 5
152
+ save_top_k: -1
153
+ auto_insert_metric_name: false
154
+ checkpointer2: null
155
+ profiler:
156
+ enabled: false
157
+ modules: null
158
+ profile:
159
+ use_cuda: true
160
+ with_stack: false
161
+ stats:
162
+ group_by_stack_n: 0
163
+ group_by_input_shapes: false
164
+ prefixes:
165
+ - 'layer_0::'
166
+ - 'layer_1::'
167
+ sort_by: cpu_time_total
168
+ scheduler:
169
+ enabled: false
170
+ interpolant:
171
+ use_tqdm: true
172
+ batch_ot: intra
173
+ prior: conditional
174
+ prior_conditional:
175
+ gamma_trans: 0.2
176
+ gamma_rots: 0.2
177
+ min_t: 0.01
178
+ t_interval:
179
+ - 0.0
180
+ - 1.0
181
+ rots:
182
+ distribution: uniform
183
+ train_schedule: linear
184
+ sample_schedule: exp
185
+ exp_rate: 10
186
+ linear_scaling: 1
187
+ trans:
188
+ train_schedule: linear
189
+ sample_schedule: linear
190
+ sampling:
191
+ num_timesteps: 20
192
+ self_condition: true
193
+ noise_res_scaling_power: 0.0
194
+ noise_scale: 1.0
195
+ t_sampling_focus: 0.0
196
+ model:
197
+ node_embed_size: 240
198
+ edge_embed_size: 120
199
+ embed:
200
+ index_embed_type: full
201
+ index_embed_dim: 128
202
+ time_embed_dim: 128
203
+ embed_aatype: true
204
+ aatype_embed_dim: 128
205
+ length_embed_dim: 16
206
+ embed_self_conditioning: true
207
+ num_bins_distance: 22
208
+ min_bin_distance: 1.0e-05
209
+ max_bin_distance: 20.0
210
+ embed_distogram: true
211
+ embed_direction: false
212
+ embed_direction_cutoff: 5
213
+ edge_features:
214
+ self_condition: true
215
+ gfa:
216
+ c_s: 240
217
+ c_z: 120
218
+ c_hidden: 120
219
+ no_heads: 8
220
+ no_qk_points: 8
221
+ no_v_points: 8
222
+ seq_tfmr_num_heads: 4
223
+ seq_tfmr_num_layers: 2
224
+ num_blocks: 6
225
+ latent:
226
+ enable: true
227
+ dim: 16
228
+ num_modes: 8
229
+ motion_message_passing_layers: 4
230
+ cross_cov_near_distance: 12.0
231
+ template_residual_scale: 1.0
232
+ template_remove_rotation: true
233
+ use_enm_features: false
234
+ enm_num_modes: 8
235
+ enm_cutoff: 12.0
236
+ enm_eps: 1.0e-06
237
+ node_cond_dim: 8
238
+ edge_cond_dim: 8
239
+ freeze_foundation: false
240
+ inject_embedder: true
241
+ inject_film: true
242
+ activation_checkpoint: true
243
+ shape_fingerprint_k: 5
244
+ shape_fingerprint_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k12_kabsch_v1.pt
245
+ motion_target_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k12_kabsch_v1.pt
246
+ z_stochastic: false
247
+ collective_enable: false
248
+ collective_rank: 4
249
+ collective_hidden_dim: 128
250
+ collective_output_scale: 1.0
251
+ collective_spectrum_eps: 1.0e-06
252
+ mode_gauge_ridge: 1.0e-06
253
+ freeze_mode_head: false
254
+ track_condition_debug: false
255
+ collective_basis_from_data: false
256
+ collective_rate_weighted: true
257
+ mixture_components: 2
258
+ q_lstsq_ridge: 0.0001
259
+ q_cholesky_jitter: 0.0001
260
+ q_detach_projection: true
261
+ q_detach_shared_encoder: true
262
+ energy_from_q: false
263
+ energy_from_q_full_cov: false
264
+ sample_coefficients: true
265
+ pca_align_top_m: 2
266
+ inference:
267
+ name: k12_ep004_s0.85
268
+ seed: 123
269
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260803_002645/epoch:004.ckpt
270
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference/cmfm
271
+ use_ckpt_name_in_outpath: true
272
+ use_gpu: true
273
+ num_gpus: 1
274
+ precision: 32-true
275
+ use_tqdm: true
276
+ log_times: false
277
+ z_per_sample: true
278
+ condition_mode: real
279
+ condition_scale: 0.85
280
+ postprocess_bfactors: true
281
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
282
+ sort: false
283
+ num_proteins: null
284
+ num_workers: 2
285
+ min_length: null
286
+ max_length: null
287
+ save_traj: false
288
+ final_only: true
289
+ cache_static_features: true
290
+ single_file: true
291
+ interpolant:
292
+ use_tqdm: true
293
+ min_t: 0.0
294
+ max_t: 0.99
295
+ rots:
296
+ distribution: uniform
297
+ sample_schedule: exp
298
+ exp_rate: 10
299
+ trans:
300
+ sample_schedule: linear
301
+ sampling:
302
+ num_timesteps: 20
303
+ self_condition: true
304
+ prior: conditional
305
+ prior_conditional:
306
+ gamma_trans: 0.2
307
+ gamma_rots: 0.2
308
+ batch_ot: intra
309
+ samples:
310
+ samples_per_protein: 250
311
+ batch_size: 10
312
+ num_res_squared: 6000000
313
+ folding_cfg: null
bbflow_base/lightning_logs/version_9/hparams.yaml ADDED
@@ -0,0 +1,264 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_official_modelonly_long_finetune_orth1_recon0_100ep_3gpu_20260630_191404
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/datasets/ATLAS
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 32
39
+ max_num_res_squared: 400000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /home/wangyusong/LD-FPG-main/bbflow/models/bbflow-0.1/bbflow-0.1.ckpt
48
+ warm_start_cfg_override: false
49
+ use_swa: false
50
+ first_val_epoch: .inf
51
+ reset_epoch: false
52
+ batch_ot:
53
+ enabled: true
54
+ cost: kabsch
55
+ noise_per_sample: 1
56
+ training:
57
+ min_plddt_mask: null
58
+ loss: se3_vf_loss
59
+ bb_atom_scale: 0.1
60
+ trans_scale: 0.1
61
+ translation_loss_weight: 2.0
62
+ t_normalize_clip: 0.9
63
+ rotation_loss_weights: 1.0
64
+ aux_loss_weight: 1.0
65
+ aux_loss_t_pass: 0.75
66
+ t_bins: 4
67
+ ca_distmat_loss_weight: 0.0
68
+ ensemble_group_size: 0
69
+ force_grouped_batch: false
70
+ lambda_shape: 1.0
71
+ lambda_local_cov: 1.0
72
+ lambda_cross_cov: 1.0
73
+ lambda_rmsf: 0.25
74
+ lambda_mode_recon: 0.0
75
+ enm_warmup_epochs: 0
76
+ lambda_enm_warmup: 1.0
77
+ log_latent_batch_debug: false
78
+ epoch_condition_probe: false
79
+ condition_probe_scale: 2.0
80
+ diagnostic_interval_steps: 50
81
+ per_frame_coeff_condition: true
82
+ lambda_motion: 1.0
83
+ lambda_q: 1.0
84
+ lambda_mode_orth: 1.0
85
+ oracle_condition: false
86
+ grad_flow_check: true
87
+ log_optimizer_coverage: true
88
+ wandb:
89
+ name: bbflow_base_official_modelonly_long_finetune_orth1_recon0_100ep_3gpu_20260630_191404
90
+ project: bbflow
91
+ save_dir: outputs/
92
+ tags: []
93
+ optimizer:
94
+ lr: 0.0001
95
+ reset_optimizer_on_load: false
96
+ warmup_lr: false
97
+ warmup_lr_factor: 0.01
98
+ trainer:
99
+ overfit_batches: 0
100
+ min_epochs: 1
101
+ max_epochs: 100
102
+ accelerator: gpu
103
+ precision: 32-true
104
+ log_every_n_steps: 50
105
+ deterministic: false
106
+ strategy: ddp
107
+ check_val_every_n_epoch: 1
108
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_official_modelonly_long_finetune_orth1_recon0_100ep_3gpu_20260630_191404
109
+ accumulate_grad_batches: 1
110
+ max_steps: -1
111
+ profiler: null
112
+ num_sanity_val_steps: 0
113
+ checkpointer:
114
+ dirpath: ./
115
+ save_last: true
116
+ save_on_train_epoch_end: true
117
+ filename: epoch:{epoch:03d}
118
+ every_n_epochs: 1
119
+ save_top_k: -1
120
+ auto_insert_metric_name: false
121
+ checkpointer2: null
122
+ profiler:
123
+ enabled: false
124
+ modules: null
125
+ profile:
126
+ use_cuda: true
127
+ with_stack: false
128
+ stats:
129
+ group_by_stack_n: 0
130
+ group_by_input_shapes: false
131
+ prefixes:
132
+ - 'layer_0::'
133
+ - 'layer_1::'
134
+ sort_by: cpu_time_total
135
+ scheduler:
136
+ enabled: false
137
+ interpolant:
138
+ use_tqdm: true
139
+ batch_ot: intra
140
+ prior: conditional
141
+ prior_conditional:
142
+ gamma_trans: 0.2
143
+ gamma_rots: 0.2
144
+ min_t: 0.01
145
+ t_interval:
146
+ - 0.0
147
+ - 1.0
148
+ rots:
149
+ distribution: uniform
150
+ train_schedule: linear
151
+ sample_schedule: exp
152
+ exp_rate: 10
153
+ linear_scaling: 1
154
+ trans:
155
+ train_schedule: linear
156
+ sample_schedule: linear
157
+ sampling:
158
+ num_timesteps: 20
159
+ self_condition: true
160
+ noise_res_scaling_power: 0.0
161
+ noise_scale: 1.0
162
+ t_sampling_focus: 0.0
163
+ model:
164
+ node_embed_size: 240
165
+ edge_embed_size: 120
166
+ embed:
167
+ index_embed_type: full
168
+ index_embed_dim: 128
169
+ time_embed_dim: 128
170
+ embed_aatype: true
171
+ aatype_embed_dim: 128
172
+ length_embed_dim: 16
173
+ embed_self_conditioning: true
174
+ num_bins_distance: 22
175
+ min_bin_distance: 1.0e-05
176
+ max_bin_distance: 20.0
177
+ embed_distogram: true
178
+ embed_direction: false
179
+ embed_direction_cutoff: 5
180
+ edge_features:
181
+ self_condition: true
182
+ gfa:
183
+ c_s: 240
184
+ c_z: 120
185
+ c_hidden: 120
186
+ no_heads: 8
187
+ no_qk_points: 8
188
+ no_v_points: 8
189
+ seq_tfmr_num_heads: 4
190
+ seq_tfmr_num_layers: 2
191
+ num_blocks: 6
192
+ latent:
193
+ enable: true
194
+ dim: 16
195
+ num_modes: 8
196
+ motion_message_passing_layers: 4
197
+ cross_cov_near_distance: 12.0
198
+ template_residual_scale: 0.1
199
+ template_remove_rotation: true
200
+ use_enm_features: false
201
+ enm_num_modes: 8
202
+ enm_cutoff: 12.0
203
+ enm_eps: 1.0e-06
204
+ node_cond_dim: 8
205
+ edge_cond_dim: 8
206
+ freeze_foundation: false
207
+ inject_embedder: true
208
+ inject_film: true
209
+ activation_checkpoint: true
210
+ shape_fingerprint_k: 5
211
+ shape_fingerprint_cache_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
212
+ motion_target_cache_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k8_kabsch_v1.pt
213
+ z_stochastic: false
214
+ track_condition_debug: false
215
+ mixture_components: 2
216
+ q_lstsq_ridge: 0.0001
217
+ q_cholesky_jitter: 0.0001
218
+ q_detach_projection: true
219
+ q_detach_shared_encoder: false
220
+ sample_coefficients: true
221
+ inference:
222
+ name: atlas_test_250_real
223
+ seed: 123
224
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_official_modelonly_long_finetune_orth1_recon0_100ep_3gpu_20260630_191404/last.ckpt
225
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/bbflow_base_official_modelonly_long_finetune_orth1_recon0_100ep_3gpu_20260630_191404/standard_downstream_fast/inference
226
+ use_ckpt_name_in_outpath: true
227
+ use_gpu: true
228
+ num_gpus: 1
229
+ use_tqdm: true
230
+ log_times: true
231
+ z_per_sample: false
232
+ condition_mode: real
233
+ condition_scale: 1.0
234
+ postprocess_bfactors: false
235
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
236
+ sort: false
237
+ num_proteins: null
238
+ min_length: null
239
+ max_length: null
240
+ save_traj: false
241
+ single_file: true
242
+ interpolant:
243
+ use_tqdm: true
244
+ min_t: 0.0
245
+ max_t: 0.99
246
+ rots:
247
+ distribution: uniform
248
+ sample_schedule: exp
249
+ exp_rate: 10
250
+ trans:
251
+ sample_schedule: linear
252
+ sampling:
253
+ num_timesteps: 20
254
+ self_condition: true
255
+ prior: conditional
256
+ prior_conditional:
257
+ gamma_trans: 0.2
258
+ gamma_rots: 0.2
259
+ batch_ot: intra
260
+ samples:
261
+ samples_per_protein: 250
262
+ batch_size: 20
263
+ num_res_squared: 4000000
264
+ folding_cfg: null
bbflow_base/lightning_logs/version_94/hparams.yaml ADDED
@@ -0,0 +1,313 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260803_002645
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/Atlas
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 8
39
+ max_num_res_squared: 1125000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /home/wangyusong/LD-FPG-main/bbflow_base/models/bbflow-0.1/bbflow-0.1.ckpt
48
+ model_only_warm_start: true
49
+ warm_start_cfg_override: false
50
+ use_swa: false
51
+ first_val_epoch: .inf
52
+ reset_epoch: false
53
+ batch_ot:
54
+ enabled: true
55
+ cost: kabsch
56
+ noise_per_sample: 1
57
+ training:
58
+ min_plddt_mask: null
59
+ loss: se3_vf_loss
60
+ bb_atom_scale: 0.1
61
+ trans_scale: 0.1
62
+ translation_loss_weight: 2.0
63
+ t_normalize_clip: 0.9
64
+ rotation_loss_weights: 1.0
65
+ aux_loss_weight: 1.0
66
+ aux_loss_t_pass: 0.75
67
+ t_bins: 4
68
+ ca_distmat_loss_weight: 0.0
69
+ ensemble_group_size: 0
70
+ force_grouped_batch: false
71
+ lambda_shape: 1.0
72
+ lambda_local_cov: 0.0
73
+ lambda_cross_cov: 0.0
74
+ lambda_rmsf: 1.0
75
+ lambda_mode_recon: 0.0
76
+ enm_warmup_epochs: 0
77
+ lambda_enm_warmup: 1.0
78
+ log_latent_batch_debug: false
79
+ full_model_activation_checkpoint: true
80
+ epoch_condition_probe: false
81
+ condition_probe_scale: 2.0
82
+ diagnostic_interval_steps: 50
83
+ lambda_generator_cov: 0.0
84
+ lambda_collective_measure: 0.0
85
+ lambda_md_subspace: 0.2
86
+ lambda_md_subspace_trace: 1.0
87
+ cmfm_numerics_log_interval: 50
88
+ cmfm_grad_guard: true
89
+ cmfm_capture_failure: true
90
+ cmfm_dump_state_dict: true
91
+ generator_cov_use_cross: false
92
+ generator_cov_t_min: 0.1
93
+ generator_cov_t_max: 0.6
94
+ generator_cov_delta_scale: 1.0
95
+ generator_cov_num_deltas: 2
96
+ generator_cov_student_chunk_deltas: 1
97
+ generator_cov_teacher_num_deltas: 1
98
+ generator_cov_teacher_reuse_student_delta: true
99
+ generator_cov_teacher_trace_denominator: teacher
100
+ generator_cov_checkpoint: false
101
+ generator_cov_initial_trace_anchor: true
102
+ generator_cov_amplitude_anchor: md_trace
103
+ generator_cov_rollout_calibration: false
104
+ generator_cov_rollout_steps: 2
105
+ generator_cov_rollout_num_deltas: 1
106
+ generator_cov_rollout_max_examples: 4
107
+ generator_cov_rollout_interval_steps: 200
108
+ generator_cov_rollout_ema_decay: 0.9
109
+ lambda_gen_local_shape: 1.0
110
+ lambda_gen_cross_shape: 1.0
111
+ lambda_gen_trace_anchor: 0.05
112
+ per_frame_coeff_condition: true
113
+ lambda_motion: 1.0
114
+ lambda_q: 1.0
115
+ lambda_mode_orth: 1.0
116
+ lambda_pca_align: 0.0
117
+ lambda_condition_cycle: 0.0
118
+ oracle_condition: false
119
+ grad_flow_check: true
120
+ log_optimizer_coverage: true
121
+ wandb:
122
+ name: mdsubspace_20260803_002645
123
+ project: bbflow
124
+ save_dir: outputs/
125
+ tags: []
126
+ optimizer:
127
+ lr: 0.0001
128
+ reset_optimizer_on_load: false
129
+ warmup_lr: false
130
+ warmup_lr_factor: 0.01
131
+ trainer:
132
+ overfit_batches: 0
133
+ min_epochs: 1
134
+ max_epochs: 30
135
+ accelerator: gpu
136
+ precision: bf16-mixed
137
+ log_every_n_steps: 50
138
+ deterministic: false
139
+ strategy: ddp
140
+ check_val_every_n_epoch: 1
141
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260803_002645
142
+ accumulate_grad_batches: 1
143
+ max_steps: -1
144
+ profiler: null
145
+ num_sanity_val_steps: 0
146
+ checkpointer:
147
+ dirpath: ./
148
+ save_last: true
149
+ save_on_train_epoch_end: true
150
+ filename: epoch:{epoch:03d}
151
+ every_n_epochs: 5
152
+ save_top_k: -1
153
+ auto_insert_metric_name: false
154
+ checkpointer2: null
155
+ profiler:
156
+ enabled: false
157
+ modules: null
158
+ profile:
159
+ use_cuda: true
160
+ with_stack: false
161
+ stats:
162
+ group_by_stack_n: 0
163
+ group_by_input_shapes: false
164
+ prefixes:
165
+ - 'layer_0::'
166
+ - 'layer_1::'
167
+ sort_by: cpu_time_total
168
+ scheduler:
169
+ enabled: false
170
+ interpolant:
171
+ use_tqdm: true
172
+ batch_ot: intra
173
+ prior: conditional
174
+ prior_conditional:
175
+ gamma_trans: 0.2
176
+ gamma_rots: 0.2
177
+ min_t: 0.01
178
+ t_interval:
179
+ - 0.0
180
+ - 1.0
181
+ rots:
182
+ distribution: uniform
183
+ train_schedule: linear
184
+ sample_schedule: exp
185
+ exp_rate: 10
186
+ linear_scaling: 1
187
+ trans:
188
+ train_schedule: linear
189
+ sample_schedule: linear
190
+ sampling:
191
+ num_timesteps: 20
192
+ self_condition: true
193
+ noise_res_scaling_power: 0.0
194
+ noise_scale: 1.0
195
+ t_sampling_focus: 0.0
196
+ model:
197
+ node_embed_size: 240
198
+ edge_embed_size: 120
199
+ embed:
200
+ index_embed_type: full
201
+ index_embed_dim: 128
202
+ time_embed_dim: 128
203
+ embed_aatype: true
204
+ aatype_embed_dim: 128
205
+ length_embed_dim: 16
206
+ embed_self_conditioning: true
207
+ num_bins_distance: 22
208
+ min_bin_distance: 1.0e-05
209
+ max_bin_distance: 20.0
210
+ embed_distogram: true
211
+ embed_direction: false
212
+ embed_direction_cutoff: 5
213
+ edge_features:
214
+ self_condition: true
215
+ gfa:
216
+ c_s: 240
217
+ c_z: 120
218
+ c_hidden: 120
219
+ no_heads: 8
220
+ no_qk_points: 8
221
+ no_v_points: 8
222
+ seq_tfmr_num_heads: 4
223
+ seq_tfmr_num_layers: 2
224
+ num_blocks: 6
225
+ latent:
226
+ enable: true
227
+ dim: 16
228
+ num_modes: 8
229
+ motion_message_passing_layers: 4
230
+ cross_cov_near_distance: 12.0
231
+ template_residual_scale: 1.0
232
+ template_remove_rotation: true
233
+ use_enm_features: false
234
+ enm_num_modes: 8
235
+ enm_cutoff: 12.0
236
+ enm_eps: 1.0e-06
237
+ node_cond_dim: 8
238
+ edge_cond_dim: 8
239
+ freeze_foundation: false
240
+ inject_embedder: true
241
+ inject_film: true
242
+ activation_checkpoint: true
243
+ shape_fingerprint_k: 5
244
+ shape_fingerprint_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k12_kabsch_v1.pt
245
+ motion_target_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k12_kabsch_v1.pt
246
+ z_stochastic: false
247
+ collective_enable: false
248
+ collective_rank: 4
249
+ collective_hidden_dim: 128
250
+ collective_output_scale: 1.0
251
+ collective_spectrum_eps: 1.0e-06
252
+ mode_gauge_ridge: 1.0e-06
253
+ freeze_mode_head: false
254
+ track_condition_debug: false
255
+ collective_basis_from_data: false
256
+ collective_rate_weighted: true
257
+ mixture_components: 2
258
+ q_lstsq_ridge: 0.0001
259
+ q_cholesky_jitter: 0.0001
260
+ q_detach_projection: true
261
+ q_detach_shared_encoder: true
262
+ energy_from_q: false
263
+ energy_from_q_full_cov: false
264
+ sample_coefficients: true
265
+ pca_align_top_m: 2
266
+ inference:
267
+ name: k12_ep009_g0.11
268
+ seed: 123
269
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260803_002645/epoch:009.ckpt
270
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference/cmfm
271
+ use_ckpt_name_in_outpath: true
272
+ use_gpu: true
273
+ num_gpus: 1
274
+ precision: 32-true
275
+ use_tqdm: true
276
+ log_times: false
277
+ z_per_sample: true
278
+ condition_mode: real
279
+ condition_scale: 1.0
280
+ postprocess_bfactors: true
281
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
282
+ sort: false
283
+ num_proteins: null
284
+ num_workers: 2
285
+ min_length: null
286
+ max_length: null
287
+ save_traj: false
288
+ final_only: true
289
+ cache_static_features: true
290
+ single_file: true
291
+ interpolant:
292
+ use_tqdm: true
293
+ min_t: 0.0
294
+ max_t: 0.99
295
+ rots:
296
+ distribution: uniform
297
+ sample_schedule: exp
298
+ exp_rate: 10
299
+ trans:
300
+ sample_schedule: linear
301
+ sampling:
302
+ num_timesteps: 20
303
+ self_condition: true
304
+ prior: conditional
305
+ prior_conditional:
306
+ gamma_trans: 0.2
307
+ gamma_rots: 0.2
308
+ batch_ot: intra
309
+ samples:
310
+ samples_per_protein: 250
311
+ batch_size: 10
312
+ num_res_squared: 6000000
313
+ folding_cfg: null
bbflow_base/lightning_logs/version_96/hparams.yaml ADDED
@@ -0,0 +1,314 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ cfg:
2
+ data:
3
+ dataset:
4
+ seed: 123
5
+ min_num_res: 0
6
+ max_num_res: 750
7
+ subset: null
8
+ split_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260805_113245
9
+ train_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/train/ATLAS_train.csv
10
+ valid_csv_paths:
11
+ - /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/validation/ATLAS_validation.csv
12
+ valid_dataset_names:
13
+ - ATLAS_validation
14
+ test_csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
15
+ validation:
16
+ metrics_subset:
17
+ - RMSD
18
+ - RMSF
19
+ - DCCM
20
+ - RMWD
21
+ - PCA-W2
22
+ - Cosine Sim
23
+ - Weak Transient Contacts
24
+ - Breaks and Clashes
25
+ valid_xtc_paths:
26
+ - /data/shared/wangyusong/Atlas
27
+ alphaflow_valid_pdb_paths:
28
+ - null
29
+ alphaflow_valid_rmsf_path: null
30
+ samples_per_valid_protein: 6
31
+ max_valid_batch_size: 100
32
+ max_valid_num_res_squared: 2900000
33
+ loader:
34
+ num_workers: 8
35
+ prefetch_factor: 10
36
+ pin_memory: false
37
+ sampler:
38
+ max_batch_size: 8
39
+ max_num_res_squared: 1125000
40
+ max_conformations: 20
41
+ experiment:
42
+ debug: false
43
+ use_wandb: false
44
+ use_tqdm: true
45
+ seed: 123
46
+ num_devices: 3
47
+ warm_start: /home/wangyusong/LD-FPG-main/bbflow_base/models/bbflow-0.1/bbflow-0.1.ckpt
48
+ model_only_warm_start: true
49
+ warm_start_cfg_override: false
50
+ use_swa: false
51
+ first_val_epoch: .inf
52
+ reset_epoch: false
53
+ batch_ot:
54
+ enabled: true
55
+ cost: kabsch
56
+ noise_per_sample: 1
57
+ training:
58
+ min_plddt_mask: null
59
+ loss: se3_vf_loss
60
+ bb_atom_scale: 0.1
61
+ trans_scale: 0.1
62
+ translation_loss_weight: 2.0
63
+ t_normalize_clip: 0.9
64
+ rotation_loss_weights: 1.0
65
+ aux_loss_weight: 1.0
66
+ aux_loss_t_pass: 0.75
67
+ t_bins: 4
68
+ ca_distmat_loss_weight: 0.0
69
+ ensemble_group_size: 0
70
+ force_grouped_batch: false
71
+ lambda_shape: 1.0
72
+ lambda_local_cov: 0.0
73
+ lambda_cross_cov: 0.0
74
+ lambda_rmsf: 1.0
75
+ lambda_mode_recon: 0.0
76
+ enm_warmup_epochs: 0
77
+ lambda_enm_warmup: 1.0
78
+ log_latent_batch_debug: false
79
+ full_model_activation_checkpoint: true
80
+ epoch_condition_probe: false
81
+ condition_probe_scale: 2.0
82
+ diagnostic_interval_steps: 50
83
+ lambda_generator_cov: 0.0
84
+ lambda_collective_measure: 0.0
85
+ lambda_md_subspace: 1.0
86
+ md_subspace_weight_exp: 0.0
87
+ lambda_md_subspace_trace: 1.0
88
+ cmfm_numerics_log_interval: 50
89
+ cmfm_grad_guard: true
90
+ cmfm_capture_failure: true
91
+ cmfm_dump_state_dict: true
92
+ generator_cov_use_cross: false
93
+ generator_cov_t_min: 0.1
94
+ generator_cov_t_max: 0.6
95
+ generator_cov_delta_scale: 1.0
96
+ generator_cov_num_deltas: 2
97
+ generator_cov_student_chunk_deltas: 1
98
+ generator_cov_teacher_num_deltas: 1
99
+ generator_cov_teacher_reuse_student_delta: true
100
+ generator_cov_teacher_trace_denominator: teacher
101
+ generator_cov_checkpoint: false
102
+ generator_cov_initial_trace_anchor: true
103
+ generator_cov_amplitude_anchor: md_trace
104
+ generator_cov_rollout_calibration: false
105
+ generator_cov_rollout_steps: 2
106
+ generator_cov_rollout_num_deltas: 1
107
+ generator_cov_rollout_max_examples: 4
108
+ generator_cov_rollout_interval_steps: 200
109
+ generator_cov_rollout_ema_decay: 0.9
110
+ lambda_gen_local_shape: 1.0
111
+ lambda_gen_cross_shape: 1.0
112
+ lambda_gen_trace_anchor: 0.05
113
+ per_frame_coeff_condition: true
114
+ lambda_motion: 1.0
115
+ lambda_q: 1.0
116
+ lambda_mode_orth: 1.0
117
+ lambda_pca_align: 0.0
118
+ lambda_condition_cycle: 0.0
119
+ oracle_condition: false
120
+ grad_flow_check: true
121
+ log_optimizer_coverage: true
122
+ wandb:
123
+ name: mdsubspace_20260805_113245
124
+ project: bbflow
125
+ save_dir: outputs/
126
+ tags: []
127
+ optimizer:
128
+ lr: 0.0001
129
+ reset_optimizer_on_load: false
130
+ warmup_lr: false
131
+ warmup_lr_factor: 0.01
132
+ trainer:
133
+ overfit_batches: 0
134
+ min_epochs: 1
135
+ max_epochs: 20
136
+ accelerator: gpu
137
+ precision: bf16-mixed
138
+ log_every_n_steps: 50
139
+ deterministic: false
140
+ strategy: ddp
141
+ check_val_every_n_epoch: 1
142
+ default_root_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260805_113245
143
+ accumulate_grad_batches: 1
144
+ max_steps: -1
145
+ profiler: null
146
+ num_sanity_val_steps: 0
147
+ checkpointer:
148
+ dirpath: ./
149
+ save_last: true
150
+ save_on_train_epoch_end: true
151
+ filename: epoch:{epoch:03d}
152
+ every_n_epochs: 2
153
+ save_top_k: -1
154
+ auto_insert_metric_name: false
155
+ checkpointer2: null
156
+ profiler:
157
+ enabled: false
158
+ modules: null
159
+ profile:
160
+ use_cuda: true
161
+ with_stack: false
162
+ stats:
163
+ group_by_stack_n: 0
164
+ group_by_input_shapes: false
165
+ prefixes:
166
+ - 'layer_0::'
167
+ - 'layer_1::'
168
+ sort_by: cpu_time_total
169
+ scheduler:
170
+ enabled: false
171
+ interpolant:
172
+ use_tqdm: true
173
+ batch_ot: intra
174
+ prior: conditional
175
+ prior_conditional:
176
+ gamma_trans: 0.2
177
+ gamma_rots: 0.2
178
+ min_t: 0.01
179
+ t_interval:
180
+ - 0.0
181
+ - 1.0
182
+ rots:
183
+ distribution: uniform
184
+ train_schedule: linear
185
+ sample_schedule: exp
186
+ exp_rate: 10
187
+ linear_scaling: 1
188
+ trans:
189
+ train_schedule: linear
190
+ sample_schedule: linear
191
+ sampling:
192
+ num_timesteps: 20
193
+ self_condition: true
194
+ noise_res_scaling_power: 0.0
195
+ noise_scale: 1.0
196
+ t_sampling_focus: 0.0
197
+ model:
198
+ node_embed_size: 240
199
+ edge_embed_size: 120
200
+ embed:
201
+ index_embed_type: full
202
+ index_embed_dim: 128
203
+ time_embed_dim: 128
204
+ embed_aatype: true
205
+ aatype_embed_dim: 128
206
+ length_embed_dim: 16
207
+ embed_self_conditioning: true
208
+ num_bins_distance: 22
209
+ min_bin_distance: 1.0e-05
210
+ max_bin_distance: 20.0
211
+ embed_distogram: true
212
+ embed_direction: false
213
+ embed_direction_cutoff: 5
214
+ edge_features:
215
+ self_condition: true
216
+ gfa:
217
+ c_s: 240
218
+ c_z: 120
219
+ c_hidden: 120
220
+ no_heads: 8
221
+ no_qk_points: 8
222
+ no_v_points: 8
223
+ seq_tfmr_num_heads: 4
224
+ seq_tfmr_num_layers: 2
225
+ num_blocks: 6
226
+ latent:
227
+ enable: true
228
+ dim: 16
229
+ num_modes: 8
230
+ motion_message_passing_layers: 4
231
+ cross_cov_near_distance: 12.0
232
+ template_residual_scale: 1.0
233
+ template_remove_rotation: true
234
+ use_enm_features: false
235
+ enm_num_modes: 8
236
+ enm_cutoff: 12.0
237
+ enm_eps: 1.0e-06
238
+ node_cond_dim: 8
239
+ edge_cond_dim: 8
240
+ freeze_foundation: false
241
+ inject_embedder: true
242
+ inject_film: true
243
+ activation_checkpoint: true
244
+ shape_fingerprint_k: 5
245
+ shape_fingerprint_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k12_kabsch_v1.pt
246
+ motion_target_cache_path: /home/wangyusong/LD-FPG-main/bbflow_official_reproduction/shape_fingerprints/atlas_full_md_motion_targets_k12_kabsch_v1.pt
247
+ z_stochastic: false
248
+ collective_enable: false
249
+ collective_rank: 4
250
+ collective_hidden_dim: 128
251
+ collective_output_scale: 1.0
252
+ collective_spectrum_eps: 1.0e-06
253
+ mode_gauge_ridge: 1.0e-06
254
+ freeze_mode_head: false
255
+ track_condition_debug: false
256
+ collective_basis_from_data: false
257
+ collective_rate_weighted: true
258
+ mixture_components: 2
259
+ q_lstsq_ridge: 0.0001
260
+ q_cholesky_jitter: 0.0001
261
+ q_detach_projection: true
262
+ q_detach_shared_encoder: true
263
+ energy_from_q: false
264
+ energy_from_q_full_cov: false
265
+ sample_coefficients: true
266
+ pca_align_top_m: 2
267
+ inference:
268
+ name: w0_ep011
269
+ seed: 123
270
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260805_113245/epoch:011.ckpt
271
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference/cmfm
272
+ use_ckpt_name_in_outpath: true
273
+ use_gpu: true
274
+ num_gpus: 1
275
+ precision: 32-true
276
+ use_tqdm: true
277
+ log_times: false
278
+ z_per_sample: true
279
+ condition_mode: real
280
+ condition_scale: 1.0
281
+ postprocess_bfactors: true
282
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
283
+ sort: false
284
+ num_proteins: null
285
+ num_workers: 2
286
+ min_length: null
287
+ max_length: null
288
+ save_traj: false
289
+ final_only: true
290
+ cache_static_features: true
291
+ single_file: true
292
+ interpolant:
293
+ use_tqdm: true
294
+ min_t: 0.0
295
+ max_t: 0.99
296
+ rots:
297
+ distribution: uniform
298
+ sample_schedule: exp
299
+ exp_rate: 10
300
+ trans:
301
+ sample_schedule: linear
302
+ sampling:
303
+ num_timesteps: 20
304
+ self_condition: true
305
+ prior: conditional
306
+ prior_conditional:
307
+ gamma_trans: 0.2
308
+ gamma_rots: 0.2
309
+ batch_ot: intra
310
+ samples:
311
+ samples_per_protein: 250
312
+ batch_size: 10
313
+ num_res_squared: 6000000
314
+ folding_cfg: null
bbflow_base/outputs/hydra/.hydra/config.yaml ADDED
@@ -0,0 +1,285 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ data:
2
+ dataset:
3
+ seed: 123
4
+ min_num_res: 0
5
+ max_num_res: 750
6
+ subset: null
7
+ split_path: ${experiment.checkpointer.dirpath}
8
+ train_csv_path: ./dataset_csv/train/ATLAS_train.csv
9
+ valid_csv_paths:
10
+ - ./dataset_csv/validation/ATLAS_validation.csv
11
+ valid_dataset_names:
12
+ - ATLAS_validation
13
+ test_csv_path: ./dataset_csv/test/ATLAS_test.csv
14
+ validation:
15
+ metrics_subset:
16
+ - RMSD
17
+ - RMSF
18
+ - DCCM
19
+ - RMWD
20
+ - PCA-W2
21
+ - Cosine Sim
22
+ - Weak Transient Contacts
23
+ - Breaks and Clashes
24
+ valid_xtc_paths:
25
+ - ./datasets/ATLAS/
26
+ alphaflow_valid_pdb_paths:
27
+ - null
28
+ alphaflow_valid_rmsf_path: null
29
+ samples_per_valid_protein: 16
30
+ max_valid_batch_size: 100
31
+ max_valid_num_res_squared: 2900000
32
+ loader:
33
+ num_workers: 8
34
+ prefetch_factor: 10
35
+ pin_memory: false
36
+ sampler:
37
+ max_batch_size: 100
38
+ max_num_res_squared: 200000
39
+ max_conformations: 20
40
+ experiment:
41
+ debug: false
42
+ use_wandb: true
43
+ use_tqdm: true
44
+ seed: 123
45
+ num_devices: 1
46
+ warm_start: null
47
+ model_only_warm_start: false
48
+ warm_start_cfg_override: true
49
+ use_swa: false
50
+ first_val_epoch: 0
51
+ reset_epoch: false
52
+ batch_ot:
53
+ enabled: true
54
+ cost: kabsch
55
+ noise_per_sample: 1
56
+ training:
57
+ min_plddt_mask: null
58
+ loss: se3_vf_loss
59
+ bb_atom_scale: 0.1
60
+ trans_scale: 0.1
61
+ translation_loss_weight: 2.0
62
+ t_normalize_clip: 0.9
63
+ rotation_loss_weights: 1.0
64
+ aux_loss_weight: 1.0
65
+ aux_loss_t_pass: 0.75
66
+ t_bins: 4
67
+ ca_distmat_loss_weight: 0.0
68
+ ensemble_group_size: 0
69
+ force_grouped_batch: false
70
+ lambda_shape: 1.0
71
+ lambda_local_cov: 1.0
72
+ lambda_cross_cov: 1.0
73
+ lambda_rmsf: 0.25
74
+ lambda_mode_recon: 0.0
75
+ enm_warmup_epochs: 0
76
+ lambda_enm_warmup: 1.0
77
+ log_latent_batch_debug: false
78
+ full_model_activation_checkpoint: false
79
+ epoch_condition_probe: true
80
+ condition_probe_scale: 2.0
81
+ diagnostic_interval_steps: 50
82
+ lambda_generator_cov: 0.0
83
+ lambda_collective_measure: 0.0
84
+ lambda_md_subspace: 0.0
85
+ md_subspace_weight_exp: 0.0
86
+ lambda_md_subspace_trace: 0.0
87
+ cmfm_numerics_log_interval: 50
88
+ cmfm_grad_guard: true
89
+ cmfm_capture_failure: true
90
+ cmfm_dump_state_dict: true
91
+ generator_cov_use_cross: false
92
+ generator_cov_t_min: 0.1
93
+ generator_cov_t_max: 0.6
94
+ generator_cov_delta_scale: 1.0
95
+ generator_cov_num_deltas: 2
96
+ generator_cov_student_chunk_deltas: 1
97
+ generator_cov_teacher_num_deltas: 1
98
+ generator_cov_teacher_reuse_student_delta: true
99
+ generator_cov_teacher_trace_denominator: teacher
100
+ generator_cov_checkpoint: false
101
+ generator_cov_initial_trace_anchor: true
102
+ generator_cov_amplitude_anchor: md_trace
103
+ generator_cov_rollout_calibration: false
104
+ generator_cov_rollout_steps: 2
105
+ generator_cov_rollout_num_deltas: 1
106
+ generator_cov_rollout_max_examples: 4
107
+ generator_cov_rollout_interval_steps: 200
108
+ generator_cov_rollout_ema_decay: 0.9
109
+ lambda_gen_local_shape: 1.0
110
+ lambda_gen_cross_shape: 1.0
111
+ lambda_gen_trace_anchor: 0.05
112
+ wandb:
113
+ name: baseline
114
+ project: bbflow
115
+ save_dir: outputs/
116
+ tags: []
117
+ optimizer:
118
+ lr: 0.0001
119
+ reset_optimizer_on_load: false
120
+ warmup_lr: false
121
+ warmup_lr_factor: 0.01
122
+ trainer:
123
+ overfit_batches: 0
124
+ min_epochs: 1
125
+ max_epochs: 250
126
+ accelerator: gpu
127
+ precision: bf16-mixed
128
+ log_every_n_steps: 1
129
+ deterministic: false
130
+ strategy: ddp
131
+ check_val_every_n_epoch: 1
132
+ default_root_dir: outputs/
133
+ accumulate_grad_batches: 1
134
+ checkpointer:
135
+ dirpath: outputs/ckpt/${experiment.wandb.project}/${experiment.wandb.name}/${now:%Y-%m-%d}_${now:%H-%M-%S}
136
+ save_last: true
137
+ save_on_train_epoch_end: true
138
+ filename: epoch:{epoch:03d}
139
+ every_n_epochs: 1
140
+ save_top_k: -1
141
+ auto_insert_metric_name: false
142
+ checkpointer2: null
143
+ profiler:
144
+ enabled: false
145
+ modules: null
146
+ profile:
147
+ use_cuda: true
148
+ with_stack: false
149
+ stats:
150
+ group_by_stack_n: 0
151
+ group_by_input_shapes: false
152
+ prefixes:
153
+ - 'layer_0::'
154
+ - 'layer_1::'
155
+ sort_by: cpu_time_total
156
+ interpolant:
157
+ use_tqdm: ${experiment.use_tqdm}
158
+ batch_ot: intra
159
+ prior: conditional
160
+ prior_conditional:
161
+ gamma_trans: 0.2
162
+ gamma_rots: 0.2
163
+ min_t: 0.01
164
+ t_interval:
165
+ - 0.0
166
+ - 1.0
167
+ rots:
168
+ distribution: uniform
169
+ train_schedule: linear
170
+ sample_schedule: exp
171
+ exp_rate: 10
172
+ linear_scaling: 1
173
+ trans:
174
+ train_schedule: linear
175
+ sample_schedule: linear
176
+ sampling:
177
+ num_timesteps: 20
178
+ self_condition: ${model.edge_features.self_condition}
179
+ noise_res_scaling_power: 0.0
180
+ noise_scale: 1.0
181
+ t_sampling_focus: 0.0
182
+ model:
183
+ node_embed_size: 240
184
+ edge_embed_size: 120
185
+ embed:
186
+ index_embed_type: full
187
+ index_embed_dim: 128
188
+ time_embed_dim: 128
189
+ embed_aatype: true
190
+ aatype_embed_dim: 128
191
+ length_embed_dim: 16
192
+ embed_self_conditioning: true
193
+ num_bins_distance: 22
194
+ min_bin_distance: 1.0e-05
195
+ max_bin_distance: 20.0
196
+ embed_distogram: true
197
+ embed_direction: false
198
+ embed_direction_cutoff: 5
199
+ edge_features:
200
+ self_condition: true
201
+ gfa:
202
+ c_s: ${model.node_embed_size}
203
+ c_z: ${model.edge_embed_size}
204
+ c_hidden: 120
205
+ no_heads: 8
206
+ no_qk_points: 8
207
+ no_v_points: 8
208
+ seq_tfmr_num_heads: 4
209
+ seq_tfmr_num_layers: 2
210
+ num_blocks: 6
211
+ latent:
212
+ enable: true
213
+ dim: 16
214
+ num_modes: 8
215
+ motion_message_passing_layers: 4
216
+ cross_cov_near_distance: 12.0
217
+ template_residual_scale: 0.1
218
+ template_remove_rotation: true
219
+ use_enm_features: false
220
+ enm_num_modes: 8
221
+ enm_cutoff: 12.0
222
+ enm_eps: 1.0e-06
223
+ node_cond_dim: 8
224
+ edge_cond_dim: 8
225
+ freeze_foundation: true
226
+ inject_embedder: true
227
+ inject_film: true
228
+ activation_checkpoint: true
229
+ shape_fingerprint_k: 5
230
+ shape_fingerprint_cache_path: null
231
+ motion_target_cache_path: null
232
+ z_stochastic: false
233
+ collective_enable: false
234
+ collective_rank: 4
235
+ collective_hidden_dim: 128
236
+ collective_output_scale: 1.0
237
+ collective_spectrum_eps: 1.0e-06
238
+ mode_gauge_ridge: 1.0e-06
239
+ inference:
240
+ name: abl_zero
241
+ seed: 123
242
+ ckpt_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260803_002645/epoch:009.ckpt
243
+ output_dir: /data/shared/wangyusong/atals/bbflow_official_reproduction/inference/cmfm
244
+ use_ckpt_name_in_outpath: true
245
+ use_gpu: true
246
+ num_gpus: 3
247
+ precision: 32-true
248
+ use_tqdm: true
249
+ log_times: false
250
+ z_per_sample: true
251
+ condition_mode: zero
252
+ condition_scale: 0.92
253
+ coefficient_tilt_alpha: 0.0
254
+ postprocess_bfactors: true
255
+ csv_path: /data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
256
+ sort: false
257
+ num_proteins: null
258
+ num_workers: 2
259
+ min_length: null
260
+ max_length: null
261
+ save_traj: false
262
+ final_only: true
263
+ cache_static_features: true
264
+ single_file: true
265
+ interpolant:
266
+ use_tqdm: ${inference.use_tqdm}
267
+ min_t: 0.0
268
+ max_t: 0.99
269
+ rots:
270
+ distribution: uniform
271
+ sample_schedule: exp
272
+ exp_rate: 10
273
+ trans:
274
+ sample_schedule: linear
275
+ sampling:
276
+ num_timesteps: 20
277
+ self_condition: true
278
+ prior: conditional
279
+ prior_conditional:
280
+ gamma_trans: 0.2
281
+ gamma_rots: 0.2
282
+ samples:
283
+ samples_per_protein: 250
284
+ batch_size: 5
285
+ num_res_squared: 2000000
bbflow_base/outputs/hydra/.hydra/hydra.yaml ADDED
@@ -0,0 +1,170 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ hydra:
2
+ run:
3
+ dir: outputs/hydra/
4
+ sweep:
5
+ dir: multirun/${now:%Y-%m-%d}/${now:%H-%M-%S}
6
+ subdir: ${hydra.job.num}
7
+ launcher:
8
+ _target_: hydra._internal.core_plugins.basic_launcher.BasicLauncher
9
+ sweeper:
10
+ _target_: hydra._internal.core_plugins.basic_sweeper.BasicSweeper
11
+ max_batch_size: null
12
+ params: null
13
+ help:
14
+ app_name: ${hydra.job.name}
15
+ header: '${hydra.help.app_name} is powered by Hydra.
16
+
17
+ '
18
+ footer: 'Powered by Hydra (https://hydra.cc)
19
+
20
+ Use --hydra-help to view Hydra specific help
21
+
22
+ '
23
+ template: '${hydra.help.header}
24
+
25
+ == Configuration groups ==
26
+
27
+ Compose your configuration from those groups (group=option)
28
+
29
+
30
+ $APP_CONFIG_GROUPS
31
+
32
+
33
+ == Config ==
34
+
35
+ Override anything in the config (foo.bar=value)
36
+
37
+
38
+ $CONFIG
39
+
40
+
41
+ ${hydra.help.footer}
42
+
43
+ '
44
+ hydra_help:
45
+ template: 'Hydra (${hydra.runtime.version})
46
+
47
+ See https://hydra.cc for more info.
48
+
49
+
50
+ == Flags ==
51
+
52
+ $FLAGS_HELP
53
+
54
+
55
+ == Configuration groups ==
56
+
57
+ Compose your configuration from those groups (For example, append hydra/job_logging=disabled
58
+ to command line)
59
+
60
+
61
+ $HYDRA_CONFIG_GROUPS
62
+
63
+
64
+ Use ''--cfg hydra'' to Show the Hydra config.
65
+
66
+ '
67
+ hydra_help: ???
68
+ hydra_logging:
69
+ version: 1
70
+ formatters:
71
+ simple:
72
+ format: '[%(asctime)s][HYDRA] %(message)s'
73
+ handlers:
74
+ console:
75
+ class: logging.StreamHandler
76
+ formatter: simple
77
+ stream: ext://sys.stdout
78
+ root:
79
+ level: INFO
80
+ handlers:
81
+ - console
82
+ loggers:
83
+ logging_example:
84
+ level: DEBUG
85
+ disable_existing_loggers: false
86
+ job_logging:
87
+ version: 1
88
+ formatters:
89
+ simple:
90
+ format: '[%(asctime)s][%(name)s][%(levelname)s] - %(message)s'
91
+ handlers:
92
+ console:
93
+ class: logging.StreamHandler
94
+ formatter: simple
95
+ stream: ext://sys.stdout
96
+ file:
97
+ class: logging.FileHandler
98
+ formatter: simple
99
+ filename: ${hydra.runtime.output_dir}/${hydra.job.name}.log
100
+ root:
101
+ level: INFO
102
+ handlers:
103
+ - console
104
+ - file
105
+ disable_existing_loggers: false
106
+ env: {}
107
+ mode: RUN
108
+ searchpath: []
109
+ callbacks: {}
110
+ output_subdir: .hydra
111
+ overrides:
112
+ hydra:
113
+ - hydra.mode=RUN
114
+ task:
115
+ - inference.ckpt_path='/data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260803_002645/epoch:009.ckpt'
116
+ - inference.csv_path=/data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv
117
+ - inference.output_dir=/data/shared/wangyusong/atals/bbflow_official_reproduction/inference/cmfm
118
+ - inference.name=abl_zero
119
+ - inference.num_gpus=3
120
+ - inference.z_per_sample=true
121
+ - inference.samples.samples_per_protein=250
122
+ - inference.samples.batch_size=5
123
+ - inference.samples.num_res_squared=2000000
124
+ - inference.interpolant.sampling.num_timesteps=20
125
+ - inference.condition_scale=0.92
126
+ - inference.condition_mode=zero
127
+ job:
128
+ name: inference
129
+ chdir: null
130
+ override_dirname: inference.ckpt_path='/data/shared/wangyusong/atals/bbflow_official_reproduction/outputs/checkpoints/mdsubspace_20260803_002645/epoch:009.ckpt',inference.condition_mode=zero,inference.condition_scale=0.92,inference.csv_path=/data/shared/wangyusong/atals/bbflow_official_reproduction/dataset_csv/test/ATLAS_test.csv,inference.interpolant.sampling.num_timesteps=20,inference.name=abl_zero,inference.num_gpus=3,inference.output_dir=/data/shared/wangyusong/atals/bbflow_official_reproduction/inference/cmfm,inference.samples.batch_size=5,inference.samples.num_res_squared=2000000,inference.samples.samples_per_protein=250,inference.z_per_sample=true
131
+ id: ???
132
+ num: ???
133
+ config_name: inference
134
+ env_set: {}
135
+ env_copy: []
136
+ config:
137
+ override_dirname:
138
+ kv_sep: '='
139
+ item_sep: ','
140
+ exclude_keys: []
141
+ runtime:
142
+ version: 1.3.2
143
+ version_base: '1.3'
144
+ cwd: /home/wangyusong/LD-FPG-main/bbflow_base
145
+ config_sources:
146
+ - path: hydra.conf
147
+ schema: pkg
148
+ provider: hydra
149
+ - path: /home/wangyusong/LD-FPG-main/bbflow_base/configs
150
+ schema: file
151
+ provider: main
152
+ - path: ''
153
+ schema: structured
154
+ provider: schema
155
+ output_dir: /home/wangyusong/LD-FPG-main/bbflow_base/outputs/hydra
156
+ choices:
157
+ model: default
158
+ interpolant: default
159
+ experiment: default
160
+ data: default
161
+ hydra/env: default
162
+ hydra/callbacks: null
163
+ hydra/job_logging: default
164
+ hydra/hydra_logging: default
165
+ hydra/hydra_help: default
166
+ hydra/help: default
167
+ hydra/sweeper: basic
168
+ hydra/launcher: basic
169
+ hydra/output: default
170
+ verbose: false