Focal Mechanism cross section using pygmt

Is there anyone who can help me or give some example of the source code for making focal mechanism cross section using pygmt or GMT

See e.g. https://docs.generic-mapping-tools.org/dev/animations/anim14.html.