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

Fix inverted sign in upward derivative filter #479

Merged
merged 9 commits into from
Mar 27, 2024

Conversation

YagoMCastro
Copy link
Contributor

@YagoMCastro YagoMCastro commented Mar 18, 2024

In order to apply the convention of positive upwards, this code:

  1. Inverts signal of expected wavenumber at derivative_upward_kernel function;
  2. Inverts signal of wavenumber at derivative_upward_kernel function;
  3. Invert signal of upward derivative on test_transformations.py

Relevant issues/PRs:
Fixes #454

Copy link

welcome bot commented Mar 18, 2024

💖 Thank you for opening your first pull request in this repository! 💖

A few things to keep in mind:

No matter what, we are really grateful that you put in the effort to do this!

@leouieda
Copy link
Member

@YagoMCastro thanks for the fix! Could you please add a description to the PR? Under "relevant issues" you should include Fixes #454 so the issue will be linked here and closed automatically when this is merged.

Copy link
Member

@leouieda leouieda left a comment

Choose a reason for hiding this comment

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

Just need to fix the placement of the minus sign in the test. Could you also add a comment to the test_derivative_upward_order2 function explaining that we don't need the minus sign there because the second derivative is positive both for z (downward) and upward derivatives?

harmonica/tests/test_transformations.py Outdated Show resolved Hide resolved
@leouieda leouieda changed the title Invert sign in upward derivative filter Fix inverted sign in upward derivative filter Mar 21, 2024
Copy link
Member

@leouieda leouieda left a comment

Choose a reason for hiding this comment

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

Great, well done!

@leouieda leouieda merged commit b158698 into fatiando:main Mar 27, 2024
18 checks passed
Copy link

welcome bot commented Mar 27, 2024

🎉 Congrats on merging your first pull request and welcome to the team! 🎉

If you would like to be added as a author on the Zenodo archive of the next release, add your full name, affiliation, and ORCID (optional) to the AUTHORS.md file of this repository. Feel free to do this in a new pull request if needed.

We hope that this was a good experience for you. Let us know if there is any way that the contributing process could be improved.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Inverted sign in upward derivative filter
2 participants