aimet icon indicating copy to clipboard operation
aimet copied to clipboard

ValueError: array has incorrect number of dimensions: 3; expected 4

Open xiexiaozheng opened this issue 1 year ago • 2 comments

When applying bias_correction to my model, an error occurs in the bias_correction.py script in the aimet. The error is located at line 340, specifically at "bias_correction.storePreActivationOutput(reference_output_batch)". The error message states: "ValueError: array has incorrect number of dimensions: 3; expected 4". The shape of reference_output_batch is (20, 256, 256), and the reference_layer is Conv1d(256, 256, kernel_size=(1,), stride=(1,)).

xiexiaozheng avatar Jul 13 '23 12:07 xiexiaozheng

@xiexiaozheng, we don't support Conv1d for bias correction ATM. If you would like, please try the Adaround technique instead of bias correction, it has proven to give much better results as compared to Bias correction.

quic-mangal avatar Jul 17 '23 17:07 quic-mangal

@xiexiaozheng, we don't support Conv1d for bias correction ATM. If you would like, please try the Adaround technique instead of bias correction, it has proven to give much better results as compared to Bias correction. I got it, thank you.

xiexiaozheng avatar Jul 20 '23 03:07 xiexiaozheng