model-optimization icon indicating copy to clipboard operation
model-optimization copied to clipboard

QAT for subclass inside the subclass

Open t7hua opened this issue 3 years ago • 2 comments

I have one subclass A, which contains another subclass B inside it. I find subclass B in fact didn't get quanted. class A (): self.layers=[] self.layers.append(Dense) self.layers.append(class B)

class A_quant(A): self.layers[0]=QuantizeWrapperV2(Dense, quant_config) _config=B.get_config() quant_layer=B_quant.from_config(_config) self.layers[1]=quant_layer

Well, everything runs fine of quant_anonatize and quant_apply. Then I find only the Dense in Class A is quant, the denses in Class B doesn't get quant.

t7hua avatar Jul 19 '22 07:07 t7hua

@Xhark could you take a look at this issue?

dansuh17 avatar Jul 30 '22 03:07 dansuh17

Hi, Would you please explain how did you make Q_quant more details? Is that quantized if you only use B_quant class?

Xhark avatar Aug 08 '22 16:08 Xhark