loveppdog opened a new issue, #12767:
URL: https://github.com/apache/tvm/issues/12767

   I want to register support op by c++ to implement the following func like 
python code.
   @tvm.ir.register_op_attr("nn.avg_pool2d","dnnl")
    def avg_pool2d_check(expr):
        attrs, args = expr.attrs, expr.args
        data_typ = args[0].checked_type
        rank = len(data_typ.shape)
        if rank < 3 or rank > 4 or data_typ.dtype != "float32":
            return False
        if attrs.layout != "NCHW":
            return False
   return true
   
   But I can't get expr in C++ by using PackedFunc (TVMArgs args, TVMRetValue* 
rv).
   How to get expr from TVMArgs ?


-- 
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-unsubscr...@tvm.apache.org.apache.org

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

Reply via email to