[MO] [TF] Added TF broadcast_to extractor (#4376)
* Added TF broadcast_to extractor * updated Supported_Frameworks_Layers.md * corrected name * corrected op name in Supported_Frameworks_Layers.md * added a space after BroadcastTo in Supported_Frameworks_Layers.md
This commit is contained in:
parent
a1f8fe3696
commit
7dca134031
@ -134,6 +134,7 @@ Standard TensorFlow\* operations:
|
|||||||
| BatchToSpaceND | No |
|
| BatchToSpaceND | No |
|
||||||
| BiasAdd | No |
|
| BiasAdd | No |
|
||||||
| Bucketize | CPU only |
|
| Bucketize | CPU only |
|
||||||
|
| BroadcastTo | No |
|
||||||
| Cast | No |
|
| Cast | No |
|
||||||
| Ceil | No |
|
| Ceil | No |
|
||||||
| Concat | No |
|
| Concat | No |
|
||||||
|
@ -370,6 +370,7 @@ extensions/front/tf/BatchMatMul_ext.py
|
|||||||
extensions/front/tf/BatchToSpaceNDToUpsample.py
|
extensions/front/tf/BatchToSpaceNDToUpsample.py
|
||||||
extensions/front/tf/BlockLSTM.py
|
extensions/front/tf/BlockLSTM.py
|
||||||
extensions/front/tf/BlockLSTM_ext.py
|
extensions/front/tf/BlockLSTM_ext.py
|
||||||
|
extensions/front/tf/broadcast_ext.py
|
||||||
extensions/front/tf/bucketize.py
|
extensions/front/tf/bucketize.py
|
||||||
extensions/front/tf/bucketize_ext.py
|
extensions/front/tf/bucketize_ext.py
|
||||||
extensions/front/tf/Cast_ext.py
|
extensions/front/tf/Cast_ext.py
|
||||||
|
29
model-optimizer/extensions/front/tf/broadcast_ext.py
Normal file
29
model-optimizer/extensions/front/tf/broadcast_ext.py
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
"""
|
||||||
|
Copyright (C) 2018-2021 Intel Corporation
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
"""
|
||||||
|
|
||||||
|
from mo.front.extractor import FrontExtractorOp
|
||||||
|
from mo.graph.graph import Node
|
||||||
|
from mo.ops.broadcast import Broadcast
|
||||||
|
|
||||||
|
|
||||||
|
class BroadcastExtractor(FrontExtractorOp):
|
||||||
|
op = 'BroadcastTo'
|
||||||
|
enabled = True
|
||||||
|
|
||||||
|
@classmethod
|
||||||
|
def extract(cls, node: Node):
|
||||||
|
Broadcast.update_node_stat(node, attrs={'mode': 'numpy'})
|
||||||
|
return cls.enabled
|
Loading…
Reference in New Issue
Block a user