"src/vscode:/vscode.git/clone" did not exist on "a1f926661689b6db3bba72f7cd381aac118e5c0a"
Commit 84ecee26 authored by Shucai Xiao's avatar Shucai Xiao
Browse files

clang format

parent 249f5024
...@@ -104,7 +104,7 @@ migraphx::shape to_shape(const py::buffer_info& info) ...@@ -104,7 +104,7 @@ migraphx::shape to_shape(const py::buffer_info& info)
} }
}); });
if (n == 0) if(n == 0)
{ {
MIGRAPHX_THROW("MIGRAPHX PYTHON: Unsupported data type" + info.format); MIGRAPHX_THROW("MIGRAPHX PYTHON: Unsupported data type" + info.format);
} }
......
...@@ -931,8 +931,10 @@ std::vector<instruction_ref> rewrite_rnn::lstm_cell(bool is_forward, ...@@ -931,8 +931,10 @@ std::vector<instruction_ref> rewrite_rnn::lstm_cell(bool is_forward,
auto ub_wb = prog.insert_instruction(ins, op::slice{{0}, {0}, {4 * hs}}, sbias); auto ub_wb = prog.insert_instruction(ins, op::slice{{0}, {0}, {4 * hs}}, sbias);
auto ub_rb = prog.insert_instruction(ins, op::slice{{0}, {4 * hs}, {8 * hs}}, sbias); auto ub_rb = prog.insert_instruction(ins, op::slice{{0}, {4 * hs}, {8 * hs}}, sbias);
wb = prog.insert_instruction(ins, op::broadcast{1, {bs, 4 * static_cast<size_t>(hs)}}, ub_wb); wb = prog.insert_instruction(
rb = prog.insert_instruction(ins, op::broadcast{1, {bs, 4 * static_cast<size_t>(hs)}}, ub_rb); ins, op::broadcast{1, {bs, 4 * static_cast<size_t>(hs)}}, ub_wb);
rb = prog.insert_instruction(
ins, op::broadcast{1, {bs, 4 * static_cast<size_t>(hs)}}, ub_rb);
} }
// peep hole // peep hole
...@@ -959,7 +961,7 @@ std::vector<instruction_ref> rewrite_rnn::lstm_cell(bool is_forward, ...@@ -959,7 +961,7 @@ std::vector<instruction_ref> rewrite_rnn::lstm_cell(bool is_forward,
xt = prog.insert_instruction(ins, op::squeeze{{0}}, xt); xt = prog.insert_instruction(ins, op::squeeze{{0}}, xt);
instruction_ref xt_sih{}; instruction_ref xt_sih{};
if (bias != prog.end()) if(bias != prog.end())
{ {
auto xt_tsw = prog.insert_instruction(ins, op::dot{}, xt, tsw, wb); auto xt_tsw = prog.insert_instruction(ins, op::dot{}, xt, tsw, wb);
auto sih_tsr = prog.insert_instruction(ins, op::dot{}, sih, tsr, rb); auto sih_tsr = prog.insert_instruction(ins, op::dot{}, sih, tsr, rb);
...@@ -974,8 +976,10 @@ std::vector<instruction_ref> rewrite_rnn::lstm_cell(bool is_forward, ...@@ -974,8 +976,10 @@ std::vector<instruction_ref> rewrite_rnn::lstm_cell(bool is_forward,
auto it_before_actv = prog.insert_instruction(ins, op::slice{{1}, {0}, {hs}}, xt_sih); auto it_before_actv = prog.insert_instruction(ins, op::slice{{1}, {0}, {hs}}, xt_sih);
auto ot_before_actv = prog.insert_instruction(ins, op::slice{{1}, {hs}, {2 * hs}}, xt_sih); auto ot_before_actv = prog.insert_instruction(ins, op::slice{{1}, {hs}, {2 * hs}}, xt_sih);
auto ft_before_actv = prog.insert_instruction(ins, op::slice{{1}, {2 * hs}, {3 * hs}}, xt_sih); auto ft_before_actv =
auto ct_before_actv = prog.insert_instruction(ins, op::slice{{1}, {3 * hs}, {4 * hs}}, xt_sih); prog.insert_instruction(ins, op::slice{{1}, {2 * hs}, {3 * hs}}, xt_sih);
auto ct_before_actv =
prog.insert_instruction(ins, op::slice{{1}, {3 * hs}, {4 * hs}}, xt_sih);
if(pph != prog.end()) if(pph != prog.end())
{ {
......
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