Skip to content

Commit

Permalink
Removed bitwise_not fx version
Browse files Browse the repository at this point in the history
  • Loading branch information
cavusmustafa committed Mar 1, 2024
1 parent 16bbbd6 commit 50b9c63
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 20 deletions.
18 changes: 0 additions & 18 deletions src/frontends/pytorch/src/op/bitwise.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -62,24 +62,6 @@ OutputVector translate_bitwise_xor(const NodeContext& context) {
return {xor_x};
};

OutputVector translate_bitwise_not_fx(const NodeContext& context) {
num_inputs_check(context, 1, 2);
auto x = context.get_input(0);
if (x.get_element_type() != element::boolean) {
auto x_bool = context.mark_node(std::make_shared<ov::op::v0::Convert>(x, element::boolean));
auto not_x = context.mark_node(std::make_shared<ov::op::v1::LogicalNot>(x_bool));
if (!context.input_is_none(1)) {
context.mutate_input(1, not_x);
}
return {not_x};
}
auto not_x = context.mark_node(std::make_shared<ov::op::v1::LogicalNot>(x));
if (!context.input_is_none(1)) {
context.mutate_input(1, not_x);
}
return {not_x};
};

} // namespace op
} // namespace pytorch
} // namespace frontend
Expand Down
3 changes: 1 addition & 2 deletions src/frontends/pytorch/src/op_table.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,6 @@ OP_CONVERTER(translate_addcmul_fx);
OP_CONVERTER(translate_addmm_fx);
OP_CONVERTER(translate_any_fx);
OP_CONVERTER(translate_arange_fx);
OP_CONVERTER(translate_bitwise_not_fx);
OP_CONVERTER(translate_batch_norm_legit_fx);
OP_CONVERTER(translate_batch_norm_legit_no_training_fx);
OP_CONVERTER(translate_batch_norm_legit_no_stats_fx);
Expand Down Expand Up @@ -735,7 +734,7 @@ const std::map<std::string, CreatorFunction> get_supported_ops_fx() {
{"aten.avg_pool3d.default", op::translate_avg_poolnd},
{"aten.baddbmm.default", op::translate_addmm_fx},
{"aten.bitwise_and.Tensor", op::translate_bitwise_and},
{"aten.bitwise_not.default", op::translate_bitwise_not_fx},
{"aten.bitwise_not.default", op::translate_bitwise_not},
{"aten.bitwise_or.Tensor", op::translate_bitwise_or},
{"aten.bitwise_xor.Tensor", op::translate_bitwise_xor},
{"aten.bmm.default", op::translate_1to1_match_2_inputs_align_types<opset10::MatMul>},
Expand Down

0 comments on commit 50b9c63

Please sign in to comment.