文件历史

216 次代码提交

作者 SHA1 备注 提交日期
elohmeier 51907e0485 fix(dgl/runtime): add static_cast to fix clang compilation when using OpenMP (#7844) 2025-01-25 18:21:01 -08:00
Muhammed Fatih BALIN 6cd7fe99c9 [release] bump version to 2.5 for nightly (#7762) 2024-09-02 13:21:09 +08:00
Rhett Ying 00f8feeee5 [release] bump version to 2.4 for nightly (#7489) 2024-06-27 11:55:38 +08:00
Rhett Ying e3082a32c4 [dev] bump version to 2.3 (#7374) 2024-05-06 11:11:52 +08:00
Rhett Ying 4bd2eadf0c [dev] bump master version to 2.2 (#7185) 2024-03-01 15:45:09 +08:00
Rhett Ying 47a1d6a85d [release] upgrade version to 2.1 on master (#6940) 2024-01-12 08:58:00 +08:00
Rhett Ying 1e34f6648a [release] upgrade latest vesion to 2.0 (#6879) 2024-01-02 10:24:32 +08:00
Chang Liu 1b3f14b0b4 [Misc.] Avoid calling IsPinned in the coo/csr constructor from every sampling process (#6568) 2023-11-22 10:45:22 -08:00
AdamGrabowski 4135b1bd5b [Performance] Fused sampling with compaction (#5924)
Co-authored-by: Hesham Mostafa <hesham.mostafa@intel.com>
2023-07-20 09:38:22 +08:00
Muhammed Fatih BALIN d3bd4c6112 [Feature] Adding kappa feature for labor (Cooperative Minibatching) (#6006)
Co-authored-by: Hongzhi (Steve), Chen <chenhongzhi.nkcs@gmail.com>
2023-07-19 10:34:28 +08:00
Quan (Andy) Gan c92d012bb1 [Build] Bump nightly version (#5704) 2023-05-18 13:30:35 +08:00
Chang Liu e6eefd1a13 [Bugfix] Fix the uninitialized pin_memory flag for empty graph (#5609) 2023-04-26 17:56:01 -07:00
Chang Liu 62b5f50a5c [Feature] Import PyTorch's pin_memory() method for DGL graph structure (#5366) 2023-04-10 19:21:32 -07:00
peizhou001 c51cc82e4b [Enhancement]Set default graph dataloader thread number (#5479)
Co-authored-by: Ubuntu <ubuntu@ip-172-31-16-19.ap-northeast-1.compute.internal>
2023-04-10 17:52:24 +08:00
Ilia Taraban acb4eb7ecd [Feature] Add bfloat16 support for CPU (#5497)
Co-authored-by: Hongzhi (Steve), Chen <chenhongzhi.nkcs@gmail.com>
2023-04-06 11:16:41 +02:00
Hongzhi (Steve), Chen 5421940a77 [Misc] Fix C++ comment style. (#5467)
Co-authored-by: Ubuntu <ubuntu@ip-172-31-28-63.ap-northeast-1.compute.internal>
2023-03-20 10:26:53 +08:00
Daniil Sizov 87fb7ed05b [Config] Enable libxsmm by default for AVX cpu (#5165)
* Enable AVX by default

* Fix linting errors

* Fix win64 build (libxsmm not linked)

Libxsmm on Win64 is not linked, should be disabled by default

* Fix clang format issues

* Change lower supported cpu version to LIBXSMM_X86_AVX2

Change lower supported cpu version to LIBXSMM_X86_AVX2 to address https://github.com/dmlc/dgl/issues/3459 issue

* Fix unit test

Remove assumption that libxsmm is enabled in the config by default (only true for intel CPUs with AVX2 instructions)

---------

Co-authored-by: Ubuntu <ubuntu@ip-172-31-15-137.us-west-2.compute.internal>
Co-authored-by: Quan (Andy) Gan <coin2028@hotmail.com>
2023-03-16 02:05:22 +08:00
Quan (Andy) Gan d8ca6317a3 [Release] Bump nightly version (#5357)
* bump version

* Update update_version.py
2023-02-22 09:13:38 +08:00
Quan (Andy) Gan f62669b05c enable sparse on windows and mac (#5277)
* enable sparse on windows and mac

* that was stupid

* let's see what's going on..

* [Sparse] Fix the import error on Mac OS.

When using template functions that are defined in source files from DGL,
the loader of MacOS somehow cannot find their definitions. This fix simply
avoids depending on template functions from DGL headers.

With this fix, the sparse tests all pass on the MAC environment.

* ok this is the problem

* make errors clearer

* uh

* test

* Update __init__.py

* disabling ddp on windows

---------

Co-authored-by: czkkkkkk <zekucai@gmail.com>
2023-02-13 13:16:17 +08:00
Quan (Andy) Gan f1fb859f99 bump version to 1.0 (#5123) 2023-01-09 11:28:26 +08:00
czkkkkkk 08b60eb162 [Sparse] Add SpMM and SDDMM on CSR and COO in dgl include headers (#5016) 2022-12-15 09:09:47 +08:00
czkkkkkk d02e560e07 Revert "[Sparse] Add SpMM and SDDMM." (#5014)
* Revert "[Sparse] Add SpMM and SDDMM. (#4999)"

This reverts commit 15365d7855.

* lint
2022-12-12 19:37:08 +08:00
czkkkkkk 15365d7855 [Sparse] Add SpMM and SDDMM. (#4999)
* [Sparse] Add SpMM and SDDMM

* Update

* Add CSR and CSC SpMM tests
2022-12-12 15:37:09 +08:00
Xin Yao aad3bd0484 [Bugfix] Fix empty tensors may being treated as pinned (#5005)
* fix empty tensor is treated as pinned

* avoid calling cudaHostGetDevicePointer on nullptr

* update empty array

* add a comment
2022-12-09 16:42:59 +08:00
Muhammed Fatih BALIN b1e2695f3e [Feature] replace dgl PRNG with pcg32 (#4807)
* replace dgl PRNG with pcg32

* remove pcg submodule, add a simple implementation

* replace pcg32 with std::mt19937_64

* fix include order

* change RandomEngine to pcg32

* Remove custom pcg32 implementation, use the submodule provided by the original author.

* minor bug

* move include for linting

* include pcg for tests too

Co-authored-by: Hongzhi (Steve), Chen <chenhongzhi.nkcs@gmail.com>
2022-12-01 09:19:28 +08:00
Muhammed Fatih BALIN bf264d00fe [Feature] (La)yer-Neigh(bor) sampling implementation (#4668)
* adding LABOR sampling

* add ladies and pladies samplers

* fix compile error after rebase

* add reference for ladies sampler

* Improve ladies implementation.

* weighted labor sampling initial implementation draft
fix indentation and small bug in ladies script

* importance_sampling currently doesn't work with weights

* fix weighted importance sampling

* move labor example into its own folder

* lint fixes

* Improve documentation

* remove examples from the main PR

* fix linting by not using c++17 features

* fix documentation of labor_sampler.py

* update documentation for labor.py

* reformat the labor.py file with black

* fix linting errors

* replace exception use with if

* fix typo in error comment

* fixing win64 build for ci

* fixing weighted implementation, works now.

* fix bug in the weighted case and importance_sampling==0

* address part of the reviews

* remove unused code paths from cuda

* remove unused code path from cpu side

* remove extra features of labor making use of random seed.

* fix exclude_edges bug

* remove pcg and seed logic from cpu implementation, seed logic should still work for cuda.

* minor style change

* refactor CPU implementation, take out the importance_sampling probability computation into a function.

* improve CUDAWorkspaceAllocator

* refactor importance_sampling part out to a function

* minor optimization

* fix linting issue

* Revert "remove pcg and seed logic from cpu implementation, seed logic should still work for cuda."

This reverts commit c250e07ac6d7e13f57e79e8a2c2f098d777378c2.

* Revert "remove extra features of labor making use of random seed."

This reverts commit 7f99034353080308f4783f27d9a08bea343fb796.

* fix the documentation

* disable NIDs

* improve the documentation in the code

* use the stream argument in pcg32 instead of skipping ahead t times, can discard the use of hashmap now since it is faster this way.

* fix linting issue

* address another round of reviews

* further optimize CPU LABOR sampling implementation

* fix linting error

* update the comment

* reformat

* rename and rephrase comment

* fix formatting according to new linting specs

* fix compile error due to renaming, fix linting.

* lint

* rename DGLHeteroGraph to DGLGraph to match master

* replace other occurrences of DGLHeteroGraph to DGLGraph

Co-authored-by: Muhammed Fatih BALIN <m.f.balin@gmail.com>
Co-authored-by: Kaan Sancak <kaansnck@gmail.com>
Co-authored-by: Quan Gan <coin2028@hotmail.com>
2022-11-22 09:03:02 +08:00
czkkkkkk 949f87cc1d [FFI] Change enumeration name in DGLObjectTypeCode to avoid conflict with Pytorch (#4905) 2022-11-16 15:25:48 +08:00
Hongzhi (Steve), Chen cb5e3489c0 [Misc] Minor code style fix. (#4843)
* [Misc] Change the max line length for cpp to 80 in lint.

* blabla

* blabla

* blabla

* ablabla

Co-authored-by: Steve <ubuntu@ip-172-31-34-29.ap-northeast-1.compute.internal>
2022-11-08 16:39:45 +08:00
Muhammed Fatih BALIN 2db4928ea4 a better way to init threadlocal prng (#4808)
Co-authored-by: Quan (Andy) Gan <coin2028@hotmail.com>
2022-11-08 12:28:19 +08:00
Hongzhi (Steve), Chen df089424c7 [Misc] Minor code style fix. (#4825)
* blabla

* more

* blabla

* blabla

* ablabla

* blabla

Co-authored-by: Steve <ubuntu@ip-172-31-34-29.ap-northeast-1.compute.internal>
2022-11-07 14:20:47 +08:00
Hongzhi (Steve), Chen 8ac27dad1a [Misc] clang-format auto fix. (#4824)
* [Misc] clang-format auto fix.

* blabla

* ablabla

* blabla

Co-authored-by: Steve <ubuntu@ip-172-31-34-29.ap-northeast-1.compute.internal>
2022-11-07 10:39:34 +08:00
Hongzhi (Steve), Chen bcd3768426 [Misc] Replace /*! with /**. (#4823)
* replace

* blabla

* balbla

* blabla

Co-authored-by: Steve <ubuntu@ip-172-31-34-29.ap-northeast-1.compute.internal>
2022-11-07 08:16:41 +08:00
Hongzhi (Steve), Chen 619d735df5 [Misc] Replace \xxx with @xxx in structured comment. (#4822)
* param

* brief

* note

* return

* tparam

* brief2

* file

* return2

* return

* blabla

* all

Co-authored-by: Steve <ubuntu@ip-172-31-34-29.ap-northeast-1.compute.internal>
2022-11-07 00:22:45 +08:00
Xin Yao 96297fb8fd [Feature] Add bfloat16 (bf16) support (#4648)
* add bf16 specializations

* remove SWITCH_BITS

* enable amp for bf16

* remove SWITCH_BITS for cpu kernels

* enbale bf16 based on CUDART

* fix compiling for sm<80

* fix cpu build

* enable unit tests

* update doc

* disable test for CUDA < 11.0

* address comments

* address comments
2022-11-06 19:48:36 +08:00
Hongzhi (Steve), Chen 6c53f351c6 Replace \xxx with @xxx in structured comment. (#4815)
* replace

* more

* file

* change

Co-authored-by: Steve <ubuntu@ip-172-31-34-29.ap-northeast-1.compute.internal>
2022-11-04 22:59:13 +08:00
Hongzhi (Steve), Chen b2d38ca82c [Misc] clang-format auto fix. (#4803)
* [Misc] clang-format auto fix.

* manual

Co-authored-by: Steve <ubuntu@ip-172-31-34-29.ap-northeast-1.compute.internal>
2022-11-02 23:15:34 +08:00
Hongzhi (Steve), Chen 07dc8fb666 [Misc] clang-format auto fix. (#4800)
* clang-format

* manul

* manul

* manual

Co-authored-by: Steve <ubuntu@ip-172-31-34-29.ap-northeast-1.compute.internal>
2022-11-02 16:53:19 +08:00
Quan (Andy) Gan 2bca4759c1 [Sampling] Enable sampling with edge masks in sample_etype_neighbors (#4749)
* sample neighbors with masks

* oops

* refactor again

* remove

* remove debug code

* rename macro

* address comments

* more stuff

* remove

* fix

* try fix unit test

* oops

* fix test

* oops

* change name

* rename a lot of stuff

* oops

* ugh

* misc fixes

* lint

* address a lot of comments

* lint

* lint

* fix

* that was silly

* fix

* fix

* fix

* oops
2022-10-29 15:49:44 +08:00
Quan (Andy) Gan 72781efbcf [Sampling] Enable sampling with edge masks on homogeneous graph (#4748)
* sample neighbors with masks

* oops

* refactor again

* remove

* remove debug code

* rename macro

* address comments

* address comment

* address comments

* rename a lot of stuff

* oops
2022-10-28 09:04:33 +08:00
Rhett Ying c78ddee265 [Feature] enable to save graphs in multiple formats (#4266)
* [Feature] enable to save graphs in multiple formats

* use StreamWithCount to accomodate formats

* fix lint

* fix dynamic cast issue

* fix lint

* refine docstring and code naming

* update docstring
2022-10-19 14:53:44 +08:00
Quan (Andy) Gan 14cafe73e2 bump version (#4667)
* bump version

* Update setup.py

* Update setup.py
2022-10-01 00:47:38 +08:00
Xin Yao 880b3b1f97 [Fix] Enable lint check for cuh files and fix compiler warnings (#4585)
* disable warning for tensorpipe

* fix warning

* enable lint check for cuh files

* resolve comments
2022-09-21 10:09:14 +08:00
nv-dlasalle 2630d2eb02 [Performance][bugfix] Implement is_unibipartite in C++ with caching. (#4556)
* updates

* Enable caching C++ result

* Add missing docstring

* Remove unused function

* Add unit test

* Address comments
2022-09-19 16:46:27 -07:00
Xin Yao cded5b80fe [Feature] Bump DLPack to v0.7 and decouple DLPack from the core library (#4454)
* rename `DLContext` to `DGLContext`

* rename `kDLGPU` to `kDLCUDA`

* replace DLTensor with DGLArray

* fix linting

* Unify DGLType and DLDataType to DGLDataType

* Fix FFI

* rename DLDeviceType to DGLDeviceType

* decouple dlpack from the core library

* fix bug

* fix lint

* fix merge

* fix build

* address comments

* rename dl_converter to dlpack_convert

* remove redundant comments
2022-09-19 16:02:43 +08:00
Xin Yao 9a00cf194f [Feature] Import PyTorch's CUDA stream management (#4503)
* add set_stream

* add .record_stream for NDArray and HeteroGraph

* refactor dgl stream Python APIs

* test record_stream

* add unit test for record stream

* use pytorch's stream

* fix lint

* fix cpu build

* address comments

* address comments

* add record stream tests for dgl.graph

* record frames and update dataloder

* add docstring

* update frame

* add backend check for record_stream

* remove CUDAThreadEntry::stream

* record stream for newly created formats

* fix bug

* fix cpp test

* fix None c_void_p to c_handle
2022-09-15 16:54:52 +08:00
Chang Liu 1c9d2a0302 [Feature] Unify the cuda stream used in core library (#4480)
* Use an internal cuda stream for CopyDataFromTo

* small fix white space

* Fix to compile

* Make stream optional in copydata for compile

* fix lint issue

* Update cub functions to use internal stream

* Lint check

* Update CopyTo/CopyFrom/CopyFromTo to use internal stream

* Address comments

* Fix backward CUDA stream

* Avoid overloading CopyFromTo()

* Minor comment update

* Overload copydatafromto in cuda device api

Co-authored-by: xiny <xiny@nvidia.com>
2022-09-06 10:14:55 +08:00
peizhou001 62af41c245 [Bug] Enable turn on/off libxsmm at runtime (#4455)
* enable turn on/off libxsmm at runtime by adding a global config and related API


Co-authored-by: Ubuntu <ubuntu@ip-172-31-19-194.ap-northeast-1.compute.internal>
2022-09-05 17:38:34 +08:00
Xin Yao 2b76674002 [Feature] Make TensorAdapter Stream Aware (#4472)
* Allocate tensors in DGL's current stream

* make tensoradaptor stream-aware

* replace TAemtpy with cpu allocator

* fix typo

* try fix cpu allocation

* clean header

* redirect AllocDataSpace as well

* resolve comments
2022-08-31 20:09:40 +08:00
Zhuobin Huang 92f87f48c7 [Bugfix] Fixed fatal log output in COO class (#4286)
Co-authored-by: Xin Yao <xiny@nvidia.com>
2022-07-27 13:22:34 +08:00
Xin Yao 1feec870c1 [Bugfix] Add CUDA context availability check before setting curand seed (#4223) 2022-07-09 10:19:10 +08:00