barry-jin commented on a change in pull request #20572:
URL: https://github.com/apache/incubator-mxnet/pull/20572#discussion_r737693044



##########
File path: python/mxnet/gluon/data/batchify.py
##########
@@ -82,7 +82,7 @@ def __call__(self, data):
             dtype = data[0].dtype
             if self._use_shared_mem:
                 out = _arr.empty((len(data),) + data[0].shape, dtype=dtype,
-                                 ctx=Context('cpu_shared', 0))
+                                 ctx=Device('cpu_shared', 0))

Review comment:
       Because here _arr can be legacy NDArray or mxnet.numpy ndarray. I didn't 
change ctx/context part inside legacy ndarray/symbol because this will need to 
change the ctx signature in backend, which will lead to more changes like 
OpContext to OpDevice in C++ side. So, I think we can do this in the future in 
seperate pull requests. 




-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to