Skip to content

[Bug] Failed when using te.gradient for roi_align #12126

Description

@hgt312

Meet this when updating tvm version

E             [bt] (8) 9   libtvm.dylib                        0x0000000163f79895 tvm::arith::IRMutatorWithAnalyzer::VisitExpr_(tvm::tir::ReduceNode const*) + 245
E             [bt] (7) 8   libtvm.dylib                        0x0000000163e322ec tvm::arith::Analyzer::Bind(tvm::tir::Var const&, tvm::Range const&, bool) + 396
E             [bt] (6) 7   libtvm.dylib                        0x0000000163f31987 tvm::arith::IntSetAnalyzer::Bind(tvm::tir::Var const&, tvm::Range const&, bool) + 55
E             [bt] (5) 6   libtvm.dylib                        0x0000000163f319fd tvm::arith::IntSetAnalyzer::Impl::Bind(tvm::tir::Var const&, tvm::Range const&, bool) + 109
E             [bt] (4) 5   libtvm.dylib                        0x0000000163f31861 tvm::arith::IntSetAnalyzer::Impl::Update(tvm::tir::Var const&, tvm::arith::IntSet const&, bool) + 1537
E             [bt] (3) 4   libtvm.dylib                        0x0000000163e323f5 tvm::runtime::detail::LogFatal::~LogFatal() + 21
E             [bt] (2) 3   libtvm.dylib                        0x0000000163e3452d tvm::runtime::detail::LogFatal::~LogFatal() + 29
E             [bt] (1) 2   libtvm.dylib                        0x0000000163e345d5 tvm::runtime::detail::LogFatal::Entry::Finalize() + 149
E             [bt] (0) 1   libtvm.dylib                        0x0000000167c2f76e tvm::runtime::Backtrace() + 30
E             File "../3rdparty/tvm/src/arith/int_set.cc", line 589
E             File "../src/impl/op.cc", line 178
E           TVMError: Cannot find a valid dispatch for op raf.op.roi_align_dx:
E           [TVM] Failed to JIT: raf_op_tvm_roi_align_dx_6: TVMError:
E           ---------------------------------------------------------------
E           An error occurred during the execution of TVM.
E           For more information, please see: https://tvm.apache.org/docs/errors.html
E           ---------------------------------------------------------------
E             Check failed: (ExprDeepEqual()(old_info.max(), info.max())) is false: Trying to update var 'rh' with a different maximum value: original=(int32(tir.ceil((max((placeholder[i, 4] - placeholder[i, 2]), 1f)/7f))) - 1), new=(int32(tir.ceil((max((placeholder[i, 4] - placeholder[i, 2]), 1f)*0.142857f))) - 1)

Seems that the only difference is x/7 vs x*(1/7), can this be solved by using simplify before equal?

@Lunderberg

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions