Fixed horribly slow work of 2D model