added random generators to layer