PyGMT Transparency function is not working

I’m trying an example code [Points with varying transparency] from PyGMT tutorial (link here), which is expected to produce an image looked like this:

However, I ran into a problem showing the transparency effect.
The below is what I produced by running this example code.
Does anybody have an idea how to fix this problem?

Below is my PyGMT version information.

I think ghostscript 9.54 was one of the rotten releases with broken transparency. Try to upgrade it.

1 Like

Thanks a lot for your great advice!
While it seems that I can’t upgrade Ghostscript via conda channel (since the latest version it provides is 9.54 as well). check here
Do you have any idea how to upgrade Ghostscript via other paths?

ghostscript 9.54 here without any problems with transparency
changed the last line of the example script to fig.savefig('test_pygmt_transparency.png', transparent=True) to get the png figure shown below.

1 Like

Thanks a lot for your reply.
I tried it and the transparency effect works!