torch-geometric

Build and train graph neural networks with PyTorch Geometric.

1|2|Updated Apr 29, 2026
One-click install
npx skills add https://github.com/fuzzy-dynamics/strings --skill torch-geometric-fuzzy-dynamics
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: torch-geometric
Source: https://github.com/fuzzy-dynamics/strings/tree/main/packages/skills/torch-geometric
Command: npx skills add https://github.com/fuzzy-dynamics/strings --skill torch-geometric-fuzzy-dynamics

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

PyTorch Geometric (PyG) is a comprehensive library for building and training graph neural networks; this skill centralizes guidance, examples, and references to accelerate learning and practical application.

Core Features & Use Cases

  • Graph data handling with Data and HeteroData structures
  • Support for common tasks: node classification, graph classification, link prediction, and heterogeneous graphs
  • Ready-made transforms, datasets, and model examples to jump-start projects

Quick Start

Train a two-layer GNN on a toy graph using PyG to see end-to-end node classification results.

Frequently Asked Questions about torch-geometric

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I build a Graph Neural Network for node classification using PyTorch?

To build a Graph Neural Network for node classification, use PyTorch Geometric (PyG) to define the model, format graph edges in edge_index, and run a standard training loop to propagate node features and predict labels.

What is the best way to handle heterogeneous graph data in PyG?

Handling heterogeneous graph data in PyG uses the HeteroData structure to manage varying node and edge types, enabling you to train models that process complex relational data for tasks like heterogeneous link prediction.

How do I scale GNN training for large graphs with NeighborLoader?

Scaling GNN training for large graphs uses the NeighborLoader to sample localized subgraphs, allowing standard training loops to process massive datasets without exceeding memory limits during node or graph classification.

Does PyG support link prediction tasks?

PyG supports link prediction by providing data structures and model examples that learn edge representations, letting you train Graph Neural Networks to predict missing connections between nodes.

Do I need PyTorch installed to use PyG?

You need PyTorch installed as a prerequisite, because PyG builds directly upon its framework to provide the Data structures, transforms, and model layers required for Graph Neural Network training.