pyg-nightly 2.7.0.dev20250607__py3-none-any.whl → 2.7.0.dev20250608__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {pyg_nightly-2.7.0.dev20250607.dist-info → pyg_nightly-2.7.0.dev20250608.dist-info}/METADATA +3 -2
- {pyg_nightly-2.7.0.dev20250607.dist-info → pyg_nightly-2.7.0.dev20250608.dist-info}/RECORD +79 -79
- torch_geometric/__init__.py +5 -4
- torch_geometric/_compile.py +3 -2
- torch_geometric/contrib/__init__.py +1 -1
- torch_geometric/data/data.py +3 -3
- torch_geometric/data/database.py +4 -0
- torch_geometric/data/dataset.py +9 -6
- torch_geometric/data/hetero_data.py +7 -6
- torch_geometric/data/hypergraph_data.py +1 -1
- torch_geometric/data/in_memory_dataset.py +2 -2
- torch_geometric/data/large_graph_indexer.py +1 -1
- torch_geometric/data/lightning/datamodule.py +28 -20
- torch_geometric/data/storage.py +1 -1
- torch_geometric/datasets/dbp15k.py +1 -1
- torch_geometric/datasets/molecule_net.py +3 -2
- torch_geometric/datasets/tag_dataset.py +1 -1
- torch_geometric/datasets/wikics.py +2 -1
- torch_geometric/deprecation.py +1 -1
- torch_geometric/distributed/rpc.py +2 -2
- torch_geometric/explain/algorithm/captum_explainer.py +2 -1
- torch_geometric/explain/algorithm/graphmask_explainer.py +7 -7
- torch_geometric/explain/explainer.py +1 -1
- torch_geometric/graphgym/config.py +3 -2
- torch_geometric/graphgym/imports.py +4 -2
- torch_geometric/graphgym/logger.py +1 -1
- torch_geometric/graphgym/models/encoder.py +2 -2
- torch_geometric/hash_tensor.py +5 -4
- torch_geometric/io/fs.py +5 -4
- torch_geometric/loader/ibmb_loader.py +4 -4
- torch_geometric/loader/mixin.py +2 -1
- torch_geometric/loader/prefetch.py +3 -2
- torch_geometric/nn/aggr/fused.py +1 -1
- torch_geometric/nn/conv/appnp.py +1 -1
- torch_geometric/nn/conv/gen_conv.py +1 -1
- torch_geometric/nn/conv/gravnet_conv.py +2 -1
- torch_geometric/nn/conv/hetero_conv.py +2 -1
- torch_geometric/nn/conv/meshcnn_conv.py +6 -4
- torch_geometric/nn/conv/message_passing.py +3 -2
- torch_geometric/nn/conv/sg_conv.py +1 -1
- torch_geometric/nn/conv/spline_conv.py +2 -1
- torch_geometric/nn/conv/ssg_conv.py +1 -1
- torch_geometric/nn/data_parallel.py +5 -4
- torch_geometric/nn/fx.py +7 -5
- torch_geometric/nn/models/attentive_fp.py +1 -1
- torch_geometric/nn/models/deep_graph_infomax.py +1 -1
- torch_geometric/nn/models/glem.py +20 -12
- torch_geometric/nn/models/gpse.py +2 -2
- torch_geometric/nn/models/graph_unet.py +1 -1
- torch_geometric/nn/models/metapath2vec.py +1 -1
- torch_geometric/nn/models/mlp.py +4 -2
- torch_geometric/nn/models/node2vec.py +1 -1
- torch_geometric/nn/models/rev_gnn.py +1 -1
- torch_geometric/nn/models/signed_gcn.py +1 -1
- torch_geometric/nn/nlp/llm.py +2 -1
- torch_geometric/nn/pool/__init__.py +8 -4
- torch_geometric/nn/pool/knn.py +13 -10
- torch_geometric/nn/to_hetero_module.py +4 -3
- torch_geometric/nn/to_hetero_transformer.py +3 -3
- torch_geometric/nn/to_hetero_with_bases_transformer.py +3 -3
- torch_geometric/sampler/base.py +7 -4
- torch_geometric/sampler/hgt_sampler.py +11 -1
- torch_geometric/sampler/neighbor_sampler.py +10 -8
- torch_geometric/testing/decorators.py +3 -2
- torch_geometric/testing/distributed.py +1 -1
- torch_geometric/transforms/add_gpse.py +11 -2
- torch_geometric/transforms/add_metapaths.py +8 -6
- torch_geometric/transforms/base_transform.py +2 -1
- torch_geometric/transforms/largest_connected_components.py +1 -1
- torch_geometric/transforms/random_link_split.py +1 -1
- torch_geometric/typing.py +13 -9
- torch_geometric/utils/_scatter.py +8 -6
- torch_geometric/utils/_spmm.py +15 -12
- torch_geometric/utils/convert.py +2 -2
- torch_geometric/utils/embedding.py +5 -3
- torch_geometric/utils/geodesic.py +4 -3
- torch_geometric/utils/sparse.py +3 -2
- {pyg_nightly-2.7.0.dev20250607.dist-info → pyg_nightly-2.7.0.dev20250608.dist-info}/WHEEL +0 -0
- {pyg_nightly-2.7.0.dev20250607.dist-info → pyg_nightly-2.7.0.dev20250608.dist-info}/licenses/LICENSE +0 -0
torch_geometric/utils/_spmm.py
CHANGED
@@ -63,18 +63,20 @@ def spmm(
|
|
63
63
|
|
64
64
|
# Always convert COO to CSR for more efficient processing:
|
65
65
|
if src.layout == torch.sparse_coo:
|
66
|
-
warnings.warn(
|
67
|
-
|
68
|
-
|
69
|
-
|
66
|
+
warnings.warn(
|
67
|
+
f"Converting sparse tensor to CSR format for more "
|
68
|
+
f"efficient processing. Consider converting your "
|
69
|
+
f"sparse tensor to CSR format beforehand to avoid "
|
70
|
+
f"repeated conversion (got '{src.layout}')", stacklevel=2)
|
70
71
|
src = src.to_sparse_csr()
|
71
72
|
|
72
73
|
# Warn in case of CSC format without gradient computation:
|
73
74
|
if src.layout == torch.sparse_csc and not other.requires_grad:
|
74
|
-
warnings.warn(
|
75
|
-
|
76
|
-
|
77
|
-
|
75
|
+
warnings.warn(
|
76
|
+
f"Converting sparse tensor to CSR format for more "
|
77
|
+
f"efficient processing. Consider converting your "
|
78
|
+
f"sparse tensor to CSR format beforehand to avoid "
|
79
|
+
f"repeated conversion (got '{src.layout}')", stacklevel=2)
|
78
80
|
|
79
81
|
# Use the default code path for `sum` reduction (works on CPU/GPU):
|
80
82
|
if reduce == 'sum':
|
@@ -99,10 +101,11 @@ def spmm(
|
|
99
101
|
# TODO The `torch.sparse.mm` code path with the `reduce` argument does
|
100
102
|
# not yet support CSC :(
|
101
103
|
if src.layout == torch.sparse_csc:
|
102
|
-
warnings.warn(
|
103
|
-
|
104
|
-
|
105
|
-
|
104
|
+
warnings.warn(
|
105
|
+
f"Converting sparse tensor to CSR format for more "
|
106
|
+
f"efficient processing. Consider converting your "
|
107
|
+
f"sparse tensor to CSR format beforehand to avoid "
|
108
|
+
f"repeated conversion (got '{src.layout}')", stacklevel=2)
|
106
109
|
src = src.to_sparse_csr()
|
107
110
|
|
108
111
|
return torch.sparse.mm(src, other, reduce)
|
torch_geometric/utils/convert.py
CHANGED
@@ -251,13 +251,13 @@ def from_networkx(
|
|
251
251
|
if group_edge_attrs is not None and not isinstance(group_edge_attrs, list):
|
252
252
|
group_edge_attrs = edge_attrs
|
253
253
|
|
254
|
-
for
|
254
|
+
for _, feat_dict in G.nodes(data=True):
|
255
255
|
if set(feat_dict.keys()) != set(node_attrs):
|
256
256
|
raise ValueError('Not all nodes contain the same attributes')
|
257
257
|
for key, value in feat_dict.items():
|
258
258
|
data_dict[str(key)].append(value)
|
259
259
|
|
260
|
-
for
|
260
|
+
for _, _, feat_dict in G.edges(data=True):
|
261
261
|
if set(feat_dict.keys()) != set(edge_attrs):
|
262
262
|
raise ValueError('Not all edges contain the same attributes')
|
263
263
|
for key, value in feat_dict.items():
|
@@ -42,7 +42,8 @@ def get_embeddings(
|
|
42
42
|
hook_handles.append(module.register_forward_hook(hook))
|
43
43
|
|
44
44
|
if len(hook_handles) == 0:
|
45
|
-
warnings.warn("The 'model' does not have any 'MessagePassing' layers"
|
45
|
+
warnings.warn("The 'model' does not have any 'MessagePassing' layers",
|
46
|
+
stacklevel=2)
|
46
47
|
|
47
48
|
training = model.training
|
48
49
|
model.eval()
|
@@ -123,8 +124,9 @@ def get_embeddings_hetero(
|
|
123
124
|
hook_handles.append(module.register_forward_hook(hook))
|
124
125
|
|
125
126
|
if len(hook_handles) == 0:
|
126
|
-
warnings.warn(
|
127
|
-
|
127
|
+
warnings.warn(
|
128
|
+
"The 'model' does not have any heterogenous "
|
129
|
+
"'MessagePassing' layers", stacklevel=2)
|
128
130
|
|
129
131
|
# Run the model forward pass
|
130
132
|
training = model.training
|
@@ -66,9 +66,10 @@ def geodesic_distance( # noqa: D417
|
|
66
66
|
|
67
67
|
if 'dest' in kwargs:
|
68
68
|
dst = kwargs['dest']
|
69
|
-
warnings.warn(
|
70
|
-
|
71
|
-
|
69
|
+
warnings.warn(
|
70
|
+
"'dest' attribute in 'geodesic_distance' is deprecated "
|
71
|
+
"and will be removed in a future release. Use the 'dst' "
|
72
|
+
"argument instead.", stacklevel=2)
|
72
73
|
|
73
74
|
max_distance = float('inf') if max_distance is None else max_distance
|
74
75
|
|
torch_geometric/utils/sparse.py
CHANGED
@@ -70,8 +70,9 @@ def dense_to_sparse(
|
|
70
70
|
f"three-dimensional (got {adj.dim()} dimensions)")
|
71
71
|
|
72
72
|
if mask is not None and adj.dim() == 2:
|
73
|
-
warnings.warn(
|
74
|
-
|
73
|
+
warnings.warn(
|
74
|
+
"Mask should not be provided in case the dense "
|
75
|
+
"adjacency matrix is two-dimensional", stacklevel=2)
|
75
76
|
mask = None
|
76
77
|
|
77
78
|
if mask is not None and mask.dim() != 2:
|
File without changes
|
{pyg_nightly-2.7.0.dev20250607.dist-info → pyg_nightly-2.7.0.dev20250608.dist-info}/licenses/LICENSE
RENAMED
File without changes
|