My accuracy is coming in negative

In this challenge, my r2 score of train data is comimg 97% but for test data it is coming negative.
link to code is:

my doubt is resolved

How did u resolve it? i am facing the same issue.