The valley is flat and was subject to flooding until 1878, when a major hydraulic engineering project changed the courses of the Aare and the Zihl and lowered the level of the three lakes by 2 meters .