Dynamics of trans-cis photoisomerization of hetarylazo dyes