As GF pointed out
"after take-off, not alter heading from the take-off heading at a height at least 500 feet above terrain, if the alteration was not:
(i) directed by Air Traffic Control: or"
If ATC request you to do it then you have the option. You can also ask for an early turn.
This can help clear the departure fan to accomodate a heavier aircraft behind in case of a go-around or for some other requirements.
You still have to clear the screen height of 50 ft I think (Can't be too sure on that one).
Also on a SID the min height for a turn is 400ft agl. Otherwise the min height is published on the plate. A visual departure is 500ft agl.
Hope this helps