What would be an Argo float object in python and the associated methods/attributes ?
Must be possible to point toward all possible GDAC hosts
import tarfile | |
import gzip | |
import xarray as xr | |
import pandas as pd | |
# Work with a BGC-S doi snapshot | |
# Snapshot was downloaded from: https://www.seanoe.org/data/00311/42182/data/110195.tar.gz | |
file = '/Users/gmaze/Downloads/110195.tar.gz' | |
# Read one of the index file as a pandas dataframe: |
#!/usr/bin/env python | |
# coding: utf-8 | |
""" | |
Convert an Argo multi-prof netcdf into zarr | |
""" | |
import xarray as xr | |
import zarr | |
from numcodecs import blosc | |
import argopy |
"Is there already an interface that allows for subsetting of the data or do you imagine that additional tools will be developed on top of the structure as is done with the current https GDAC service? "
In short:
With regard to better understanding how Argo data could be easily subset-ed from the "cloud", this is for me the opportunity to try to summarise some key points: see below and, sorry for some possible shortcomings and verbosity of the email !
In long:
import pandas as pd | |
import urllib | |
import urllib.parse | |
import json | |
class FrenchFleet: | |
""" | |
Examples | |
-------- |
import pandas as pd | |
import copernicusmarine | |
class Armor3d: | |
"""Global Ocean 1/4° Multi Observation Product ARMOR3D | |
Product description: | |
https://data.marine.copernicus.eu/product/MULTIOBS_GLO_PHY_TSUV_3D_MYNRT_015_012 | |
If start_date + n_days <= 2022-12-28: |
#!/bin/sh | |
# | |
# Clone a conda env and add it to jupyter kernel list | |
# | |
# This is basicaly a nice shortcut for: | |
# mamba create --name argopy-pull208 --clone argopy-py38-all-pinned | |
# python -m ipykernel install --user --name=argopy-pull208 | |
# | |
# | |
# Created by G. Maze on 2023-06-21. |
# Must be installed in python env: | |
# - motuclient (via pip, https://github.com/clstoulouse/motu-client-python) | |
# - pydap (via conda, https://github.com/pydap/pydap) | |
import os | |
import requests | |
import xarray as xr | |
# Set-up a request session that will know how to authenticate on the CMEMS server | |
MOTU_USERNAME, MOTU_PASSWORD = ( |
import aiohttp | |
import asyncio | |
from aiohttp.helpers import URL | |
from aiohttp.web import HTTPException | |
import nest_asyncio | |
nest_asyncio.apply() # To be used in jupyter notebooks | |
class OceanOPS_Deployments: | |
""" Use the OceanOPS API for metadata access to retrieve Argo floats deployment information |
import urllib.request | |
import json | |
import numpy as np | |
import pandas as pd | |
def get_float_config(wmo, cyc=None): | |
def id_mission(missionCycles, a_cyc): | |
this_mission = None | |
for im, mission in enumerate(missionCycles): |