forked from openvinotoolkit/nncf
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fuse LeakyReLU along with other non-ReLU activations (openvinotoolkit…
…#1076) ### Changes torch.nn.functional.leaky_relu nodes are now properly fused with preceding operations. ### Reason for changes Purported performance increases from fusing. ### Related tickets N/A ### Tests tests.torch.test_compressed_graph.test_synthetic_model_quantization <!--- How was the correctness of changes tested and whether new tests were added -->
- Loading branch information
Showing
4 changed files
with
34 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
15 changes: 15 additions & 0 deletions
15
tests/torch/data/reference_graphs/quantized/synthetic_model/ConvBNLeakyReLU.dot
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
strict digraph { | ||
"0 /nncf_model_input_0" [id=0, type=nncf_model_input]; | ||
"1 SymmetricQuantizer/symmetric_quantize_0" [id=1, type=symmetric_quantize]; | ||
"2 ConvBNLeakyReLU/NNCFConv2d[conv]/ModuleDict[pre_ops]/UpdateWeight[0]/SymmetricQuantizer[op]/symmetric_quantize_0" [id=2, type=symmetric_quantize]; | ||
"3 ConvBNLeakyReLU/NNCFConv2d[conv]/conv2d_0" [id=3, type=conv2d]; | ||
"4 ConvBNLeakyReLU/NNCFBatchNorm[bn]/batch_norm_0" [id=4, type=batch_norm]; | ||
"5 ConvBNLeakyReLU/leaky_relu_0" [id=5, type=leaky_relu]; | ||
"6 /nncf_model_output_0" [id=6, type=nncf_model_output]; | ||
"0 /nncf_model_input_0" -> "1 SymmetricQuantizer/symmetric_quantize_0"; | ||
"1 SymmetricQuantizer/symmetric_quantize_0" -> "3 ConvBNLeakyReLU/NNCFConv2d[conv]/conv2d_0"; | ||
"2 ConvBNLeakyReLU/NNCFConv2d[conv]/ModuleDict[pre_ops]/UpdateWeight[0]/SymmetricQuantizer[op]/symmetric_quantize_0" -> "3 ConvBNLeakyReLU/NNCFConv2d[conv]/conv2d_0"; | ||
"3 ConvBNLeakyReLU/NNCFConv2d[conv]/conv2d_0" -> "4 ConvBNLeakyReLU/NNCFBatchNorm[bn]/batch_norm_0"; | ||
"4 ConvBNLeakyReLU/NNCFBatchNorm[bn]/batch_norm_0" -> "5 ConvBNLeakyReLU/leaky_relu_0"; | ||
"5 ConvBNLeakyReLU/leaky_relu_0" -> "6 /nncf_model_output_0"; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters