"tests/python/common/test_batch-graph.py" did not exist on "611393021a85e10ccd433a264a3487726b7b1841"
Unverified Commit 8a8d36e9 authored by Minjie Wang's avatar Minjie Wang Committed by GitHub
Browse files

[Doc] add doc for DGLCSVDataset

[Doc] add doc for DGLCSVDataset
parents 39121dfd 6ce3c178
...@@ -18,6 +18,10 @@ Base Dataset Class ...@@ -18,6 +18,10 @@ Base Dataset Class
.. autoclass:: DGLDataset .. autoclass:: DGLDataset
:members: download, save, load, process, has_cache, __getitem__, __len__ :members: download, save, load, process, has_cache, __getitem__, __len__
CSV Dataset Class
-----------------
.. autoclass:: CSVDataset
Node Prediction Datasets Node Prediction Datasets
--------------------------------------- ---------------------------------------
......
This diff is collapsed.
...@@ -23,6 +23,7 @@ shows how to implement each component of it. ...@@ -23,6 +23,7 @@ shows how to implement each component of it.
* :ref:`guide-data-pipeline-process` * :ref:`guide-data-pipeline-process`
* :ref:`guide-data-pipeline-savenload` * :ref:`guide-data-pipeline-savenload`
* :ref:`guide-data-pipeline-loadogb` * :ref:`guide-data-pipeline-loadogb`
* :ref:`guide-data-pipeline-loadcsv`
.. toctree:: .. toctree::
:maxdepth: 1 :maxdepth: 1
...@@ -34,3 +35,4 @@ shows how to implement each component of it. ...@@ -34,3 +35,4 @@ shows how to implement each component of it.
data-process data-process
data-savenload data-savenload
data-loadogb data-loadogb
data-loadcsv
\ No newline at end of file
...@@ -6,8 +6,7 @@ from ..base import DGLError ...@@ -6,8 +6,7 @@ from ..base import DGLError
class CSVDataset(DGLDataset): class CSVDataset(DGLDataset):
""" This class aims to parse data from CSV files, construct DGLGraph """Dataset class that loads and parses graph data from CSV files.
and behaves as a DGLDataset.
Parameters Parameters
---------- ----------
...@@ -51,7 +50,9 @@ class CSVDataset(DGLDataset): ...@@ -51,7 +50,9 @@ class CSVDataset(DGLDataset):
any available graph-level data such as graph-level feature, labels. any available graph-level data such as graph-level feature, labels.
Examples Examples
[TODO]: link to a detailed web page. --------
Please refer to :ref:`guide-data-pipeline-loadcsv`.
""" """
META_YAML_NAME = 'meta.yaml' META_YAML_NAME = 'meta.yaml'
......
...@@ -222,6 +222,16 @@ dataset = SyntheticDataset() ...@@ -222,6 +222,16 @@ dataset = SyntheticDataset()
graph, label = dataset[0] graph, label = dataset[0]
print(graph, label) print(graph, label)
######################################################################
# Creating Dataset from CSV via :class:`~dgl.data.CSVDataset`
# ------------------------------------------------------------
#
# The previous examples describe how to create a dataset from CSV files
# step-by-step. DGL also provides a utility class :class:`~dgl.data.CSVDataset`
# for reading and parsing data from CSV files. See :ref:`guide-data-pipeline-loadcsv`
# for more details.
#
# Thumbnail credits: (Un)common Use Cases for Graph Databases, Michal Bachman # Thumbnail credits: (Un)common Use Cases for Graph Databases, Michal Bachman
# sphinx_gallery_thumbnail_path = '_static/blitz_6_load_data.png' # sphinx_gallery_thumbnail_path = '_static/blitz_6_load_data.png'
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment