文件历史

提交图

13 次代码提交

作者 SHA1 备注 提交日期
Hongzhi (Steve), Chen 89b321b847 [Misc] Rename number_of_edges and number_of_nodes to num_edges and num_nodes. (#5488)
* nn-only

* data-only

---------

Co-authored-by: Ubuntu <ubuntu@ip-172-31-28-63.ap-northeast-1.compute.internal>
2023-03-28 12:58:54 +08:00
Xin Yao ae4a5b7394 [Feature] Add state_dict, load_state_dict, param_groups to dgl.optim.SparseGradOptimizer (#5311)
* init update

* all get/set optm_state

* add unit tests

* add docstring

* fix for multiple embeddings

* move embedding methods to private

* fix lint

* fix unit tests

* resolve comments

* merge master
2023-03-08 16:46:34 +08:00
Hongzhi (Steve), Chen a454734f16 [Misc] Follow up on the missing comment in PR#4989. (#5437)
Co-authored-by: Ubuntu <ubuntu@ip-172-31-28-63.ap-northeast-1.compute.internal>
Co-authored-by: Xin Yao <yaox12@outlook.com>
2023-03-08 13:32:21 +08:00
Xin Yao 8d5d8962ad [Refactor] Replace third_party/nccl with PyTorch's NCCL backend (#4989)
* expose GeneratePermutation

* add sparse_all_to_all_push

* add sparse_all_to_all_pull

* add unit test

* handle world_size=1

* remove python nccl wrapper

* remove the nccl dependency

* use pinned memory to speedup D2H copy

* fix lint

* resolve comments

* fix lint

* fix ut

* resolve comments
2023-03-08 12:59:10 +08:00
peizhou001 611393021a [API Deprecation] Remove candidates in DGLGraph (#4946) 2022-12-01 16:41:53 +08:00
Hongzhi (Steve), Chen 76bb54044e [Misc] Black auto fix. (#4682)
Co-authored-by: Steve <ubuntu@ip-172-31-34-29.ap-northeast-1.compute.internal>
2022-10-08 14:16:12 +08:00
nv-dlasalle 7359481497 [Feature][GPU] Add function for setting weights of a sparse embedding on multiple GPUs. (#3047)
* add unit test

* Extend NDArrayPartition object

* Add method for setting embedding, and improve documentation

* Sync before returning

* Use name unique to sparse embedding class to avoid delete

Co-authored-by: xiang song(charlie.song) <classicxsong@gmail.com>
2021-06-22 08:48:12 -07:00
nv-dlasalle 17d604b5c7 [Feature] Allow using NCCL for communication in dgl.NodeEmbedding and dgl.SparseOptimizer (#2824)
* Split from NCCL PR

* Fix type in comment

* Expand documentation for sparse_all_to_all_push

* Restore previous behavior in example

* Re-work optimizer to use NCCL based on gradient location

* Allow for running with embedding on CPU but using NCCL for gradient exchange

* Optimize single partition case

* Fix pylint errors

* Add missing include

* fix gradient indexing

* Fix line continuation

* Migrate 'first_step'

* Skip tests without enough GPUs to run NCCL

* Improve empty tensor handling for pytorch 1.5

* Fix indentation

* Allow multiple NCCL communicator to coexist

* Improve handling of empty message

* Update python/dgl/nn/pytorch/sparse_emb.py

Co-authored-by: xiang song(charlie.song) <classicxsong@gmail.com>

* Update python/dgl/nn/pytorch/sparse_emb.py

Co-authored-by: xiang song(charlie.song) <classicxsong@gmail.com>

* Keepy empty tensor dimensionaless

* th.empty -> th.tensor

* Preserve shape for empty non-zero dimension tensors

* Use shared state, when embedding is shared

* Add support for gathering an embedding

* Fix typo

* Fix more typos

* Fix backend call

* Use NodeDataLoader to take advantage of ddp

* Update training script to share memory

* Only squeeze last dimension

* Better handle empty message

* Keep embedding on the target device GPU if dgl_sparse if false in RGCN example

* Fix typo in comment

* Add asserts

* Improve documentation in example

Co-authored-by: xiang song(charlie.song) <classicxsong@gmail.com>
2021-06-10 21:19:00 -07:00
Soji Adeshina 0e964ea566 increase timeout for dgl.nn.NodeEmbedding TCPStore get/wait to 10 minutes (#2967)
Co-authored-by: xiang song(charlie.song) <classicxsong@gmail.com>
2021-06-02 14:56:42 +08:00
xiang song(charlie.song) c37e036432 [Bug Fix] Fix sparse opt bug (#2859)
* Fix #2856

* upd

* Fix unitest

* upd

* upd

* upd

* Fix

Co-authored-by: Ubuntu <ubuntu@ip-172-31-57-25.ec2.internal>
2021-04-25 13:40:21 +08:00
xiang song(charlie.song) 453d358d2c [Doc] Fix docs for sparse optimizer (#2680)
Co-authored-by: Ubuntu <ubuntu@ip-172-31-56-220.ec2.internal>
Co-authored-by: Minjie Wang <wmjlyjemaine@gmail.com>
2021-02-19 14:07:35 +08:00
xiang song(charlie.song) 23afe911b2 [Bug Fix] Fix several sparse optimizer bugs (#2596)
* Fix pytorch TCP kvstore bug

* lint

* Fix

* upd

* Fix lint

* Fix

* trigger

* fix

Co-authored-by: Ubuntu <ubuntu@ip-172-31-56-220.ec2.internal>
2021-02-05 11:49:41 +08:00
xiang song(charlie.song) a7e941c379 [Feature] Add support for sparse embedding (#2451)
* Add sparse embedding for dgl and update rgcn example

* upd

* Fix

* Revert "Fix"

This reverts commit 4da87cdfb8b8c3506b7fc7376cd2385ba8045c2a.

* Fix

* upd

* upd

* Fix

* Add unitest and update impl

* fix

* Clean up rgcn example code

* upd

* upd

* update

* Fix

* update score

* sparse for sage

* remove model sparse

* upd

* upd

* remove global norm

* revert delete model_sparse.py

* update according to comments

* Fix doc

* upd

* Fix test

* upd

* lint

* lint

* lint

* upd

* upd

* clean up

Co-authored-by: Ubuntu <ubuntu@ip-172-31-56-220.ec2.internal>
2021-01-28 00:26:49 +08:00