Thanks @wweic for the help. I’ve just merged your changes into my branch. The newest issue comes while processing node rnn/while/Exit_2
. It seems that there are two issues, and I don’t know which one is the root cause. Let me know if you have any thoughts, I’ll continue investigating
Update: I’m still stumped on this. I’ve tried a handful of things that haven’t worked, and now I’m spending time trying to figure out why the while loop is malformed. Does anyone have some insight here?
In `main`:
v0.0.4
fn (%rnn/Shape_1: Tensor[(3), int32], %Placeholder_1: Tensor[(1), int32]) {
%9 = (
let %while_loop-malformed-ir = fn (%loop_var0: Tensor[(1, 4), float32]) {
%0 = strided_slice(%rnn/Shape_1, begin=[0], end=[1], strides=[1]);
%1 = less(meta[relay.Constant][0], %0);
%2 = max(%Placeholder_1, axis=[0]);
%3 = maximum(meta[relay.Constant][2], %2);
%4 = minimum(%0, %3);
%5 = less(meta[relay.Constant][1], %4);
%6 = logical_and(%1, %5);
%7 = min(%6);
if (%7) {
free_var %while_loop
%while_loop()
} else {
(%loop_var0,)
}
};
%8 = full(0f, shape=[1, 4], dtype="float32");
%while_loop(%8)
) unable to unify: `fn (Tensor[(1, 4), float32]) -> (Tensor[(1, 4), float32],)` and `fn () -> meta[relay.IncompleteType][0]
// meta data omitted. you can use show_meta_data=True to include meta data`; ;
%9.2 an internal invariant was violated while typechecking your program [17:19:37] /home/jonso/dev/tvm_public_fork/tvm/src/relay/pass/type_infer.cc:76: Check failed: param->index < data->fields.size() (2 vs. 1) :
;
}