-
Notifications
You must be signed in to change notification settings - Fork 3
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
Add handling of spatial simulations #5
Comments
For the spatial simulations, could we design it so that we have a base work directory (like Design questions to settle:
|
For the directory structure, this is what I have as a plan so far:
The Note we have a separate Also, the custom laboratory directory is in |
Running with payu allows us to use a different met forcing file for consecutive years/restarts (see https://github.com/CABLE-LSM/cable_example). However, we only have met forcing files up from 1901 to 1909 so the run will fail if we go beyond 1909. Should we add the ability to repeat the forcing every N years/restarts?
I don't think I can answer this but it sounds reasonable to initialise CABLE with the same restart file. Would it beneficial to the user if they could use their own restart file? It would also be great to have a test in benchcab that can verify the spinup is working correctly. |
Some other design related questions:
|
So why do we need to be able to set up a custom path for the laboratory? Do you have a use case in mind or it is just to give us the option if the use case appears afterwards? In the last paragraph, I'm guessing you meant "standard laboratory directory" and not "custom". I am just mentioning it to make sure I understand correctly what you mean. |
The main idea is to keep the "benchcab-payu" laboratory separate from the "standalone payu" laboratory. By default the laboratory is |
Would the option be to get the command to run to build with MPI support? |
Sorry, it's my bad. I read "benchcab config.yaml" instead of "payu config.yaml", so I was wondering why we would want to let users specify their own path. I totally get the idea to set everything within the benchcab work directory. And that's much better that way. |
Yep I see the issue here. We could do something similar to what is done in Github Actions to specify the commands? For example, build_commands: |
cd offline
./bespoke_build_script.sh --mpi Also, should we run both fluxsite tests and spatial tests from the build_commands: |
cd offline
./bespoke_build_script.sh # build the serial executable
./bespoke_build_script.sh --clean # clean the build (if needed)
./bespoke_build_script.sh --mpi # build the MPI executable Actually on second thought, this approach doesn't lend itself nicely for removing environment modules lines from the build script. It is probably sufficient to specify the arguments on top of the path to the build script: build_script:
- path: offline/bespoke_build_script.sh
- args: [--mpi] On third thought... 😆 if we prefer the Github Actions syntax, we could disable the |
But this doesn't allow us to remove the "module load/add" lines from the build script or even worst "module purge", right? Hence opening the door to module inconsistencies. |
This shouldn't be a problem since we can let the mock take in any arbitrary arguments |
Ah, I finally understood what you are proposing. You want to disable the About running fluxsites and spatial tests from one command, yes. But could be done in a future version. As you note, this would most likely require to clean the compilation between the 2. It would have to be done once we are sure the fluxsites tasks are done with. Now that I understand your "third thought", I think the best is to ask for the exact commands and use the mock module script. One question: is it easier if we have one key per command? Then it makes it clear people always need all 4 commands? Or is it enough to specify in the documentation? I am wondering if some people will think that the commands would be executed one after the other and worry if the "clean" option removes the built executable. Also, how do we ensure people give the commands in the correct order? What if someone gives MPI command first, single CPU command and then clean command? I can't see how we can check within |
I don't think it's necessary as long as in the end we have a build_commands: |
cd offline
./bespoke_build_script.sh # build the serial executable
rm -rf .tmp # clean without removing the executable
./bespoke_build_script.sh --mpi # build the MPI executable We would just have to make it clear to the user that when using custom build commands, benchcab expects all the executables it needs can be found in the |
I am revisiting this considering the issue #130 around the parallelisation of the compilation. If we want to run all compilations at the same time, then should we have 2 checkout/clone of each source code's branch: one to compile serially and one to compile in parallel. And then you just get 2 commands: serial and MPI. In this case, should we have a key for each command? Or specify the order in the documentation? |
I've added a comment on that issue here #130 (comment). For building legacy CABLE versions in parallel, we could defer this responsibility to the user? In theory, the user could background each process to run in parallel like this build_commands: |
cd offline
./serial_build &
./mpi_build &
wait |
The spatial test suite runs CABLE with CRUJRA forcing at ACCESS resolution (see [here][cable_example] for more details) over all science configurations and model versions. Spatial tests use the [payu framework][payu]. The payu framework was chosen so that we: - Encourage uptake of payu amongst users of CABLE - Have the foundations in place for running coupled models (atmosphere + land) with payu. - Can easily test longer running simulations (payu makes it easy to run a model multiple times and have state persist in the model via restart files). The run directory structure is organised as follows: runs/ ├── spatial │ └── tasks │ ├── <spatial-task-name> (a payu control / experiment directory) │ └── ... ├── payu-laboratory │ └── ... └── fluxsite └── ... Note we have a separate payu-laboratory directory. This is so we keep all CABLE outputs produced by benchcab under the bench_example work directory. Add the ability to build the CABLE executable with MPI at runtime so that we run the spatial configurations with MPI. Add the --mpi flag to benchcab build command so that the user can run the MPI build step independently. Add utility functions for git API requests and manipulating namelist files. Fixes #5 [payu]: https://github.com/payu-org/payu [cable_example]: [email protected]:CABLE-LSM/cable_example.git
The spatial test suite runs CABLE with CRUJRA forcing at ACCESS resolution (see [here][cable_example] for more details) over all science configurations and model versions. Spatial tests use the [payu framework][payu]. The payu framework was chosen so that we: - Encourage uptake of payu amongst users of CABLE - Have the foundations in place for running coupled models (atmosphere + land) with payu - Can easily test longer running simulations (payu makes it easy to run a model multiple times and have state persist in the model via restart files) The run directory structure is organised as follows: runs/ ├── spatial │ └── tasks │ ├── <spatial-task-name> (a payu control / experiment directory) │ └── ... ├── payu-laboratory │ └── ... └── fluxsite └── ... Note we have a separate payu-laboratory directory. This is so we keep all CABLE outputs produced by benchcab under the bench_example work directory. Add the ability to build the CABLE executable with MPI at runtime so that we run the spatial configurations with MPI. Add the --mpi flag to benchcab build command so that the user can run the MPI build step independently. Add utility functions for git API requests and manipulating namelist files. Fixes #5 [payu]: https://github.com/payu-org/payu [cable_example]: https://github.com/CABLE-LSM/cable_example
The spatial test suite runs CABLE with CRUJRA forcing at ACCESS resolution (see [here][cable_example] for more details) over all science configurations and model versions. Spatial tests use the [payu framework][payu]. The payu framework was chosen so that we: - Encourage uptake of payu amongst users of CABLE - Have the foundations in place for running coupled models (atmosphere + land) with payu - Can easily test longer running simulations (payu makes it easy to run a model multiple times and have state persist in the model via restart files) The run directory structure is organised as follows: runs/ ├── spatial │ └── tasks │ ├── <spatial-task-name> (a payu control / experiment directory) │ └── ... ├── payu-laboratory │ └── ... └── fluxsite └── ... Note we have a separate payu-laboratory directory. This is so we keep all CABLE outputs produced by benchcab under the bench_example work directory. Add the ability to build the CABLE executable with MPI at runtime so that we run the spatial configurations with MPI. Add the --mpi flag to benchcab build command so that the user can run the MPI build step independently. Add utility functions for git API requests and manipulating namelist files. Add subcommands to run each step of the spatial workflow in isolation. Add payu key in the benchcab config file so that users can easily configure payu experiments. Fixes #5 [payu]: https://github.com/payu-org/payu [cable_example]: https://github.com/CABLE-LSM/cable_example
The spatial test suite runs CABLE with CRUJRA forcing at ACCESS resolution (see [here][cable_example] for more details) over all science configurations and model versions. Spatial tests use the [payu framework][payu]. The payu framework was chosen so that we: - Encourage uptake of payu amongst users of CABLE - Have the foundations in place for running coupled models (atmosphere + land) with payu - Can easily test longer running simulations (payu makes it easy to run a model multiple times and have state persist in the model via restart files) The run directory structure is organised as follows: runs/ ├── spatial │ └── tasks │ ├── <spatial-task-name> (a payu control / experiment directory) │ └── ... ├── payu-laboratory │ └── ... └── fluxsite └── ... Note we have a separate payu-laboratory directory. This is so we keep all CABLE outputs produced by benchcab under the bench_example work directory. Add the ability to build the CABLE executable with MPI at runtime so that we run the spatial configurations with MPI. Add the --mpi flag to benchcab build command so that the user can run the MPI build step independently. Add utility functions for git API requests and manipulating namelist files. Add subcommands to run each step of the spatial workflow in isolation. Add payu key in the benchcab config file so that users can easily configure payu experiments. Fixes #5 [payu]: https://github.com/payu-org/payu [cable_example]: https://github.com/CABLE-LSM/cable_example
The spatial test suite runs CABLE with CRUJRA forcing at ACCESS resolution (see [here][cable_example] for more details) over all science configurations and model versions. Spatial tests use the [payu framework][payu]. The payu framework was chosen so that we: - Encourage uptake of payu amongst users of CABLE - Have the foundations in place for running coupled models (atmosphere + land) with payu - Can easily test longer running simulations (payu makes it easy to run a model multiple times and have state persist in the model via restart files) The run directory structure is organised as follows: runs/ ├── spatial │ └── tasks │ ├── <spatial-task-name> (a payu control / experiment directory) │ └── ... ├── payu-laboratory │ └── ... └── fluxsite └── ... Note we have a separate payu-laboratory directory. This is so we keep all CABLE outputs produced by benchcab under the bench_example work directory. Add the ability to build the CABLE executable with MPI at runtime so that we run the spatial configurations with MPI. Add the --mpi flag to benchcab build command so that the user can run the MPI build step independently. Add utility functions for git API requests and manipulating namelist files. Add subcommands to run each step of the spatial workflow in isolation. Add payu key in the benchcab config file so that users can easily configure payu experiments and pass in command line arguments to the `payu run` command. Fixes #5 [payu]: https://github.com/payu-org/payu [cable_example]: https://github.com/CABLE-LSM/cable_example
The spatial test suite runs CABLE with CRUJRA forcing at ACCESS resolution (see [here][cable_example] for more details) over all science configurations and model versions. Spatial tests use the [payu framework][payu]. The payu framework was chosen so that we: - Encourage uptake of payu amongst users of CABLE - Have the foundations in place for running coupled models (atmosphere + land) with payu - Can easily test longer running simulations (payu makes it easy to run a model multiple times and have state persist in the model via restart files) The run directory structure is organised as follows: runs/ ├── spatial │ └── tasks │ ├── <spatial-task-name> (a payu control / experiment directory) │ └── ... ├── payu-laboratory │ └── ... └── fluxsite └── ... Note we have a separate payu-laboratory directory. This is so we keep all CABLE outputs produced by benchcab under the bench_example work directory. Add the ability to build the CABLE executable with MPI at runtime so that we run the spatial configurations with MPI. Add the --mpi flag to benchcab build command so that the user can run the MPI build step independently. Add utility functions for git API requests and manipulating namelist files. Add subcommands to run each step of the spatial workflow in isolation. Add payu key in the benchcab config file so that users can easily configure payu experiments and pass in command line arguments to the `payu run` command. Fixes #5 [payu]: https://github.com/payu-org/payu [cable_example]: https://github.com/CABLE-LSM/cable_example
Hey team! Please add your planning poker estimate with Zenhub @ccarouge @SeanBryan51 |
The spatial test suite runs CABLE with CRUJRA forcing at ACCESS resolution (see [here][cable_example] for more details) over all science configurations and model versions. Spatial tests use the [payu framework][payu]. The payu framework was chosen so that we: - Encourage uptake of payu amongst users of CABLE - Have the foundations in place for running coupled models (atmosphere + land) with payu - Can easily test longer running simulations (payu makes it easy to run a model multiple times and have state persist in the model via restart files) The run directory structure is organised as follows: runs/ ├── spatial │ └── tasks │ ├── <spatial-task-name> (a payu control / experiment directory) │ └── ... ├── payu-laboratory │ └── ... └── fluxsite └── ... Note we have a separate payu-laboratory directory. This is so we keep all CABLE outputs produced by benchcab under the bench_example work directory. Add the ability to build the CABLE executable with MPI at runtime so that we run the spatial configurations with MPI. Add the --mpi flag to benchcab build command so that the user can run the MPI build step independently. Add utility functions for git API requests and manipulating namelist files. Add subcommands to run each step of the spatial workflow in isolation. Add payu key in the benchcab config file so that users can easily configure payu experiments and pass in command line arguments to the `payu run` command. Fixes #5 [payu]: https://github.com/payu-org/payu [cable_example]: https://github.com/CABLE-LSM/cable_example
The spatial test suite runs CABLE with CRUJRA forcing at ACCESS resolution (see [here][cable_example] for more details) over all science configurations and model versions. Spatial tests use the [payu framework][payu]. The payu framework was chosen so that we: - Encourage uptake of payu amongst users of CABLE - Have the foundations in place for running coupled models (atmosphere + land) with payu - Can easily test longer running simulations (payu makes it easy to run a model multiple times and have state persist in the model via restart files) The run directory structure is organised as follows: runs/ ├── spatial │ └── tasks │ ├── <spatial-task-name> (a payu control / experiment directory) │ └── ... ├── payu-laboratory │ └── ... └── fluxsite └── ... Note we have a separate payu-laboratory directory. This is so we keep all CABLE outputs produced by benchcab under the bench_example work directory. Add the ability to build the CABLE executable with MPI at runtime so that we run the spatial configurations with MPI. Add the --mpi flag to benchcab build command so that the user can run the MPI build step independently. Add utility functions for git API requests and manipulating namelist files. Add subcommands to run each step of the spatial workflow in isolation. Add payu key in the benchcab config file so that users can easily configure payu experiments and pass in command line arguments to the `payu run` command. Fixes #5 [payu]: https://github.com/payu-org/payu [cable_example]: https://github.com/CABLE-LSM/cable_example
Spatial tests use the [payu framework][payu]. The payu framework was chosen so that we: - Encourage uptake of payu amongst users of CABLE - Have the foundations in place for running coupled models (atmosphere + land) with payu - Can easily test longer running simulations (payu makes it easy to run a model multiple times and have state persist in the model via restart files) The design of the spatial tests assumes each payu experiment is tailored to running CABLE with a specific meteorological forcing. This has the benefit that all the required inputs are already defined in the payu configuration file. An alternative would be to build up the spatial namelist configurations from scratch. This would be problematic as it is unclear if CABLE requires 'forcing specific' namelist options to be enabled to run with a particular met forcing. That is, CABLE does not allow for easy plug and play with different met forcings via the namelist file. The run directory structure is organised as follows: runs/ ├── spatial │ └── tasks │ ├── <spatial-task-name> (a payu control / experiment directory) │ └── ... ├── payu-laboratory │ └── ... └── fluxsite └── ... Note we have a separate payu-laboratory directory. This is so we keep all CABLE outputs produced by benchcab under the bench_example work directory. This change includes the following additional features: - Add the ability to build the CABLE executable with MPI at runtime so that we run the spatial configurations with MPI. - Add the --mpi flag to benchcab build command so that the user can run the MPI build step independently. - Add subcommands to run each step of the spatial workflow in isolation. - Add payu key in the benchcab config file so that users can easily configure payu experiments and add optional command line arguments to the payu run command. - Add met_forcings key to specify different met forcings and their respective payu experiment. Fixes #5 [payu]: https://github.com/payu-org/payu [cable_example]: https://github.com/CABLE-LSM/cable_example
Spatial tests use the [payu framework][payu]. The payu framework was chosen so that we: - Encourage uptake of payu amongst users of CABLE - Have the foundations in place for running coupled models (atmosphere + land) with payu - Can easily test longer running simulations (payu makes it easy to run a model multiple times and have state persist in the model via restart files) The design of the spatial tests assumes each payu experiment is tailored to running CABLE with a specific meteorological forcing. This has the benefit that all the required inputs are already defined in the payu configuration file. An alternative would be to build up the spatial namelist configurations from scratch. This would be problematic as it is unclear if CABLE requires 'forcing specific' namelist options to be enabled to run with a particular met forcing. That is, CABLE does not allow for easy plug and play with different met forcings via the namelist file. The run directory structure is organised as follows: runs/ ├── spatial │ └── tasks │ ├── <spatial-task-name> (a payu control / experiment directory) │ └── ... ├── payu-laboratory │ └── ... └── fluxsite └── ... Note we have a separate payu-laboratory directory. This is so we keep all CABLE outputs produced by benchcab under the bench_example work directory. This change includes the following additional features: - Add the ability to build the CABLE executable with MPI at runtime so that we run the spatial configurations with MPI. - Add the --mpi flag to benchcab build command so that the user can run the MPI build step independently. - Add subcommands to run each step of the spatial workflow in isolation. - Add payu key in the benchcab config file so that users can easily configure payu experiments and add optional command line arguments to the payu run command. - Add met_forcings key to specify different met forcings and their respective payu experiment. Fixes #5 [payu]: https://github.com/payu-org/payu [cable_example]: https://github.com/CABLE-LSM/cable_example
Spatial tests use the [payu framework][payu]. The payu framework was chosen so that we: - Encourage uptake of payu amongst users of CABLE - Have the foundations in place for running coupled models (atmosphere + land) with payu - Can easily test longer running simulations (payu makes it easy to run a model multiple times and have state persist in the model via restart files) The design of the spatial tests assumes each payu experiment is tailored to running CABLE with a specific meteorological forcing. This has the benefit that all the required inputs are already defined in the payu configuration file. An alternative would be to build up the spatial namelist configurations from scratch. This would be problematic as it is unclear if CABLE requires 'forcing specific' namelist options to be enabled to run with a particular met forcing. That is, CABLE does not allow for easy plug and play with different met forcings via the namelist file. The run directory structure is organised as follows: runs/ ├── spatial │ └── tasks │ ├── <spatial-task-name> (a payu control / experiment directory) │ └── ... ├── payu-laboratory │ └── ... └── fluxsite └── ... Note we have a separate payu-laboratory directory. This is so we keep all CABLE outputs produced by benchcab under the bench_example work directory. This change includes the following additional features: - Add the ability to build the CABLE executable with MPI at runtime so that we run the spatial configurations with MPI. - Add the --mpi flag to benchcab build command so that the user can run the MPI build step independently. - Add subcommands to run each step of the spatial workflow in isolation. - Add payu key in the benchcab config file so that users can easily configure payu experiments and add optional command line arguments to the payu run command. - Add met_forcings key to specify different met forcings and their respective payu experiment. Fixes #5 [payu]: https://github.com/payu-org/payu [cable_example]: https://github.com/CABLE-LSM/cable_example
Tests for the spatial/global configuration for CABLE offline should be the next configuration we add to the test suite (at least before CASA).
Sub-tasks for this issue include:
Spatial met forcing files and an example run directory are available here:
/g/data/tm70/ccc561/CABLE/CABLE-as-ACCESS_Yingping
. This can be used as inspiration for our run directories for the spatial tests. Note, if we use the same configurations we should:The text was updated successfully, but these errors were encountered: