[MITgcm-devel] changes in exch-1
Jean-Michel Campin
jmc at ocean.mit.edu
Thu May 20 13:10:29 EDT 2010
Jean,
I found the secret place where all the good stuff is
> MITgcm_contrib/heimbach/OpenAD/OAD_support
is it right ?
and not hard to understand why nothing works anymore.
But should still work with checkpoint62g, right ?
Cheers
Jean-Michel
On Thu, May 20, 2010 at 11:19:15AM -0400, Jean-Michel Campin wrote:
> Hi Jean,
>
> To summarize the recent changes, 3 steps:
>
> step 1) internal changes within exch-1 code for multi-threaded with MPI
> (in exch_rx_send_put_x/y.template & exch_rx_recv_get_x/y.template)
> done on May 16; I sent an email to you on devel list since
> I simplify (reduce number of MPI calls) but did not know what
> should be done with AMPI.
> If I trust the daily test on dodongo & dokdo, this went well.
>
> step 2) (May 18) split exch_rx.F into Forward S/R (exch1_rx.F)
> and Adjoint S/R (exch1_rx_ad.F) and remove argument "simulationMode".
>
> Then we have checkpoint62g
>
> step 3) (May 19) change all flow dir for exch-1 and remove all autodiff/exch_*
> stuff
>
> steps 2 & 3) are the implementation of the changes I proposed in an email
> I sent to devel list on May 04, and put a copy here after.
>
> The main motivation was to get a similar AD processing with exch-2 & exch-1
> (and there are more users switching to exch2, at JPL, + Gael with
> ecco-v4, so it makes sense to consolidate this part).
>
> 2 short questions:
> a) can you confirm that checkpoint62g (after step-2) was working with
> OpenAD ? (the test I got from May 19 are OK, but want to be sure they
> include the step-2 changes from May 18).
> b) Did you try before OpenAD with exch-2 ? in this case, might be easier
> to fix step-3 (the AD processing now start at the same level).
>
> Thanks,
> Jean-Michel
>
> ======================================================================
> > Date: Tue, 4 May 2010 17:07:38 -0400
> > To: mitgcm-devel at mitgcm.org
> > Subject: [MITgcm-devel] changing exch-1
> >
> > Hi,
> >
> > I propose to split the basic exch1 subroutines (exch_rx.F,
> > generated from exch_rx.template) in 2 S/R, 1 forward and
> > 1 adjoint S/R, and then drop the "simulationMode" argument.
> >
> > My impression is that this way we could leave TAF see all the
> > different exch_*_rx.f subroutines, just need to have the right
> > flow dir for this basic exch1 S/R.
> >
> > This would also be much closer to what is done in pkg/exch2
> > (no true "simulationMode" arg., TAF see almost all the exch2_*_rx.f
> > files, with flow dir and hand written AD S/R for the 2 basic
> > exch2 S/R: exch2_rx1_cube & exch2_rx2_cube)
> > This way, we could avoid to have this mixed (and confusing) situation
> > where:
> > - without EXCH2, for each of exch_*_rx.f subroutine we need
> > an hand-written AD version (generally just a call to basic exch1 S/R
> > with arg. simulationMode = Reverse).
> > - with EXCH2, those exch1 S/R need to be (and are already) listed
> > in pkg/exch2/exch2_ad_diff.list
> > and the flow dir from pkg/autodiff/exch*ad*.flow needs to
> > be hidden (as well as the hand-written AD S/R version).
> >
> > We will need also a quick solution for the 4 exch_*_rx_cube
> > (exch_rx_cube, exch_uv_rx_cube, exch_z_rx_cube, exch_bg_rx_cube)
> > but presently the code corresponding to simulationMode=Reverse is
> > missing; so not a big deal to leave just a stop in an empty
> > hand-written AD S/R.
> ======================================================================
>
> On Thu, May 20, 2010 at 01:39:33AM -0500, Jean Utke wrote:
> > Hi Jean-Michel.
> >
> > Apparently you also changed that the exch routines get differentiated
> > but before they werent and the
> > manual layer that existed in exch_ad.F is apparently gone too,
> > Now - it would be helpfull to find out what the extent of all these
> > changes is and then I can follow up with my regression test.
> > Please let me know asap.
> >
> > Thanks,
> >
> > Jean
> >
> >
> > On 05/16/2010 10:16 PM, Jean-Michel Campin wrote:
> > > Hi Jean,
> > >
> > > I made few changes in (eesupp/src) exch S/R
> > > (exch_rx_send_put_x/y.template & exch_rx_recv_get_x/y.template)
> > > to works for local array with MPI and multi-threaded.
> > >
> > > I had to move around few MPI calls (in exch_rx_send_put_x/y)
> > > and I am not sure I did it right for the code you added
> > > with ALLOW_AUTODIFF_OPENAD_AMPI
> > > might be worth to check this before using it.
> > >
> > > Thanks,
> > > Jean-Michel
> > >
> > > _______________________________________________
> > > MITgcm-devel mailing list
> > > MITgcm-devel at mitgcm.org
> > > http://mitgcm.org/mailman/listinfo/mitgcm-devel
> > >
> >
> >
> > --
> > Jean Utke
> > Argonne National Lab. / MCS (240-1156)
> > 9700 S Cass Ave., Argonne, IL, 60439, USA
> > phone +1 630 252 4552 / mobile +1 630 363 5753
> >
> >
> > _______________________________________________
> > MITgcm-devel mailing list
> > MITgcm-devel at mitgcm.org
> > http://mitgcm.org/mailman/listinfo/mitgcm-devel
>
> _______________________________________________
> MITgcm-devel mailing list
> MITgcm-devel at mitgcm.org
> http://mitgcm.org/mailman/listinfo/mitgcm-devel
More information about the MITgcm-devel
mailing list