|
5 | 5 | "cell_type": "markdown", |
6 | 6 | "metadata": {}, |
7 | 7 | "source": [ |
8 | | - "# Running the STEMMUS_SCOPE model\n", |
| 8 | + "# Running the STEMMUS_SCOPE model with different dataset\n", |
9 | 9 | "\n", |
10 | | - "This notebook shows how to run the STEMMUS_SCOPE model uisng the Executable file, including preprocessing and postprocessing. \n", |
| 10 | + "This notebook shows how to run the STEMMUS_SCOPE model uisng the Executable file, including preprocessing and postprocessing. For postprocesisng, the file required_netcdf_variables.csv can be found at https://github.com/EcoExtreML/STEMMUS_SCOPE/blob/main/utils/csv_to_nc/required_netcdf_variables.csv.\n", |
11 | 11 | "\n", |
12 | 12 | "## Which options are available?\n", |
13 | 13 | "\n", |
14 | | - "See the [run_model_with_different_options.ipynb](./run_model_with_different_options.ipynb) for avialbale options e.g. Executable file, Matlab, Octave.\n", |
| 14 | + "See the [Run the model with different options](./run_model_with_different_options.ipynb) for avialbale options e.g. Executable file, Matlab, Octave.\n", |
15 | 15 | "The STEMMUS_SCOPE executable file is located in a repository https://github.com/EcoExtreML/STEMMUS_SCOPE/blob/main/run_model_on_snellius/exe/STEMMUS_SCOPE.\n", |
16 | 16 | "\n", |
17 | 17 | "## Which datasets are available?\n", |
18 | 18 | "The config file shows how to set the paths to different data needed by the model. Check the data source on Snelius and CRIB and modify the config file accordingly:\n", |
19 | 19 | "\n", |
20 | | - "#### On CRIB:\n", |
21 | | - "- Site data: /data/shared/EcoExtreML/STEMMUS_SCOPEv1.0.0/input, config file template https://github.com/EcoExtreML/STEMMUS_SCOPE/blob/main/config_file_crib.txt\n", |
22 | | - "- Global data: /data/shared/EcoExtreML/STEMMUS_SCOPEv1.0.0/global_data, config file template https://github.com/EcoExtreML/STEMMUS_SCOPE/blob/main/run_model_on_snellius/config_file_snellius_global.txt\n", |
| 20 | + "#### On CRIB\n", |
| 21 | + "- Site data:\n", |
| 22 | + " - path to data: `/data/shared/EcoExtreML/STEMMUS_SCOPEv1.0.0/input`,\n", |
| 23 | + " - config file template: https://github.com/EcoExtreML/STEMMUS_SCOPE/blob/main/config_file_crib.txt\n", |
| 24 | + "- Global data:\n", |
| 25 | + " - path to data `/data/shared/EcoExtreML/STEMMUS_SCOPEv1.0.0/global_data`,\n", |
| 26 | + " - config file template: https://github.com/EcoExtreML/STEMMUS_SCOPE/blob/main/run_model_on_snellius/config_file_snellius_global.txt\n", |
23 | 27 | "\n", |
24 | | - "#### On SNellius:\n", |
25 | | - "- Site data: /projects/0/ttse0619/, config file template https://github.com/EcoExtreML/STEMMUS_SCOPE/blob/main/run_model_on_snellius/config_file_snellius.txt\n", |
26 | | - "- Global data: /projects/0/ttse0619/global_data, config file template https://github.com/EcoExtreML/STEMMUS_SCOPE/blob/main/run_model_on_snellius/config_file_snellius_global.txt\n", |
| 28 | + "#### On Snellius\n", |
| 29 | + "- Site data:\n", |
| 30 | + " - path to data: `/projects/0/ttse0619/`,\n", |
| 31 | + " - config file template: https://github.com/EcoExtreML/STEMMUS_SCOPE/blob/main/run_model_on_snellius/config_file_snellius.txt\n", |
| 32 | + "- Global data:\n", |
| 33 | + " - path to data: `/projects/0/ttse0619/global_data`,\n", |
| 34 | + " - config file template: https://github.com/EcoExtreML/STEMMUS_SCOPE/blob/main/run_model_on_snellius/config_file_snellius_global.txt\n", |
27 | 35 | "\n", |
28 | 36 | "Choose how do you want to run the model:\n", |
29 | 37 | "\n", |
|
204 | 212 | }, |
205 | 213 | { |
206 | 214 | "cell_type": "code", |
207 | | - "execution_count": 4, |
| 215 | + "execution_count": null, |
208 | 216 | "metadata": {}, |
209 | 217 | "outputs": [], |
210 | 218 | "source": [ |
|
213 | 221 | "path_to_model_src = \"./STEMMUS_SCOPE\"" |
214 | 222 | ] |
215 | 223 | }, |
| 224 | + { |
| 225 | + "cell_type": "markdown", |
| 226 | + "metadata": {}, |
| 227 | + "source": [ |
| 228 | + "If you run the model on your own machine, make sure `LD_LIBRARY_PATH` is set correctly. To do this, uncomment the cell below and run it:" |
| 229 | + ] |
| 230 | + }, |
| 231 | + { |
| 232 | + "cell_type": "code", |
| 233 | + "execution_count": null, |
| 234 | + "metadata": {}, |
| 235 | + "outputs": [], |
| 236 | + "source": [ |
| 237 | + "# # Set LD_LIBRARY_PATH\n", |
| 238 | + "matlab_path = !whereis MATLAB\n", |
| 239 | + "matlab_path = matlab_path.s.split(\": \")[1]\n", |
| 240 | + "os.environ['LD_LIBRARY_PATH'] = (\n", |
| 241 | + " f\"{matlab_path}/MATLAB_Runtime/R2023a/runtime/glnxa64:\"\n", |
| 242 | + " f\"{matlab_path}/MATLAB_Runtime/R2023a/bin/glnxa64:\"\n", |
| 243 | + " f\"{matlab_path}/MATLAB_Runtime/R2023a/sys/os/glnxa64:\"\n", |
| 244 | + " f\"{matlab_path}/MATLAB_Runtime/R2023a/extern/bin/glnxa64:\"\n", |
| 245 | + " f\"{matlab_path}/MATLAB_Runtime/R2023a/sys/opengl/lib/glnxa64\")\n", |
| 246 | + "print(os.environ['LD_LIBRARY_PATH'])" |
| 247 | + ] |
| 248 | + }, |
216 | 249 | { |
217 | 250 | "cell_type": "code", |
218 | 251 | "execution_count": 5, |
|
0 commit comments