Closed hwaseem04 closed 8 months ago
EMA is a commonly used training method (https://www.fidelity.com/learning-center/trading-investing/technical-analysis/technical-indicator-guide/ema)
If you want to use ema during inference, you also need to add this parameter during training. This code will save two models, one without ema and one with ema.
According to your error message, I think it is not caused by ema, but because you added time_trans during training, that is (https://github.com/microsoft/ProphetNet/blob/e2c6657309537b94818f5ddbb2a2c5b5559257bf/AR-diffusion/model_utils/ CrossAttention.py#L31), the corresponding parameter is time_att=True. I want to set time_att=False to run the code. In addition, if you want to add time_att=True during inference, you should also add this parameter during training.
I want to set
time_att=False
to run the code.
Perfect, setting time_att=False
removes the error during inference. I realised that I didn't use time_att=True
during training.
I trained the model from scratch using a custom dataset. After training, I utilized one of the weights stored in order to perform inference. But I get the below error:
My inference script:
And also, what is the difference between
load_from_ema=True
vsload_from_ema=False
any possible direction to debug? @wutong4012