Commit da81615c authored by Ted Themistokleous's avatar Ted Themistokleous
Browse files

Remove contiguous being added with onnx/tf parsing of reshape()

Not needed so we don;'t need the extra contiguous as we're trying to
eliminate the need to use contiguous
parent ae6db5af
......@@ -54,8 +54,7 @@ struct parse_reshape : op_parser<parse_reshape>
}
auto cont = info.add_instruction(make_op("contiguous"), args[0]);
auto resh = info.add_instruction(make_op("reshape", {{"dims", dims}}), cont);
return info.add_instruction(make_op("contiguous"), resh);
return info.add_instruction(make_op("reshape", {{"dims", dims}}), cont);
}
};
......
......@@ -45,9 +45,8 @@ struct parse_reshape : op_parser<parse_reshape>
auto s = args[1]->eval();
std::vector<int64_t> dims;
s.visit([&](auto v) { copy(v, std::back_inserter(dims)); });
auto resh = info.add_instruction(make_op("reshape", {{"dims", dims}}),
return info.add_instruction(make_op("reshape", {{"dims", dims}}),
info.make_contiguous(args[0]));
return info.make_contiguous(resh);
}
};
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment