Skip to content

Prepare full one-degree spatial-grid Perceiver experiment - #848

Draft
alxmrs wants to merge 16 commits into
mainfrom
experiment/perceiver-spatial-grid-1deg
Draft

Prepare full one-degree spatial-grid Perceiver experiment#848
alxmrs wants to merge 16 commits into
mainfrom
experiment/perceiver-spatial-grid-1deg

Conversation

@alxmrs

@alxmrs alxmrs commented Aug 20, 2026

Copy link
Copy Markdown
Member

Summary

  • add coordinate-tied spatial-grid Perceiver encoding
  • add direct output cross-attention, overlap assembly, and smooth processor conditioning
  • add a 70-epoch one-degree train preset plus matching eval and viz presets
  • add a lab notebook with preflight gates; no training job has been submitted

This is stacked on #842 so its review diff excludes the native-SDPA implementation. After #842 lands, this branch can be rebased onto main.

Intended run

The preset assumes two GPUs, per-rank batch 2, and eight accumulation steps for effective global batch 32. It uses the shared OM4 data preset pointed at the one-degree data root. A real-data one-degree optimizer probe is required before releasing the 70-epoch allocation.

Validation

  • 402 passed, 2 skipped, 67 deselected, 10 xfailed
  • all pre-commit hooks pass from a cold cache
  • model construction: 75,194,225 trainable parameters; spatial encoder output patch extent 3 x 5 degrees

@alxmrs alxmrs left a comment

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Overall, this looks really solid.

Comment thread src/samudra/configs/perceiver_spatial_grid_1deg/data.yaml Outdated
Comment thread src/samudra/configs/perceiver_spatial_grid_1deg/model.yaml Outdated
gradient_accumulation_steps: 8
learning_rate: 0.0006
scheduler: {type: cosine}
loss: mse

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Samudra 2 typically uses a dynamic mse with a limit of 20 -- we can experiment with loss configs later. I agree, this loss is good to start with.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Agreed. I retained plain normalized MSE so this run stays comparable to the architecture searches and isolates the transport intervention. Dynamic MSE is a worthwhile later loss ablation after we have this architectural baseline.

Comment thread src/samudra/models/modules/decoder.py Outdated
return resized[..., scale_width : scale_width + target_width]


class DirectCrossAttentionIO(nn.Module):

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Should we run a search to test how many layers worth of cross and self attentions we should try?

This is surprisingly simple, but maybe that is the point.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

The simplicity is intentional for the decoder. The encoder is already a complete local Perceiver IO with input cross-attention, two latent self-attention stages, and output-query cross-attention. The decoder retains only one query-to-processor cross-attention plus FFN because the processor already mixes spatial state and Jesse’s localization rejected a second decoder latent/self-attention stack. I documented a focused follow-up over encoder depths {1,2,4} and direct cross-attention depths {1,2} after this baseline. I do not recommend delaying the full run for that search, and I would keep output-query self-attention out initially because it is quadratic within each output window and lacks supporting evidence.

Comment thread src/samudra/models/modules/decoder.py Outdated
@alxmrs
alxmrs force-pushed the experiment/perceiver-spatial-grid-1deg branch from 6d1baff to d3650b8 Compare August 21, 2026 00:52
Base automatically changed from feature/native-sdpa-perceiver to main August 24, 2026 21:43
@review-notebook-app

Copy link
Copy Markdown

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Backlog

Development

Successfully merging this pull request may close these issues.

1 participant