This reply has been reported for inappropriate content.
whew… I’m with paulie. there’s A LOT going on in here and there are some lines you can free up in your code that A) do nothing or B) you can write it more efficiently. That and all the gradient setting flying around the code makes ones head spin. Not all is lost though. I’d just refine your code a bit and I’m sure that would clear up some current issues, as well as future ones.