Skip to content

Add configurable fixed and k-fold splits for omics datasets - #134

Merged
cornelislouisa merged 1 commit into
mainfrom
louisa/omics-kfold
Sep 12, 2026
Merged

Add configurable fixed and k-fold splits for omics datasets#134
cornelislouisa merged 1 commit into
mainfrom
louisa/omics-kfold

Conversation

@cornelislouisa

Copy link
Copy Markdown
Collaborator

Summary

  • Omics graphs and sklearn baselines now share compute_omics_split_indices: default fixed is still shuffle-42 then 70/15/15 (same cache path); k-fold is a stratified 3/1/1 rotation where data_seed is the test fold.
  • Fold-aware caches, wandb run names, and sync_num_nodes_from_dataset keep LayerNorm/flatten dims aligned when train size is not exactly 70%.
  • Optional grouping plumbing is present but defaults to null on every omics dataset. Hub revision is unchanged.

Test plan

  • pytest tests/data/test_omics_split_indices.py tests/utils/test_num_nodes_sync.py tests/data/test_dataset_config_consistency.py
  • python -m ogbench dataset=brca model=gcn
  • python -m ogbench dataset=brca model=gcn dataset.split_params.split_type=k-fold dataset.split_params.data_seed=0

Keep the historical 70/15/15 cache path as the default while letting each run pick a 3/1/1 test fold, and share that split between graphs and sklearn baselines.

Co-authored-by: Cursor <cursoragent@cursor.com>
num_nodes:
${calculate_num_nodes:${dataset.parameters.num_samples},${dataset.loader.parameters.train_val_test_split},${dataset.loader.parameters.node_sample_ratio},
${dataset.parameters.full_num_nodes}}
num_nodes: ${calculate_num_nodes:${dataset.parameters.num_samples},${dataset.loader.parameters.train_val_test_split},${dataset.loader.parameters.node_sample_ratio},${dataset.parameters.full_num_nodes},${dataset.split_params.split_type},${dataset.split_params.k}}

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

note for later, these are not the most readable...

@cornelislouisa
cornelislouisa merged commit c63f502 into main Sep 12, 2026
3 checks passed
@cornelislouisa
cornelislouisa deleted the louisa/omics-kfold branch September 12, 2026 02:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants