You are viewing a plain text version of this content. The canonical link for it is here.
Posted to discuss-archive@tvm.apache.org by yhj050806 via Apache TVM Discuss <no...@discuss.tvm.ai> on 2020/09/06 02:58:13 UTC

[Apache TVM Discuss] [Questions] How to know current Expr's type, CallNode, IfNode or anything else


I want to know current Expr is CallNode , IfNode or anything else?  how do I do?

1) I see  "Object::_type_key" can indicate the Expr's type, but I don't find any interface to get the _type_key?  Should I use  the interface "Object::GetTypeKey() " , but sometimes coredump happened when I call expr->GetTypeKey()
2) is there any debug interface for printing the expr information when I use gdb to walkthrough the TVM source code ?
thanks





---
[Visit Topic](https://discuss.tvm.apache.org/t/how-to-know-current-exprs-type-callnode-ifnode-or-anything-else/7819/1) to respond.

You are receiving this because you enabled mailing list mode.

To unsubscribe from these emails, [click here](https://discuss.tvm.apache.org/email/unsubscribe/a1b0bbcfb1eec3893c24ef7ea7dc7564840f33904d8c52a17f4b3f6fca6bedd5).

[Apache TVM Discuss] [Questions] How to know current Expr's type, CallNode, IfNode or anything else

Posted by tqchen via Apache TVM Discuss <no...@discuss.tvm.ai>.

You can use obj.as API in the c++, or isinstance in python





---
[Visit Topic](https://discuss.tvm.apache.org/t/how-to-know-current-exprs-type-callnode-ifnode-or-anything-else/7819/2) to respond.

You are receiving this because you enabled mailing list mode.

To unsubscribe from these emails, [click here](https://discuss.tvm.apache.org/email/unsubscribe/aff2f42255142bf92410e7702f68cb5936286f6f5932e6039c8e683354ea97bb).