Forgive me if I ask trivial things but I am a beginner, this is the code:
model_quantized = model

eval_batch_size = value_batch_size
model_quantized.eval()
model_quantized.qconfig = torch.quantization.get_default_qconfig('qnnpack')
torch.backends.quantized.engine = 'qnnpack'

torch.quantization.prepare(model_quantized, inplace=True)
evaluate(model_quantized, criterion, loader_train, neval_batches=num_calibration_batches)

torch.quantization.convert(model_quantized, inplace=True)
top1, top5 = evaluate(model_quantized, criterion, loader_valid, neval_batches=num_eval_batches)

temp_scale, temp_zero_point = torch.quantization.observer.MinMaxObserver.calculate_qparams()

but if i run it, i get:
Traceback (most recent call last):
  File "main2D.py", line 785, in <module>
    temp_scale, temp_zero_point = torch.quantization.observer.MinMaxObserver.calculate_qparams()
TypeError: calculate_qparams() missing 1 required positional argument: 'self'

Should i write the command differently or in a different place?
Thank you very much.