Done. I also successfully reproduced the problem using only one set of features, labels and two sets of global variables. It is clear now that the problem is related to them (global vars). I added an updated notebook here:
  
      

      colab.research.google.com
  

  
    

Google Colaboratory 2