stgraph.dataset.static package¶
Submodules¶
stgraph.dataset.static.cora_dataloader module¶
Citation network consisting of scientific publications.
- class stgraph.dataset.static.cora_dataloader.CoraDataLoader(verbose: bool = False, redownload: bool = False)[source]¶
Bases:
STGraphStaticDatasetCitation network consisting of scientific publications.
The Cora dataset consists of 2708 scientific publications classified into one of seven classes. The citation network consists of 5429 links. Each publication in the dataset is described by a 0/1-valued word vector indicating the absence/presence of the corresponding word from the dictionary. The dictionary consists of 1433 unique words.
This class provides functionality for loading, processing, and accessing the Cora dataset for use in deep learning tasks such as graph-based node classification.
gdata¶ num_nodes
num_edges
num_feats
num_classes
2708
10556
1433
7
Example
from stgraph.dataset import CoraDataLoader cora = CoraDataLoader() num_nodes = cora.gdata["num_nodes"] edge_list = cora.get_edges()
- Parameters:
verbose (bool, optional) – Flag to control whether to display verbose info (default is False)
redownload (bool, optional (default is False)) – Redownload the dataset online and save to cache
- name¶
The name of the dataset.
- Type:
str
- gdata¶
Graph meta data.
- Type:
dict
stgraph.dataset.static.stgraph_static_dataset module¶
Base class for all STGraph static graph datasets.
- class stgraph.dataset.static.stgraph_static_dataset.STGraphStaticDataset[source]¶
Bases:
STGraphDatasetBase class for static graph datasets.
Module contents¶
Collection of dataset loaders for Static real-world datasets.