dmlc / dmlc/dgl

[Sparse] Better Sparse Matrix between-devices copying strategy

Open
#5,119 2 comments 0 reactions 0 assignees View on GitHub
topic: Sparse API
Dominant language
Python
Stars
14.3k
Forks
3.1k
PR merge metrics
No merged PRs in 30d

Description

## 🔨Work Item

**IMPORTANT:**
* This template is only for dev team to track project progress. For feature request or bug report, please use the corresponding issue templates.
* DO NOT create a new work item if the purpose is to fix an existing issue or feature request. We will directly use the issue in the project tracker.

Project tracker: https://github.com/orgs/dmlc/projects/2

## Description

code pointer: python/dgl/sparse/sparse_matrix.py

When move sparse matrix between CPU and GPU, the potentially existing CSC, CSR formats will be forced to convert to COO format, and recreate the sparse matrix in the target device. We should reconsider that whether this is the most efficient way to copy the sparse matrix.

Also since matrix moving between devices is not heavy ops in training pipeline, so the priority of the improvement is considered medium.
In mini-batch training, it will be called frequently, but most of the mini-batch creation are using COO format anyway.

## Depending work items or issues

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.