Spaces:
Running
Running
Commit
·
cebb5be
1
Parent(s):
244d41c
Update README.md
Browse files
README.md
CHANGED
@@ -7,7 +7,18 @@ sdk: static
|
|
7 |
pinned: false
|
8 |
---
|
9 |
|
10 |
-
The goal of this repository is to store the different graph datasets currently available as benchmarks, to provide them in an homogeneous and easily loadable way.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
11 |
|
12 |
|
13 |
Currently available graphs are:
|
|
|
7 |
pinned: false
|
8 |
---
|
9 |
|
10 |
+
The goal of this repository is to store the different graph datasets currently available as benchmarks, to provide them in an homogeneous and easily loadable way. For example, to load them in PyGeometric, you can do the following:
|
11 |
+
```python
|
12 |
+
from datasets import load_dataset
|
13 |
+
|
14 |
+
from torch_geometric.data import Data
|
15 |
+
from torch_geometric.loader import DataLoader
|
16 |
+
|
17 |
+
graphs_dataset = load_dataset("graphs-datasets/<dataset-name>")
|
18 |
+
# For the train set (replace by valid or test as needed)
|
19 |
+
graphs_list = [Data(graph) for graph in graphs_dataset["train"]]
|
20 |
+
graphs_pygeometric = DataLoader(graph_list)
|
21 |
+
```
|
22 |
|
23 |
|
24 |
Currently available graphs are:
|