Errors and bugs fixed, introduced better pipeline approach#127
Closed
Srishti-1806 wants to merge 1 commit into
Closed
Errors and bugs fixed, introduced better pipeline approach#127Srishti-1806 wants to merge 1 commit into
Srishti-1806 wants to merge 1 commit into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Added - Major New Features (v0.4.0 - Research-Grade Release)
1. Backend Abstraction Layer
GraphBackendabstract base class with automatic format detectionNetworkXBackend,PyGBackend,DGLBackendimplementationsget_backend()auto-detection for seamless format switching2. Spatial Indexing Optimization
SpatialIndex,KDTreeIndex,BallTreeIndexclassescreate_spatial_index()andfind_neighbors_vectorized()functions3. Temporal Graph Support
TemporalGraphclass for dynamic graphs with temporal edgescreate_temporal_graph()for autoregressive time-series modelingadd_temporal_edges_to_graph()for manual temporal connection4. Configuration-Driven Pipeline
GraphConfigdataclass for declarative graph definitionPipelineBuilderfor config-driven graph creationcreate_graph_from_config()for loading YAML/dict configsconfig_keisler.yaml,config_graphcast.yaml5. Feature Engineering Layer
FeatureExtractorclass with specialized weather feature functionsadd_wind_velocity(): Magnitude from u/v componentsadd_wind_direction(): Computing wind direction anglesadd_pressure_gradient(): Spatial pressure changesadd_temporal_encoding(): Sinusoidal temporal positional encodingadd_spatial_encoding(): Positional encoding based on coordinatesadd_node_degree_features(): Graph topology featuresnormalize_features(): Min-Max and Z-score normalization6. ML Pipeline Integration
GraphDatasetandPyGGraphDatasetfor PyTorch compatibilitycreate_dataloader(): Easy PyTorch DataLoader creationcreate_pyg_dataloader(): Specialized PyTorch Geometric DataLoadersbatch_graphs(): Vectorized batching of multiple graphscreate_model_input(): Format conversion for different ML frameworkssplit_graph_for_training(): Train/val/test node splitting7. Prebuilt Graph Architectures
load_prebuilt(): Quick access to common architectureslist_prebuilt(): Discover available architecturesregister_archetype(): Register custom architectures8. Enhanced Dependencies
[pytorch]: PyTorch + PyTorch Geometric[dgl]: DGL framework support[config]: YAML configuration support (PyYAML)[ml]: Full ML pipeline (torch, torch-geometric, scikit-learn)[visualisation]: Plotly for advanced visualization[all]: All optional dependencies9. Examples and Documentation
example_1_prebuilt.py: Quick start with prebuilt graphsexample_2_config.py: Configuration-driven creationexample_3_temporal.py: Temporal graphs for time seriesexample_4_features.py: Feature engineering workflowexample_5_spatial_indexing.py: Performance optimizationexample_6_ml_pipeline.py: ML integration and DataLoadersAdded (Previous Unreleased)
wmg.diagnostics.check_graph_consistency) to ensure structural health, such as verifying all grid nodes successfully connect to the mesh (Assert that all nodes are in g2m #42).filter_graph, for example to selectnodes by type (
node__type="mesh"), edges by component(
edge__component="g2m"), long edges (edge__len__gt=...), and spatialwindows (
node__pos__bbox=(8, 16, 8, 16)), including combined filters.#46, @leifdenby & @Joltsy10
__version__attribute to the package init#56 @AdMub
v0.3.0
Added
Add a decoding mask option to only include subset of grid nodes in m2g
#34 @joeloskarsson
Add test to check python codeblocks in README keep working as code changes
#38 @leifdenby
Add coords_crs and graph_crs arguments to allow for using lat-lons coordinates
or other CRSs as input. These are then converted to the specific CRS used when
constructing the graph.
#32, @joeloskarsson
Changed
[2, Ny, Nx]), to allow for non-regularly gridded coordinates
#32, @joeloskarsson
Fixed
Fix the bug with edgeless nodes being dropped
#51, @pkhalaj, @wi-spang, @krikru
Fix crash when trying to create flat multiscale graphs with >= 3 levels
#41, @joeloskarsson
Fix example in README
#38 @leifdenby
Maintenance
Update github CI actions, including pre-commit action to fix caching issue
that lead to tests failing
#48, @leifdenby
Update github CI actions to fix failing build and deploy of jupyterbook
#49,
#54, @leifdenby
Improve isolation of README example tests by executing each code block in an isolated namespace.
#65 @Shristi-Goel
v0.2.0
Added
added github pull-request template to ease contribution and review process
#18, @joeloskarsson
Allow for specifying relative distance as
rel_max_distwhen connecting nodes usingwithin_radiusmethod.#19
@joeloskarsson
save.to_pygcan now handle any number of 1D or 2D edge or node features whenconverting pytorch-geometric
Dataobjects totorch.Tensorobjects.#31
@maxiimilian
Add containing_rectangle graph connection method for m2g edges
#28
@joeloskarsson
Changed
Create different number of mesh nodes in x- and y-direction.
#21
@joeloskarsson
Changed the
refinement_factorargument into two: agrid_refinement_factorand alevel_refinement_factor.#19
@joeloskarsson
Connect grid nodes only to the bottom level of hierarchical mesh graphs.
#19
@joeloskarsson
Change default archetypes to match the graph creation from neural-lam.
#19
@joeloskarsson
Fixed
Fix
attributekeyword bug in save function#35
@joeloskarsson
Fix wrong number of mesh levels when grid is multiple of refinement factor
#26
@joeloskarsson
Maintenance
documentation #25,
@leifdenby
v0.1.0
First tagged release of
weather-model-graphswhich includes functionality tocreate three graph archetypes (Keisler nearest-neighbour, GraphCast multi-range
and Oskarsson hierarchical graphs) deliniating the different connectivity
options, background on graph-based data-driven models, 2D plotting utilities,
JupyterBook based documentation. In this version the graph assumes grid
coordinates are Cartesian coordinates.