Skip to content

Commit

Permalink
Fix paths for real now
Browse files Browse the repository at this point in the history
  • Loading branch information
BSchilperoort committed Oct 25, 2024
1 parent e769bd4 commit e5f4232
Showing 1 changed file with 15 additions and 14 deletions.
29 changes: 15 additions & 14 deletions book/oneModel/example_model_run_HBV.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,7 @@
"outputs": [],
"source": [
"# # option two: load data that you or someone else generated previously\n",
"# camelsgb_forcing = ewatercycle.forcing.sources['CaravanForcing'].load(directory=forcing_path_caravan)"
"# camelsgb_forcing = ewatercycle.forcing.sources['CaravanForcing'].load(directory=prepared_forcing_path_caravan_central)"
]
},
{
Expand All @@ -230,10 +230,10 @@
" <span style=\"color: #808000; text-decoration-color: #808000\">directory</span>=<span style=\"color: #800080; text-decoration-color: #800080; font-weight: bold\">PosixPath</span><span style=\"font-weight: bold\">(</span><span style=\"color: #008000; text-decoration-color: #008000\">'/home/bschilpero/forcing/camelsgb_73010/caravan'</span><span style=\"font-weight: bold\">)</span>,\n",
" <span style=\"color: #808000; text-decoration-color: #808000\">shape</span>=<span style=\"color: #800080; text-decoration-color: #800080; font-weight: bold\">PosixPath</span><span style=\"font-weight: bold\">(</span><span style=\"color: #008000; text-decoration-color: #008000\">'/home/bschilpero/forcing/camelsgb_73010/caravan/camelsgb_73010.shp'</span><span style=\"font-weight: bold\">)</span>,\n",
" <span style=\"color: #808000; text-decoration-color: #808000\">filenames</span>=<span style=\"font-weight: bold\">{</span>\n",
" <span style=\"color: #008000; text-decoration-color: #008000\">'Q'</span>: <span style=\"color: #008000; text-decoration-color: #008000\">'camelsgb_73010_1997-08-01_2000-08-31_Q.nc'</span>,\n",
" <span style=\"color: #008000; text-decoration-color: #008000\">'evspsblpot'</span>: <span style=\"color: #008000; text-decoration-color: #008000\">'camelsgb_73010_1997-08-01_2000-08-31_evspsblpot.nc'</span>,\n",
" <span style=\"color: #008000; text-decoration-color: #008000\">'pr'</span>: <span style=\"color: #008000; text-decoration-color: #008000\">'camelsgb_73010_1997-08-01_2000-08-31_pr.nc'</span>,\n",
" <span style=\"color: #008000; text-decoration-color: #008000\">'tasmax'</span>: <span style=\"color: #008000; text-decoration-color: #008000\">'camelsgb_73010_1997-08-01_2000-08-31_tasmax.nc'</span>,\n",
" <span style=\"color: #008000; text-decoration-color: #008000\">'Q'</span>: <span style=\"color: #008000; text-decoration-color: #008000\">'camelsgb_73010_1997-08-01_2000-08-31_Q.nc'</span>,\n",
" <span style=\"color: #008000; text-decoration-color: #008000\">'pr'</span>: <span style=\"color: #008000; text-decoration-color: #008000\">'camelsgb_73010_1997-08-01_2000-08-31_pr.nc'</span>,\n",
" <span style=\"color: #008000; text-decoration-color: #008000\">'tasmin'</span>: <span style=\"color: #008000; text-decoration-color: #008000\">'camelsgb_73010_1997-08-01_2000-08-31_tasmin.nc'</span>,\n",
" <span style=\"color: #008000; text-decoration-color: #008000\">'tas'</span>: <span style=\"color: #008000; text-decoration-color: #008000\">'camelsgb_73010_1997-08-01_2000-08-31_tas.nc'</span>\n",
" <span style=\"font-weight: bold\">}</span>\n",
Expand All @@ -247,10 +247,10 @@
" \u001b[33mdirectory\u001b[0m=\u001b[1;35mPosixPath\u001b[0m\u001b[1m(\u001b[0m\u001b[32m'/home/bschilpero/forcing/camelsgb_73010/caravan'\u001b[0m\u001b[1m)\u001b[0m,\n",
" \u001b[33mshape\u001b[0m=\u001b[1;35mPosixPath\u001b[0m\u001b[1m(\u001b[0m\u001b[32m'/home/bschilpero/forcing/camelsgb_73010/caravan/camelsgb_73010.shp'\u001b[0m\u001b[1m)\u001b[0m,\n",
" \u001b[33mfilenames\u001b[0m=\u001b[1m{\u001b[0m\n",
" \u001b[32m'Q'\u001b[0m: \u001b[32m'camelsgb_73010_1997-08-01_2000-08-31_Q.nc'\u001b[0m,\n",
" \u001b[32m'evspsblpot'\u001b[0m: \u001b[32m'camelsgb_73010_1997-08-01_2000-08-31_evspsblpot.nc'\u001b[0m,\n",
" \u001b[32m'pr'\u001b[0m: \u001b[32m'camelsgb_73010_1997-08-01_2000-08-31_pr.nc'\u001b[0m,\n",
" \u001b[32m'tasmax'\u001b[0m: \u001b[32m'camelsgb_73010_1997-08-01_2000-08-31_tasmax.nc'\u001b[0m,\n",
" \u001b[32m'Q'\u001b[0m: \u001b[32m'camelsgb_73010_1997-08-01_2000-08-31_Q.nc'\u001b[0m,\n",
" \u001b[32m'pr'\u001b[0m: \u001b[32m'camelsgb_73010_1997-08-01_2000-08-31_pr.nc'\u001b[0m,\n",
" \u001b[32m'tasmin'\u001b[0m: \u001b[32m'camelsgb_73010_1997-08-01_2000-08-31_tasmin.nc'\u001b[0m,\n",
" \u001b[32m'tas'\u001b[0m: \u001b[32m'camelsgb_73010_1997-08-01_2000-08-31_tas.nc'\u001b[0m\n",
" \u001b[1m}\u001b[0m\n",
Expand All @@ -274,7 +274,7 @@
{
"data": {
"text/plain": [
"[<matplotlib.lines.Line2D at 0x7f2af741d490>]"
"[<matplotlib.lines.Line2D at 0x7f9f297ead80>]"
]
},
"execution_count": 9,
Expand Down Expand Up @@ -314,7 +314,8 @@
"# )\n",
"\n",
"# option two: load data that you or someone else generated previously\n",
"load_location = forcing_path_ERA5 / \"work\" / \"diagnostic\" / \"script\" #this is needed because ERA5 forcing data is stored deep in a sub-directory\n",
"# this is needed because ERA5 forcing data is stored deep in a sub-directory\n",
"load_location = prepared_forcing_path_ERA5_central / \"work\" / \"diagnostic\" / \"script\" \n",
"ERA5_forcing = ewatercycle.forcing.sources[\"LumpedMakkinkForcing\"].load(directory=load_location)"
]
},
Expand Down Expand Up @@ -451,7 +452,7 @@
},
{
"cell_type": "code",
"execution_count": 15,
"execution_count": 14,
"id": "ebbd898f-b3cc-4d03-8050-21067d31c1e8",
"metadata": {
"ExecuteTime": {
Expand All @@ -474,7 +475,7 @@
},
{
"cell_type": "code",
"execution_count": 16,
"execution_count": 15,
"id": "ba14b408-e446-45aa-b406-91dc35f40bc1",
"metadata": {
"ExecuteTime": {
Expand Down Expand Up @@ -503,7 +504,7 @@
},
{
"cell_type": "code",
"execution_count": 17,
"execution_count": 16,
"id": "579fe3d8-0418-4e76-9d66-9c1a938812cc",
"metadata": {
"ExecuteTime": {
Expand All @@ -530,7 +531,7 @@
},
{
"cell_type": "code",
"execution_count": 18,
"execution_count": 17,
"id": "a6fd6178-1059-497a-a91f-dd0fa983df2a",
"metadata": {
"ExecuteTime": {
Expand All @@ -554,7 +555,7 @@
},
{
"cell_type": "code",
"execution_count": 19,
"execution_count": 18,
"id": "ccde9dca-258d-409c-a602-d4abda553b32",
"metadata": {
"ExecuteTime": {
Expand All @@ -568,7 +569,7 @@
},
{
"cell_type": "code",
"execution_count": 20,
"execution_count": 19,
"id": "02879a8d-c55f-4a74-a6cf-8154cffb3d0b",
"metadata": {},
"outputs": [
Expand All @@ -578,7 +579,7 @@
"Text(0, 0.5, 'Discharge (mm/d)')"
]
},
"execution_count": 20,
"execution_count": 19,
"metadata": {},
"output_type": "execute_result"
},
Expand Down

0 comments on commit e5f4232

Please sign in to comment.