Changed certain types representing number of nodes in each layer to long.