Better to check Infer result with topi results at build time instead of leaving to a runtime error. (#476)