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 iteration number in pre/postStep #643

Merged
merged 1 commit into from
Jan 26, 2024
Merged

Conversation

prisae
Copy link
Contributor

@prisae prisae commented Jan 25, 2024

I think the setPreStep and setPostStep calls get a wrong iteration number in the inversion framework. This tiny PR should fix this.

@halbmy halbmy self-assigned this Jan 25, 2024
@halbmy halbmy added the bug label Jan 25, 2024
@halbmy
Copy link
Contributor

halbmy commented Jan 25, 2024

Absolutely! We are counting from 0 in Python, but in inverse theory $m_0$ is the starting model.

But instead of writing i+1 three times, we should maybe use for i in range(1, maxIter+1).

@halbmy halbmy merged commit 320f5fc into gimli-org:dev Jan 26, 2024
@prisae prisae deleted the patch-1 branch June 10, 2024 13:00
prisae added a commit to prisae/gimli that referenced this pull request Jun 10, 2024
In here, I fixed the iteration number:
gimli-org#643

In here, the iterator was changed from `range(maxIter) to `range(1, maxIter)`, without changing back PR643, making the thing wrong again.
gimli-org@d72b828
halbmy pushed a commit that referenced this pull request Jun 11, 2024
In here, I fixed the iteration number:
#643

In here, the iterator was changed from `range(maxIter) to `range(1, maxIter)`, without changing back PR643, making the thing wrong again.
d72b828
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants