tqchen commented on pull request #5913:
URL: https://github.com/apache/incubator-tvm/pull/5913#issuecomment-648892769


   see comments, we don't need to expose the(non_empty) function as a primitive 
function, given that it is not a numpy function, and is only used in AutoTVM, 
instead we can achieve the same goal by 
   
   ```python
   x = nd.empty(..)
   random_fill  = get_packed_func("contrib.random.random_fill") 
   random_fill(x)
   ```
   
   Notably, the above solution is better because:
   - Minimum interface exposure(non autotvm devs don't need to be aware of the 
change)
   - Random initialization is performed on the device, the current impl 
actually will results in random number generated on the host then transfering 
to the device.
   


----------------------------------------------------------------
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.

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


Reply via email to