How to set parameter list for optimizer for a set of linked sub-networks

my code seems to work.
also see: Giving multiple parameters in optimizer