Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[GPU] Fix FC shape agnostic kernel build failure issue. #22868

Merged
merged 8 commits into from
Feb 26, 2024

Conversation

hyunback
Copy link
Contributor

@hyunback hyunback commented Feb 15, 2024

239-image-bind-quantize notebook fails in GPU.
Target model has Conv - Fakequantize - FC pattern and FC was set fsv16 format. Currently FC shape agnostic kernel only support planar format, so enforce planar format in FC before supporting block format.

Tickets:

  • 132364

if (node.is_type<fully_connected>()) {
if (allow_new_shape_infer) {
expected = format::get_default_format(node.get_input_layout(0).get_rank());
node.set_preferred_input_fmt(0, expected);
Copy link
Contributor

Choose a reason for hiding this comment

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

Is it complicated to make a functional test case for such pattern? If not, I think it would be better to implement one..

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 functional test.

Copy link
Contributor

Choose a reason for hiding this comment

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

Could you please add a comment noting that plain input format is enforced because there is no available shape agnostic kernel supporting blocked format for now? Once we enable shape agnostic kernel for fsv->bfyx fc optimized kernel (i8), then we could relax the condition..

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 the comment.

@hyunback hyunback force-pushed the fix_notebook_issue0216 branch from 29ad8ef to 233c2b2 Compare February 20, 2024 11:34
if (node.is_type<fully_connected>()) {
if (allow_new_shape_infer) {
// Plain input format is enforced because no available shape agnostic kernel supporting blocked format.
// TODO: will remove once enable shape agnostic kernel for fsv->bfyx FC optimized kernel(i8)
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
// TODO: will remove once enable shape agnostic kernel for fsv->bfyx FC optimized kernel(i8)
// TODO: The condition will be relaxed once more shape agnostic kernels for other formats are enabled (e.g., fsv->bfyx FC optimized kernel(i8)))

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Applied.

@yeonbok yeonbok added this pull request to the merge queue Feb 26, 2024
Merged via the queue into openvinotoolkit:master with commit c40b675 Feb 26, 2024
88 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category: GPU OpenVINO GPU plugin
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants