[MITgcm-support] New added Diagnostics-problem

Dimitris Menemenlis dmenemenlis at gmail.com
Thu Oct 29 17:10:51 EDT 2015


Hi Kaveh, I am curious.
What does pkg/sediment do?
Is it a physics or a biogeochemistry package?

Cheers, 

Dimitris Menemenlis

> On Oct 29, 2015, at 5:04 PM, kaveh Purkiani <kavehpurkiani at googlemail.com> wrote:
> 
> Hi Michel,
> 
> I have my own package (SEDIMENT), same structure as mypackage provided in MITgcm. But, when ever I have written mypackage at former emails, meant SEDIMENT.
> 
> regards,
> 
> Kaveh.
> 
> On Thu, Oct 29, 2015 at 8:17 PM, Jean-Michel Campin <jmc at ocean.mit.edu <mailto:jmc at ocean.mit.edu>> wrote:
> Hi Kaveh,
> 
> I am a little bit confused: within MITgcm code, there is a package
> called "mypackage" and I was assuming that when you refer to
> mypackage_diagnostics_init.F like here:
> > > > 1- New diagnostic in mypackage_diagnostics_init.F is added like below:
> you mean a modification in MITgcm/pkg/mypackage/mypackage_diagnostics_init.F
> 
> But as I understand now, it might be in a new subroutine/file called
> sediment_diagnostics_init.F
> >         CALL SEDIMENT_DIAGNOSTICS_INIT( myThid )
> 
> Could you please clarify this point above ?
> 
> Cheers,
> Jean-Michel
> 
> On Thu, Oct 29, 2015 at 04:36:08PM +0100, kaveh Purkiani wrote:
> > Dear Michel,
> >
> > Here are the issues:
> >
> > I don't have better suggestion than to check basic things, such as:
> > 1) is pkg/mypackage compiled ?
> >
> > Yes, it is compiled, here is the STDOUT
> >
> >  pkg/sediment             compiled   and   used ( useSEDIMENT
> > = T )
> >
> >
> > 2) is this package turned on ? ( useMYPACKAGE=.TRUE. in data.pkg)
> >
> > Yes, it is turned on.
> >
> > (PID.TID 0000.0001) > useSEDIMENT=.TRUE.,
> >
> > 3) check that S/R MYPACKAGE_DIAGNOSTICS_INIT is called
> >   by adding "debugMode=.TRUE." in eedata ; this print the sequence of
> >  subroutine calls in STDOUT files.
> >
> >
> > The debug mode compilation and run did work but turned out that mypackage
> > _DIAGNOSTICS_INIT is not at STOUT files and perhaps is not called.
> >
> >
> > As I mentioned before in mypackage_diagnostics_init.F I have a call routine
> > like below.
> >
> >       diagName  = 'TEST    '
> >       diagTitle = 'New Concentration'
> >       diagUnits = 'mmol/m^3/d       '
> >       diagCode  = 'SMR     MR       '
> >       CALL DIAGNOSTICS_ADDTOLIST( diagNum,
> >      I     diagName, diagCode, diagUnits, diagTitle,0,myThid )
> >       CALL DIAGNOSTICS_SETKLEV( diagName, 3, myThid )
> >
> >
> > the mypackage_init_fixed.F calls the mypackage_diagnostics_init like below:
> >
> >
> > #ifdef ALLOW_DIAGNOSTICS
> >       IF ( useDiagnostics ) THEN
> >         CALL SEDIMENT_DIAGNOSTICS_INIT( myThid )
> >       ENDIF
> > #endif
> >
> >
> > It is not sufficient to write a new diagnostics at
> > available.diagnostics.log ?
> >
> > What do I miss?
> >
> > 4) check that your changes are indeed present in the "small .f" file
> >  version, i.e.: mypackage_diagnostics_init.f (in the build dir).
> >
> >
> > yes, all my changes are in there.
> >
> >
> >
> > I appreciate your time in advance.
> >
> > regards,
> >
> >
> > Kaveh.
> >
> > On Wed, Oct 28, 2015 at 8:46 PM, Jean-Michel Campin <jmc at ocean.mit.edu <mailto:jmc at ocean.mit.edu>>
> > wrote:
> >
> > > Hi Kaveh,
> > >
> > > The error you are getting is consistent with the fact that
> > > the new diagnostics "new     " is not present in the log file:
> > >  available_diagnostics.log
> > > and I suspect that this piece of code you added in
> > > mypackage_diagnostics_init.F
> > > is not run through.
> > >
> > > I don't have better suggestion than to check basic things, such as:
> > > 1) is pkg/mypackage compiled ?
> > > 2) is this package turned on ? ( useMYPACKAGE=.TRUE. in data.pkg)
> > > 3) check that S/R MYPACKAGE_DIAGNOSTICS_INIT is called
> > >   by adding "debugMode=.TRUE." in eedata ; this print the sequence of
> > >  subroutine calls in STDOUT files.
> > > 4) check that your changes are indeed present in the "small .f" file
> > >  version, i.e.: mypackage_diagnostics_init.f (in the build dir).
> > >
> > > Cheers,
> > > Jean-Michel
> > >
> > > On Wed, Oct 28, 2015 at 04:12:36PM +0100, kaveh Purkiani wrote:
> > > > Hi all,
> > > >
> > > > I followed the user manual to add new diagnostics to the code.
> > > >
> > > > 1- New diagnostic in mypackage_diagnostics_init.F is added like below:
> > > >
> > > >       diagName  = 'new     '         (it is 8 characters long)
> > > >       diagTitle = 'New Concentration'
> > > >       diagUnits = 'mmol/m^3/d      '
> > > >       diagCode  = 'SMR     MR      '
> > > >       CALL DIAGNOSTICS_ADDTOLIST( diagNum,
> > > >      I     diagName, diagCode, diagUnits, diagTitle, 0,myThid )
> > > >
> > > >
> > > > 2- At mypackage_forcing.F the diagnostics_fill call is added:
> > > >
> > > > #ifdef ALLOW_DIAGNOSTICS
> > > >       CALL DIAGNOSTICS_FILL(new_pTracer,'new     ',0,Nr,1,bi,bj,myThid)
> > > > #endif /* ALLOW_DIAGNOSTICS */
> > > >
> > > >
> > > > 3- DIAGNOSTICS_SIZE.h is considered at code folder and data.diagnostics
> > > has
> > > > been defined in input folder.
> > > > Model compiled successfully. I have this error massage at model run :
> > > >
> > > >  (PID.TID 0001.0001) *** ERROR *** DIAGNOSTICS_SET_POINTERS: new      is
> > > > not a Diagnostic
> > > >
> > > > When I check the available.diagnostic.log in the running folder there is
> > > no
> > > > new variable which I thought it has been provided through the implemented
> > > > code.
> > > >
> > > > the diagnostics_set_ponters.F says :
> > > >
> > > > If (ndCount.EQ.0) call this error.
> > > > ndCount is number of diasable diagnostics in fldsList which is unknown to
> > > > me.
> > > >
> > > >
> > > > Any clue to solve this is very much appreciated.
> > > >
> > > >
> > > > regards,
> > > >
> > > > Kaveh.
> > >
> > > > _______________________________________________
> > > > MITgcm-support mailing list
> > > > MITgcm-support at mitgcm.org <mailto:MITgcm-support at mitgcm.org>
> > > > http://mitgcm.org/mailman/listinfo/mitgcm-support <http://mitgcm.org/mailman/listinfo/mitgcm-support>
> > >
> > >
> > > _______________________________________________
> > > MITgcm-support mailing list
> > > MITgcm-support at mitgcm.org <mailto:MITgcm-support at mitgcm.org>
> > > http://mitgcm.org/mailman/listinfo/mitgcm-support <http://mitgcm.org/mailman/listinfo/mitgcm-support>
> > >
> 
> > _______________________________________________
> > MITgcm-support mailing list
> > MITgcm-support at mitgcm.org <mailto:MITgcm-support at mitgcm.org>
> > http://mitgcm.org/mailman/listinfo/mitgcm-support <http://mitgcm.org/mailman/listinfo/mitgcm-support>
> 
> 
> _______________________________________________
> MITgcm-support mailing list
> MITgcm-support at mitgcm.org <mailto:MITgcm-support at mitgcm.org>
> http://mitgcm.org/mailman/listinfo/mitgcm-support <http://mitgcm.org/mailman/listinfo/mitgcm-support>
> 
> _______________________________________________
> MITgcm-support mailing list
> MITgcm-support at mitgcm.org
> http://mitgcm.org/mailman/listinfo/mitgcm-support

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mitgcm.org/pipermail/mitgcm-support/attachments/20151029/5e0fd6f7/attachment.htm>


More information about the MITgcm-support mailing list