-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
[Good First Issue] [Snippets] [ARM]: Enable FakeQuantize tokenization #28508
Comments
.take |
Thank you for looking into this issue! Please let us know if you have any questions or require any help. |
Hi @a-sidorova, I ran the tests and as expected the tests failed. I'm failing to understand the tests completely. Here is one of the tests for reference:
I'm sure I am missing something, please guide me through this. Thanks. |
@srinjoydutta03 thank you for the questions!
You're absolutely right - all emitters are already implemented. If some emitter is missed, you will see the following exception from target machine/generator: Also let me help you with logs of tests:
It means, the test expects that the execution model (state after
I believe that this check is more for x64 where we support blocked layouts in CPU Plugin. Please see brief comment. Since By the way, I've found the tests If you have more questions, feel free to ask them! 😊 |
Thank you so much for the help :). I would think for other tests too, the per_channel and per_channel_inputs as well I should set the first parameter to I have enclosed the On doing so the tests run successfully now, with 6 tests skipped for 16bit floating point precisions. |
@srinjoydutta03 thank you for the status sharing! Now we're waiting for the PR from you! 😊 |
@srinjoydutta03 as for our discussion about the next tasks which can be interesting for you. At the moment, we have the following ARM-related tasks which already have assignee.. But she has a lot of taken issues without any activity in these tasks:
Just leave please the comment in the interesting for you issue. I will reassign to you! 😊 |
Context
Snippets is a highly specialized JIT (just-in-time) compiler for computational graphs. It provides a scalable approach to operations' fusions and enablement. As a typical compiler,
Snippets
have frontend (tokenizer), optimizer and backend (generator).The first of the
Snippets
pipeline, Tokenization, identifies parts of the initialov::Model
that can be lowered bySnippets
efficiently, and tokenizes them into one whole node -Subgraph
.The second step of the pipeline (Optimizer) is applying common and device-specific optimizations to
Subgraph
and getting lowered representation of tokenizedSubgraph
.Finally, the last stage is code emission. The target generator maps every operation in the IR to a binary code emitter JIT Emitter, which is then used to produce a piece of executable code. As a result, we produce an executable that performs calculations described by the initial input
ov::Model
.The purpose of this issue is enabling FakeQuantize operation tokenization in Snippets for ARM devices.
Snippets decomposes
FakeQuantize
into several simple elementwise operations usingFakeQuantizeDecomposition
pass. This pass is called after the op tokenization into Subgraph.Prerequisites
Recommended to use ARM CPU based platform for development (e.g. Mac, Raspberry Pi etc). The cross-compilation with an emulator (e.g. QEMU) using is still option:
cmake -DCMAKE_TOOLCHAIN_FILE=../cmake/arm64.toolchain.cmake ..
.What needs to be done?
smoke*Snippets*_FQDecomposition_*
tests. Launch tests (how to launch them - please see the sectionTests
below). There should be failed tests.FakeQuantize
op tokenization in tokenizer callback in CPU Plugin - update theis_supported_op
.Tests
Tests are disabled in default build, so ensure to add
-DENABLE_TESTS=ON
into cmake command.GoogleTest is used for testing. CPU functional test target is ov_cpu_func_tests. You can use
GoogleTest
filter:./bin/[platform]/[build_type]/ov_cpu_func_tests --gtest_filter="*smoke*Snippets*FQDecomposition*"
Examples
Resources
Contact points
@a-sidorova, @dmitry-gorokhov
The text was updated successfully, but these errors were encountered: