You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tvm.apache.org by GitBox <gi...@apache.org> on 2022/07/15 18:06:48 UTC

[GitHub] [tvm] mbs-octoml commented on a diff in pull request #12107: [Relay] Allow partial virtual device annotations.

mbs-octoml commented on code in PR #12107:
URL: https://github.com/apache/tvm/pull/12107#discussion_r922406486


##########
python/tvm/target/virtual_device.py:
##########
@@ -27,7 +27,9 @@ class VirtualDevice(Object):
     """A compile time representation for where data is to be stored at runtime,
     and how to compile code to compute it."""
 
-    def __init__(self, device, target=None, memory_scope="") -> None:
+    def __init__(self, device=None, target=None, memory_scope="") -> None:
+        if device is None:
+            device = tvm.device(-1, -1)

Review Comment:
   Added a comment. Yes, it just means 'nothing known about the device type or id, it may be filled in during device planning based on how the contraints work out'.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@tvm.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org