Argo Float store#
If you are familiar with Argo float WMO numbers, you may be interested in using directly the Argo float store ArgoFloat.
This store aims to facilitate all Argo netcdf file load/read operations for a specific float. Whatever the Argo netcdf file location, local or remote, you can now delegate to argopy the burden of transfer protocol and GDAC paths handling.
All float store methods and properties are documented in the ArgoFloat API page.
The simplest use case may look like this:
In [1]: from argopy import ArgoFloat
In [2]: WMO = 6903091 # Use any float
In [3]: ds = ArgoFloat(WMO).open_dataset('prof')
This will trigger download and opening of the https://data-argo.ifremer.fr/dac/coriolis/6903091/6903091_prof.nc file. You should notice
that ArgoFloat automatically determined in which DAC folder to find this float and constructed the appropriate path
toward the requested dataset prof.
Float store creation#
If a specific host is not provided, ArgoFloat will fetch float data from the gdac global option (which is set to the Ifremer http server by default), but you can use any valid GDAC host and possibly shortcuts as well:
In [4]: af = ArgoFloat(WMO)
# or:
# af = ArgoFloat(WMO, host='/home/ref-argo/gdac') # Use your local GDAC copy
# af = ArgoFloat(WMO, host='https') # Shortcut for https://data-argo.ifremer.fr
# af = ArgoFloat(WMO, host='ftp') # shortcut for ftp://ftp.ifremer.fr/ifremer/argo
# af = ArgoFloat(WMO, host='s3') # Shortcut for s3://argo-gdac-sandbox/pub
Note that in order to include dataset from the auxiliary GDAC folder, you need to specify it with the aux argument at
the instantiation of the class:
In [5]: af = ArgoFloat(WMO, aux=True)
In [6]: af
Out[6]:
<argofloat.6903091.http.online>
GDAC host: https://data-argo.ifremer.fr
DAC name: coriolis
Network(s): ['BGC']
Deployment date: 2021-03-05 22:55 [1943 days ago]
Float type and manufacturer: PROVOR_III [NKE]
Number of cycles: 214
Dashboard: https://fleetmonitoring.euro-argo.eu/float/6903091
Netcdf dataset available: ['Rtraj', 'Sprof', 'meta', 'meta_aux', 'prof', 'tech', 'tech_aux']
List dataset and loading#
Once you created an ArgoFloat instance, you can list all available dataset with:
In [7]: af.ls_dataset()
Out[7]:
{'Rtraj': 'https://data-argo.ifremer.fr/dac/coriolis/6903091/6903091_Rtraj.nc',
'Sprof': 'https://data-argo.ifremer.fr/dac/coriolis/6903091/6903091_Sprof.nc',
'meta': 'https://data-argo.ifremer.fr/dac/coriolis/6903091/6903091_meta.nc',
'meta_aux': 'https://data-argo.ifremer.fr/aux/coriolis/6903091/6903091_meta_aux.nc',
'prof': 'https://data-argo.ifremer.fr/dac/coriolis/6903091/6903091_prof.nc',
'tech': 'https://data-argo.ifremer.fr/dac/coriolis/6903091/6903091_tech.nc',
'tech_aux': 'https://data-argo.ifremer.fr/aux/coriolis/6903091/6903091_tech_aux.nc'}
Note that dataset from the auxiliary GDAC folder are included in this store, and referenced with the _aux suffix.
So finally, you can open any of these dataset using their keyword:
In [8]: ds = af.open_dataset('meta') # load <WMO>_meta.nc
# or:
# ds = af.open_dataset('prof') # load <WMO>_prof.nc
# ds = af.open_dataset('tech') # load <WMO>_tech.nc
# ds = af.open_dataset('Rtraj') # load <WMO>_Rtraj.nc
Note that you can open a dataset lazily, this is explained in the Laziness with an ArgoFloat or gdacfs documentation page.
Note
The ArgoFloat.open_dataset() also support for direct file loading as a netCDF4 Dataset object. Just use the netCDF4=True option.
In [9]: af.open_dataset('meta', netCDF4=True)
Out[9]:
<class 'netCDF4.Dataset'>
root group (NETCDF3_CLASSIC data model, file format NETCDF3):
title: Argo float metadata file
institution: CORIOLIS
source: Argo float
history: 2026-04-28T09:48:00Z creation; 2026-06-27T15:52:50Z last update (coriolis float real time data processing)
references: http://www.argodatamgt.org/Documentation
user_manual_version: 3.1
Conventions: Argo-3.1 CF-1.6
decoder_version: CODA_085a
id: https://doi.org/10.17882/42182
dimensions(sizes): DATE_TIME(14), STRING4096(4096), STRING1024(1024), STRING256(256), STRING128(128), STRING64(64), STRING32(32), STRING16(16), STRING8(8), STRING4(4), STRING2(2), N_PARAM(43), N_SENSOR(12), N_CONFIG_PARAM(79), N_LAUNCH_CONFIG_PARAM(289), N_MISSIONS(49), N_POSITIONING_SYSTEM(1), N_TRANS_SYSTEM(1)
variables(dimensions): |S1 DATA_TYPE(STRING16), |S1 FORMAT_VERSION(STRING4), |S1 HANDBOOK_VERSION(STRING4), |S1 DATE_CREATION(DATE_TIME), |S1 DATE_UPDATE(DATE_TIME), |S1 PLATFORM_NUMBER(STRING8), |S1 PTT(STRING256), |S1 TRANS_SYSTEM(N_TRANS_SYSTEM, STRING16), |S1 TRANS_SYSTEM_ID(N_TRANS_SYSTEM, STRING32), |S1 TRANS_FREQUENCY(N_TRANS_SYSTEM, STRING16), |S1 POSITIONING_SYSTEM(N_POSITIONING_SYSTEM, STRING8), |S1 PLATFORM_FAMILY(STRING256), |S1 PLATFORM_TYPE(STRING32), |S1 PLATFORM_MAKER(STRING256), |S1 FIRMWARE_VERSION(STRING32), |S1 MANUAL_VERSION(STRING16), |S1 FLOAT_SERIAL_NO(STRING32), |S1 STANDARD_FORMAT_ID(STRING16), |S1 DAC_FORMAT_ID(STRING16), |S1 WMO_INST_TYPE(STRING4), |S1 PROJECT_NAME(STRING64), |S1 PROGRAM_NAME(STRING64), |S1 DATA_CENTRE(STRING2), |S1 PI_NAME(STRING64), |S1 ANOMALY(STRING256), |S1 BATTERY_TYPE(STRING64), |S1 BATTERY_PACKS(STRING64), |S1 CONTROLLER_BOARD_TYPE_PRIMARY(STRING32), |S1 CONTROLLER_BOARD_TYPE_SECONDARY(STRING32), |S1 CONTROLLER_BOARD_SERIAL_NO_PRIMARY(STRING32), |S1 CONTROLLER_BOARD_SERIAL_NO_SECONDARY(STRING32), |S1 SPECIAL_FEATURES(STRING1024), |S1 FLOAT_OWNER(STRING64), |S1 OPERATING_INSTITUTION(STRING64), |S1 CUSTOMISATION(STRING1024), |S1 LAUNCH_DATE(DATE_TIME), float64 LAUNCH_LATITUDE(), float64 LAUNCH_LONGITUDE(), |S1 LAUNCH_QC(), |S1 START_DATE(DATE_TIME), |S1 START_DATE_QC(), |S1 STARTUP_DATE(DATE_TIME), |S1 STARTUP_DATE_QC(), |S1 DEPLOYMENT_PLATFORM(STRING128), |S1 DEPLOYMENT_CRUISE_ID(STRING32), |S1 DEPLOYMENT_REFERENCE_STATION_ID(STRING256), |S1 END_MISSION_DATE(DATE_TIME), |S1 END_MISSION_STATUS(), |S1 LAUNCH_CONFIG_PARAMETER_NAME(N_LAUNCH_CONFIG_PARAM, STRING128), float64 LAUNCH_CONFIG_PARAMETER_VALUE(N_LAUNCH_CONFIG_PARAM), |S1 CONFIG_PARAMETER_NAME(N_CONFIG_PARAM, STRING128), float64 CONFIG_PARAMETER_VALUE(N_MISSIONS, N_CONFIG_PARAM), int32 CONFIG_MISSION_NUMBER(N_MISSIONS), |S1 CONFIG_MISSION_COMMENT(N_MISSIONS, STRING256), |S1 SENSOR(N_SENSOR, STRING32), |S1 SENSOR_MAKER(N_SENSOR, STRING256), |S1 SENSOR_MODEL(N_SENSOR, STRING256), |S1 SENSOR_SERIAL_NO(N_SENSOR, STRING16), |S1 SENSOR_FIRMWARE_VERSION(N_SENSOR, STRING32), |S1 PARAMETER(N_PARAM, STRING64), |S1 PARAMETER_SENSOR(N_PARAM, STRING128), |S1 PARAMETER_UNITS(N_PARAM, STRING32), |S1 PARAMETER_ACCURACY(N_PARAM, STRING32), |S1 PARAMETER_RESOLUTION(N_PARAM, STRING32), |S1 PREDEPLOYMENT_CALIB_EQUATION(N_PARAM, STRING4096), |S1 PREDEPLOYMENT_CALIB_COEFFICIENT(N_PARAM, STRING4096), |S1 PREDEPLOYMENT_CALIB_COMMENT(N_PARAM, STRING4096)
groups:
Integration within argopy#
The ArgoFloat class is further used in argopy in the ArgoIndex iterator.
In [10]: from argopy import ArgoIndex
# Make a search on Argo index of profiles:
In [11]: idx = ArgoIndex().query.lon_lat([-70, -55, 20, 30], nrows=100)
# Then iterate over ArgoFloat matching the results:
In [12]: for a_float in idx.iterfloats():
....: ds = a_float.open_dataset('meta')
....: print(a_float.WMO, ds['LAUNCH_DATE'].data)
....:
1900022 2002-03-03T13:27:00.000000000
1900242 2003-06-03T17:10:00.000000000
1900639 2006-01-28T16:08:00.000000000
1900707 2006-06-02T22:19:00.000000000
Plotting features#
The ArgoFloat class come with a ArgoFloat.plot accessor than can take several methods to quickly visualize data from the float:
Check all the detailed arguments on the API reference ArgoFloat.plot.
from argopy import ArgoFloat
af = ArgoFloat(6903262)
af.plot.trajectory()
# af.plot.trajectory(figsize=(18,18), padding=[1, 5])
from argopy import ArgoFloat
af = ArgoFloat(6903262)
af.plot.map('TEMP', pres=450, cmap='Spectral_r')
from argopy import ArgoFloat
af = ArgoFloat(6903262)
af.plot.map('PROFILE_PSAL_QC')
from argopy import ArgoFloat
af = ArgoFloat(6903262)
af.plot.scatter('TEMP')
Plotting QC will automatically select the appropriate colormap:
af.plot.scatter('PSAL_QC')
Note that by default, variables are loaded from the prof netcdf dataset, but variables from other netcdf dataset can also be plotted if the appropriate dataset is indicated with the ds argument:
from argopy import ArgoFloat
af = ArgoFloat(6903262)
af.plot.scatter('MEASUREMENT_CODE', ds='Rtraj')