Join GitHub today
GitHub is home to over 36 million developers working together to host and review code, manage projects, and build software together.Sign up
[Partitioner] Add quantization profiling flow in Partitioner #3169
We run resnet50 for testing (see Test Plan)
[Optional Fixes #3112]
The following example shows that dump/load quantization profile for resnet50. The profile is generated using CPU backend, while the quantized model in running with Interpreter backend.
This is for heterogeneous partition testing (using this config file : tests/runtime_test/heterogeneousConfigs.yaml) :
Please see a detailed explanation of how to fill out the fields in the relevant sections in PULL_REQUEST.md.
rdzhabarov left a comment •
What do you think about having two partitioning schemas (two partitioner classes) at high level: regular partitioner and profile capturing partitioner.
You'd instantiate HostManager with the right partitioner (pass required partitioner as a param in HostManager ctor) and remove all custom logic inside the partitioner. I have not thought about details, but in this case there supposed to be a cleaner implementation without too much if/elses inside the exact partitioner. I becomes increasingly harder to maintain all the custom logic inside this partitioner.
Thanks for your advice. Maybe not tow classes, but 2 partition methods? I will think about it.
jfix71 left a comment
Cool! Added one question in code, not sure if it makes sense, I don't know the Partitioner super well
Also, it's possible/valid to compile Glow without the CPU backend enabled. Can we check