It's to do with the distance it takes to get from V2 to flap retract speed when an engine fails, each take off or intersection has in theory a different altitude to raise the flaps governed by what you may fly into on the take off flight path.
400 feet is the minimum by regulation, do you really want to fly level at 400 feet trying to speed up to flap retract when it's 40 degrees at Al Bateen and you are heading towards downtown Abu Dhabi at MTOM.
In the mountains you may need to fly V2 to your engines 5 or 10 minute limit before being able to fly level for flap retract. If you don't buy take off perf or calculate it like we are supposed to then 1500 feet has got to be safer than 400 feet for level acceleration?.