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

med_methods_mod LOGMSG questions #390

Closed
jedwards4b opened this issue Jun 22, 2023 · 4 comments · Fixed by #392
Closed

med_methods_mod LOGMSG questions #390

jedwards4b opened this issue Jun 22, 2023 · 4 comments · Fixed by #392

Comments

@jedwards4b
Copy link
Collaborator

@mvertens

I have a case in which I get a failure at line 1399 of med_methods_mod.F90 because both lranki and lranko are 0. I think maybe this case should not be an error.

@jedwards4b
Copy link
Collaborator Author

I tried a change

diff --git a/mediator/med_methods_mod.F90 b/mediator/med_methods_mod.F90
index d510e64..649c9c5 100644
--- a/mediator/med_methods_mod.F90
+++ b/mediator/med_methods_mod.F90
@@ -1354,7 +1354,10 @@ contains
         call med_methods_Field_GetFldPtr(lfield, fldptr1=dataptro1, fldptr2=dataptro2, rank=lranko, rc=rc)
         if (chkerr(rc,__LINE__,u_FILE_u)) return
 
-        if (lranki == 1 .and. lranko == 1) then
+        if (lranki == 0 .and. lranko == 0) then
+           ! do nothing
+          call ESMF_LogWrite(trim(subname)//": Both ranki and ranko are 0", ESMF_LOGMSG_INFO)
+        elseif (lranki == 1 .and. lranko == 1) then

And it appears to work correctly.

@mvertens
Copy link
Collaborator

@jedwards4b - Good fix. What caused the lranki=lranko=0? Can you issue a PR with this fix?

@jedwards4b
Copy link
Collaborator Author

I was scaling PFS.ne30pg3_t232.BLT1850_v0c.derecho_intel
and it did this when I ran NTASKS_ATM=5400
yes I will have a PR soon.

@mvertens
Copy link
Collaborator

Thanks!

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 a pull request may close this issue.

2 participants