Fix forward_loop: pass as callable, not via create_forward_loop
This commit is contained in:
@@ -115,9 +115,10 @@ def main():
|
||||
calib_seq=args.calib_seq,
|
||||
)
|
||||
|
||||
# Create forward loop from dataloader (modelopt helper)
|
||||
from modelopt.torch.utils.dataset_utils import create_forward_loop
|
||||
forward_loop = create_forward_loop(calib_dataloader)
|
||||
# Build forward loop for calibration
|
||||
def forward_loop(model):
|
||||
for batch in calib_dataloader:
|
||||
model(**batch)
|
||||
|
||||
# Quantize
|
||||
quant_cfg = QUANT_CONFIGS[args.qformat]
|
||||
|
||||
Reference in New Issue
Block a user