Conversation
If copying the template and setting `pgbinary_flag=.true.` in binary_job will segfault if there isn't a pgbinary namelist in inlist_project
|
Either this is a placebo and not actually fixing anything, or I am seeing a very different issue (although I have the exact same stack trace as was shown on slack). The problem I am seeing is
This patch does not fix that for me (it seems unlikely that it could). The following does however (this just guards the limit calculations against bad numbers): diff --git a/star/private/pgstar_support.f90 b/star/private/pgstar_support.f90
index 232dada2b..48544ec06 100644
--- a/star/private/pgstar_support.f90
+++ b/star/private/pgstar_support.f90
@@ -854,17 +854,23 @@ contains
if (use_given_ymin) then
ymin = given_ymin
else
- ymin = minval(yvec(1:npts))
+ ymin = minval(yvec(1:npts), mask=.not. is_bad(yvec(1:npts)))
end if
use_given_ymax = abs(given_ymax + 101.0) > 1e-6
if (use_given_ymax) then
ymax = given_ymax
else
- ymax = maxval(yvec(1:npts))
+ ymax = maxval(yvec(1:npts), mask=.not. is_bad(yvec(1:npts)))
end if
dy = ymax - ymin
+ if (is_bad(dy)) then
+ ymax = given_ymax
+ ymin = given_ymin
+ dy = ymax - ymin
+ end if
+
if (.not. use_given_ymin) ymin = ymin - ymargin * dy
if (.not. use_given_ymax) ymax = ymax + ymargin * dy |
|
Oh good catch @VincentVanlaer! I tried it with the default |
|
Do you mean you only tested Eb's fix with the default inlists, or did you hit the same problem with the default inlists? |
|
Original issue (found in MESA 24.08.1): I'm encountering a weird pgbinary behavior: with Setting I originally thought it was just some interplay between the flags, unrelated to the choice of period -- this seems now incorrect. |
I only tested Eb's fix with the default and found no issues (once a |
|
My fix is just a patch/guard for bad numbers, not the real solution. I believe Vincent has identified the actual source of bad numbers. I can't test though, i can't reproduce on arm. |
|
@Debraheem Did your patch fix this issue for you? Cause that's what I am still somewhat confused about, since it doesn't seem that it can fix this issue. |
Do you have a workdir that reproduces this? I'm trying to get this to happen, but I don't know what exactly your setup is. |
|
Mathieu's original backtrace and files attached Backtrace for this error: |
|
Hashed it out with @mathren over slack. The reproducer for the |
|
Just for reference, to get the segfault issue because of the lack of a So it appears there may be two problems at once:
|
|
I think it is not a segfault for the lack of |
This branch attempts to address some pgbinary bugs raised by @mathren. @mathren can you document here how to reproduce your initial issue.