diff --git a/datasets/MUTAG/LICENSE b/datasets/MUTAG/LICENSE new file mode 100644 index 00000000..e69de29b diff --git a/datasets/MUTAG/MUTAG.ipynb b/datasets/MUTAG/MUTAG.ipynb new file mode 100644 index 00000000..1181f6ce --- /dev/null +++ b/datasets/MUTAG/MUTAG.ipynb @@ -0,0 +1,875 @@ +{ + "cells": [ + { + "attachments": {}, + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Data " + ] + }, + { + "cell_type": "code", + "execution_count": 265, + "metadata": {}, + "outputs": [], + "source": [ + "import json \n", + "import numpy as np\n", + "import torch\n", + "import scipy.sparse as sparse\n", + "import dgl\n", + "from gli.io import save_heterograph, Attribute" + ] + }, + { + "cell_type": "code", + "execution_count": 266, + "metadata": {}, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Done loading data from cached files.\n" + ] + } + ], + "source": [ + "dataset = dgl.data.MUTAGDataset()\n", + "graph = dataset[0]" + ] + }, + { + "cell_type": "code", + "execution_count": 269, + "metadata": {}, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Adding attribute _ID to SCHEMA\n", + "(3687,)\n", + "Adding attribute _ID to _Literal\n", + "(1104,)\n", + "Adding attribute _ID to bond\n", + "(9317,)\n", + "Adding attribute label to d\n", + "(9529,)\n", + "Adding attribute labels to d\n", + "(9529,)\n", + "Adding attribute test_mask to d\n", + "(9529,)\n", + "Adding attribute train_mask to d\n", + "(9529,)\n", + "Adding attribute _ID to d\n", + "(9529,)\n", + "Adding attribute _ID to hasStructure\n", + "(3526,)\n" + ] + } + ], + "source": [ + "node_groups = graph.ntypes\n", + "node_attrs = {}\n", + "num_nodes_dict = {}\n", + "for node_group in node_groups:\n", + " node_group_scheme = graph.node_attr_schemes(node_group)\n", + " node_group_attributes = []\n", + " for key in node_group_scheme:\n", + " name=str(key)\n", + " data=graph.nodes[node_group].data[name].numpy()\n", + " print(f'Adding attribute {name} to {node_group}')\n", + " print(data.shape)\n", + " node_group_attributes.append(Attribute(name, data))\n", + " node_attrs[node_group] = node_group_attributes\n", + " num_nodes_dict[node_group] = graph.num_nodes(node_group)" + ] + }, + { + "cell_type": "code", + "execution_count": 287, + "metadata": {}, + "outputs": [ + { + "data": { + "text/plain": [ + "9529" + ] + }, + "execution_count": 287, + "metadata": {}, + "output_type": "execute_result" + } + ], + "source": [ + "arr = graph.nodes['d'].data['label'].numpy()\n", + "len(arr)" + ] + }, + { + "cell_type": "code", + "execution_count": 270, + "metadata": {}, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Adding attribute _ID to ('SCHEMA', '22-rdf-syntax-ns#type', 'SCHEMA')\n", + "(3526,)\n", + "Adding attribute _ID to ('SCHEMA', 'owl#disjointWith', 'SCHEMA')\n", + "(6,)\n", + "Adding attribute _ID to ('SCHEMA', 'rdf-schema#domain', 'SCHEMA')\n", + "(19,)\n", + "Adding attribute _ID to ('SCHEMA', 'rdf-schema#range', 'SCHEMA')\n", + "(4,)\n", + "Adding attribute _ID to ('SCHEMA', 'rdf-schema#subClassOf', 'SCHEMA')\n", + "(138,)\n", + "Adding attribute _ID to ('SCHEMA', 'rev-22-rdf-syntax-ns#type', 'SCHEMA')\n", + "(3526,)\n", + "Adding attribute _ID to ('SCHEMA', 'rev-22-rdf-syntax-ns#type', 'bond')\n", + "(9317,)\n", + "Adding attribute _ID to ('SCHEMA', 'rev-22-rdf-syntax-ns#type', 'd')\n", + "(9529,)\n", + "Adding attribute _ID to ('SCHEMA', 'rev-owl#disjointWith', 'SCHEMA')\n", + "(6,)\n", + "Adding attribute _ID to ('SCHEMA', 'rev-rdf-schema#domain', 'SCHEMA')\n", + "(19,)\n", + "Adding attribute _ID to ('SCHEMA', 'rev-rdf-schema#range', 'SCHEMA')\n", + "(4,)\n", + "Adding attribute _ID to ('SCHEMA', 'rev-rdf-schema#subClassOf', 'SCHEMA')\n", + "(138,)\n", + "Adding attribute _ID to ('_Literal', 'rev-amesTestPositive', 'd')\n", + "(340,)\n", + "Adding attribute _ID to ('_Literal', 'rev-charge', 'd')\n", + "(9189,)\n", + "Adding attribute _ID to ('_Literal', 'rev-chromaberr', 'd')\n", + "(55,)\n", + "Adding attribute _ID to ('_Literal', 'rev-chromex', 'd')\n", + "(35,)\n", + "Adding attribute _ID to ('_Literal', 'rev-cytogen_ca', 'd')\n", + "(293,)\n", + "Adding attribute _ID to ('_Literal', 'rev-cytogen_sce', 'd')\n", + "(283,)\n", + "Adding attribute _ID to ('_Literal', 'rev-drosophila_rt', 'd')\n", + "(25,)\n", + "Adding attribute _ID to ('_Literal', 'rev-drosophila_slrl', 'd')\n", + "(25,)\n", + "Adding attribute _ID to ('_Literal', 'rev-micronuc_f', 'd')\n", + "(13,)\n", + "Adding attribute _ID to ('_Literal', 'rev-micronuc_m', 'd')\n", + "(13,)\n", + "Adding attribute _ID to ('_Literal', 'rev-mouse_lymph', 'd')\n", + "(203,)\n", + "Adding attribute _ID to ('_Literal', 'rev-salmonella', 'd')\n", + "(305,)\n", + "Adding attribute _ID to ('_Literal', 'rev-salmonella_n', 'd')\n", + "(61,)\n", + "Adding attribute _ID to ('_Literal', 'rev-salmonella_reduc', 'd')\n", + "(5,)\n", + "Adding attribute _ID to ('bond', '22-rdf-syntax-ns#type', 'SCHEMA')\n", + "(9317,)\n", + "Adding attribute _ID to ('bond', 'inBond', 'd')\n", + "(18634,)\n", + "Adding attribute _ID to ('bond', 'rev-hasBond', 'd')\n", + "(9317,)\n", + "Adding attribute _ID to ('d', '22-rdf-syntax-ns#type', 'SCHEMA')\n", + "(9529,)\n", + "Adding attribute _ID to ('d', 'amesTestPositive', '_Literal')\n", + "(340,)\n", + "Adding attribute _ID to ('d', 'charge', '_Literal')\n", + "(9189,)\n", + "Adding attribute _ID to ('d', 'chromaberr', '_Literal')\n", + "(55,)\n", + "Adding attribute _ID to ('d', 'chromex', '_Literal')\n", + "(35,)\n", + "Adding attribute _ID to ('d', 'cytogen_ca', '_Literal')\n", + "(293,)\n", + "Adding attribute _ID to ('d', 'cytogen_sce', '_Literal')\n", + "(283,)\n", + "Adding attribute _ID to ('d', 'drosophila_rt', '_Literal')\n", + "(25,)\n", + "Adding attribute _ID to ('d', 'drosophila_slrl', '_Literal')\n", + "(25,)\n", + "Adding attribute _ID to ('d', 'hasAtom', 'd')\n", + "(9189,)\n", + "Adding attribute _ID to ('d', 'hasBond', 'bond')\n", + "(9317,)\n", + "Adding attribute _ID to ('d', 'hasStructure', 'hasStructure')\n", + "(3526,)\n", + "Adding attribute _ID to ('d', 'micronuc_f', '_Literal')\n", + "(13,)\n", + "Adding attribute _ID to ('d', 'micronuc_m', '_Literal')\n", + "(13,)\n", + "Adding attribute _ID to ('d', 'mouse_lymph', '_Literal')\n", + "(203,)\n", + "Adding attribute _ID to ('d', 'rev-hasAtom', 'd')\n", + "(9189,)\n", + "Adding attribute _ID to ('d', 'rev-inBond', 'bond')\n", + "(18634,)\n", + "Adding attribute _ID to ('d', 'salmonella', '_Literal')\n", + "(305,)\n", + "Adding attribute _ID to ('d', 'salmonella_n', '_Literal')\n", + "(61,)\n", + "Adding attribute _ID to ('d', 'salmonella_reduc', '_Literal')\n", + "(5,)\n", + "Adding attribute _ID to ('hasStructure', 'rev-hasStructure', 'd')\n", + "(3526,)\n" + ] + } + ], + "source": [ + "edge_groups = graph.canonical_etypes\n", + "edge_attrs = {}\n", + "for edge_group in edge_groups:\n", + " edge_group_scheme = graph.edge_attr_schemes(edge_group)\n", + " edge_group_attributes = []\n", + " for key in edge_group_scheme:\n", + " name=str(key)\n", + " data=graph.edges[edge_group].data[name].numpy()\n", + " print(f'Adding attribute {name} to {edge_group}')\n", + " print(data.shape)\n", + " edge_group_attributes.append(Attribute(name, data))\n", + " edge_attrs[edge_group] = edge_group_attributes" + ] + }, + { + "cell_type": "code", + "execution_count": 271, + "metadata": {}, + "outputs": [], + "source": [ + "edge={}\n", + "for edge_group in edge_groups:\n", + " src_edges = graph.edges(etype=edge_group, order='srcdst')[0].numpy()\n", + " dst_edges = graph.edges(etype=edge_group, order='srcdst')[1].numpy()\n", + " edge_matrix = np.zeros((src_edges.size,2), dtype=np.int32)\n", + " for i,(src,dst) in enumerate(zip(src_edges,dst_edges)):\n", + " edge_matrix[i] = [src,dst]\n", + " edge[edge_group] = edge_matrix" + ] + }, + { + "cell_type": "code", + "execution_count": 272, + "metadata": {}, + "outputs": [ + { + "data": { + "text/plain": [ + "{'description': 'MUTAG Dataset.',\n", + " 'citation': '@article{Debnath1991StructureactivityRO,\\ntitle={Structure-activity relationship of mutagenic aromatic and heteroaromatic nitro compounds. Correlation with molecular orbital energies and hydrophobicity.},\\nauthor={Asim Kumar Debnath and R L Compadre and Gargi Debnath and Alan J. Shusterman and Corwin Hansch},\\njournal={Journal of medicinal chemistry},\\nyear={1991},\\nvolume={34 2},\\npages={786-97},\\nurl={https://api.semanticscholar.org/CorpusID:19990980}}',\n", + " 'data': {'Node': {'SCHEMA': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Node_SCHEMA__ID'}},\n", + " '_Literal': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Node__Literal__ID'}},\n", + " 'bond': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Node_bond__ID'}},\n", + " 'd': {'label': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Node_d_label'},\n", + " 'labels': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Node_d_labels'},\n", + " 'test_mask': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Node_d_test_mask'},\n", + " 'train_mask': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Node_d_train_mask'},\n", + " '_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Node_d__ID'}},\n", + " 'hasStructure': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Node_hasStructure__ID'}}},\n", + " 'Edge': {'SCHEMA_22-rdf-syntax-ns#type_SCHEMA': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_SCHEMA_22-rdf-syntax-ns#type_SCHEMA__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_SCHEMA_22-rdf-syntax-ns#type_SCHEMA__Edge'}},\n", + " 'SCHEMA_owl#disjointWith_SCHEMA': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_SCHEMA_owl#disjointWith_SCHEMA__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_SCHEMA_owl#disjointWith_SCHEMA__Edge'}},\n", + " 'SCHEMA_rdf-schema#domain_SCHEMA': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_SCHEMA_rdf-schema#domain_SCHEMA__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_SCHEMA_rdf-schema#domain_SCHEMA__Edge'}},\n", + " 'SCHEMA_rdf-schema#range_SCHEMA': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_SCHEMA_rdf-schema#range_SCHEMA__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_SCHEMA_rdf-schema#range_SCHEMA__Edge'}},\n", + " 'SCHEMA_rdf-schema#subClassOf_SCHEMA': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_SCHEMA_rdf-schema#subClassOf_SCHEMA__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_SCHEMA_rdf-schema#subClassOf_SCHEMA__Edge'}},\n", + " 'SCHEMA_rev-22-rdf-syntax-ns#type_SCHEMA': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_SCHEMA_rev-22-rdf-syntax-ns#type_SCHEMA__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_SCHEMA_rev-22-rdf-syntax-ns#type_SCHEMA__Edge'}},\n", + " 'SCHEMA_rev-22-rdf-syntax-ns#type_bond': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_SCHEMA_rev-22-rdf-syntax-ns#type_bond__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_SCHEMA_rev-22-rdf-syntax-ns#type_bond__Edge'}},\n", + " 'SCHEMA_rev-22-rdf-syntax-ns#type_d': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_SCHEMA_rev-22-rdf-syntax-ns#type_d__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_SCHEMA_rev-22-rdf-syntax-ns#type_d__Edge'}},\n", + " 'SCHEMA_rev-owl#disjointWith_SCHEMA': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_SCHEMA_rev-owl#disjointWith_SCHEMA__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_SCHEMA_rev-owl#disjointWith_SCHEMA__Edge'}},\n", + " 'SCHEMA_rev-rdf-schema#domain_SCHEMA': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_SCHEMA_rev-rdf-schema#domain_SCHEMA__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_SCHEMA_rev-rdf-schema#domain_SCHEMA__Edge'}},\n", + " 'SCHEMA_rev-rdf-schema#range_SCHEMA': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_SCHEMA_rev-rdf-schema#range_SCHEMA__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_SCHEMA_rev-rdf-schema#range_SCHEMA__Edge'}},\n", + " 'SCHEMA_rev-rdf-schema#subClassOf_SCHEMA': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_SCHEMA_rev-rdf-schema#subClassOf_SCHEMA__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_SCHEMA_rev-rdf-schema#subClassOf_SCHEMA__Edge'}},\n", + " '_Literal_rev-amesTestPositive_d': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge__Literal_rev-amesTestPositive_d__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge__Literal_rev-amesTestPositive_d__Edge'}},\n", + " '_Literal_rev-charge_d': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge__Literal_rev-charge_d__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge__Literal_rev-charge_d__Edge'}},\n", + " '_Literal_rev-chromaberr_d': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge__Literal_rev-chromaberr_d__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge__Literal_rev-chromaberr_d__Edge'}},\n", + " '_Literal_rev-chromex_d': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge__Literal_rev-chromex_d__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge__Literal_rev-chromex_d__Edge'}},\n", + " '_Literal_rev-cytogen_ca_d': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge__Literal_rev-cytogen_ca_d__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge__Literal_rev-cytogen_ca_d__Edge'}},\n", + " '_Literal_rev-cytogen_sce_d': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge__Literal_rev-cytogen_sce_d__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge__Literal_rev-cytogen_sce_d__Edge'}},\n", + " '_Literal_rev-drosophila_rt_d': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge__Literal_rev-drosophila_rt_d__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge__Literal_rev-drosophila_rt_d__Edge'}},\n", + " '_Literal_rev-drosophila_slrl_d': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge__Literal_rev-drosophila_slrl_d__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge__Literal_rev-drosophila_slrl_d__Edge'}},\n", + " '_Literal_rev-micronuc_f_d': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge__Literal_rev-micronuc_f_d__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge__Literal_rev-micronuc_f_d__Edge'}},\n", + " '_Literal_rev-micronuc_m_d': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge__Literal_rev-micronuc_m_d__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge__Literal_rev-micronuc_m_d__Edge'}},\n", + " '_Literal_rev-mouse_lymph_d': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge__Literal_rev-mouse_lymph_d__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge__Literal_rev-mouse_lymph_d__Edge'}},\n", + " '_Literal_rev-salmonella_d': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge__Literal_rev-salmonella_d__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge__Literal_rev-salmonella_d__Edge'}},\n", + " '_Literal_rev-salmonella_n_d': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge__Literal_rev-salmonella_n_d__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge__Literal_rev-salmonella_n_d__Edge'}},\n", + " '_Literal_rev-salmonella_reduc_d': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge__Literal_rev-salmonella_reduc_d__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge__Literal_rev-salmonella_reduc_d__Edge'}},\n", + " 'bond_22-rdf-syntax-ns#type_SCHEMA': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_bond_22-rdf-syntax-ns#type_SCHEMA__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_bond_22-rdf-syntax-ns#type_SCHEMA__Edge'}},\n", + " 'bond_inBond_d': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_bond_inBond_d__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_bond_inBond_d__Edge'}},\n", + " 'bond_rev-hasBond_d': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_bond_rev-hasBond_d__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_bond_rev-hasBond_d__Edge'}},\n", + " 'd_22-rdf-syntax-ns#type_SCHEMA': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_22-rdf-syntax-ns#type_SCHEMA__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_22-rdf-syntax-ns#type_SCHEMA__Edge'}},\n", + " 'd_amesTestPositive__Literal': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_amesTestPositive__Literal__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_amesTestPositive__Literal__Edge'}},\n", + " 'd_charge__Literal': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_charge__Literal__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_charge__Literal__Edge'}},\n", + " 'd_chromaberr__Literal': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_chromaberr__Literal__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_chromaberr__Literal__Edge'}},\n", + " 'd_chromex__Literal': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_chromex__Literal__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_chromex__Literal__Edge'}},\n", + " 'd_cytogen_ca__Literal': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_cytogen_ca__Literal__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_cytogen_ca__Literal__Edge'}},\n", + " 'd_cytogen_sce__Literal': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_cytogen_sce__Literal__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_cytogen_sce__Literal__Edge'}},\n", + " 'd_drosophila_rt__Literal': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_drosophila_rt__Literal__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_drosophila_rt__Literal__Edge'}},\n", + " 'd_drosophila_slrl__Literal': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_drosophila_slrl__Literal__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_drosophila_slrl__Literal__Edge'}},\n", + " 'd_hasAtom_d': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_hasAtom_d__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_hasAtom_d__Edge'}},\n", + " 'd_hasBond_bond': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_hasBond_bond__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_hasBond_bond__Edge'}},\n", + " 'd_hasStructure_hasStructure': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_hasStructure_hasStructure__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_hasStructure_hasStructure__Edge'}},\n", + " 'd_micronuc_f__Literal': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_micronuc_f__Literal__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_micronuc_f__Literal__Edge'}},\n", + " 'd_micronuc_m__Literal': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_micronuc_m__Literal__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_micronuc_m__Literal__Edge'}},\n", + " 'd_mouse_lymph__Literal': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_mouse_lymph__Literal__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_mouse_lymph__Literal__Edge'}},\n", + " 'd_rev-hasAtom_d': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_rev-hasAtom_d__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_rev-hasAtom_d__Edge'}},\n", + " 'd_rev-inBond_bond': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_rev-inBond_bond__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_rev-inBond_bond__Edge'}},\n", + " 'd_salmonella__Literal': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_salmonella__Literal__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_salmonella__Literal__Edge'}},\n", + " 'd_salmonella_n__Literal': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_salmonella_n__Literal__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_salmonella_n__Literal__Edge'}},\n", + " 'd_salmonella_reduc__Literal': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_salmonella_reduc__Literal__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_d_salmonella_reduc__Literal__Edge'}},\n", + " 'hasStructure_rev-hasStructure_d': {'_ID': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_hasStructure_rev-hasStructure_d__ID'},\n", + " '_Edge': {'description': '',\n", + " 'type': 'int',\n", + " 'format': 'Tensor',\n", + " 'file': 'MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz',\n", + " 'key': 'Edge_hasStructure_rev-hasStructure_d__Edge'}}},\n", + " 'Graph': {'_NodeList': {'file': 'MUTAG__heterograph__Graph_NodeList__804c9125dc997d017012d4a6d8e9623c.sparse.npz'}}},\n", + " 'is_heterogeneous': True}" + ] + }, + "execution_count": 272, + "metadata": {}, + "output_type": "execute_result" + } + ], + "source": [ + "save_heterograph(name=\"MUTAG\",\n", + " edge=edge,\n", + " node_attrs=node_attrs,\n", + " num_nodes_dict=num_nodes_dict,\n", + " edge_attrs=edge_attrs,\n", + " description=\"MUTAG Dataset.\",\n", + " citation=\"@article{Debnath1991StructureactivityRO,\\ntitle={Structure-activity relationship of mutagenic aromatic and heteroaromatic nitro compounds. Correlation with molecular orbital energies and hydrophobicity.},\\nauthor={Asim Kumar Debnath and R L Compadre and Gargi Debnath and Alan J. Shusterman and Corwin Hansch},\\njournal={Journal of medicinal chemistry},\\nyear={1991},\\nvolume={34 2},\\npages={786-97},\\nurl={https://api.semanticscholar.org/CorpusID:19990980}}\")" + ] + }, + { + "cell_type": "code", + "execution_count": 288, + "metadata": {}, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "MUTAG Dataset.\n" + ] + } + ], + "source": [ + "from gli.dataloading import read_gli_graph, read_gli_task, combine_graph_and_task\n", + "\n", + "g = read_gli_graph(\"./metadata.json\")\n" + ] + } + ], + "metadata": { + "kernelspec": { + "display_name": "Python 3", + "language": "python", + "name": "python3" + }, + "language_info": { + "codemirror_mode": { + "name": "ipython", + "version": 3 + }, + "file_extension": ".py", + "mimetype": "text/x-python", + "name": "python", + "nbconvert_exporter": "python", + "pygments_lexer": "ipython3", + "version": "3.11.5" + }, + "orig_nbformat": 4, + "vscode": { + "interpreter": { + "hash": "b0fa6594d8f4cbf19f97940f81e996739fb7646882a419484c72d19e05852a7e" + } + } + }, + "nbformat": 4, + "nbformat_minor": 2 +} diff --git a/datasets/MUTAG/README.md b/datasets/MUTAG/README.md new file mode 100644 index 00000000..e1c79e61 --- /dev/null +++ b/datasets/MUTAG/README.md @@ -0,0 +1,32 @@ +# MUTAG + +## Dataset Description + +MUTAG is a collection of nitroaromatic compounds. In this dataset, a single large heterogenous graph is used to represent various chemical compounds where Vertices represent atoms and edges represent bonds between corresponding atoms. + +The goal is to predict the mutagenicity of a given compound on Salmonella Typhimurium, which is denoted by the attribute 'label' on nodes of type 'd'. + +## Statistics +- Nodes: 27163 +- Edges: 148100 (including reverse edges) +- Target Category: d +- Number of Classes: 2 + + +## Citation + +`@article{Debnath1991StructureactivityRO, + title={Structure-activity relationship of mutagenic aromatic and heteroaromatic nitro compounds. Correlation with molecular orbital energies and hydrophobicity.}, + author={Asim Kumar Debnath and R L Compadre and Gargi Debnath and Alan J. Shusterman and Corwin Hansch}, + journal={Journal of medicinal chemistry}, + year={1991}, + volume={34 2}, + pages={ + 786-97 + }, + url={https://api.semanticscholar.org/CorpusID:19990980} +}` + +## Preprocessing +The data files and task config file in GLI format are transformed from the [DGL implementation](https://docs.dgl.ai/generated/dgl.data.MUTAGDataset.html#dgl.data.MUTAGDataset) Check MUTAG.ipynb for the preprocessing. + diff --git a/datasets/MUTAG/metadata.json b/datasets/MUTAG/metadata.json new file mode 100644 index 00000000..c8d23da8 --- /dev/null +++ b/datasets/MUTAG/metadata.json @@ -0,0 +1,889 @@ +{ + "description": "MUTAG Dataset.", + "citation": "@article{Debnath1991StructureactivityRO,\ntitle={Structure-activity relationship of mutagenic aromatic and heteroaromatic nitro compounds. Correlation with molecular orbital energies and hydrophobicity.},\nauthor={Asim Kumar Debnath and R L Compadre and Gargi Debnath and Alan J. Shusterman and Corwin Hansch},\njournal={Journal of medicinal chemistry},\nyear={1991},\nvolume={34 2},\npages={786-97},\nurl={https://api.semanticscholar.org/CorpusID:19990980}}", + "data": { + "Node": { + "SCHEMA": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Node_SCHEMA__ID" + } + }, + "_Literal": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Node__Literal__ID" + } + }, + "bond": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Node_bond__ID" + } + }, + "d": { + "label": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Node_d_label" + }, + "labels": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Node_d_labels" + }, + "test_mask": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Node_d_test_mask" + }, + "train_mask": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Node_d_train_mask" + }, + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Node_d__ID" + } + }, + "hasStructure": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Node_hasStructure__ID" + } + } + }, + "Edge": { + "SCHEMA_22-rdf-syntax-ns#type_SCHEMA": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_SCHEMA_22-rdf-syntax-ns#type_SCHEMA__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_SCHEMA_22-rdf-syntax-ns#type_SCHEMA__Edge" + } + }, + "SCHEMA_owl#disjointWith_SCHEMA": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_SCHEMA_owl#disjointWith_SCHEMA__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_SCHEMA_owl#disjointWith_SCHEMA__Edge" + } + }, + "SCHEMA_rdf-schema#domain_SCHEMA": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_SCHEMA_rdf-schema#domain_SCHEMA__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_SCHEMA_rdf-schema#domain_SCHEMA__Edge" + } + }, + "SCHEMA_rdf-schema#range_SCHEMA": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_SCHEMA_rdf-schema#range_SCHEMA__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_SCHEMA_rdf-schema#range_SCHEMA__Edge" + } + }, + "SCHEMA_rdf-schema#subClassOf_SCHEMA": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_SCHEMA_rdf-schema#subClassOf_SCHEMA__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_SCHEMA_rdf-schema#subClassOf_SCHEMA__Edge" + } + }, + "SCHEMA_rev-22-rdf-syntax-ns#type_SCHEMA": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_SCHEMA_rev-22-rdf-syntax-ns#type_SCHEMA__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_SCHEMA_rev-22-rdf-syntax-ns#type_SCHEMA__Edge" + } + }, + "SCHEMA_rev-22-rdf-syntax-ns#type_bond": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_SCHEMA_rev-22-rdf-syntax-ns#type_bond__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_SCHEMA_rev-22-rdf-syntax-ns#type_bond__Edge" + } + }, + "SCHEMA_rev-22-rdf-syntax-ns#type_d": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_SCHEMA_rev-22-rdf-syntax-ns#type_d__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_SCHEMA_rev-22-rdf-syntax-ns#type_d__Edge" + } + }, + "SCHEMA_rev-owl#disjointWith_SCHEMA": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_SCHEMA_rev-owl#disjointWith_SCHEMA__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_SCHEMA_rev-owl#disjointWith_SCHEMA__Edge" + } + }, + "SCHEMA_rev-rdf-schema#domain_SCHEMA": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_SCHEMA_rev-rdf-schema#domain_SCHEMA__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_SCHEMA_rev-rdf-schema#domain_SCHEMA__Edge" + } + }, + "SCHEMA_rev-rdf-schema#range_SCHEMA": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_SCHEMA_rev-rdf-schema#range_SCHEMA__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_SCHEMA_rev-rdf-schema#range_SCHEMA__Edge" + } + }, + "SCHEMA_rev-rdf-schema#subClassOf_SCHEMA": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_SCHEMA_rev-rdf-schema#subClassOf_SCHEMA__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_SCHEMA_rev-rdf-schema#subClassOf_SCHEMA__Edge" + } + }, + "_Literal_rev-amesTestPositive_d": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge__Literal_rev-amesTestPositive_d__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge__Literal_rev-amesTestPositive_d__Edge" + } + }, + "_Literal_rev-charge_d": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge__Literal_rev-charge_d__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge__Literal_rev-charge_d__Edge" + } + }, + "_Literal_rev-chromaberr_d": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge__Literal_rev-chromaberr_d__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge__Literal_rev-chromaberr_d__Edge" + } + }, + "_Literal_rev-chromex_d": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge__Literal_rev-chromex_d__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge__Literal_rev-chromex_d__Edge" + } + }, + "_Literal_rev-cytogen_ca_d": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge__Literal_rev-cytogen_ca_d__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge__Literal_rev-cytogen_ca_d__Edge" + } + }, + "_Literal_rev-cytogen_sce_d": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge__Literal_rev-cytogen_sce_d__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge__Literal_rev-cytogen_sce_d__Edge" + } + }, + "_Literal_rev-drosophila_rt_d": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge__Literal_rev-drosophila_rt_d__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge__Literal_rev-drosophila_rt_d__Edge" + } + }, + "_Literal_rev-drosophila_slrl_d": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge__Literal_rev-drosophila_slrl_d__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge__Literal_rev-drosophila_slrl_d__Edge" + } + }, + "_Literal_rev-micronuc_f_d": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge__Literal_rev-micronuc_f_d__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge__Literal_rev-micronuc_f_d__Edge" + } + }, + "_Literal_rev-micronuc_m_d": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge__Literal_rev-micronuc_m_d__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge__Literal_rev-micronuc_m_d__Edge" + } + }, + "_Literal_rev-mouse_lymph_d": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge__Literal_rev-mouse_lymph_d__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge__Literal_rev-mouse_lymph_d__Edge" + } + }, + "_Literal_rev-salmonella_d": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge__Literal_rev-salmonella_d__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge__Literal_rev-salmonella_d__Edge" + } + }, + "_Literal_rev-salmonella_n_d": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge__Literal_rev-salmonella_n_d__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge__Literal_rev-salmonella_n_d__Edge" + } + }, + "_Literal_rev-salmonella_reduc_d": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge__Literal_rev-salmonella_reduc_d__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge__Literal_rev-salmonella_reduc_d__Edge" + } + }, + "bond_22-rdf-syntax-ns#type_SCHEMA": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_bond_22-rdf-syntax-ns#type_SCHEMA__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_bond_22-rdf-syntax-ns#type_SCHEMA__Edge" + } + }, + "bond_inBond_d": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_bond_inBond_d__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_bond_inBond_d__Edge" + } + }, + "bond_rev-hasBond_d": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_bond_rev-hasBond_d__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_bond_rev-hasBond_d__Edge" + } + }, + "d_22-rdf-syntax-ns#type_SCHEMA": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_22-rdf-syntax-ns#type_SCHEMA__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_22-rdf-syntax-ns#type_SCHEMA__Edge" + } + }, + "d_amesTestPositive__Literal": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_amesTestPositive__Literal__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_amesTestPositive__Literal__Edge" + } + }, + "d_charge__Literal": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_charge__Literal__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_charge__Literal__Edge" + } + }, + "d_chromaberr__Literal": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_chromaberr__Literal__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_chromaberr__Literal__Edge" + } + }, + "d_chromex__Literal": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_chromex__Literal__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_chromex__Literal__Edge" + } + }, + "d_cytogen_ca__Literal": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_cytogen_ca__Literal__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_cytogen_ca__Literal__Edge" + } + }, + "d_cytogen_sce__Literal": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_cytogen_sce__Literal__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_cytogen_sce__Literal__Edge" + } + }, + "d_drosophila_rt__Literal": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_drosophila_rt__Literal__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_drosophila_rt__Literal__Edge" + } + }, + "d_drosophila_slrl__Literal": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_drosophila_slrl__Literal__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_drosophila_slrl__Literal__Edge" + } + }, + "d_hasAtom_d": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_hasAtom_d__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_hasAtom_d__Edge" + } + }, + "d_hasBond_bond": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_hasBond_bond__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_hasBond_bond__Edge" + } + }, + "d_hasStructure_hasStructure": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_hasStructure_hasStructure__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_hasStructure_hasStructure__Edge" + } + }, + "d_micronuc_f__Literal": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_micronuc_f__Literal__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_micronuc_f__Literal__Edge" + } + }, + "d_micronuc_m__Literal": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_micronuc_m__Literal__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_micronuc_m__Literal__Edge" + } + }, + "d_mouse_lymph__Literal": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_mouse_lymph__Literal__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_mouse_lymph__Literal__Edge" + } + }, + "d_rev-hasAtom_d": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_rev-hasAtom_d__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_rev-hasAtom_d__Edge" + } + }, + "d_rev-inBond_bond": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_rev-inBond_bond__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_rev-inBond_bond__Edge" + } + }, + "d_salmonella__Literal": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_salmonella__Literal__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_salmonella__Literal__Edge" + } + }, + "d_salmonella_n__Literal": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_salmonella_n__Literal__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_salmonella_n__Literal__Edge" + } + }, + "d_salmonella_reduc__Literal": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_salmonella_reduc__Literal__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_d_salmonella_reduc__Literal__Edge" + } + }, + "hasStructure_rev-hasStructure_d": { + "_ID": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_hasStructure_rev-hasStructure_d__ID" + }, + "_Edge": { + "description": "", + "type": "int", + "format": "Tensor", + "file": "MUTAG__heterograph__9cea5bb4360603ef4117ff6b4c6c0103.npz", + "key": "Edge_hasStructure_rev-hasStructure_d__Edge" + } + } + }, + "Graph": { + "_NodeList": { + "file": "MUTAG__heterograph__Graph_NodeList__804c9125dc997d017012d4a6d8e9623c.sparse.npz" + } + } + }, + "is_heterogeneous": true +} \ No newline at end of file