Skip to content

Conversation

@bopeng1234
Copy link
Contributor

@bopeng1234 bopeng1234 commented Dec 3, 2025

Move the ConvertWeightCompressedConv1x1ToMatmul pattern and its test from the intel_gpu plugin to the common transformation folder. The purpose is to reuse it on both the CPU and GPU sides.

Tickets:

@github-actions github-actions bot added category: GPU OpenVINO GPU plugin category: transformations OpenVINO Runtime library - Transformations labels Dec 3, 2025
@bopeng1234 bopeng1234 marked this pull request as ready for review December 3, 2025 05:45
@bopeng1234 bopeng1234 requested review from a team as code owners December 3, 2025 05:45
@bopeng1234 bopeng1234 requested review from evkotov and removed request for a team December 3, 2025 05:45
@bopeng1234 bopeng1234 marked this pull request as draft December 3, 2025 09:22
@bopeng1234
Copy link
Contributor Author

bopeng1234 commented Dec 4, 2025

This is just a code movement work for #32224

@bopeng1234 bopeng1234 force-pushed the conv1x1tomatmul_move branch from 0712b55 to 841f925 Compare December 4, 2025 08:33
@bopeng1234 bopeng1234 marked this pull request as ready for review December 4, 2025 08:34
@mryzhov mryzhov self-assigned this Dec 4, 2025
Copy link
Contributor

@mdvoretc-intel mdvoretc-intel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Confirmed that Phi-Silica use case is not affected, LGTM.

@maxnick maxnick requested a review from Lyamin-Roman December 5, 2025 10:29
@bopeng1234 bopeng1234 force-pushed the conv1x1tomatmul_move branch from 5c06c94 to 50c547c Compare December 9, 2025 09:33
#include "openvino/opsets/opset7_decl.hpp"
#include "transformations/rt_info/decompression.hpp"

using namespace ov;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The test coverage seems limited. Currently there are only two test cases: one positive (1x1 conv transforms to matmul) and one negative (3x3 conv does not transform). Are there plans to add tests for:
asymmetric quantization path (with zero-point subtraction)
bias addition path
Parameter weights instead of Constant
Reshape on output instead of Transpose
Convert on output

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added more test cases.

public:
OPENVINO_GRAPH_REWRITE_RTTI("ConvertWeightCompressedConv1x1ToMatmul");
ConvertWeightCompressedConv1x1ToMatmul() {
add_matcher<ov::pass::ConvertWeightCompressedConv1x1ToMatmulMatcher>();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the transformation contains only one matcher transformation, do we really need to include in GraphRewrite manually?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

removed the graph rewriter, only keep one match pass ConvertWeightCompressedConv1x1ToMatmul

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

category: GPU OpenVINO GPU plugin category: transformations OpenVINO Runtime library - Transformations

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants