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
ColossalAI
Commits
fb354605
Unverified
Commit
fb354605
authored
Jul 12, 2022
by
Frank Lee
Committed by
GitHub
Jul 12, 2022
Browse files
[fx] added ndim property to proxy (#1253)
parent
4a09fc09
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
0 deletions
+4
-0
colossalai/fx/proxy.py
colossalai/fx/proxy.py
+4
-0
No files found.
colossalai/fx/proxy.py
View file @
fb354605
...
...
@@ -57,6 +57,10 @@ class ColoProxy(Proxy):
self
.
_assert_meta_data_is_tensor
()
return
self
.
meta_data
.
shape
@
property
def
ndim
(
self
):
return
self
.
dim
()
def
dim
(
self
):
self
.
_assert_meta_data_is_tensor
()
return
self
.
meta_data
.
dim
()
...
...
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