An update on “randomizing” surfacing times ahead of the Argo Steering Team meeting.
This post is a simplified update of a previous post, Diversifying Argo Surfacing Times ahead of the AST. We will use the latest Argo index file to check on local surfacing times of Argo Canada floats, broken down by float type. Python code can be expanded to show each step.
import pandas as pd
import matplotlib.pyplot as plt
import seaborn as sns
set(style="ticks", palette="colorblind")
sns.
# load the global index
= pd.read_csv(
global_index "ftp://ftp.ifremer.fr/ifremer/argo/ar_index_global_prof.txt.gz",
="gzip", header=8
compression
)# subset to only the MEDS DAC, profiles with valid dates
= global_index.loc[global_index.file.str.contains('meds')]
meds = meds.loc[meds.date.notna()]
meds
# convert date to pandas timestamps, take only profiles from the last 3 years
"date"] = meds.date.astype(str)\
meds[apply(lambda x: x.replace(".0", ""))\
.apply(pd.Timestamp, tz="utc")
.= meds.loc[meds.date > pd.Timestamp("01-2022", tz="utc")] meds
For each float type, different methods can be used depending on the float mission parameter set to vary the surfacing time of day. Argo Canada currently operates 4 kinds of floats: MetOcean NOVA, NKE ARVOR (SBE and RBR), NKE PROVOR (CTS4 and CTS5 - different operating systems), and NKE deep ARVOR.
import timezonefinder
= timezonefinder.TimezoneFinder()
tf import pytz
= {
profiler_type "865":"NOVA",
"843":"POPS",
"844":"ARVOR_SBE",
"846":"APEX",
"878":"ARVOR_RBR",
"838":"ARVOR_DEEP",
"836":"PROVOR_CTS4",
"834":"PROVOR_CTS5",
}
# exclude invalid locations
= meds.loc[(meds.latitude.notna()) & (meds.longitude.notna())]
meds
# get timezone, local time, and hour at surface for each profile
"timezone"] = [
meds[=lat, lng=lon))\
pytz.timezone(tf.certain_timezone_at(latfor lat, lon in zip(meds.latitude, meds.longitude)
]"local_time"] = [utc_time.tz_convert(tz) for utc_time, tz in zip(meds.date, meds.timezone)]
meds["surface_hour"] = [local_time.hour + 0.5 for local_time in meds.local_time]
meds[
# add a column for WMO number as well as platform name
"WMO"] = [int(s.split("/")[1]) for s in meds.file]
meds["cycle"] = [int(s.split("_")[1].split('.')[0].replace('D','')) for s in meds.file]
meds["platform"] = [profiler_type[f"{p}"] for p in meds.profiler_type]
meds[# create column for profile year
"year"] = [d.year for d in meds.local_time]
meds[= meds.loc[meds.year > 2022] sub
The plot below shows a histogram of Argo Canada profiles in 2023 and 2024.
# create a FacetGrid that will plot by year, 2022, 2023
= sns.displot(
g ="surface_hour", col="year", hue="platform",
sub, x="hist", bins=list(range(24)), multiple="stack",
kind=dict(despine=False, sharey=False)
facet_kws
)300)
g.fig.set_dpi(True)
g.fig.set_constrained_layout( plt.show()
Finally, we use the code below to check if any floats, excluding NOVA floats, have a low standard deviation of surfacing times.
= meds.loc[meds.platform != "NOVA"]
meds for wmo in meds["WMO"].unique():
if meds.loc[meds.WMO == wmo].surface_hour.std() < 4:
print(
== wmo].platform.iloc[0],
meds.loc[meds.WMO
wmo, f"{meds.loc[meds.WMO == wmo].cycle.iloc[-1]:d}\t",
f"{meds.loc[meds.WMO == wmo].surface_hour.std():.1f}",
== wmo].date.iloc[-1],
meds.loc[meds.WMO == wmo].timezone.iloc[0]
meds.loc[meds.WMO )
ARVOR_SBE 4902581 1 1.4 2022-05-19 08:50:00+00:00 Etc/GMT+4
ARVOR_SBE 4902610 2 2.9 2023-10-01 01:27:00+00:00 Etc/GMT+9
ARVOR_DEEP 4902631 5 2.4 2024-06-16 14:30:00+00:00 Etc/GMT+10
ARVOR_DEEP 4902633 41 2.3 2024-06-12 14:26:00+00:00 Etc/GMT+10
ARVOR_DEEP 4902638 14 1.7 2024-06-13 13:52:00+00:00 Etc/GMT+4
ARVOR_DEEP 4902639 14 1.2 2024-06-13 10:36:00+00:00 Etc/GMT+4
PROVOR_CTS5 4902686 32 0.2 2024-06-14 15:44:00+00:00 Etc/GMT+3
PROVOR_CTS5 4902687 28 0.0 2024-06-14 15:36:00+00:00 Etc/GMT+3
PROVOR_CTS5 4902688 23 0.0 2024-06-14 15:40:00+00:00 Etc/GMT+3
The only floats that show up are two ARVOR floats that failed after 1-2 profiles and the deep floats that define cycle time as an integer number of days.
For attribution, please cite this work as
Gordon (2024, March 11). Argo Canada Development Blog: Update: Argo Canada Surfacing Times. Retrieved from https://argocanada.github.io/blog/posts/2024-03-11-update-argo-canada-surfacing-times/
BibTeX citation
@misc{gordon2024update:, author = {Gordon, Christopher}, title = {Argo Canada Development Blog: Update: Argo Canada Surfacing Times}, url = {https://argocanada.github.io/blog/posts/2024-03-11-update-argo-canada-surfacing-times/}, year = {2024} }