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

Development #97

Merged
merged 18 commits into from
Nov 4, 2024
Merged

Development #97

merged 18 commits into from
Nov 4, 2024

Conversation

amirDahari1
Copy link
Member

Fixes the iter limit reach and negative flux convergence issues.

@amirDahari1 amirDahari1 requested a review from stke9 January 18, 2024 14:22
@amirDahari1
Copy link
Member Author

solves #91 by calling s.calc_vertical_flux() after solve

@amirDahari1
Copy link
Member Author

solves #100

@amirDahari1 amirDahari1 requested a review from rmdocherty May 31, 2024 12:03
@amirDahari1 amirDahari1 mentioned this pull request Jul 26, 2024
Copy link
Contributor

Choose a reason for hiding this comment

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

Lines 49-51 and and 344-346 seem to be redundant

Copy link
Member Author

Choose a reason for hiding this comment

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

Thanks, deleted them, check out my latest commit.

@amirDahari1 amirDahari1 requested a review from daubners October 28, 2024 13:29
@@ -491,10 +498,15 @@ def check_convergence(self, verbose, conv_crit, start, iter_limit):

return False

def check_vertical_flux(self, conv_crit):
def calc_vertical_flux(self):
Copy link
Contributor

Choose a reason for hiding this comment

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

Is this different for every solver or could it simply be inherited?

vert_flux = (self.conc[:, 1:-1, 1:-1, 1:-1] - self.conc[:,
:-2, 1:-1, 1:-1]) * self.pre_factors[1][:, :-2, 1:-1, 1:-1]
vert_flux[self.nn == torch.inf] = 0
return vert_flux

def check_vertical_flux(self, conv_crit):
Copy link
Contributor

Choose a reason for hiding this comment

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

Inheritance? see question above

@daubners daubners merged commit 982efc5 into main Nov 4, 2024
4 checks passed
This was referenced Nov 18, 2024
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.

3 participants