Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
dgl
Commits
2a78e48f
Unverified
Commit
2a78e48f
authored
Jan 11, 2023
by
Hongzhi (Steve), Chen
Committed by
GitHub
Jan 11, 2023
Browse files
polish (#5150)
Co-authored-by:
Steve
<
ubuntu@ip-172-31-34-29.ap-northeast-1.compute.internal
>
parent
41b41809
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
6 deletions
+6
-6
python/dgl/sparse/elementwise_op.py
python/dgl/sparse/elementwise_op.py
+6
-6
No files found.
python/dgl/sparse/elementwise_op.py
View file @
2a78e48f
...
@@ -17,7 +17,7 @@ def add(
...
@@ -17,7 +17,7 @@ def add(
The supported combinations are shown as follows.
The supported combinations are shown as follows.
+--------------+------------+--------------+--------+
+--------------+------------+--------------+--------+
|
A \ B | DiagMatrix | SparseMatrix | scalar |
| A \
\
B | DiagMatrix | SparseMatrix | scalar |
+--------------+------------+--------------+--------+
+--------------+------------+--------------+--------+
| DiagMatrix | ✅ | ✅ | 🚫 |
| DiagMatrix | ✅ | ✅ | 🚫 |
+--------------+------------+--------------+--------+
+--------------+------------+--------------+--------+
...
@@ -56,13 +56,13 @@ def add(
...
@@ -56,13 +56,13 @@ def add(
def
sub
(
A
:
Union
[
DiagMatrix
],
B
:
Union
[
DiagMatrix
])
->
Union
[
DiagMatrix
]:
def
sub
(
A
:
Union
[
DiagMatrix
],
B
:
Union
[
DiagMatrix
])
->
Union
[
DiagMatrix
]:
r
"""Elementwise subtraction for ``DiagMatrix`` and ``SparseMatrix``
. This is
r
"""Elementwise subtraction for ``DiagMatrix`` and ``SparseMatrix``
,
equivalent to ``A - B``.
equivalent to ``A - B``.
The supported combinations are shown as follows.
The supported combinations are shown as follows.
+--------------+------------+--------------+--------+
+--------------+------------+--------------+--------+
|
A \ B | DiagMatrix | SparseMatrix | scalar |
| A \
\
B | DiagMatrix | SparseMatrix | scalar |
+--------------+------------+--------------+--------+
+--------------+------------+--------------+--------+
| DiagMatrix | ✅ | 🚫 | 🚫 |
| DiagMatrix | ✅ | 🚫 | 🚫 |
+--------------+------------+--------------+--------+
+--------------+------------+--------------+--------+
...
@@ -104,7 +104,7 @@ def mul(
...
@@ -104,7 +104,7 @@ def mul(
The supported combinations are shown as follows.
The supported combinations are shown as follows.
+--------------+------------+--------------+--------+
+--------------+------------+--------------+--------+
|
A \ B | DiagMatrix | SparseMatrix | scalar |
| A \
\
B | DiagMatrix | SparseMatrix | scalar |
+--------------+------------+--------------+--------+
+--------------+------------+--------------+--------+
| DiagMatrix | ✅ | 🚫 | ✅ |
| DiagMatrix | ✅ | 🚫 | ✅ |
+--------------+------------+--------------+--------+
+--------------+------------+--------------+--------+
...
@@ -159,7 +159,7 @@ def div(
...
@@ -159,7 +159,7 @@ def div(
The supported combinations are shown as follows.
The supported combinations are shown as follows.
+--------------+------------+--------------+--------+
+--------------+------------+--------------+--------+
|
A \ B | DiagMatrix | SparseMatrix | scalar |
| A \
\
B | DiagMatrix | SparseMatrix | scalar |
+--------------+------------+--------------+--------+
+--------------+------------+--------------+--------+
| DiagMatrix | ✅ | 🚫 | ✅ |
| DiagMatrix | ✅ | 🚫 | ✅ |
+--------------+------------+--------------+--------+
+--------------+------------+--------------+--------+
...
@@ -205,7 +205,7 @@ def power(
...
@@ -205,7 +205,7 @@ def power(
The supported combinations are shown as follows.
The supported combinations are shown as follows.
+--------------+------------+--------------+--------+
+--------------+------------+--------------+--------+
|
A \ B | DiagMatrix | SparseMatrix | scalar |
| A \
\
B | DiagMatrix | SparseMatrix | scalar |
+--------------+------------+--------------+--------+
+--------------+------------+--------------+--------+
| DiagMatrix | 🚫 | 🚫 | ✅ |
| DiagMatrix | 🚫 | 🚫 | ✅ |
+--------------+------------+--------------+--------+
+--------------+------------+--------------+--------+
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment