We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Sigmoid not being merged into horizontally fused convolution because of multiple outputs. Minimal example program:
import migraphx import numpy as np p = migraphx.program() mm = p.get_main_module() shape_1 = migraphx.shape(lens=[1, 128, 160, 160], type='float_type') shape_2 = migraphx.shape(lens=[1, 64, 160, 160], type='float_type') x1 = mm.add_parameter('x1', shape_1) w1 = mm.add_literal(np.ones([64, 128, 1, 1], dtype=np.float32) * 0.5) w2 = mm.add_literal(np.ones([64, 128, 1, 1], dtype=np.float32) * 0.75) conv1 = mm.add_instruction(migraphx.op('convolution', padding=[0, 0, 0, 0], stride=[1, 1], dilation=[1, 1], padding_mode=0, group=1), [x1, w1]) conv2 = mm.add_instruction(migraphx.op('convolution', padding=[0, 0, 0, 0], stride=[1, 1], dilation=[1, 1], padding_mode=0, group=1), [x1, w2]) lit1 = mm.add_literal(np.ones([64], dtype=np.float32) * 0.5) lit2 = mm.add_literal(np.ones([64], dtype=np.float32) * 0.25) broadcast1 = mm.add_instruction(migraphx.op('broadcast', axis=1, out_lens=[1, 64, 160, 160]), [lit1]) broadcast2 = mm.add_instruction(migraphx.op('broadcast', axis=1, out_lens=[1, 64, 160, 160]), [lit2]) add1 = mm.add_instruction(migraphx.op('add'), [conv1, broadcast1]) sig1 = mm.add_instruction(migraphx.op('sigmoid'), [add1]) mul1 = mm.add_instruction(migraphx.op('mul'), [sig1, add1]) add2 = mm.add_instruction(migraphx.op('add'), [conv2, broadcast2]) sig2 = mm.add_instruction(migraphx.op('sigmoid'), [add2]) mul2 = mm.add_instruction(migraphx.op('mul'), [sig2, add2]) mm.add_return([mul1, mul2])
The text was updated successfully, but these errors were encountered:
CharlieL7
No branches or pull requests
Sigmoid not being merged into horizontally fused convolution because of multiple outputs. Minimal example program:
The text was updated successfully, but these errors were encountered: