Opto-coupled PWM output
Analog optocouplers are not great with regards to rise/fall time uniformity. A typical circuit you see is a simple pull-up but then you're limited by low-level versus speed versus power dissipation. 

So unless you can use a digital high speed optocoupler that has an integrated amplifier, you're pretty much stuck with that push-pull configuration. Possibly even with an external output stage if you need more oomph in your load. 

Note that digital optocouplers usually come as 3.3V or 5V variants and the signal may not exceed the VCC.

Incidentally, you need to add a base resistor to that PNP transistor.