Having made music for 20 years, I’ve learned to not stress about it when you feel like you’ve lost your inspiration.
Give it some time, and it will come to you – but looking for it and spending energy on it doesn’t help very often.
Leave your place of work/art, take a walk, and most importantly, do something relaxing that frees your mind from any sort of obsessive thinking.
That will give your consciousness space, which in turn gives your ideas energy, and you’ll be back on track again.
Just don’t force it.