We flew over a coastal cloud layer yesterday into KSMO which was reporting clear skies and unlimited visibility. The approach end to Rwy 21 was clear but the other end of the field was covered in clouds and when we took off a few minutes later we had to turn abruptly at 300' AGL to stay 500' below and 2000' away from them. It would probably have been safer to request a Special VFR departure. I’ve gotten SVFR for arrivals when our airport is IFR but the approach end of the field is VFR but never when the field is VFR. Is that something that is possible? If it is possible, is that something that KSMO tower will do given its proximity to LAX and separation that is needed for their traffic.