bug fixed with resizing network