I had problems with the piriformis and used to do these piriformis exercises 3 or more times a day, every day. At the time, I was working from home, so able to do them as often as I could, so I just kept stretching. I adapted them slightly so that I could feel the pull on the piriformis.
Clamshell glutes strengthener
I used this one (taken from bodycontrol Pilates), the trick is to lift the leg using the glutes and not the quads which is what most of us tend to do. The advice given to me was to start with very small lifts, the emphasis being on getting right rather than massive lifts.
This isn't a brilliant film, but it's the only one that I could find that gives written instructions as well. If you're good at it, you can add a band to make the glutes work harder!
I also did a programme of stretching other leg muscles so that they were all loosened in conjunction with each other. I also had a series of massages where my fizz really worked at that area - hurt afterwards, but it worked.
Sorry that you've got these problems, but hope it gets better, sounds as if it is, but just slowly
.