[Misc] Add BNB quantization for Whisper (#12381)

Signed-off-by: Jee Jee Li <pandaleefree@gmail.com>
This commit is contained in:
Jee Jee Li
2025-02-04 16:27:36 +08:00
committed by GitHub
parent c36ac98d01
commit 96b23621c1
3 changed files with 82 additions and 44 deletions

View File

@@ -131,3 +131,10 @@ class ParamMapping:
packed_name,
index,
)
def get_sub_modules(self,
module_name: str) -> Optional[Tuple[str, List[str]]]:
for key, value in self.packed_mapping.items():
if module_name.endswith(key):
return key, value
return None