This is required to disable any gradient calculation during validation / prediction in training loop. From my understanding if not included, it wll update weights on each validation / prediction iteration.
This is original final_prediction output
This is with grad turned off during validation / prediction.
This section in predict() https://github.com/Seanny123/da-rnn/blob/8585806feee7726084bb2f733a3aaefada9c1f2f/main.py#L178-L181 should be changed to
This is required to disable any gradient calculation during validation / prediction in training loop. From my understanding if not included, it wll update weights on each validation / prediction iteration.
This is original final_prediction output
This is with grad turned off during validation / prediction.