Speed up improvements in weights update