Added code to allow overwritten of methods at trainable objects