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

Development utilities #63

Open
wants to merge 29 commits into
base: develop
Choose a base branch
from
Open

Development utilities #63

wants to merge 29 commits into from

Conversation

jwallwork23
Copy link
Collaborator

@jwallwork23 jwallwork23 commented Nov 25, 2024

Closes #50.

There are quite a lot of things that you need to remember to do when building and running GISS-GC. I've tried my best to provide extensive docs on this but it has become difficult to manage when working across different platforms, especially when I don't have access to the one @AdelekeBankole is running on.

Here I propose an automated workflow that should hopefully make it easier for us to ensure that we're running the same thing.

@jwallwork23 jwallwork23 added the documentation Improvements or additions to documentation label Nov 25, 2024
@jwallwork23 jwallwork23 self-assigned this Nov 25, 2024
@jwallwork23 jwallwork23 marked this pull request as draft November 25, 2024 16:03
@jwallwork23 jwallwork23 marked this pull request as ready for review November 25, 2024 16:28
@jwallwork23 jwallwork23 linked an issue Nov 25, 2024 that may be closed by this pull request
@jwallwork23
Copy link
Collaborator Author

To review this, please check that the instructions in .dev are sufficiently clear and that it all works for you.

@@ -14,7 +14,7 @@ FFLAGS += -qopenmp
F90FLAGS += -qopenmp
LFLAGS += -qopenmp
endif
CTM_FLAGS = $(LFLAGS)
CTM_LFLAGS = $(LFLAGS)
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change is just fixing a minor oversight introduced in #62, as discussed in the meeting.

Comment on lines 153 to 173
- name: Build GISS-GC with GISS_GC_14 rundeck in debug mode
run: |
. /opt/spack-environment/activate.sh
# Environment variables for passing NetCDF-C paths to GEOS-Chem
export NETCDF_HOME=$(nc-config --prefix)
export GC_BIN=${NETCDF_HOME}/bin
export GC_INCLUDE=${NETCDF_HOME}/include
export GC_LIB=${NETCDF_HOME}/lib
# Environment variables for passing NetCDF-Fortran paths to GEOS-Chem
export NETCDF_F_HOME=$(nf-config --prefix)
export GC_F_BIN=${NETCDF_F_HOME}/bin
export GC_F_INCLUDE=${NETCDF_F_HOME}/include
export GC_F_LIB=${NETCDF_F_HOME}/lib
# Environment variable for OpenMPI build
MPIF90=$(find /opt/software -name mpif90 | head -n 1)
export MPI_ROOT=${MPIF90%/bin/mpif90}
# Copy over modelErc
cp .github/modelErc ~/.modelErc
# Remove the previous build and rebuild the model in debug mode
cp .dev/utils/build.sh .
./build.sh -f --debug
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here I add a CI job to test building with the --debug option.

@jwallwork23
Copy link
Collaborator Author

I just tested this setup on CSD3 using an existing setup.sh. Making sure that ${GC_INPUTS} is exported in setup.sh, all that needed changing was latest commit (761a522). I could then run

./build.sh --giss-only -f
./run --giss-only

and this ran to completion without error.

Running

./build.sh -f
./run.sh

I hit the same error (#65) as I get on my local machine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Store config files in repo
1 participant