Unverified Commit 31e4a89b authored by Mufei Li's avatar Mufei Li Committed by GitHub
Browse files

[DGL-Go] Inference for Node Prediction Pipeline (full & ns) (#4095)

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update
parent 69226588
# Accuracy across 10 runs: 0.7819 ± 0.003176
version: 0.0.1
pipeline_name: nodepred
pipeline_mode: train
device: cuda:0
data:
name: pubmed
......@@ -23,5 +24,5 @@ general_pipeline:
lr: 0.01
weight_decay: 0.0005
loss: CrossEntropyLoss
save_path: "model.pth"
save_path: "results" # Directory to save the experiment results
num_runs: 10 # Number of experiments to run
version: 0.0.1
pipeline_name: nodepred
pipeline:
name: nodepred
mode: train
device: cpu
data:
name: cora
......
......@@ -106,5 +106,13 @@ def test_recipe(recipe):
def test_node_cora():
os.system('dgl configure nodepred --data cora --model gcn')
os.system('dgl train --cfg nodepred_cora_gcn.yaml')
assert os.path.exists('checkpoint.pth')
assert os.path.exists('model.pth')
assert os.path.exists('results')
assert os.path.exists('results/run_0.pth')
os.system('dgl configure-apply nodepred --cpt results/run_0.pth')
assert os.path.exists('apply_nodepred_cora_gcn.yaml')
os.system('dgl configure-apply nodepred --data cora --cpt results/run_0.pth --cfg apply.yaml')
assert os.path.exists('apply.yaml')
os.system('dgl apply --cfg apply.yaml')
assert os.path.exists('apply_results/output.csv')
os.system('dgl export --cfg apply.yaml --output apply.py')
assert os.path.exists('apply.py')
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