Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GMT-Ghostscript incompatibility: Give recommendations and extend examples #3249

Merged
merged 32 commits into from
May 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
d7bf83c
Add transparency element to Getting started example
yvonnefroehlich May 14, 2024
b9abfac
Add reminder in release_checklist
yvonnefroehlich May 14, 2024
c524903
Fix typo
yvonnefroehlich May 14, 2024
9225116
Add note to 'Common installation issues'
yvonnefroehlich May 14, 2024
5c8a2df
Add comment to mention focus on transparency
yvonnefroehlich May 14, 2024
441d5d7
Remove comment in code block
yvonnefroehlich May 15, 2024
fcd16ae
Use implict targets for link within docs
yvonnefroehlich May 15, 2024
8dbc959
Shorten explanation in README
yvonnefroehlich May 15, 2024
15c0c78
Use lower-case letter
yvonnefroehlich May 15, 2024
c78bb3d
Merge branch 'main' into mention-gs-gmt-transprency
yvonnefroehlich May 15, 2024
0dbc778
Reduce line length
yvonnefroehlich May 15, 2024
869be37
Update articel
yvonnefroehlich May 15, 2024
78eadd8
Link to directly to subsection
yvonnefroehlich May 15, 2024
299ec6b
Use plural
yvonnefroehlich May 15, 2024
bd926d2
Remove double white space
yvonnefroehlich May 15, 2024
bdba4ef
Remove double white space
yvonnefroehlich May 15, 2024
9da5d54
Give gs and GMT version combination suggestions
yvonnefroehlich May 15, 2024
5fa9574
Start 'Ghostscript' with upper-case letter
yvonnefroehlich May 15, 2024
6f519e3
Increase figure size and font size
yvonnefroehlich May 16, 2024
577afe7
Add output figure of testing example
yvonnefroehlich May 16, 2024
2db2413
Merge branch 'main' into mention-gs-gmt-transprency
yvonnefroehlich May 16, 2024
19d7bc0
Center figure and reduce size
yvonnefroehlich May 16, 2024
efa855c
Improve note in 'Commen installation issues'
yvonnefroehlich May 16, 2024
cbb8cb7
Rewrapp to 88 characters
yvonnefroehlich May 16, 2024
2071627
Merge branch 'main' into mention-gs-gmt-transprency
yvonnefroehlich May 16, 2024
5e8ee92
Improve note under 'Common installation issues'
yvonnefroehlich May 16, 2024
c0829bb
Add article
yvonnefroehlich May 16, 2024
c402d4f
Remove verb
yvonnefroehlich May 16, 2024
f42cdf3
Rewrap to 88 characters
yvonnefroehlich May 17, 2024
33b64c7
Make formulations consistent
yvonnefroehlich May 17, 2024
2f78bc6
Merge branch 'main' into mention-gs-gmt-transprency
yvonnefroehlich May 18, 2024
1a537e8
Add 'testing your install' to reminder in release_checklist
yvonnefroehlich May 18, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .github/ISSUE_TEMPLATE/4-release_checklist.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ assignees: ''
- [ ] All tests pass in the ["GMT Dev Tests" workflow](https://github.com/GenericMappingTools/pygmt/actions/workflows/ci_tests_dev.yaml)
- [ ] All tests pass in the ["Doctests" workflow](https://github.com/GenericMappingTools/pygmt/actions/workflows/ci_doctests.yaml)
- [ ] Deprecations and related tests are removed for this version by running `grep --include="*.py" -r 'remove_version="vX.Y.Z"' pygmt` from the base of the repository
- [ ] Update warnings in `pygmt.show_versions()` as well as notes in [Common installation issues](https://www.pygmt.org/dev/install.html#not-working-transparency)
and [Testing your install]((https://www.pygmt.org/dev/install.html#testing-your-install) regarding GMT-Ghostscript incompatibility
- [ ] Reserve a DOI on [Zenodo](https://zenodo.org) by clicking on "New Version"
- [ ] Review the ["PyGMT Team" page](https://www.pygmt.org/dev/team.html)
- [ ] Finish up 'Changelog entry for v0.x.x' Pull Request:
Expand Down
7 changes: 5 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,11 +74,14 @@ or a [Jupyter notebook](https://docs.jupyter.org/en/latest/running.html), and tr
``` python
import pygmt
fig = pygmt.Figure()
fig.coast(projection="H10c", region="g", frame=True, land="gray")
fig.coast(projection="N15c", region="g", frame=True, land="tan", water="lightblue")
fig.text(position="MC", text="PyGMT", font="80p,Helvetica-Bold,red@75")
fig.show()
```

For more examples, please have a look at the [Gallery](https://www.pygmt.org/latest/gallery/index.html) and
You should see a global map with land and water masses colored in tan and lightblue, respectively. On top,
there should be the semi-transparent text "PyGMT". For more examples, please have a look at the
[Gallery](https://www.pygmt.org/latest/gallery/index.html) and
[Tutorials](https://www.pygmt.org/latest/tutorials/index.html).

## Contacting us
Expand Down
23 changes: 20 additions & 3 deletions doc/install.md
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ If you have [PyArrow](https://arrow.apache.org/docs/python/index.html) installed
does have some initial support for `pandas.Series` and `pandas.DataFrame` objects with
Apache Arrow-backed arrays. Specifically, only uint/int/float and date32/date64 dtypes
are supported for now. Support for string Arrow dtypes is still a work in progress.
For more details, see [issue #2800](https://github.com/GenericMappingTools/pygmt/issues/2800).
For more details, see [issue #2800](https://github.com/GenericMappingTools/pygmt/issues/2800).
:::

## Installing GMT and other dependencies
Expand Down Expand Up @@ -238,11 +238,17 @@ import pygmt
pygmt.show_versions()

fig = pygmt.Figure()
fig.coast(region="g", frame=True, shorelines=1)
fig.coast(projection="N15c", region="g", frame=True, land="tan", water="lightblue")
fig.text(position="MC", text="PyGMT", font="80p,Helvetica-Bold,red@75")
fig.show()
```
Copy link
Member

@seisman seisman May 14, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be great if we can add the image here so that it's more straightforward to see the differences if any. But I'm unsure what's the best way to add the image here.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, this would definitely be nice! I was also thinking about this while writing the explanation comment. I have to see when I have time to figure out a solution - maybe a table: left the code and right the image?

![pygmt-get-started](https://github.com/GenericMappingTools/pygmt/assets/3974108/f7f51484-8640-4b58-ae5b-6c71e7150f7a){.align-center width="70%"}

yvonnefroehlich marked this conversation as resolved.
Show resolved Hide resolved
If you see a global map with shorelines, then you're all set.
You should see a global map with land and water masses colored in tan and lightblue
respectively. On top, there should be the semi-transparent text "PyGMT". If the
semi-transparency does not show up, there is probably an incompatibility between your
GMT and Ghostscript versions. For details, please run `pygmt.show_versions()` and see
[Not working transparency](#not-working-transparency).

## Common installation issues

Expand Down Expand Up @@ -284,3 +290,14 @@ jupyter kernelspec list --json

After that, you need to restart Jupyter, open your notebook, select the `pygmt` kernel
and then import pygmt.


### Not working transparency

It is known that some combinations of GMT and Ghostscript versions cause issues,
especially regarding transparency. If the transparency doesn't work in your figures,
please check your GMT and Ghostscript versions (you can run `pygmt.show_versions()`).
We recommend:

- Ghostscript 9.53-9.56 for GMT 6.3.0/6.4.0
- Ghostscript 10.03 or later for GMT 6.5.0