Skip to content

Additional steps not yet included in restart repo #11

@ma595

Description

@ma595
✓ All done! Next steps:
    1. Back transform the coordinates of the pieced restart files using ncks
       (see bash script xarray_to_CMIP.sh)
    2. Rename/Overwrite the "NEW_" restart files to their old version if you're happy with them
       (see bash script rewrite.sh)
    3. Point to the restart directory in your simulation config.card
       You might need to reorganize them in a ./OCE/Restart/CM....nc structure
       instead of ./OCE_CM...nc (there's the rename.sh bash script for that)

See the example script Jumper.sh for reference.

Old code

We obviously need ncks and ncrename included as dependencies.

xarray_to_CMIP.sh

for i in "$@"
do
#ls -lh $i
ncrename -v yy,y $i
#ls -lh $i
#ncks -3 -O $i $i
#ls -lh $i
ncrename -v xx,x $i
#ls -lh $i
#ncks -7 - O $i $i
#ls -lh $i
done

CMIP_to_xarray.sh

for i in "$@"
do
#ls -lh $i
ncrename -v yy,y $i
#ls -lh $i
#ncks -3 -O $i $i
#ls -lh $i
ncrename -v xx,x $i
#ls -lh $i
#ncks -7 - O $i $i
#ls -lh $i
done

rename.sh

mkdir OCE
mkdir OCE/Restart
mkdir ATM
mkdir ATM/Restart
mkdir ICE
mkdir ICE/Restart
mkdir SBG
mkdir SBG/Restart
mkdir SRF
mkdir SRF/Restart
mkdir MBG
mkdir MBG/Restart
mkdir CPL
mkdir CPL/Restart
cp -r ../Exe .
for a in $@
do
mv $a ${a:0:3}'/Restart/'${a#???_}
done

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions