is QAT still on the roadmap for keras3? #20319
-
is QAT still on the roadmap? ( #18930 from Feb has it as a "near future" release. ) have been porting code to keras3 ( as a way to move more to Jax ) & have options for post training quantisation but expect a non trivial benefit from QAT in a number of projects. can see a path forward by partially porting pieces of https://www.tensorflow.org/model_optimization/api_docs/python/tfmot and/or https://github.com/google/aqt but will hold back if a QAT api is imminent ? ( additionally; might have some bandwidth to help if there are community contrib options? ) |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 4 replies
-
bump though i can jump through hoops to get tfmot working ( ish ) the fact it is keras2 compat only is a pain :/ if keras3 QAT is pending i can hold out, otherwise will have to consider dropping back to keras2 :( :( :( |
Beta Was this translation helpful? Give feedback.
-
QAT is still on the roadmap but the work hasn't started yet, as we've had to prioritize other things... we can definitely re-prioritize it though. Most of the infra is already here in via the work @james77777778 did for float8 training. |
Beta Was this translation helpful? Give feedback.
-
great! if there's any pointers you can give me @james77777778 i'd be happy to help out; should have a bit of bandwidth for this over the next few months. |
Beta Was this translation helpful? Give feedback.
I'm happy to help with this but unfortunately I don't have enough bandwidth right now.
@matpalm I suggest starting by implementing these ops in a backend-agnostic way, as they are necessary for QAT:
tf.quantization.fake_quant_with_min_max_args
tf.quantization.fake_quant_with_min_max_vars
tf.quantization.fake_quant_with_min_max_vars_per_channel
You should be able to implement them using
ops.custom_gradient