Skip to content

Commit

Permalink
update notebooks .md to match notebooks .ipynb
Browse files Browse the repository at this point in the history
  • Loading branch information
vadmbertr committed Jun 25, 2024
1 parent 6f5412f commit 124fe34
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 11 deletions.
6 changes: 3 additions & 3 deletions notebooks/alboran_sea/alboran_sea.md
Original file line number Diff line number Diff line change
Expand Up @@ -102,14 +102,14 @@ lat_u, lon_u, lat_v, lon_v = geometry.compute_uv_grids(lat_t, lon_t)
norm_vorticity_t = kinematics.normalized_relative_vorticity(
uvel, vvel, lat_u, lon_u, lat_v, lon_v, mask, interpolate=True
)
magnitude = ma.masked_array(kinematics.magnitude(uvel, vvel, interpolate=True), mask)
magnitude = ma.masked_array(kinematics.magnitude(uvel, vvel, mask, interpolate=True), mask)

mmin = np.nanmin(magnitude)
mmax = np.nanmax(magnitude)

# interpolate to the center of the cells
uvel_t = operators.interpolation(uvel, axis=1, padding="left")
vvel_t = operators.interpolation(vvel, axis=0, padding="left")
uvel_t = operators.interpolation(uvel, mask, axis=1, padding="left")
vvel_t = operators.interpolation(vvel, mask, axis=0, padding="left")
```


Expand Down
16 changes: 8 additions & 8 deletions notebooks/gaussian_eddy/gaussian_eddy.md
Original file line number Diff line number Diff line change
Expand Up @@ -149,8 +149,8 @@ $f\mathbf{k} \times \mathbf{u_g} = -g \nabla \eta$
```python
u_geos_est, v_geos_est = _geostrophy(ssh, dXY, dXY, coriolis_factor)

u_geos_est_t = interpolation(u_geos_est, axis=1, padding="left")
v_geos_est_t = interpolation(v_geos_est, axis=0, padding="left")
u_geos_est_t = interpolation(u_geos_est, mask, axis=1, padding="left")
v_geos_est_t = interpolation(v_geos_est, mask, axis=0, padding="left")

azim_geos_est = magnitude(u_geos_est_t, v_geos_est_t, interpolate=False)
```
Expand Down Expand Up @@ -285,8 +285,8 @@ u_cyclo_est, v_cyclo_est, _ = _variational(u_geos_u, v_geos_v, dXY, dXY, dXY, dX
coriolis_factor, coriolis_factor, mask,
n_it=20, optim=optim)

u_cyclo_est_t = interpolation(u_cyclo_est, axis=1, padding="left")
v_cyclo_est_t = interpolation(v_cyclo_est, axis=0, padding="left")
u_cyclo_est_t = interpolation(u_cyclo_est, mask, axis=1, padding="left")
v_cyclo_est_t = interpolation(v_cyclo_est, mask, axis=0, padding="left")

azim_cyclo_est = magnitude(u_cyclo_est_t, v_cyclo_est_t, interpolate=False)
```
Expand Down Expand Up @@ -363,8 +363,8 @@ u_cyclo_est, v_cyclo_est, _ = _iterative(u_geos_u, v_geos_v, dXY, dXY, dXY, dXY,
use_res_filter=True, res_filter_size=3,
return_losses=False)

u_cyclo_est_t = interpolation(u_cyclo_est, axis=1, padding="left")
v_cyclo_est_t = interpolation(v_cyclo_est, axis=0, padding="left")
u_cyclo_est_t = interpolation(u_cyclo_est, mask, axis=1, padding="left")
v_cyclo_est_t = interpolation(v_cyclo_est, mask, axis=0, padding="left")

azim_cyclo_est = magnitude(u_cyclo_est_t, v_cyclo_est_t, interpolate=False)
```
Expand Down Expand Up @@ -437,8 +437,8 @@ u_cyclo_est, v_cyclo_est, _ = _iterative(u_geos_u, v_geos_v, dXY, dXY, dXY, dXY,
use_res_filter=False, res_filter_size=1,
return_losses=False)

u_cyclo_est_t = interpolation(u_cyclo_est, axis=1, padding="left")
v_cyclo_est_t = interpolation(v_cyclo_est, axis=0, padding="left")
u_cyclo_est_t = interpolation(u_cyclo_est, mask, axis=1, padding="left")
v_cyclo_est_t = interpolation(v_cyclo_est, mask, axis=0, padding="left")

azim_cyclo_est = magnitude(u_cyclo_est_t, v_cyclo_est_t, interpolate=False)
```
Expand Down

0 comments on commit 124fe34

Please sign in to comment.