class_docstr: Dataset Class for `How Powerful Are Graph Neural Networks? <https://arxiv.org/abs/1810.00826>`_.
  
  This is adapted from `<https://github.com/weihua916/powerful-gnns/blob/master/dataset.zip>`_.
  
  The class provides an interface for nine datasets used in the paper along with the paper-specific
  settings. The datasets are ``'MUTAG'``, ``'COLLAB'``, ``'IMDBBINARY'``, ``'IMDBMULTI'``,
  ``'NCI1'``, ``'PROTEINS'``, ``'PTC'``, ``'REDDITBINARY'``, ``'REDDITMULTI5K'``.
  
  If ``degree_as_nlabel`` is set to ``False``, then ``ndata['label']`` stores the provided node label,
  otherwise ``ndata['label']`` stores the node in-degrees.
  
  For graphs that have node attributes, ``ndata['attr']`` stores the node attributes.
  For graphs that have no attribute, ``ndata['attr']`` stores the corresponding one-hot encoding
  of ``ndata['label']``.
  
  Parameters
  ---------
  name: str
      dataset name, one of
      (``'MUTAG'``, ``'COLLAB'``,         ``'IMDBBINARY'``, ``'IMDBMULTI'``,         ``'NCI1'``, ``'PROTEINS'``, ``'PTC'``,         ``'REDDITBINARY'``, ``'REDDITMULTI5K'``)
  self_loop: bool
      add self to self edge if true
  degree_as_nlabel: bool
      take node degree as label and feature if true
  transform: callable, optional
      A transform that takes in a :class:`~dgl.DGLGraph` object and returns
      a transformed version. The :class:`~dgl.DGLGraph` object will be
      transformed before every access.
  
  Attributes
  ----------
  num_classes : int
      Number of classes for multiclass classification
  
  Examples
  --------
  >>> data = GINDataset(name='MUTAG', self_loop=False)
  
  The dataset instance is an iterable
  
  >>> len(data)
  188
  >>> g, label = data[128]
  >>> g
  Graph(num_nodes=13, num_edges=26,
        ndata_schemes={'label': Scheme(shape=(), dtype=torch.int64), 'attr': Scheme(shape=(7,), dtype=torch.float32)}
        edata_schemes={})
  >>> label
  tensor(1)
  
  Batch the graphs and labels for mini-batch training
  
  >>> graphs, labels = zip(*[data[i] for i in range(16)])
  >>> batched_graphs = dgl.batch(graphs)
  >>> batched_labels = torch.tensor(labels)
  >>> batched_graphs
  Graph(num_nodes=330, num_edges=748,
        ndata_schemes={'label': Scheme(shape=(), dtype=torch.int64), 'attr': Scheme(shape=(7,), dtype=torch.float32)}
        edata_schemes={})
class_docstr_tok: ["Dataset","Class","for","`","How","Powerful","Are","Graph","Neural","Networks","?","<","https",":","\/\/arxiv.org\/abs\/1810.00826",">","`","_",".","This","is","adapted","from","`","<","https",":","\/\/github.com\/weihua916\/powerful-gnns\/blob\/master\/dataset.zip",">","`","_",".","The","class","provides","an","interface","for","nine","datasets","used","in","the","paper","along","with","the","paper-specific","settings",".","The","datasets","are","``","'MUTAG","'","``",",","``","'COLLAB","'","``",",","``","'IMDBBINARY","'","``",",","``","'IMDBMULTI","'","``",",","``","'NCI1","'","``",",","``","'PROTEINS","'","``",",","``","'PTC","'","``",",","``","'REDDITBINARY","'","``",",","``","'REDDITMULTI5K","'","``",".","If","``","degree_as_nlabel","``","is","set","to","``","False","``",",","then","``","ndata","[","'label","'","]","``","stores","the","provided","node","label",",","otherwise","``","ndata","[","'label","'","]","``","stores","the","node","in-degrees",".","For","graphs","that","have","node","attributes",",","``","ndata","[","'attr","'","]","``","stores","the","node","attributes",".","For","graphs","that","have","no","attribute",",","``","ndata","[","'attr","'","]","``","stores","the","corresponding","one-hot","encoding","of","``","ndata","[","'label","'","]","``",".","Parameters","--","--","--","--","-","name",":","str","dataset","name",",","one","of","(","``","'MUTAG","'","``",",","``","'COLLAB","'","``",",","``","'IMDBBINARY","'","``",",","``","'IMDBMULTI","'","``",",","``","'NCI1","'","``",",","``","'PROTEINS","'","``",",","``","'PTC","'","``",",","``","'REDDITBINARY","'","``",",","``","'REDDITMULTI5K","'","``",")","self_loop",":","bool","add","self","to","self","edge","if","true","degree_as_nlabel",":","bool","take","node","degree","as","label","and","feature","if","true","transform",":","callable",",","optional","A","transform","that","takes","in","a",":","class",":","`","~dgl.DGLGraph","`","object","and","returns","a","transformed","version",".","The",":","class",":","`","~dgl.DGLGraph","`","object","will","be","transformed","before","every","access",".","Attributes","--","--","--","--","--","num_classes",":","int","Number","of","classes","for","multiclass","classification","Examples","--","--","--","--",">",">",">","data","=","GINDataset","(","name='MUTAG","'",",","self_loop=False",")","The","dataset","instance","is","an","iterable",">",">",">","len","(","data",")","188",">",">",">","g",",","label","=","data","[","128","]",">",">",">","g","Graph","(","num_nodes=13",",","num_edges=26",",","ndata_schemes=","{","'label","'",":","Scheme","(","shape=","(",")",",","dtype=torch.int64",")",",","'attr","'",":","Scheme","(","shape=","(","7",",",")",",","dtype=torch.float32",")","}","edata_schemes=","{","}",")",">",">",">","label","tensor","(","1",")","Batch","the","graphs","and","labels","for","mini-batch","training",">",">",">","graphs",",","labels","=","zip","(","*","[","data","[","i","]","for","i","in","range","(","16",")","]",")",">",">",">","batched_graphs","=","dgl.batch","(","graphs",")",">",">",">","batched_labels","=","torch.tensor","(","labels",")",">",">",">","batched_graphs","Graph","(","num_nodes=330",",","num_edges=748",",","ndata_schemes=","{","'label","'",":","Scheme","(","shape=","(",")",",","dtype=torch.int64",")",",","'attr","'",":","Scheme","(","shape=","(","7",",",")",",","dtype=torch.float32",")","}","edata_schemes=","{","}",")"]
code: def _file_path(self):
      return os.path.join(
          self.raw_dir,
          "GINDataset",
          "dataset",
          self.name,
          "{}.txt".format(self.name),
      )
  
imports: import os
  import numpy
  from ..None import backend
  from ..convert import graph
  from ..utils import retry_method_with_fix
  from .dgl_dataset import DGLBuiltinDataset
  from .utils import download, extract_archive, load_graphs, load_info, loadtxt, save_graphs, save_info
label_desc: Use image node_id 6 for calling the GINDataset obj's underlying member method code with example usage: obj._file_path() and returns: os