Commit Graph

76 Commits

Author SHA1 Message Date
Zihao Ye
18bfec24cf [hotfix] Refactor edge softmax module (#1967)
* upd

* upd

* upd

* upd

* upd

* upd

* upd

* upd
2020-08-07 23:50:12 +08:00
Xiangkun Hu
3d8377062c [Doc] Dataset api doc add save_info(), load_info() (#1954)
* PPIDataset

* Revert "PPIDataset"

This reverts commit 264bd0c960.

* update doc

* Update data.rst

Co-authored-by: Jinjing Zhou <VoVAllen@users.noreply.github.com>
Co-authored-by: xiang song(charlie.song) <classicxsong@gmail.com>
2020-08-06 22:25:45 +08:00
Tong He
967ecb8064 [Dataset] Fix the docstring format for dgl.data section (#1941)
* PPIDataset

* Revert "PPIDataset"

This reverts commit 264bd0c960.

* update data rst

* update data doc and docstring

* API doc rst for dataset

* docstring

* update api doc

* add url format

* update docstring

* update citation graph

* update knowledge graph

* update gc datasets

* fix index

* Rst fix (#3)

* Fix syntax

* syntax

* update docstring

* update doc (#4)

* final update

* fix rdflib

* fix rdf

Co-authored-by: HuXiangkun <huxk_hit@qq.com>
Co-authored-by: Ubuntu <ubuntu@ip-172-31-51-214.ec2.internal>
Co-authored-by: xiang song(charlie.song) <classicxsong@gmail.com>
2020-08-06 14:47:49 +08:00
Zihao Ye
05a4337901 [Doc] Introduce the relation of message passing APIs and operators in docstring. (#1878)
* upd

* fix typo

* upd
2020-07-29 00:41:47 +08:00
Zihao Ye
2fa2b4534e [Feature] Support higher order derivative for message passing. (#1877)
* upd

* fix typo
2020-07-28 23:11:06 +08:00
Zihao Ye
2b8eb5be6f [refactor] Move spmm and sddmm operators to operator module (#1873)
* upd

* upd

* upd

* upd
2020-07-28 18:39:12 +08:00
Zihao Ye
bc209bff94 [bugfix] Fix the deterministic of kernel test and add documentation. (#1799)
* upd

* upd

* upd

* relax

* relax too

* upd
2020-07-14 04:22:31 +08:00
Quan (Andy) Gan
168a88e570 [Sampling] NodeDataLoader for node classification (#1635)
* neighbor sampler data loader first commit

* more commit

* nodedataloader

* fix

* update RGCN example

* update OGB

* fixes

* fix minibatch RGCN crashing with self loop

* reverting gatconv test code

* fix

* change to new solution that doesn't require tf dataloader

* fix

* lint

* fix

* fixes

* change doc

* fix docstring

* docstring fixes

* return seeds and input nodes from data loader

* fixes

* fix test

* fix windows build problem

* add pytorch wrapper

* fixes

* add pytorch wrapper

* add unit test

* add -1 support to sample_neighbors & fix docstrings

* docstring fix

* lint

* add minibatch rgcn evaluations

Co-authored-by: xiang song(charlie.song) <classicxsong@gmail.com>
Co-authored-by: Tong He <hetong007@gmail.com>
2020-07-02 16:31:05 +08:00
Mufei Li
36c7b77167 [LifeSci] Move to Independent Repo (#1592)
* Move LifeSci

* Remove doc
2020-06-05 21:28:24 +08:00
Mufei Li
90d2118da5 [Dataset] Change Cora Split (#1583)
* Use new version of Cora

* Fix import
2020-06-03 15:45:38 +08:00
Quan (Andy) Gan
7ba9cbc63e [Docs] Fix docstrings and documentations (#1420)
* fix docs of to_block

* fix

* oops

* more fixes
2020-05-19 13:04:55 +08:00
Zihao Ye
c2e61ce10b [Refactor] Restrict sparse format for DGLHeteroGraph (#1474)
* upd

* simplify

* further simplify

* lint

* doc

* upd

* upd

* upd

* upd

* upd

* upd

* upd

* lint

* rename format

* upd

* lint

* upd

* upd

* upd

* udp

* debug

* upd

* upd

* upd

* upd

* upd

* 无可厚非吧

* 中三边肥

* 你一定要喊吗

* lint

* upd

* upd

* upd

* upd

* upd

* upd

* upd

* Update unit_graph.h

Co-authored-by: Zihao Ye <yzh119@192.168.0.110>
Co-authored-by: Minjie Wang <wmjlyjemaine@gmail.com>
Co-authored-by: Quan (Andy) Gan <coin2028@hotmail.com>
2020-05-14 22:11:12 +08:00
Zihao Ye
93ac29ce34 [Refactor] Unify DGLGraph, BatchedDGLGraph and DGLSubGraph (#1216)
* upd

* upd

* upd

* lint

* fix

* fix test

* fix

* fix

* upd

* upd

* upd

* upd

* upd

* upd

* upd

* upd

* upd

* upd

* upd tutorial

* upd

* upd

* fix kg

* upd doc organization

* refresh test

* upd

* refactor doc

* fix lint

Co-authored-by: Minjie Wang <minjie.wang@nyu.edu>
2020-03-05 18:03:57 +08:00
Minjie Wang
5967d81782 [Doc] Re-organize API docs and tutorials (#1222)
* reorg tutorials and api docs

* fix
2020-01-26 21:26:34 +08:00
VoVAllen
a00636a02b [Tensorflow] Several nn & example (#1191)
* several nn example

* appnp

* fix lint

* lint

* add dgi

* fix

* fix

* fix

* fff

* docs

* 111

* fix

* change init

* change result

* tiaocan+1

* fix

* fix lint

* fix

* fix
2020-01-19 22:48:40 +08:00
Zihao Ye
ca302a13ac [Feature] Add dgl.nn.*.Sequential for usability (#1166)
* upd

* upd

* upd

* upd

* lint

* upd

* upd

* upd

* upd

Co-authored-by: VoVAllen <VoVAllen@users.noreply.github.com>
2020-01-09 12:39:22 +08:00
Mufei Li
cf9ba90fd4 [Chem] ACNN and various utilities (#1117)
* Add several splitting methods

* Update

* Update

* Update

* Update

* Update

* Fix

* Update

* Update

* Update

* Update

* Fix

* Fix

* Fix

* Fix

* Fix

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Finally

* CI
2019-12-19 11:54:40 +08:00
Da Zheng
869093e890 fix doc of EdgeSampler. (#1093) 2019-12-12 19:15:06 -08:00
Mufei Li
ead64de98e [Hetero] Batching/Unbatching DGLHeteroGraph (#1017)
* Update

* Update

* Update

* Fix

* CI style fix

* CI fix style

* Fix

* Try CI

* Fix test

* Update

* Update

* Update

* Update
2019-11-26 14:40:50 +08:00
Zihao Ye
9a0511c8e9 [NN] nn modules & examples update (#890)
* upd

* damn it

* fuck

* fuck pylint

* fudge

* remove some comments about MXNet

* upd

* upd

* damn it

* damn it

* fuck

* fuck

* upd

* upd

* pylint bastard

* upd

* upd

* upd

* upd

* upd

* upd

* upd

* upd

* upd
2019-11-03 17:29:42 -05:00
Mufei Li
52c7ef49fc [Model Zoo] AttentiveFP (#955)
* Update

* Fix style

* Update

* Update

* Fix

* Update

* Update
2019-10-26 01:57:34 +08:00
Mufei Li
577cf2e63b [Model Zoo] Refactor and Add Utils for Chemistry (#928)
* Refactor

* Add note

* Update

* CI
2019-10-22 00:47:45 +08:00
Quan (Andy) Gan
3ee7e11268 [Hetero][Tutorial] Heterograph tutorials (#878)
* heterograph tutorial skeleton

* [WIP][Tutorial] Heterogeneous graph tutorial

* fix

* update
2019-10-08 15:33:54 +08:00
Mufei Li
e2b7f745ca [Hetero] Doc (#892)
* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* Update

* style fixes & undefined name fix

* transpose=False in test
2019-10-06 20:17:40 +08:00
Da Zheng
15b951d4c4 [KG][Model] Knowledge graph embeddings (#888)
* upd

* fig edgebatch edges

* add test

* trigger

* Update README.md for pytorch PinSage example.

Add noting that the PinSage model example under
example/pytorch/recommendation only work with Python 3.6+
as its dataset loader depends on stanfordnlp package
which work only with Python 3.6+.

* Provid a frame agnostic API to test nn modules on both CPU and CUDA side.

1. make dgl.nn.xxx frame agnostic
2. make test.backend include dgl.nn modules
3. modify test_edge_softmax of test/mxnet/test_nn.py and
    test/pytorch/test_nn.py work on both CPU and GPU

* Fix style

* Delete unused code

* Make agnostic test only related to tests/backend

1. clear all agnostic related code in dgl.nn
2. make test_graph_conv agnostic to cpu/gpu

* Fix code style

* fix

* doc

* Make all test code under tests.mxnet/pytorch.test_nn.py
work on both CPU and GPU.

* Fix syntex

* Remove rand

* Add TAGCN nn.module and example

* Now tagcn can run on CPU.

* Add unitest for TGConv

* Fix style

* For pubmed dataset, using --lr=0.005 can achieve better acc

* Fix style

* Fix some descriptions

* trigger

* Fix doc

* Add nn.TGConv and example

* Fix bug

* Update data in mxnet.tagcn test acc.

* Fix some comments and code

* delete useless code

* Fix namming

* Fix bug

* Fix bug

* Add test for mxnet TAGCov

* Add test code for mxnet TAGCov

* Update some docs

* Fix some code

* Update docs dgl.nn.mxnet

* Update weight init

* Fix

* init version.

* change default value of regularization.

* avoid specifying adversarial_temperature

* use default eval_interval.

* remove original model.

* remove optimizer.

* set default value of num_proc

* set default value of log_interval.

* don't need to set neg_sample_size_valid.

* remove unused code.

* use uni_weight by default.

* unify model.

* rename model.

* remove unnecessary data sampler.

* remove the code for checkpoint.

* fix eval.

* raise exception in invalid arguments.

* remove RowAdagrad.

* remove unsupported score function for now.

* Fix bugs of kg
Update README

* Update Readme for mxnet distmult

* Update README.md

* Update README.md

* revert changes on dmlc

* add tests.

* update CI.

* add tests script.

* reorder tests in CI.

* measure performance.

* add results on wn18

* remove some code.

* rename the training script.

* new results on TransE.

* remove --train.

* add format.

* fix.

* use EdgeSubgraph.

* create PBGNegEdgeSubgraph to simplify the code.

* fix test

* fix CI.

* run nose for unit tests.

* remove unused code in dataset.

* change argument to save embeddings.

* test training and eval scripts in CI.

* check Pytorch version.

* fix a minor problem in config.

* fix a minor bug.

* fix readme.

* Update README.md

* Update README.md

* Update README.md
2019-10-02 12:57:29 -07:00
VoVAllen
9c790b1143 [Dataset] Add CoraFull, Amazon, KarateClub, Coauthor Dataset (#855)
* convert np.ndarray to backend tensor

* add datasets

* add qm7

* add dataset

* add dataset

* fix

* change ppi

* tu dataset

* add datasets

* fix

* fix

* fix

* fix

* add docstring

* docs

* doc
2019-10-01 01:19:59 +08:00
VoVAllen
e16667bfb9 [Fix] Fix Transform (#876)
* add transform

* lint

* lint

* fix

* fixmx

* fix

* add test

* fix typo

* fix default num_classes

* change to non-inplace operation

* fix lint

* fix

* fix

* fix lint

* fixlint
2019-09-26 21:21:53 -04:00
VoVAllen
bf8bb58f60 [Transform] Add to_self_loop, remove_self_loop, onehot_degree transform (#862)
* add transform

* lint

* lint

* fix

* fixmx

* fix

* add test

* fix typo

* fix default num_classes

* change to non-inplace operation

* fix lint

* fix
2019-09-21 00:05:38 +08:00
xiang song(charlie.song)
0a56d65223 [Feature] x_dot_x builtin kernel support (#831)
* upd

* fig edgebatch edges

* add test

* trigger

* Update README.md for pytorch PinSage example.

Add noting that the PinSage model example under
example/pytorch/recommendation only work with Python 3.6+
as its dataset loader depends on stanfordnlp package
which work only with Python 3.6+.

* Provid a frame agnostic API to test nn modules on both CPU and CUDA side.

1. make dgl.nn.xxx frame agnostic
2. make test.backend include dgl.nn modules
3. modify test_edge_softmax of test/mxnet/test_nn.py and
    test/pytorch/test_nn.py work on both CPU and GPU

* Fix style

* Delete unused code

* Make agnostic test only related to tests/backend

1. clear all agnostic related code in dgl.nn
2. make test_graph_conv agnostic to cpu/gpu

* Fix code style

* fix

* doc

* Make all test code under tests.mxnet/pytorch.test_nn.py
work on both CPU and GPU.

* Fix syntex

* Remove rand

* Start implementing masked-mm kernel.

Add base control flow code.

* Add masked dot declare

* Update func/variable name

* Skeleton compile OK

* Update Implement. Unify BinaryDot with BinaryReduce

* New Impl of x_dot_x, reuse binary reduce template

* Compile OK.

TODO:
1. make sure x_add_x, x_sub_x, x_mul_x, x_div_x work
2. let x_dot_x work
3. make sure backward of x_add_x, x_sub_x, x_mul_x, x_div_x work
4. let x_dot_x backward work

* Fix code style

* Now we can pass the tests/compute/test_kernel.py for add/sub/mul/div forward and backward

* Fix mxnet test code

* Add u_dot_v, u_dot_e, v_dot_e unitest.

* Update doc

* Now also support v_dot_u, e_dot_u, e_dot_v

* Add unroll for some loop

* Add some Opt for cuda backward of dot builtin.

Backward is still slow for dot

* Apply UnravelRavel opt for broadcast backward

* update docstring
2019-09-14 19:27:31 +08:00
VoVAllen
0fb13f7b9d [Feature] Data format (#728)
* Add serialization

* add serialization

* add serialization

* lalalalalalalala

* lalalalalalalala

* serialize

* serialize

* nnn

* WIP: import tvm runtime node system

* WIP: object system

* containers

* tested basic container composition

* tested custom object

* tmp

* fix setattr bug

* tested object container return

* fix lint

* some comments about get/set state

* fix lint

* fix lint

* update cython

* fix cython

* ffi doc

* fix doc

* WIP: using object system for graph

* c++ side refactoring done; compiled

* remove stale apis

* fix bug in DGLGraphCreate; passed test_graph.py

* fix bug in python modify; passed utest for pytorch/cpu

* fix lint

* Add serialization

* Add serialization

* fix

* fix typo

* serialize with new ffi

* commit

* commit

* commit

* save

* save

* save

* save

* commit

* clean

* Delete tt2.py

* fix lint

* Add serialization

* fix lint 2

* fix lint

* fix lint

* fix lint

* fix lint

* Fix Lint

* Add serialization

* Change to Macro

* fix

* fix

* fix bugs

* refactor

* refactor

* updating dmlc-core to include force flag

* trying tempfile

* delete leaked pointer

* Fix assert

* fix assert

* add comment and test case

* add graph labels

* add load labels

* lint

* lint

* add graph labels

* lint

*  fix windows

* fix

* update dmlc-core to latest

* fix

* fix camel naming
2019-09-09 20:57:51 +08:00
xiang song(charlie.song)
bcd33e0ac0 [Kernel][Perf] Message builtin with broadcasting performance optimization (#815)
* upd

* fig edgebatch edges

* add test

* trigger

* Update README.md for pytorch PinSage example.

Add noting that the PinSage model example under
example/pytorch/recommendation only work with Python 3.6+
as its dataset loader depends on stanfordnlp package
which work only with Python 3.6+.

* Provid a frame agnostic API to test nn modules on both CPU and CUDA side.

1. make dgl.nn.xxx frame agnostic
2. make test.backend include dgl.nn modules
3. modify test_edge_softmax of test/mxnet/test_nn.py and
    test/pytorch/test_nn.py work on both CPU and GPU

* Fix style

* Delete unused code

* Make agnostic test only related to tests/backend

1. clear all agnostic related code in dgl.nn
2. make test_graph_conv agnostic to cpu/gpu

* Fix code style

* fix

* doc

* Make all test code under tests.mxnet/pytorch.test_nn.py
work on both CPU and GPU.

* Fix syntex

* Remove rand

* Add TAGCN nn.module and example

* Now tagcn can run on CPU.

* Add unitest for TGConv

* Fix style

* For pubmed dataset, using --lr=0.005 can achieve better acc

* Fix style

* Fix some descriptions

* Test performance of udf

* trigger

* Fix doc

* Add nn.TGConv and example

* Update test code

* Fix bug

* Update data in mxnet.tagcn test acc.

* Fix some comments and code

* delete useless code

* Fix namming

* Fix bug

* Fix bug

* Add test for mxnet TAGCov

* Add test code for mxnet TAGCov

* Update some docs

* Fix some code

* Update docs dgl.nn.mxnet

* Update weight init

* Fix

* Minor opt for URRevel

* Delete test code

* Update code style and notes.

* Fix func name
2019-09-09 01:11:37 +08:00
Mufei Li
189c2c0907 [Model Zoo] Refactor Model Zoo for Chemistry (#839)
* Update

* Update

* Update

* Update fix

* Update

* Update

* Refactor

* Update

* Update

* Update

* Update

* Update

* Update

* Fix style
2019-09-07 20:01:09 +08:00
VoVAllen
1e2abc9ae9 [Docs] Adjust doc (#808)
* fix doc

* poke ci

* poke ci

* upd

* fix doc

* upd

* add title for all nn

* upd
2019-08-31 00:17:49 +08:00
Quan (Andy) Gan
98b825e3a1 [Doc][Conda] Fixing pytorch.nn.factory docs and Conda license (#805)
* [Conda] Update license

* doc fixes
2019-08-28 16:56:31 +08:00
Quan (Andy) Gan
a5b661a23e [Doc] Fixing pytorch nn factory docs (#804) 2019-08-28 16:23:06 +08:00
Quan (Andy) Gan
828e269cf4 [Doc] Fixing KNNGraph docs (#803) 2019-08-28 14:52:22 +08:00
xiang song(charlie.song)
e17add5602 [NN] Add MXNet impl for TAGCN module. (#799)
* upd

* fig edgebatch edges

* add test

* trigger

* Update README.md for pytorch PinSage example.

Add noting that the PinSage model example under
example/pytorch/recommendation only work with Python 3.6+
as its dataset loader depends on stanfordnlp package
which work only with Python 3.6+.

* Provid a frame agnostic API to test nn modules on both CPU and CUDA side.

1. make dgl.nn.xxx frame agnostic
2. make test.backend include dgl.nn modules
3. modify test_edge_softmax of test/mxnet/test_nn.py and
    test/pytorch/test_nn.py work on both CPU and GPU

* Fix style

* Delete unused code

* Make agnostic test only related to tests/backend

1. clear all agnostic related code in dgl.nn
2. make test_graph_conv agnostic to cpu/gpu

* Fix code style

* fix

* doc

* Make all test code under tests.mxnet/pytorch.test_nn.py
work on both CPU and GPU.

* Fix syntex

* Remove rand

* Add TAGCN nn.module and example

* Now tagcn can run on CPU.

* Add unitest for TGConv

* Fix style

* For pubmed dataset, using --lr=0.005 can achieve better acc

* Fix style

* Fix some descriptions

* trigger

* Fix doc

* Add nn.TGConv and example

* Fix bug

* Update data in mxnet.tagcn test acc.

* Fix some comments and code

* delete useless code

* Fix namming

* Fix bug

* Fix bug

* Add test code for mxnet TAGCov

* Update some docs

* Fix some code

* Update docs dgl.nn.mxnet

* Update weight init

* Fix
2019-08-28 13:19:17 +08:00
Quan (Andy) Gan
dc19cd5687 [Example] Dynamic Graph CNN on Point Cloud (#789)
* initial commit

* second commit

* another commit

* change docstring

* migrating to dgl.nn

* fixes

* docs

* lint

* multiple fixes

* doc
2019-08-28 09:21:57 +08:00
Zihao Ye
650f6ee1e0 [NN] Add commonly used GNN models from examples to dgl.nn modules. (#748)
* gat

* upd

* upd sage

* upd

* upd

* upd

* upd

* upd

* add gmmconv

* upd ggnn

* upd

* upd

* upd

* upd

* add citation examples

* add README

* fix cheb

* improve doc

* formula

* upd

* trigger

* lint

* lint

* upd

* add test for transform

* add test

* check

* upd

* improve doc

* shape check

* upd

* densechebconv, currently not correct (?)

* fix cheb

* fix

* upd

* upd sgc-reddit

* upd

* trigger
2019-08-27 18:21:19 +08:00
Minjie Wang
708765f0a1 [NN] RGCN modules (#744)
* rgcn module

* support id input

* WIP: model codes

* use faster index select

* dropout

* self loop

* WIP: link prediction

* fix lint

* WIP: docs

* docstring

* docstring

* merge two child classes

* mxnet rgcn module

* fix lint

* fix lint

* fix rename bug

* add uniform edge sampler

* fix fn name

* docstring

* fix mxnet rgcn module

* fix mx rgcn

* enable test on cuda
2019-08-23 16:38:48 -04:00
Zihao Ye
742d79a792 upd (#741) 2019-08-06 18:39:05 +08:00
Zihao Ye
5d3f470b72 [Feature] DGL Pooling modules (#669)
* removal doc

* glob

* upd

* rm knn

* add softmax

* upd

* upd

* add broadcast and s2s

* optimize max_on

* forsaken changes to heterograph

* upd

* upd

* upd

* upd

* upd

* bugfix

* upd

* upd

* upd

* upd

* format upd

* upd format

* upd doc

* upd

* import order

* upd

* rm warnings

* fix

* upd test

* upd

* upd

* fix device

* upd

* upd

* upd

* upd

* remove 1.1

* upd

* trigger

* trigger

* add more tests

* fix device

* upd

* upd

* refactor

* fix?

* fix

* upd docstring

* refactor

* upd

* fix

* upd

* upd

* upd

* fix

* upd docs

* add shape

* refactor & upd doc

* upd doc

* upd
2019-08-06 01:43:25 +08:00
Minjie Wang
fc9d30fae4 [Graph] add local scope function (#735)
* add local scope function

* fix lint

* fix docstring

* change local_scope to local_var; add context manager

* address comments
2019-08-02 00:11:48 -04:00
Quan (Andy) Gan
e9e587b6cb [Refactor] C random number generator (#729)
* rng refactor

* fix bugs

* unit test

* remove setsize

* lint

* fix test

* use explicit instantiation instead of inlining

* stricter test

* use tvm solution

* moved python interface to dgl.random

* lint

* address comments

* make getthreadid an inline function
2019-07-31 17:54:30 +08:00
Minjie Wang
e16e895d53 [Doc] fix some document warnings (#645)
* fix doc

* fix some format and warnings

* fix
2019-06-11 13:41:41 -04:00
Da Zheng
463807c511 [Doc] indexing missing docs. (#625)
* add doc of NodeFlow.

* add missing API in nodeflow.

* add docs and two more API to NodeFlow.

* add more docs.

* fix.

* fix.

* fix.

* add docs for distributed sampler.
2019-06-10 18:11:36 -07:00
Minjie Wang
ebbb6296f9 [Doc] doc page for builtin functions (#642)
* doc page for builtin functions; install from source doc

* upload rst

* update
2019-06-10 18:29:28 -04:00
Mufei Li
fb9dcc51ff [Feature] Add API to convert graph to bidirected graph (#598)
* to_bidirected

* to_bidirected

* Fix style

* Fix

* Update

* Fix

* Fix

* Update

* Add examples
2019-06-10 14:02:29 +08:00
HQ
993fd3f94b [Enhancement] Add DGLGraph.to for PyTorch and MXNet backend (#600)
* add graph_to

* use backend copy_to

* add test

* fix test

* framework agnostic to() test

* disable pylint complaint

* add examples

* fix docstring

* formatting

* Format

* Update test_to_device.py
2019-06-08 16:21:29 +08:00
Zihao Ye
baa16231f3 [Feature] Remove nodes/edges. (#599)
* upd

* upd

* reformat

* upd

* upd

* add test

* fix arange

* fix slight bug

* upd

* trigger

* upd docs

* upd

* upd

* upd

* change subgraph to be raw data wrapper

* upd

* fix test
2019-06-08 13:44:36 +08:00