ganler commented on issue #12400:
URL: https://github.com/apache/tvm/issues/12400#issuecomment-1218540542

   Had a closer look. It seems those are not bugs as you might misunderstood 
the `axis` attribute. According to relay.squeeze 
[doc](https://tvm.apache.org/docs/reference/api/python/relay/index.html), 
`axis` should be `None` or a list of integer or an expression. 
   
   > axis ([None](https://docs.python.org/3/library/constants.html#None) or 
List[[int](https://docs.python.org/3/library/functions.html#int)] or Expr) – 
The set of axes to remove.
   
   If `axis` is `[]` it means none of the axies will be squeezed so that it is 
fairly correct to have identical output shapes. If you meant to have dim-1 
axies automatically squeezed, it should be `axis=None`. 
   
   > TypeError: iteration over a 0-d array
   
   I also don't think it is related to 
https://github.com/apache/tvm/issues/11697 as that happens at runtime and the 
cases here happens even before compile time.
   
   For `axis=relay.Constant(tvm.nd.array(np.array(0)))`, the `np.array(0)` is a 
scalar instead of an integer list as is prompted by the error message. 


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