Skip to content

Improve gallery examples#827

Merged
seisman merged 1 commit intomasterfrom
fix-gallery
Feb 1, 2021
Merged

Improve gallery examples#827
seisman merged 1 commit intomasterfrom
fix-gallery

Conversation

@seisman
Copy link
Member

@seisman seisman commented Jan 31, 2021

Description of proposed changes

  • Use SI units
  • Improve some comments
  • Improve some external references
  • Improve some stylings
  • Remove some links to the GMT documentation (We should refer users to the PyGMT API references).

Reminders

  • Run make format and make check to make sure the code follows the style guide.
  • Add tests for new features or tests that would have caught the bug that you're fixing.
  • Add new public functions/methods/classes to doc/api/index.rst.
  • Write detailed docstrings for all functions/methods.
  • If adding new functionality, add an example to docstrings or tutorials.

Notes

  • You can write /format in the first line of a comment to lint the code automatically

- Use SI units
- Improve some comments
- Improve some external references
- Improve some stylings
- Remove some links to the GMT documentation
@seisman seisman requested review from a team January 31, 2021 06:34
@seisman seisman added documentation Improvements or additions to documentation skip-changelog Skip adding Pull Request to changelog labels Jan 31, 2021
@seisman seisman added this to the 0.3.0 milestone Jan 31, 2021
@weiji14
Copy link
Member

weiji14 commented Jan 31, 2021

Could we speed-up two of the slowest (>10s) tutorial examples you mentioned in #825 in this PR?

computation time summary:

  • ../examples/tutorials/regions.py: 11.34 sec 0.0 MB
  • ../examples/tutorials/3d-perspective-image.py: 10.06 sec 0.0 MB

@seisman
Copy link
Member Author

seisman commented Jan 31, 2021

Could we speed-up two of the slowest (>10s) tutorial examples you mentioned in #825 in this PR?

computation time summary:

  • ../examples/tutorials/regions.py: 11.34 sec 0.0 MB
  • ../examples/tutorials/3d-perspective-image.py: 10.06 sec 0.0 MB

Tried to speed up regions.py by removing the borders arguments. The running time reduces from 11 s to 8 s. Still slow. The main issue in regions.py is that it contains too many similar figures.

@seisman
Copy link
Member Author

seisman commented Jan 31, 2021

I prefer to leave them to another PR.

@seisman
Copy link
Member Author

seisman commented Feb 1, 2021

Ping @weiji14 for a review.

@seisman seisman merged commit 153355e into master Feb 1, 2021
@seisman seisman deleted the fix-gallery branch February 1, 2021 06:55
sixy6e pushed a commit to sixy6e/pygmt that referenced this pull request Dec 21, 2022
- Use SI units
- Improve some comments
- Improve some external references
- Improve some stylings
- Remove some links to the GMT documentation
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation skip-changelog Skip adding Pull Request to changelog

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants