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

   I'm trying to use MetaSchedule to tune vae_decoder model. But it failed to 
extract tasks.
   
   ### Expected behavior
   
   It should successful.
   
   ### Actual behavior
   
   ```txt
     File "/home/xxx/xxx/tvm_tunning/tunningx/tunning/meta_schedule.py", line 
67, in do_all_tune
       database = ms.relay_integration.tune_relay(
     File "/home/xxx/xxx/tvm/python/tvm/meta_schedule/relay_integration.py", 
line 352, in tune_relay
       return tune_tasks(
     File "/home/xxx/xxx/tvm/python/tvm/meta_schedule/tune.py", line 118, in 
tune_tasks
       task_scheduler.tune(
     File 
"/home/xxx/xxx/tvm/python/tvm/meta_schedule/task_scheduler/task_scheduler.py", 
line 132, in tune
       _ffi_api.TaskSchedulerTune(  # type: ignore # pylint: disable=no-member
     File "/home/xxx/xxx/tvm/python/tvm/_ffi/_ctypes/packed_func.py", line 238, 
in __call__
       raise get_last_ffi_error()
   ValueError: Traceback (most recent call last):
     11: TVMFuncCall
     10: _ZN3tvm7runtime13PackedFunc
     9: tvm::runtime::TypedPackedFunc<void (tvm::meta_schedule::TaskScheduler, 
tvm::runtime::Array<tvm::meta_schedule::TuneContext, void>, 
tvm::runtime::Array<tvm::FloatImm, void>, int, int, int, 
tvm::meta_schedule::Builder, tvm::meta_schedule::Runner, 
tvm::runtime::Array<tvm::meta_schedule::MeasureCallback, void>, 
tvm::runtime::Optional<tvm::meta_schedule::Database>, 
tvm::runtime::Optional<tvm::meta_schedule::CostModel>)>::AssignTypedLambda<tvm::runtime::Registry::set_body_method<tvm::meta_schedule::TaskScheduler,
 tvm::meta_schedule::TaskSchedulerNode, void, 
tvm::runtime::Array<tvm::meta_schedule::TuneContext, void>, 
tvm::runtime::Array<tvm::FloatImm, void>, int, int, int, 
tvm::meta_schedule::Builder, tvm::meta_schedule::Runner, 
tvm::runtime::Array<tvm::meta_schedule::MeasureCallback, void>, 
tvm::runtime::Optional<tvm::meta_schedule::Database>, 
tvm::runtime::Optional<tvm::meta_schedule::CostModel>, void>(void 
(tvm::meta_schedule::TaskSchedulerNode::*)(tvm::runtime::Array<tvm::meta_s
 chedule::TuneContext, void>, tvm::runtime::Array<tvm::FloatImm, void>, int, 
int, int, tvm::meta_schedule::Builder, tvm::meta_schedule::Runner, 
tvm::runtime::Array<tvm::meta_schedule::MeasureCallback, void>, 
tvm::runtime::Optional<tvm::meta_schedule::Database>, 
tvm::runtime::Optional<tvm::meta_schedule::CostModel>))::{lambda(tvm::meta_schedule::TaskScheduler,
 tvm::runtime::Array<tvm::meta_schedule::TuneContext, void>, 
tvm::runtime::Array<tvm::FloatImm, void>, int, int, int, 
tvm::meta_schedule::Builder, tvm::meta_schedule::Runner, 
tvm::runtime::Array<tvm::meta_schedule::MeasureCallback, void>, 
tvm::runtime::Optional<tvm::meta_schedule::Database>, 
tvm::runtime::Optional<tvm::meta_schedule::CostModel>)#1}>(tvm::runtime::Registry::set_body_method<tvm::meta_schedule::TaskScheduler,
 tvm::meta_schedule::TaskSchedulerNode, void, 
tvm::runtime::Array<tvm::meta_schedule::TuneContext, void>, 
tvm::runtime::Array<tvm::FloatImm, void>, int, int, int, 
tvm::meta_schedule::Builder, tvm::meta_schedule:
 :Runner, tvm::runtime::Array<tvm::meta_schedule::MeasureCallback, void>, 
tvm::runtime::Optional<tvm::meta_schedule::Database>, 
tvm::runtime::Optional<tvm::meta_schedule::CostModel>, void>(void 
(tvm::meta_schedule::TaskSchedulerNode::*)(tvm::runtime::Array<tvm::meta_schedule::TuneContext,
 void>, tvm::runtime::Array<tvm::FloatImm, void>, int, int, int, 
tvm::meta_schedule::Builder, tvm::meta_schedule::Runner, 
tvm::runtime::Array<tvm::meta_schedule::MeasureCallback, void>, 
tvm::runtime::Optional<tvm::meta_schedule::Database>, 
tvm::runtime::Optional<tvm::meta_schedule::CostModel>))::{lambda(tvm::meta_schedule::TaskScheduler,
 tvm::runtime::Array<tvm::meta_schedule::TuneContext, void>, 
tvm::runtime::Array<tvm::FloatImm, void>, int, int, int, 
tvm::meta_schedule::Builder, tvm::meta_schedule::Runner, 
tvm::runtime::Array<tvm::meta_schedule::MeasureCallback, void>, 
tvm::runtime::Optional<tvm::meta_schedule::Database>, 
tvm::runtime::Optional<tvm::meta_schedule::CostModel>)#1}, std::__cxx11::basi
 c_string<char, std::char_traits<char>, std::allocator<char> 
>)::{lambda(tvm::runtime::TVMArgs const&, 
tvm::runtime::TVMRetValue*)#1}::operator()(tvm::runtime::TVMArgs const&, 
tvm::runtime::TVMRetValue*) const [clone .isra.0]
     8: 
tvm::meta_schedule::GradientBasedNode::Tune(tvm::runtime::Array<tvm::meta_schedule::TuneContext,
 void>, tvm::runtime::Array<tvm::FloatImm, void>, int, int, int, 
tvm::meta_schedule::Builder, tvm::meta_schedule::Runner, 
tvm::runtime::Array<tvm::meta_schedule::MeasureCallback, void>, 
tvm::runtime::Optional<tvm::meta_schedule::Database>, 
tvm::runtime::Optional<tvm::meta_schedule::CostModel>)
     7: 
tvm::meta_schedule::TaskSchedulerNode::Tune(tvm::runtime::Array<tvm::meta_schedule::TuneContext,
 void>, tvm::runtime::Array<tvm::FloatImm, void>, int, int, int, 
tvm::meta_schedule::Builder, tvm::meta_schedule::Runner, 
tvm::runtime::Array<tvm::meta_schedule::MeasureCallback, void>, 
tvm::runtime::Optional<tvm::meta_schedule::Database>, 
tvm::runtime::Optional<tvm::meta_schedule::CostModel>)
     6: 
tvm::meta_schedule::PostOrderApplyNode::GenerateDesignSpace(tvm::IRModule 
const&)
     5: 
tvm::meta_schedule::MultiLevelTilingTensorCoreNode::Apply(tvm::tir::Schedule 
const&, tvm::tir::BlockRV const&)
     4: 
tvm::meta_schedule::MultiLevelTilingTensorCoreNode::ApplySubRules(std::vector<tvm::meta_schedule::State,
 std::allocator<tvm::meta_schedule::State> >)
     3: 
tvm::meta_schedule::MultiLevelTilingTensorCoreNode::AddWriteReuseTensorCore(tvm::meta_schedule::TensorCoreState)
 const
     2: tvm::tir::TracedScheduleNode::ReverseComputeInline(tvm::tir::BlockRV 
const&)
     1: tvm::tir::ConcreteScheduleNode::ReverseComputeInline(tvm::tir::BlockRV 
const&)
     0: tvm::tir::ConcreteScheduleNode::GetSRef(tvm::tir::BlockRV const&) const
     File "/home/xxx/xxx/tvm/src/tir/schedule/./concrete_schedule.h", line 285
   ValueError: The block no longer exists in the IRModule
   ```
   
    I think **ValueError: The block no longer exists in the IRModule** is the 
reason.
   
   ### Environment
   
   TVM Version: Unity Latest
   OS: Ubuntu 20.04
   
   ### Triage
   
   * core:ffi
   


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