One-click install
npx skills add https://github.com/robotlearning123/claude-scientific-skills --skill torch-geometric-robotlearning123
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: torch-geometric
Source: https://github.com/robotlearning123/claude-scientific-skills/tree/main/scientific-skills/torch_geometric
Command: npx skills add https://github.com/robotlearning123/claude-scientific-skills --skill torch-geometric-robotlearning123

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires torch, torch_geometric, and includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill provides tools for developing and training graph neural networks, enabling users to model complex relationships in data represented as graphs.

Core Features & Use Cases

  • Graph Neural Networks (GNNs): Node classification, link prediction, graph classification, etc.
  • Molecular Property Prediction: For drug discovery and chemical property prediction.
  • Social Network Analysis: For community detection and influence prediction.
  • 3D Geometric Data: For point clouds, meshes, and molecular structures.
  • Heterogeneous Graphs: For multi-type nodes and edges (e.g., knowledge graphs).
  • Large-Scale Graph Learning: For neighbor sampling and distributed training.
  • Use Case: Imagine you have a large citation network. Use this Skill to build a GNN model for node classification to predict the research field of each paper.

Quick Start

Install PyTorch Geometric and create a simple graph with the following code:

import torch
from torch_geometric.data import Data

# Create a simple graph with 3 nodes
edge_index = torch.tensor([[0, 1, 1, 2], [1, 0, 2, 1]], dtype=torch.long)
x = torch.tensor([[-1], [0], [1]], dtype=torch.float)
data = Data(x=x, edge_index=edge_index)
print(f"Nodes: {data.num_nodes}, Edges: {data.num_edges}")

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 in Python?

To build a graph neural network for node classification, use PyTorch Geometric to define graph structures with edge indices and node features, then train a GNN model to predict node labels. This Skill enables modeling relationships in graph-structured data like citation networks.

Can I train graph neural networks for molecular property prediction using PyTorch?

Yes, you can train graph neural networks for molecular property prediction using PyTorch. This Skill provides tools to model 3D geometric data and molecular structures, enabling chemical property prediction and drug discovery applications through graph representation learning.

Does this Skill support heterogeneous graphs for knowledge graph learning?

Yes, this Skill supports heterogeneous graphs for knowledge graph learning. It enables modeling of multi-type nodes and edges, allowing you to build and train graph neural networks that capture complex relationships in diverse graph-structured data.

What is the best way to handle large-scale graph learning with neighbor sampling?

The best way to handle large-scale graph learning is using neighbor sampling and distributed training. This Skill provides specialized graph neural network tools that enable efficient training on large graphs by sampling local neighborhoods during message passing.

Do I need PyTorch installed to use this graph neural network library?

Yes, you need PyTorch and Python installed to use this graph neural network library. PyTorch serves as the foundational deep learning framework required for graph representation, neural network model definition, and the training process.

How do I create a simple graph structure with PyTorch Geometric?

To create a simple graph, use the Data class from PyTorch Geometric, passing node features as a tensor and edge connections as an edge index tensor. This defines the graph structure required for training graph neural networks.