Download HYCOM model outputs using MATLAB or Python scripts

MATLAB and Python scripts to batch-download a temporal series of HYCOM model output data at time frequency of 3-hourly or 1-hourly
122 téléchargements
Mise à jour 24 jan. 2023

Afficher la licence

These scripts are intended for use to download a consecutive temporal series of 3-hourly or 1-hourly HYCOM predictions from www.hycom.org. The available variables for 3-hourly HYCOM predictions include the sea surface elevation, and water temperature, salinity, u-velocity, and v-velocity at all model depth layers. The available variables for 1-hourly predictions include the surface diagnostic water_flux_into_ocean, ocean_mixed_layer_thickness, surface_downward_heat_flux_in_air, sea_surface_elevation, steric_ssh, surface_boundary_layer_thickness, u_barotropic_velocity, and v_barotropic_velocity.
The 3-hourly scripts are generalized to extract HYCOM data for any dates and times between 1994 to the present from any selected location in the world oceans at all model depths. The 1-hourly scripts download sur/surface diagnostic data between 2019 to the present for any selected location.
The output data extracted from hycom is saved to your drive in netcdf format for each datetime.
Four versions of the 3-hourly and 1-hourly scripts are available as follows for use with different computing platforms (all four versions are available at https://github.com/gjpelletier/get_hycom):
  • get_hycom_3hr.m and get_hycom_1hr.m are MATLAB scripts
  • get_hycom_3hr.py and get_hycom_1hr.py are Python scripts
  • get_hycom_3hr.ipynb and get_hycom_1hr.ipynb are Jupyter notebooks that are set up as Google Colab notebooks to save hycom outputs in netcdf files directly to your Google drive
  • get_hycom_3hr.ps1 and get_hycom_1hr.ps1 are written in Microsoft Windows Powershell. Powershell is a part of the Windows OS, and it is also available to run in Linux or MacOS. This is a good option for people who do not use Python, Jupyter notebooks, or MATLAB.
INSTRUCTIONS
  1. In the user input section, specify the following: - specify the list of variables to be extracted in any combination of the available variables - specify the west, east, south, and north extent of the bounding box to be extracted - specify the name of the resultDirectory where the hycom data will be saved as output - specify the date_start and number_of_days (or date_end in the MATLAB and Powershell versions) of the period to be extracted, and the corresponding hycom codes for the model glb and expt
  2. Execute whichever version of the script you are using to generate the output nc files
  3. During execution you should see the progress of each 3-hourly or 1-hourly file that is extracted during the period of interest from beginning to end. Each nc file name has the format yyyyMMdd_HH.nc to indicate the datetime stamp in UTC

Citation pour cette source

Gregory Pelletier (2024). Download HYCOM model outputs using MATLAB or Python scripts (https://www.mathworks.com/matlabcentral/fileexchange/123790-download-hycom-model-outputs-using-matlab-or-python-scripts), MATLAB Central File Exchange. Récupéré le .

Compatibilité avec les versions de MATLAB
Créé avec R2022b
Compatible avec toutes les versions
Plateformes compatibles
Windows macOS Linux
Tags Ajouter des tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
Version Publié le Notes de version
1.0.5

improved readability of system feedback

1.0.4

removed clearing of workspace variables to improve utility as a function

1.0.3

update readme

1.0.2

updated readme

1.0.1

updated readme

1.0.0