ONE - On-device Neural Engine
Loading...
Searching...
No Matches
DumpFakeQuantFM Namespace Reference

Data Structures

class  DumpFakeQuantFM
 

Functions

 _name_before_fq (name)
 

Variables

str fq_postfix = '_FQ_Quantize_FQ_Dequantize'
 

Function Documentation

◆ _name_before_fq()

DumpFakeQuantFM._name_before_fq (   name)
protected

Definition at line 31 of file DumpFakeQuantFM.py.

31def _name_before_fq(name):
32 if not name.endswith(fq_postfix):
33 return None
34
35 return name[0:name.find(fq_postfix)]
36
37
38# Dump fake-quantized model's intermediate FM data according to tensors.txt
39#
40# Before
41# self._dir/
42# tensors.json
43#
44# After
45# self._dir/
46# tensors.json
47# <TENSOR_ID>.npy
48# NOTE tensors.json has a dictionary {TENSOR_NAME -> TENSOR_ID}

Referenced by DumpFakeQuantFM.DumpFakeQuantFM.DefaultOpPost().

Variable Documentation

◆ fq_postfix

str DumpFakeQuantFM.fq_postfix = '_FQ_Quantize_FQ_Dequantize'

Definition at line 25 of file DumpFakeQuantFM.py.