SNR of AES-128 on CW305

Hi, I’ve computed the signal to noise ration (SNR) for the hardware AES-128 (1 round per cycle implementation) both for the leakage model sbox_out and last_round_state_diff.
The result is the one shown in figure below and it left me perplexed.
I expected a better SNR of the last_round_state_diff than that of the sbox_out, in particular with a high spike on the last round.
Indeed, I’m able to recover easily the key with the last_round_state_diff but not with the sbox_out leakage model.
What am i missing ? Thanks in advance

For completeness the code i used to compute the snr is :

leak_model = cwa.leakage_models.sbox_output
snr_so = cwa.calculate_snr(project.traces, leak_model=leak_model, db=False)

The signal component of the SNR calculation done by calculate_snr() is defined by the leakage function. If you use an inappropriate leakage function, then I think the “SNR” result you get from this is kind of meaningless.

My mistake, I was playing with a modified AES implementation and I did not close the project correctly before of calculating the SNR of the original AES.

Now the result is as shown below and it makes sense
PowerVsSNR