feat: Implement Graph Specification Validator (Gap 6)#132
feat: Implement Graph Specification Validator (Gap 6)#132Prince637-boo wants to merge 3 commits into
Conversation
aaf82a7 to
56b3619
Compare
|
A few things:
On the actual validator:
I'm not trying to discourage this, this looks really good but a lot of stuff isnt solidified yet, I think it would be better to hold off on it for now and when we have a stable format and pipeline this would be a good starting point to build from |
|
Thanks @Joltsy10 for the detailed feedback! I completely understand the concern about the timing and the architectural placement. My goal was to provide a foundation for Gap 6 as early as possible, but I agree that the final graph structure needs to be more stable before we finalize the validation rules. I’m happy to put this on hold for now. Regarding the location: if the consensus shifts towards hosting the validator in neural-lam, I’m ready to port the logic there once the input formats (Lat/Lon vs Cartesian) are finalized. I'll stay tuned to the discussions in #473 to align with the upcoming standards. |
|
Please use the full PR template for this. How do you envision this relating to the type of validation in mllam/neural-lam#323 ? It seems a bit double to me to first validate that the graph is correct here, and then validate it again in neural-lam? But maybe this makes sense, if it checks different things? |
|
Thanks @joeloskarsson for the feedback! I'll update the PR with the proper template immediately. Regarding the relationship with neural-lam#323, I see them as complementary layers: 1.WMG Validator (Structural/Geometric): This ensures the graph itself is mathematically sound right after construction (e.g., L2 norm consistency on the sphere, bidirectional symmetry between hierarchical levels). It catches 'heavy' geometric errors at the source. 2.Neural-LAM Validator (Runtime/Integrity): This focuses on data loading and ensuring the graph matches the specific model requirements (dimensions, features) just before training. By validating in WMG, we avoid saving corrupted graph files to disk, which saves time and prevents debugging complex geometry issues during the training phase. I'm happy to refine the scope to ensure there is no overlap! |
Describe your changes
This PR introduces a Graph Structural & Geometric Validator for
weather-model-graphs. Whileneural-lam#323focuses on validating the "on-disk" format (shapes, types, and file structure) for model consumption, this validator focuses on the mathematical and geometric integrity of the graph during or after construction.Key features added:
.pttensors with themetadata.jsonto ensure consistency.Issue Link
Relates to the "Gap 6" (Graph Validation) roadmap and supports the ongoing integration efforts in
neural-lam#473.Type of change
Checklist before requesting a review
Checklist for reviewers
Author checklist after completed review
Checklist for assignee