easygraph.datasets.hypergraph.Yelp module#

class easygraph.datasets.hypergraph.Yelp.YelpRestaurant(data_root: str | None = None)[source]#

Bases: BaseData

The Yelp-Restaurant dataset is a restaurant-review network dataset for node classification task.

More details see the DHG or YOU ARE ALLSET: A MULTISET LEARNING FRAMEWORK FOR HYPERGRAPH NEURAL NETWORKS paper.

The content of the Yelp-Restaurant dataset includes the following:

  • num_classes: The number of classes: \(11\).

  • num_vertices: The number of vertices: \(50,758\).

  • num_edges: The number of edges: \(679,302\).

  • dim_features: The dimension of features: \(1,862\).

  • features: The vertex feature matrix. torch.Tensor with size \((50,758 \times 1,862)\).

  • edge_list: The edge list. List with length \(679,302\).

  • labels: The label list. torch.LongTensor with size \((50,758, )\).

  • state: The state list. torch.LongTensor with size \((50,758, )\).

  • city: The city list. torch.LongTensor with size \((50,758, )\).

Parameters:

data_root (str, optional) – The data_root has stored the data. If set to None, this function will auto-download from server and save into the default direction ~/.dhg/datasets/. Defaults to None.