Skip to content
Snippets Groups Projects
Commit 3f9ca4f7 authored by Lionel GUEZ's avatar Lionel GUEZ
Browse files

Rename `calculate_radii_and_rossby`

Rename function `calculate_radii_and_rossby` to `calculate_radii_rossby`.
parent 9d8cc9fd
Branches
Tags
No related merge requests found
...@@ -30,8 +30,8 @@ import util_eddies ...@@ -30,8 +30,8 @@ import util_eddies
import sys import sys
import bisect import bisect
def calculate_radii_and_rossby(start, end, inc, segment, e_overestim, handlers, def calculate_radii_rossby(start, end, inc, segment, e_overestim, handlers,
array_d_init): array_d_init):
radii = 0 # in m radii = 0 # in m
rossby = 0 rossby = 0
days_modifier = 0 days_modifier = 0
...@@ -171,9 +171,8 @@ for n in g.vertices(): ...@@ -171,9 +171,8 @@ for n in g.vertices():
last_rossby = 0 last_rossby = 0
# First 7 days calculation # First 7 days calculation
first_res = calculate_radii_and_rossby(0, num_of_days_to_avg, first_res = calculate_radii_rossby(0, num_of_days_to_avg, 1, segment,
1, segment, e_overestim, e_overestim, handlers, array_d_init)
handlers, array_d_init)
# average and assign radii # average and assign radii
first_radii = first_res['radii'] / num_of_days_to_avg first_radii = first_res['radii'] / num_of_days_to_avg
...@@ -188,10 +187,10 @@ for n in g.vertices(): ...@@ -188,10 +187,10 @@ for n in g.vertices():
g.vp.first_av_ros[n] = first_rossby g.vp.first_av_ros[n] = first_rossby
# Last 7 days calculation # Last 7 days calculation
last_res = calculate_radii_and_rossby(len(segment) - 1, len(segment) - last_res = calculate_radii_rossby(len(segment) - 1, len(segment) -
(num_of_days_to_avg + 1), -1, (num_of_days_to_avg + 1), -1,
segment, e_overestim, handlers, segment, e_overestim, handlers,
array_d_init) array_d_init)
# Average and assign the last radii # Average and assign the last radii
last_radii = last_res['radii'] / num_of_days_to_avg last_radii = last_res['radii'] / num_of_days_to_avg
...@@ -208,8 +207,8 @@ for n in g.vertices(): ...@@ -208,8 +207,8 @@ for n in g.vertices():
# The number of eddies in a segment is lower than the number # The number of eddies in a segment is lower than the number
# of days over which to average. The values will be the same # of days over which to average. The values will be the same
# except for the positions. # except for the positions.
res = calculate_radii_and_rossby(0, num_of_days, 1, segment, res = calculate_radii_rossby(0, num_of_days, 1, segment, e_overestim,
e_overestim, handlers, array_d_init) handlers, array_d_init)
# grab the days modifier # grab the days modifier
modifier = res['days_modifier'] modifier = res['days_modifier']
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment