!pip3 install s3fs
Collecting s3fs Using cached s3fs-2022.3.0-py3-none-any.whl (26 kB) Collecting aiobotocore~=2.2.0 Using cached aiobotocore-2.2.0.tar.gz (59 kB) Collecting aiohttp<=4 Downloading aiohttp-3.8.1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl (1.2 MB) |████████████████████████████████| 1.2 MB 36.6 MB/s eta 0:00:01 Collecting fsspec==2022.3.0 Using cached fsspec-2022.3.0-py3-none-any.whl (136 kB) Collecting botocore<1.24.22,>=1.24.21 Using cached botocore-1.24.21-py3-none-any.whl (8.6 MB) Collecting wrapt>=1.10.10 Downloading wrapt-1.14.1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl (77 kB) |████████████████████████████████| 77 kB 4.3 MB/s s eta 0:00:01 Collecting aioitertools>=0.5.1 Using cached aioitertools-0.10.0-py3-none-any.whl (23 kB) Collecting frozenlist>=1.1.1 Downloading frozenlist-1.3.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl (156 kB) |████████████████████████████████| 156 kB 110.5 MB/s eta 0:00:01 Collecting yarl<2.0,>=1.0 Downloading yarl-1.7.2-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl (304 kB) |████████████████████████████████| 304 kB 113.6 MB/s eta 0:00:01 Collecting multidict<7.0,>=4.5 Downloading multidict-6.0.2-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (114 kB) |████████████████████████████████| 114 kB 116.5 MB/s eta 0:00:01 Collecting aiosignal>=1.1.2 Using cached aiosignal-1.2.0-py3-none-any.whl (8.2 kB) Requirement already satisfied: attrs>=17.3.0 in /home/ubuntu/miniconda3/lib/python3.9/site-packages (from aiohttp<=4->s3fs) (21.2.0) Collecting async-timeout<5.0,>=4.0.0a3 Using cached async_timeout-4.0.2-py3-none-any.whl (5.8 kB) Collecting charset-normalizer<3.0,>=2.0 Using cached charset_normalizer-2.0.12-py3-none-any.whl (39 kB) Collecting typing_extensions>=4.0 Downloading typing_extensions-4.2.0-py3-none-any.whl (24 kB) Collecting jmespath<2.0.0,>=0.7.1 Downloading jmespath-1.0.0-py3-none-any.whl (23 kB) Requirement already satisfied: python-dateutil<3.0.0,>=2.1 in /home/ubuntu/miniconda3/lib/python3.9/site-packages (from botocore<1.24.22,>=1.24.21->aiobotocore~=2.2.0->s3fs) (2.8.2) Requirement already satisfied: urllib3<1.27,>=1.25.4 in /home/ubuntu/miniconda3/lib/python3.9/site-packages (from botocore<1.24.22,>=1.24.21->aiobotocore~=2.2.0->s3fs) (1.26.6) Requirement already satisfied: six>=1.5 in /home/ubuntu/miniconda3/lib/python3.9/site-packages (from python-dateutil<3.0.0,>=2.1->botocore<1.24.22,>=1.24.21->aiobotocore~=2.2.0->s3fs) (1.16.0) Requirement already satisfied: idna>=2.0 in /home/ubuntu/miniconda3/lib/python3.9/site-packages (from yarl<2.0,>=1.0->aiohttp<=4->s3fs) (2.10) Building wheels for collected packages: aiobotocore Building wheel for aiobotocore (setup.py) ... done Created wheel for aiobotocore: filename=aiobotocore-2.2.0-py3-none-any.whl size=57091 sha256=8eaccd3e9f906e99f3e568ef051963dbfffc7f775f334e717ab9dae47aed3208 Stored in directory: /home/ubuntu/.cache/pip/wheels/03/00/b5/78eda0a8dffd05e210f46e99fd8df6775f76cca046f7a3a5fc Successfully built aiobotocore Installing collected packages: multidict, frozenlist, yarl, typing-extensions, jmespath, charset-normalizer, async-timeout, aiosignal, wrapt, botocore, aioitertools, aiohttp, fsspec, aiobotocore, s3fs Attempting uninstall: typing-extensions Found existing installation: typing-extensions 3.10.0.0 Uninstalling typing-extensions-3.10.0.0: Successfully uninstalled typing-extensions-3.10.0.0 Attempting uninstall: fsspec Found existing installation: fsspec 2021.7.0 Uninstalling fsspec-2021.7.0: Successfully uninstalled fsspec-2021.7.0 Successfully installed aiobotocore-2.2.0 aiohttp-3.8.1 aioitertools-0.10.0 aiosignal-1.2.0 async-timeout-4.0.2 botocore-1.24.21 charset-normalizer-2.0.12 frozenlist-1.3.0 fsspec-2022.3.0 jmespath-1.0.0 multidict-6.0.2 s3fs-2022.3.0 typing-extensions-4.2.0 wrapt-1.14.1 yarl-1.7.2
import xarray as xr
import matplotlib.pyplot as plt
import numpy as np
import pandas as pd
from s3fs import S3FileSystem, S3Map
Warning: ecCodes 2.21.0 or higher is recommended. You are running version 2.16.0
# Access the AODN s3 bucket like this
# print all "virtual folders holding data"
fs = S3FileSystem(anon=True)
aodn = fs.ls('imos-data')
for item in aodn:
print(item)
imos-data/Bureau_of_Meteorology imos-data/CSIRO imos-data/Deakin_University imos-data/Defence_Technology_Agency-New_Zealand imos-data/Department_of_Defence imos-data/Department_of_Environment_and_Science-Queensland imos-data/Department_of_Transport-Western_Australia imos-data/Derwent_Estuary_Program imos-data/Future_Reef_MAP imos-data/IMOS imos-data/Macquarie_University imos-data/NSW-OEH imos-data/TERN imos-data/UNSW imos-data/UON imos-data/UWA imos-data/WAMSI imos-data/error.html imos-data/index.html imos-data/robots.txt
# We are looking for IMOS
print('####')
aodn = fs.ls('imos-data/IMOS')
for item in aodn:
print(item)
#### imos-data/IMOS/AATAMS imos-data/IMOS/ACORN imos-data/IMOS/ACORN_JCU_historical imos-data/IMOS/ANFOG imos-data/IMOS/ANMN imos-data/IMOS/AUV imos-data/IMOS/Argo imos-data/IMOS/BGC_DB imos-data/IMOS/DWM imos-data/IMOS/FAIMMS imos-data/IMOS/NTP imos-data/IMOS/OceanCurrent imos-data/IMOS/SAIMOS imos-data/IMOS/SOOP imos-data/IMOS/SRS imos-data/IMOS/eMII
# And at the end ANFOG
print('####')
aodn = fs.ls('imos-data/IMOS/ANFOG')
for item in aodn:
print(item)
#### imos-data/IMOS/ANFOG/REALTIME imos-data/IMOS/ANFOG/seaglider imos-data/IMOS/ANFOG/slocum_glider
# Slocum is what we want
print('####')
#aodn = fs.ls('imos-data/IMOS/ANFOG/REALTIME/slocum_glider/TwoRocks20210812')
aodn = fs.ls('imos-data/IMOS/ANFOG/slocum_glider')
for item in aodn:
print(item)
#### imos-data/IMOS/ANFOG/slocum_glider/AIMS20151021 imos-data/IMOS/ANFOG/slocum_glider/AIMS20151127 imos-data/IMOS/ANFOG/slocum_glider/BassStrait20160302 imos-data/IMOS/ANFOG/slocum_glider/BassStrait20170321 imos-data/IMOS/ANFOG/slocum_glider/BassStrait20180305 imos-data/IMOS/ANFOG/slocum_glider/BassStrait20180406 imos-data/IMOS/ANFOG/slocum_glider/BassStrait20190123 imos-data/IMOS/ANFOG/slocum_glider/BassStrait20190216 imos-data/IMOS/ANFOG/slocum_glider/BassStrait20200220 imos-data/IMOS/ANFOG/slocum_glider/BassStrait20200706 imos-data/IMOS/ANFOG/slocum_glider/BassStrait20210617 imos-data/IMOS/ANFOG/slocum_glider/BassStrait20210716 imos-data/IMOS/ANFOG/slocum_glider/Bremer20130221 imos-data/IMOS/ANFOG/slocum_glider/Cairns20151130 imos-data/IMOS/ANFOG/slocum_glider/Cairns20160324 imos-data/IMOS/ANFOG/slocum_glider/Cairns20160427 imos-data/IMOS/ANFOG/slocum_glider/Cairns20160726 imos-data/IMOS/ANFOG/slocum_glider/Cairns20180621 imos-data/IMOS/ANFOG/slocum_glider/Cairns20190618 imos-data/IMOS/ANFOG/slocum_glider/Cairns20200514 imos-data/IMOS/ANFOG/slocum_glider/CapricornBunker20200307 imos-data/IMOS/ANFOG/slocum_glider/Challenger20180812 imos-data/IMOS/ANFOG/slocum_glider/CharlotteBay20151124 imos-data/IMOS/ANFOG/slocum_glider/Coffs20111112 imos-data/IMOS/ANFOG/slocum_glider/Cooktown20160217 imos-data/IMOS/ANFOG/slocum_glider/Cooktown20160322 imos-data/IMOS/ANFOG/slocum_glider/Cooktown20160503 imos-data/IMOS/ANFOG/slocum_glider/Cooktown20160727 imos-data/IMOS/ANFOG/slocum_glider/Cooktown20191113 imos-data/IMOS/ANFOG/slocum_glider/CrowdyHead20091002 imos-data/IMOS/ANFOG/slocum_glider/Dampier20190523 imos-data/IMOS/ANFOG/slocum_glider/Forster20170911 imos-data/IMOS/ANFOG/slocum_glider/Forster20180205 imos-data/IMOS/ANFOG/slocum_glider/Forster20180505 imos-data/IMOS/ANFOG/slocum_glider/Forster20180629 imos-data/IMOS/ANFOG/slocum_glider/Forster20181201 imos-data/IMOS/ANFOG/slocum_glider/Forster20190312 imos-data/IMOS/ANFOG/slocum_glider/Forster20190614 imos-data/IMOS/ANFOG/slocum_glider/Forster20190905 imos-data/IMOS/ANFOG/slocum_glider/Forster20191108 imos-data/IMOS/ANFOG/slocum_glider/Forster20200228 imos-data/IMOS/ANFOG/slocum_glider/Forster20200613 imos-data/IMOS/ANFOG/slocum_glider/Forster20200905 imos-data/IMOS/ANFOG/slocum_glider/Forster20201109 imos-data/IMOS/ANFOG/slocum_glider/Forster20210607 imos-data/IMOS/ANFOG/slocum_glider/Forster20220328 imos-data/IMOS/ANFOG/slocum_glider/ForsterA20210329 imos-data/IMOS/ANFOG/slocum_glider/GBR20151103 imos-data/IMOS/ANFOG/slocum_glider/GBR20170310 imos-data/IMOS/ANFOG/slocum_glider/GBR20171106 imos-data/IMOS/ANFOG/slocum_glider/GBR20180222 imos-data/IMOS/ANFOG/slocum_glider/GBR20181018 imos-data/IMOS/ANFOG/slocum_glider/GBR20190222 imos-data/IMOS/ANFOG/slocum_glider/GBR20200123 imos-data/IMOS/ANFOG/slocum_glider/Harrington20090317 imos-data/IMOS/ANFOG/slocum_glider/Heron20121127 imos-data/IMOS/ANFOG/slocum_glider/Heron20130403 imos-data/IMOS/ANFOG/slocum_glider/Heron20130815 imos-data/IMOS/ANFOG/slocum_glider/Heron20131008 imos-data/IMOS/ANFOG/slocum_glider/Heron20131120 imos-data/IMOS/ANFOG/slocum_glider/Heron20140323 imos-data/IMOS/ANFOG/slocum_glider/Heron20140522 imos-data/IMOS/ANFOG/slocum_glider/Heron20140829 imos-data/IMOS/ANFOG/slocum_glider/Heron20141001 imos-data/IMOS/ANFOG/slocum_glider/Heron20141127 imos-data/IMOS/ANFOG/slocum_glider/Heron20150421 imos-data/IMOS/ANFOG/slocum_glider/Heron20150521 imos-data/IMOS/ANFOG/slocum_glider/JervisBay20180503 imos-data/IMOS/ANFOG/slocum_glider/JervisBay20180503a imos-data/IMOS/ANFOG/slocum_glider/JurienBay20210122 imos-data/IMOS/ANFOG/slocum_glider/Kalbarri20091222 imos-data/IMOS/ANFOG/slocum_glider/Kimberley20111121 imos-data/IMOS/ANFOG/slocum_glider/Kimberley20120529 imos-data/IMOS/ANFOG/slocum_glider/Kimberley20120727 imos-data/IMOS/ANFOG/slocum_glider/Kimberley20120914 imos-data/IMOS/ANFOG/slocum_glider/Kimberley20130214 imos-data/IMOS/ANFOG/slocum_glider/Kimberley20130613 imos-data/IMOS/ANFOG/slocum_glider/Kimberley20130925 imos-data/IMOS/ANFOG/slocum_glider/Kimberley20131203 imos-data/IMOS/ANFOG/slocum_glider/Kimberley20140204 imos-data/IMOS/ANFOG/slocum_glider/Kimberley20140408 imos-data/IMOS/ANFOG/slocum_glider/Kimberley20140812 imos-data/IMOS/ANFOG/slocum_glider/Kimberley20140926 imos-data/IMOS/ANFOG/slocum_glider/Kimberley20150312 imos-data/IMOS/ANFOG/slocum_glider/Kimberley20150520 imos-data/IMOS/ANFOG/slocum_glider/LizardSlope20210317 imos-data/IMOS/ANFOG/slocum_glider/MissionBeach0120220126 imos-data/IMOS/ANFOG/slocum_glider/MissionBeach0220220126 imos-data/IMOS/ANFOG/slocum_glider/MissionBeach20211116 imos-data/IMOS/ANFOG/slocum_glider/MissionBeach20220301 imos-data/IMOS/ANFOG/slocum_glider/NSW20100921 imos-data/IMOS/ANFOG/slocum_glider/NSW20101126 imos-data/IMOS/ANFOG/slocum_glider/NSW20110518 imos-data/IMOS/ANFOG/slocum_glider/NSW20110810 imos-data/IMOS/ANFOG/slocum_glider/Ningaloo20170427 imos-data/IMOS/ANFOG/slocum_glider/Onslow20190617 imos-data/IMOS/ANFOG/slocum_glider/Onslow20200205 imos-data/IMOS/ANFOG/slocum_glider/Onslow20200627 imos-data/IMOS/ANFOG/slocum_glider/Onslow20200923 imos-data/IMOS/ANFOG/slocum_glider/Onslow20201117 imos-data/IMOS/ANFOG/slocum_glider/Onslow20210225 imos-data/IMOS/ANFOG/slocum_glider/Onslow20210328 imos-data/IMOS/ANFOG/slocum_glider/Onslow20210709 imos-data/IMOS/ANFOG/slocum_glider/Onslow20210925 imos-data/IMOS/ANFOG/slocum_glider/Onslow20211022 imos-data/IMOS/ANFOG/slocum_glider/Onslow20220203 imos-data/IMOS/ANFOG/slocum_glider/PNG20190422 imos-data/IMOS/ANFOG/slocum_glider/PalmPassage20200227 imos-data/IMOS/ANFOG/slocum_glider/PalmPassage20210125 imos-data/IMOS/ANFOG/slocum_glider/PerthCanyon20121206 imos-data/IMOS/ANFOG/slocum_glider/Pilbara20120211 imos-data/IMOS/ANFOG/slocum_glider/Pilbara20120630 imos-data/IMOS/ANFOG/slocum_glider/Pilbara20120723 imos-data/IMOS/ANFOG/slocum_glider/Pilbara20130212 imos-data/IMOS/ANFOG/slocum_glider/Pilbara20130310 imos-data/IMOS/ANFOG/slocum_glider/Pilbara20130619 imos-data/IMOS/ANFOG/slocum_glider/Pilbara20130709 imos-data/IMOS/ANFOG/slocum_glider/Pilbara20130919 imos-data/IMOS/ANFOG/slocum_glider/Pilbara20140210 imos-data/IMOS/ANFOG/slocum_glider/Pilbara20140523 imos-data/IMOS/ANFOG/slocum_glider/Pilbara20140912 imos-data/IMOS/ANFOG/slocum_glider/Pilbara20141119 imos-data/IMOS/ANFOG/slocum_glider/Pilbara20150311 imos-data/IMOS/ANFOG/slocum_glider/PortStephens20081125 imos-data/IMOS/ANFOG/slocum_glider/PortStephens20091028 imos-data/IMOS/ANFOG/slocum_glider/PortStephens20100309 imos-data/IMOS/ANFOG/slocum_glider/Portland20160128 imos-data/IMOS/ANFOG/slocum_glider/Portland20160229 imos-data/IMOS/ANFOG/slocum_glider/Portland20170208 imos-data/IMOS/ANFOG/slocum_glider/Portland20170422 imos-data/IMOS/ANFOG/slocum_glider/Portland20180209 imos-data/IMOS/ANFOG/slocum_glider/Portland20180313 imos-data/IMOS/ANFOG/slocum_glider/Portland20190218 imos-data/IMOS/ANFOG/slocum_glider/Portland20190923 imos-data/IMOS/ANFOG/slocum_glider/Portland20210621 imos-data/IMOS/ANFOG/slocum_glider/Rottnest20211013 imos-data/IMOS/ANFOG/slocum_glider/RowleyShoals20190425 imos-data/IMOS/ANFOG/slocum_glider/RowleyShoals20200506 imos-data/IMOS/ANFOG/slocum_glider/SpencerGulf20080716 imos-data/IMOS/ANFOG/slocum_glider/SpencerGulf20090115 imos-data/IMOS/ANFOG/slocum_glider/SpencerGulf20090528 imos-data/IMOS/ANFOG/slocum_glider/SpencerGulf20091104 imos-data/IMOS/ANFOG/slocum_glider/SpencerGulf20100210 imos-data/IMOS/ANFOG/slocum_glider/SpencerGulf20110202 imos-data/IMOS/ANFOG/slocum_glider/SpencerGulf20120412 imos-data/IMOS/ANFOG/slocum_glider/SpencerGulf20120912 imos-data/IMOS/ANFOG/slocum_glider/SpencerGulf20121127 imos-data/IMOS/ANFOG/slocum_glider/SpencerGulf20130411 imos-data/IMOS/ANFOG/slocum_glider/SpencerGulf20131031 imos-data/IMOS/ANFOG/slocum_glider/SpencerGulf20140320 imos-data/IMOS/ANFOG/slocum_glider/SpencerGulf20140605 imos-data/IMOS/ANFOG/slocum_glider/SpencerGulf20141010 imos-data/IMOS/ANFOG/slocum_glider/SpencerGulf20141127 imos-data/IMOS/ANFOG/slocum_glider/SpencerGulf20150416 imos-data/IMOS/ANFOG/slocum_glider/SpencerGulf20150528 imos-data/IMOS/ANFOG/slocum_glider/StormBay20110805 imos-data/IMOS/ANFOG/slocum_glider/StormBay20110926 imos-data/IMOS/ANFOG/slocum_glider/StormBay20111104 imos-data/IMOS/ANFOG/slocum_glider/StormBay20120313 imos-data/IMOS/ANFOG/slocum_glider/StormBay20120608 imos-data/IMOS/ANFOG/slocum_glider/StormBay20120823 imos-data/IMOS/ANFOG/slocum_glider/StormBay20120904 imos-data/IMOS/ANFOG/slocum_glider/StormBay20120921 imos-data/IMOS/ANFOG/slocum_glider/StormBay20121019 imos-data/IMOS/ANFOG/slocum_glider/StormBay20121114 imos-data/IMOS/ANFOG/slocum_glider/StormBay20130208 imos-data/IMOS/ANFOG/slocum_glider/StormBay20130226 imos-data/IMOS/ANFOG/slocum_glider/StormBay20130325 imos-data/IMOS/ANFOG/slocum_glider/StormBay20130522 imos-data/IMOS/ANFOG/slocum_glider/StormBay20130620 imos-data/IMOS/ANFOG/slocum_glider/StormBay20140109 imos-data/IMOS/ANFOG/slocum_glider/StormBay20140326 imos-data/IMOS/ANFOG/slocum_glider/StormBay20140613 imos-data/IMOS/ANFOG/slocum_glider/StormBay20140903 imos-data/IMOS/ANFOG/slocum_glider/StormBay20141017 imos-data/IMOS/ANFOG/slocum_glider/StormBay20141120 imos-data/IMOS/ANFOG/slocum_glider/StormBay20150205 imos-data/IMOS/ANFOG/slocum_glider/StormBay20150429 imos-data/IMOS/ANFOG/slocum_glider/StormBay20150616 imos-data/IMOS/ANFOG/slocum_glider/StormBay20150825 imos-data/IMOS/ANFOG/slocum_glider/StormBay20151006 imos-data/IMOS/ANFOG/slocum_glider/StormBay20160415 imos-data/IMOS/ANFOG/slocum_glider/StormBay20160913 imos-data/IMOS/ANFOG/slocum_glider/StormBay20170221 imos-data/IMOS/ANFOG/slocum_glider/StormBay20170310 imos-data/IMOS/ANFOG/slocum_glider/StormBay20170517 imos-data/IMOS/ANFOG/slocum_glider/StormBay20170615 imos-data/IMOS/ANFOG/slocum_glider/StormBay20210415 imos-data/IMOS/ANFOG/slocum_glider/Sydney20220117 imos-data/IMOS/ANFOG/slocum_glider/TasEastCoast20190213 imos-data/IMOS/ANFOG/slocum_glider/TasEastCoast20190316 imos-data/IMOS/ANFOG/slocum_glider/TasEastCoast20210309 imos-data/IMOS/ANFOG/slocum_glider/TasEastCoast20220125 imos-data/IMOS/ANFOG/slocum_glider/TasEastCoast20220311 imos-data/IMOS/ANFOG/slocum_glider/TimorSea20181017a imos-data/IMOS/ANFOG/slocum_glider/TimorSea20181017b imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20080621 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20090120 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20090220 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20090313 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20090327 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20090402 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20090515 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20090603 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20090729 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20090821 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20091208 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20100122 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20100218 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20100507 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20100628 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20100730 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20100805 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20100916 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20101026 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20110310 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20110412 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20110610 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20110818 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20110913 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20111118 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20120223 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20120517 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20120802 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20120824 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20130215 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20130416 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20131017 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20140213 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20140516 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20140808 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20141111 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20150203 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20150305 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20150526 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20151014 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20160408 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20160512 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20160712 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20161105 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20161111 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20170120 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20170512 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20170725 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20171012 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20180503 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20180503a imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20180615 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20180817 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20181030 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20190321 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20190625 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20190913 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20191129 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20200110 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20200625 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20201120 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20210118 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20210719 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20210811 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20210914 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20211126 imos-data/IMOS/ANFOG/slocum_glider/Weipa20211123 imos-data/IMOS/ANFOG/slocum_glider/Yamba20120619 imos-data/IMOS/ANFOG/slocum_glider/Yamba20120714 imos-data/IMOS/ANFOG/slocum_glider/Yamba20120904 imos-data/IMOS/ANFOG/slocum_glider/Yamba20121114 imos-data/IMOS/ANFOG/slocum_glider/Yamba20130531 imos-data/IMOS/ANFOG/slocum_glider/Yamba20130919 imos-data/IMOS/ANFOG/slocum_glider/Yamba20131009 imos-data/IMOS/ANFOG/slocum_glider/Yamba20131120 imos-data/IMOS/ANFOG/slocum_glider/Yamba20140325 imos-data/IMOS/ANFOG/slocum_glider/Yamba20140624 imos-data/IMOS/ANFOG/slocum_glider/Yamba20140915 imos-data/IMOS/ANFOG/slocum_glider/Yamba20150210 imos-data/IMOS/ANFOG/slocum_glider/Yamba20150416 imos-data/IMOS/ANFOG/slocum_glider/Yamba20150601 imos-data/IMOS/ANFOG/slocum_glider/Yamba20151110 imos-data/IMOS/ANFOG/slocum_glider/Yamba20160331 imos-data/IMOS/ANFOG/slocum_glider/Yamba20160415 imos-data/IMOS/ANFOG/slocum_glider/Yamba20160816 imos-data/IMOS/ANFOG/slocum_glider/Yamba20161107 imos-data/IMOS/ANFOG/slocum_glider/Yamba20170327 imos-data/IMOS/ANFOG/slocum_glider/Yamba20170626 imos-data/IMOS/ANFOG/slocum_glider/Yamba20170822 imos-data/IMOS/ANFOG/slocum_glider/Yamba20171114 imos-data/IMOS/ANFOG/slocum_glider/Yamba20181031 imos-data/IMOS/ANFOG/slocum_glider/Yamba20191108 imos-data/IMOS/ANFOG/slocum_glider/Yamba20201030 imos-data/IMOS/ANFOG/slocum_glider/Yamba20211102
# TwoRocks is transect in front of Perth
print('####')
aodn = fs.ls('imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20100628')
for item in aodn:
print(item)
aodn = fs.glob('imos-data/IMOS/ANFOG/slocum_glider/TwoRocks*/*.nc') # Use glob to get all netcdf files
print(aodn), len(aodn)
['imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20080621/IMOS_ANFOG_BCEOPSTUV_20080621T042451Z_SL104_FV01_timeseries_END-20080705T045822Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20090120/IMOS_ANFOG_BCEOPSTUV_20090120T033759Z_SL106_FV01_timeseries_END-20090210T004931Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20090220/IMOS_ANFOG_BCEOPSTUV_20090220T061924Z_SL106_FV01_timeseries_END-20090312T210957Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20090313/IMOS_ANFOG_BCEOPSTUV_20090313T041531Z_SL104_FV01_timeseries_END-20090326T230457Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20090327/IMOS_ANFOG_BCEOPSTUV_20090327T034748Z_SL106_FV01_timeseries_END-20090402T034658Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20090402/IMOS_ANFOG_BCEOPSTUV_20090402T091759Z_SL104_FV01_timeseries_END-20090426T232326Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20090515/IMOS_ANFOG_BCEOPSTUV_20090515T055002Z_SL109_FV01_timeseries_END-20090603T002847Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20090603/IMOS_ANFOG_BCEOPSTUV_20090603T032159Z_SL130_FV01_timeseries_END-20090625T022821Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20090729/IMOS_ANFOG_BCEOPSTUV_20090729T013833Z_SL106_FV01_timeseries_END-20090811T000117Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20090821/IMOS_ANFOG_BCEOPSTUV_20090821T032146Z_SL106_FV01_timeseries_END-20090830T233619Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20091208/IMOS_ANFOG_BCEOPSTUV_20091208T023257Z_SL106_FV01_timeseries_END-20091223T223037Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20100122/IMOS_ANFOG_BCEOPSTUV_20100122T011835Z_SL106_FV01_timeseries_END-20100214T215909Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20100218/IMOS_ANFOG_BCEOPSTUV_20100218T021826Z_SL130_FV01_timeseries_END-20100308T194548Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20100507/IMOS_ANFOG_BCEOPSTUV_20100507T030402Z_SL130_FV01_timeseries_END-20100515T133815Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20100628/IMOS_ANFOG_BCEOPSTUV_20100628T045246Z_SL130_FV01_timeseries_END-20100714T233721Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20100730/IMOS_ANFOG_BCEOPSTUV_20100730T053330Z_SL130_FV01_timeseries_END-20100822T235924Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20100805/IMOS_ANFOG_BCEOPSTUV_20100805T033135Z_SL106_FV01_timeseries_END-20100817T135539Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20100916/IMOS_ANFOG_CEOPSTUV_20100916T092745Z_SL130_FV01_timeseries_END-20100919T105712Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20101026/IMOS_ANFOG_CEOPSTUV_20101026T072027Z_SL130_FV01_timeseries_END-20101111T231407Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20110310/IMOS_ANFOG_BCEOPSTUV_20110310T060200Z_SL209_FV01_timeseries_END-20110324T213520Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20110412/IMOS_ANFOG_BCEOPSTUV_20110412T032339Z_SL130_FV01_timeseries_END-20110501T003005Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20110610/IMOS_ANFOG_BCEPSTUV_20110610T020551Z_SL209_FV01_timeseries_END-20110703T235411Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20110818/IMOS_ANFOG_BCEOPSTUV_20110818T015037Z_SL239_FV01_timeseries_END-20110908T034326Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20110913/IMOS_ANFOG_BCEOPSTUV_20110913T005156Z_SL130_FV01_timeseries_END-20111004T011724Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20111118/IMOS_ANFOG_BCEOPSTUV_20111116T051449Z_SL209_FV01_timeseries_END-20111216T020556Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20120223/IMOS_ANFOG_BCEOPSTUV_20120223T051836Z_SL209_FV01_timeseries_END-20120318T001719Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20120517/IMOS_ANFOG_BCEOPSTUV_20120517T063406Z_SL248_FV01_timeseries_END-20120531T033618Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20120802/IMOS_ANFOG_BCEOPSTUV_20120802T032144Z_SL209_FV01_timeseries_END-20120818T222644Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20120824/IMOS_ANFOG_BCEOPSTUV_20120824T031255Z_SL248_FV01_timeseries_END-20120914T035136Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20130215/IMOS_ANFOG_BCEOPSTUV_20130215T031401Z_SL248_FV01_timeseries_END-20130311T201356Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20130416/IMOS_ANFOG_BCEOPSTUV_20130416T010901Z_SL248_FV01_timeseries_END-20130505T032950Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20131017/IMOS_ANFOG_BCEOPSTUV_20131017T012116Z_SL239_FV01_timeseries_END-20131107T001750Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20140213/IMOS_ANFOG_BCEOPSTUV_20140213T044158Z_SL281_FV01_timeseries_END-20140304T212833Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20140516/IMOS_ANFOG_BCEOPSTUV_20140516T062515Z_SL281_FV01_timeseries_END-20140602T025421Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20140808/IMOS_ANFOG_BCEOPSTUV_20140808T024806Z_SL281_FV01_timeseries_END-20140824T223908Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20141111/IMOS_ANFOG_BCEOPSTUV_20141113T053347Z_SL239_FV01_timeseries_END-20141201T225746Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20150203/IMOS_ANFOG_BCEOPSTUV_20150203T051811Z_SL281_FV01_timeseries_END-20150225T024709Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20150305/IMOS_ANFOG_BCEOPSTUV_20150305T020550Z_SL281_FV01_timeseries_END-20150327T030527Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20150526/IMOS_ANFOG_BCEOPSTUV_20150526T015723Z_SL502_FV01_timeseries_END-20150614T233556Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20151014/IMOS_ANFOG_BCEOPSTUV_20151015T014701Z_SL209_FV01_timeseries_END-20151112T004920Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20160408/IMOS_ANFOG_BCEOPSTUV_20160408T072602Z_SL287_FV01_timeseries_END-20160509T055452Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20160512/IMOS_ANFOG_BCEOPSTUV_20160512T034541Z_SL502_FV01_timeseries_END-20160530T020243Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20160712/IMOS_ANFOG_BCEOPSTUV_20160712T030412Z_SL209_FV01_timeseries_END-20160725T002823Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20161105/IMOS_ANFOG_BCEOPSTUV_20161105T073456Z_SL287_FV01_timeseries_END-20161106T220725Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20161111/IMOS_ANFOG_BCEOPSTUV_20161111T010818Z_SL287_FV01_timeseries_END-20161209T001520Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20170120/IMOS_ANFOG_BCEOPSTUV_20170120T022742Z_SL287_FV01_timeseries_END-20170212T003005Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20170512/IMOS_ANFOG_BCEOPSTUV_20170512T052323Z_SL239_FV01_timeseries_END-20170612T053013Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20170725/IMOS_ANFOG_BCEOPSTUV_20170725T060752Z_SL239_FV01_timeseries_END-20170821T045629Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20171012/IMOS_ANFOG_BCEOPSTUV_20171012T013516Z_SL248_FV01_timeseries_END-20171030T010521Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20180503/IMOS_ANFOG_BCEOPSTUV_20180503T061400Z_SL286_FV01_timeseries_END-20180523T030110Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20180503a/IMOS_ANFOG_BCEOPSTUV_20180503T080042Z_SL210_FV01_timeseries_END-20180505T054942Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20180615/IMOS_ANFOG_BCEOPSTUV_20180608T083723Z_SL210_FV01_timeseries_END-20180711T053604Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20180817/IMOS_ANFOG_BCEOPSTUV_20180817T023958Z_SL248_FV01_timeseries_END-20180912T032502Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20181030/IMOS_ANFOG_BCEOPSTUV_20181030T021121Z_SL248_FV01_timeseries_END-20181126T073524Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20190321/IMOS_ANFOG_BCEOPSTUV_20190321T025617Z_SL210_FV01_timeseries_END-20190407T093336Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20190625/IMOS_ANFOG_BCEOPSTUV_20190625T071857Z_SL248_FV01_timeseries_END-20190723T040704Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20190913/IMOS_ANFOG_BCEOPSTUV_20190913T040605Z_SL248_FV01_timeseries_END-20191008T021018Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20191129/IMOS_ANFOG_BCEOPSTUV_20191129T062113Z_SL248_FV01_timeseries_END-20191216T010823Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20200110/IMOS_ANFOG_BCEOPSTUV_20200110T041738Z_SL209_FV01_timeseries_END-20200206T035846Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20200625/IMOS_ANFOG_BCEOPSTUV_20200625T074407Z_SL248_FV01_timeseries_END-20200721T053759Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20201120/IMOS_ANFOG_BCEOPSTUV_20201120T040120Z_SL209_FV01_timeseries_END-20201214T004019Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20210118/IMOS_ANFOG_BCEOPSTUV_20210118T034439Z_SL248_FV01_timeseries_END-20210202T202731Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20210719/IMOS_ANFOG_BCEOPSTUV_20210719T073121Z_SL248_FV01_timeseries_END-20210805T054450Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20210811/IMOS_ANFOG_BCEOPSTUV_20210812T100016Z_SL209_FV01_timeseries_END-20210816T043002Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20210914/IMOS_ANFOG_BCEOPSTUV_20210914T033022Z_SL286_FV01_timeseries_END-20211006T031737Z.nc', 'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20211126/IMOS_ANFOG_BCEOPSTUV_20211126T003347Z_SL287_FV01_timeseries_END-20211217T001439Z.nc']
(None, 66)
bbox=(115, -32.5, 116, -31.5)
# Function that combines the steps above to return a QC'd variable as a DataArray object subsetted for given area and depth
def get_temp_qc_aodn(filename, bbox):
fileobj = fs.open(filename)
ds = xr.open_dataset(fileobj)
badidx = ds['TEMP_quality_control'].values !=1
temp = ds['TEMP']
temp[badidx] = np.nan
temp = temp.resample(TIME ="10Min").mean()
depth = ds['DEPTH'].resample(TIME = "10Min").mean()
lon = ds['LONGITUDE'].resample(TIME = "10Min").mean()
lat = ds['LATITUDE'].resample(TIME = "10Min").mean()
try:
OK = np.where((lon>bbox[0]) & (lon<bbox[2]) & (lat>bbox[1]) & (lat<bbox[3]) & (depth>=8) & (depth <= 12))
except:
print('No subset')
fileobj.close()
ds.close()
return temp[OK]
aodn[0]
'imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20080621/IMOS_ANFOG_BCEOPSTUV_20080621T042451Z_SL104_FV01_timeseries_END-20080705T045822Z.nc'
fileobj = fs.open(aodn[0])
ds = xr.open_dataset(fileobj)
badidx = ds['TEMP_quality_control'].values !=1
temp = ds['TEMP']
temp[badidx] = np.nan
temp = temp.resample(TIME ="10Min").mean()
depth = ds['DEPTH'].resample(TIME = "10Min").mean()
lon = ds['LONGITUDE'].resample(TIME = "10Min").mean()
lat = ds['LATITUDE'].resample(TIME = "10Min").mean()
OK = np.where((lon>bbox[0]) & (lon<bbox[2])
& (lat>bbox[1]) & (lat<bbox[3]) & (depth>=8) & (depth <= 12))
temp[OK]
<xarray.DataArray 'TEMP' (TIME: 40)> array([19.68346882, 19.67666758, 19.66706525, 19.64053368, 19.63771601, 19.63306948, 19.64587449, 19.66194798, 19.66835551, 19.67194548, 19.66925176, 19.66674433, 19.66716736, 19.66012758, 19.64769519, 19.62226096, 19.62539987, 19.62394012, 19.61569383, 19.82404496, 19.88789194, 19.91448996, 20.01473199, 20.164518 , 20.33005002, 21.11841261, 21.10518283, 20.78183905, 20.83912153, 21.41862931, 20.05078145, 20.19479749, 21.24599676, 21.14558383, 21.16107756, 21.1997161 , 21.29360536, 21.38844704, 21.436588 , 21.4339921 ]) Coordinates: * TIME (TIME) datetime64[ns] 2008-06-21T04:50:00 ... 2008-07-04T05:10:00
test = get_temp_qc_aodn(aodn[0], bbox)
test
<xarray.DataArray 'TEMP' (TIME: 40)> array([19.68346882, 19.67666758, 19.66706525, 19.64053368, 19.63771601, 19.63306948, 19.64587449, 19.66194798, 19.66835551, 19.67194548, 19.66925176, 19.66674433, 19.66716736, 19.66012758, 19.64769519, 19.62226096, 19.62539987, 19.62394012, 19.61569383, 19.82404496, 19.88789194, 19.91448996, 20.01473199, 20.164518 , 20.33005002, 21.11841261, 21.10518283, 20.78183905, 20.83912153, 21.41862931, 20.05078145, 20.19479749, 21.24599676, 21.14558383, 21.16107756, 21.1997161 , 21.29360536, 21.38844704, 21.436588 , 21.4339921 ]) Coordinates: * TIME (TIME) datetime64[ns] 2008-06-21T04:50:00 ... 2008-07-04T05:10:00
alltemp = None
cnt = 1
for tempfile in aodn[0:-1]:
print("%d/%d %s" %(cnt,len(aodn),tempfile))
cnt = cnt + 1
if alltemp is None:
temp = get_temp_qc_aodn(tempfile, bbox)
alltemp = temp
else:
temp = get_temp_qc_aodn(tempfile, bbox)
# Print out the time information for each file (this is helpful to choose the time vector above...)
print(temp.TIME.values[0], temp.TIME.values[-1], temp.TIME.shape)
print(alltemp.TIME.values[0], alltemp.TIME.values[-1], alltemp.TIME.shape)
dt = temp.TIME[1] - temp.TIME[0]
print(dt.values.astype('timedelta64[s]'))
# Interpolation step
#temp_i = temp.interp(TIME=time)
# Check for too many missing values...
#if np.all(np.isnan(temp_i)):
# print('Skipping file... all bad data!!')
# continue
# Stack the vector onto the main array
alltemp = xr.concat([alltemp,temp], dim='TIME', join='exact')
1/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20080621/IMOS_ANFOG_BCEOPSTUV_20080621T042451Z_SL104_FV01_timeseries_END-20080705T045822Z.nc 2/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20090120/IMOS_ANFOG_BCEOPSTUV_20090120T033759Z_SL106_FV01_timeseries_END-20090210T004931Z.nc 2009-01-20T08:00:00.000000000 2009-02-09T20:10:00.000000000 (27,) 2008-06-21T04:50:00.000000000 2008-07-04T05:10:00.000000000 (40,) 6000 seconds 3/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20090220/IMOS_ANFOG_BCEOPSTUV_20090220T061924Z_SL106_FV01_timeseries_END-20090312T210957Z.nc 2009-02-20T22:20:00.000000000 2009-03-12T19:20:00.000000000 (18,) 2008-06-21T04:50:00.000000000 2009-02-09T20:10:00.000000000 (67,) 50400 seconds 4/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20090313/IMOS_ANFOG_BCEOPSTUV_20090313T041531Z_SL104_FV01_timeseries_END-20090326T230457Z.nc 2009-03-13T06:50:00.000000000 2009-03-26T06:00:00.000000000 (28,) 2008-06-21T04:50:00.000000000 2009-03-12T19:20:00.000000000 (85,) 14400 seconds 5/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20090327/IMOS_ANFOG_BCEOPSTUV_20090327T034748Z_SL106_FV01_timeseries_END-20090402T034658Z.nc 2009-03-28T05:50:00.000000000 2009-03-30T01:50:00.000000000 (8,) 2008-06-21T04:50:00.000000000 2009-03-26T06:00:00.000000000 (113,) 14400 seconds 6/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20090402/IMOS_ANFOG_BCEOPSTUV_20090402T091759Z_SL104_FV01_timeseries_END-20090426T232326Z.nc 2009-04-02T11:30:00.000000000 2009-04-26T14:20:00.000000000 (50,) 2008-06-21T04:50:00.000000000 2009-03-30T01:50:00.000000000 (121,) 10200 seconds 7/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20090515/IMOS_ANFOG_BCEOPSTUV_20090515T055002Z_SL109_FV01_timeseries_END-20090603T002847Z.nc 2009-05-15T10:00:00.000000000 2009-06-02T21:30:00.000000000 (50,) 2008-06-21T04:50:00.000000000 2009-04-26T14:20:00.000000000 (171,) 57600 seconds 8/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20090603/IMOS_ANFOG_BCEOPSTUV_20090603T032159Z_SL130_FV01_timeseries_END-20090625T022821Z.nc 2009-06-03T03:20:00.000000000 2009-06-25T01:30:00.000000000 (45,) 2008-06-21T04:50:00.000000000 2009-06-02T21:30:00.000000000 (221,) 36600 seconds 9/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20090729/IMOS_ANFOG_BCEOPSTUV_20090729T013833Z_SL106_FV01_timeseries_END-20090811T000117Z.nc 2009-07-29T09:50:00.000000000 2009-08-10T23:30:00.000000000 (15,) 2008-06-21T04:50:00.000000000 2009-06-25T01:30:00.000000000 (266,) 28200 seconds 10/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20090821/IMOS_ANFOG_BCEOPSTUV_20090821T032146Z_SL106_FV01_timeseries_END-20090830T233619Z.nc 2009-08-21T05:10:00.000000000 2009-08-30T19:40:00.000000000 (17,) 2008-06-21T04:50:00.000000000 2009-08-10T23:30:00.000000000 (281,) 7800 seconds 11/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20091208/IMOS_ANFOG_BCEOPSTUV_20091208T023257Z_SL106_FV01_timeseries_END-20091223T223037Z.nc 2009-12-08T03:10:00.000000000 2009-12-23T21:30:00.000000000 (26,) 2008-06-21T04:50:00.000000000 2009-08-30T19:40:00.000000000 (298,) 2400 seconds 12/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20100122/IMOS_ANFOG_BCEOPSTUV_20100122T011835Z_SL106_FV01_timeseries_END-20100214T215909Z.nc 2010-01-22T01:20:00.000000000 2010-02-14T14:00:00.000000000 (81,) 2008-06-21T04:50:00.000000000 2009-12-23T21:30:00.000000000 (324,) 600 seconds 13/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20100218/IMOS_ANFOG_BCEOPSTUV_20100218T021826Z_SL130_FV01_timeseries_END-20100308T194548Z.nc 2010-02-18T11:10:00.000000000 2010-03-03T21:10:00.000000000 (25,) 2008-06-21T04:50:00.000000000 2010-02-14T14:00:00.000000000 (405,) 72000 seconds 14/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20100507/IMOS_ANFOG_BCEOPSTUV_20100507T030402Z_SL130_FV01_timeseries_END-20100515T133815Z.nc 2010-05-07T03:10:00.000000000 2010-05-14T21:30:00.000000000 (17,) 2008-06-21T04:50:00.000000000 2010-03-03T21:10:00.000000000 (430,) 6600 seconds 15/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20100628/IMOS_ANFOG_BCEOPSTUV_20100628T045246Z_SL130_FV01_timeseries_END-20100714T233721Z.nc 2010-06-28T04:50:00.000000000 2010-07-14T21:40:00.000000000 (46,) 2008-06-21T04:50:00.000000000 2010-05-14T21:30:00.000000000 (447,) 7800 seconds 16/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20100730/IMOS_ANFOG_BCEOPSTUV_20100730T053330Z_SL130_FV01_timeseries_END-20100822T235924Z.nc 2010-07-30T07:30:00.000000000 2010-08-22T23:50:00.000000000 (76,) 2008-06-21T04:50:00.000000000 2010-07-14T21:40:00.000000000 (493,) 7200 seconds 17/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20100805/IMOS_ANFOG_BCEOPSTUV_20100805T033135Z_SL106_FV01_timeseries_END-20100817T135539Z.nc 2010-08-05T05:40:00.000000000 2010-08-17T05:40:00.000000000 (26,) 2008-06-21T04:50:00.000000000 2010-08-22T23:50:00.000000000 (569,) 6600 seconds 18/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20100916/IMOS_ANFOG_CEOPSTUV_20100916T092745Z_SL130_FV01_timeseries_END-20100919T105712Z.nc 2010-09-17T05:40:00.000000000 2010-09-19T06:00:00.000000000 (9,) 2008-06-21T04:50:00.000000000 2010-08-17T05:40:00.000000000 (595,) 14400 seconds 19/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20101026/IMOS_ANFOG_CEOPSTUV_20101026T072027Z_SL130_FV01_timeseries_END-20101111T231407Z.nc 2010-10-26T09:20:00.000000000 2010-11-11T23:00:00.000000000 (51,) 2008-06-21T04:50:00.000000000 2010-09-19T06:00:00.000000000 (604,) 14400 seconds 20/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20110310/IMOS_ANFOG_BCEOPSTUV_20110310T060200Z_SL209_FV01_timeseries_END-20110324T213520Z.nc 2011-03-10T06:50:00.000000000 2011-03-24T10:30:00.000000000 (29,) 2008-06-21T04:50:00.000000000 2010-11-11T23:00:00.000000000 (655,) 3600 seconds 21/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20110412/IMOS_ANFOG_BCEOPSTUV_20110412T032339Z_SL130_FV01_timeseries_END-20110501T003005Z.nc 2011-04-12T05:30:00.000000000 2011-04-30T21:30:00.000000000 (75,) 2008-06-21T04:50:00.000000000 2011-03-24T10:30:00.000000000 (684,) 6600 seconds 22/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20110610/IMOS_ANFOG_BCEPSTUV_20110610T020551Z_SL209_FV01_timeseries_END-20110703T235411Z.nc 2011-06-10T05:00:00.000000000 2011-07-02T17:00:00.000000000 (30,) 2008-06-21T04:50:00.000000000 2011-04-30T21:30:00.000000000 (759,) 37200 seconds 23/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20110818/IMOS_ANFOG_BCEOPSTUV_20110818T015037Z_SL239_FV01_timeseries_END-20110908T034326Z.nc 2011-08-18T05:50:00.000000000 2011-08-24T09:10:00.000000000 (22,) 2008-06-21T04:50:00.000000000 2011-07-02T17:00:00.000000000 (789,) 33000 seconds 24/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20110913/IMOS_ANFOG_BCEOPSTUV_20110913T005156Z_SL130_FV01_timeseries_END-20111004T011724Z.nc 2011-09-13T02:50:00.000000000 2011-10-03T19:50:00.000000000 (83,) 2008-06-21T04:50:00.000000000 2011-08-24T09:10:00.000000000 (811,) 10800 seconds 25/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20111118/IMOS_ANFOG_BCEOPSTUV_20111116T051449Z_SL209_FV01_timeseries_END-20111216T020556Z.nc 2011-11-18T03:30:00.000000000 2011-12-15T17:50:00.000000000 (56,) 2008-06-21T04:50:00.000000000 2011-10-03T19:50:00.000000000 (894,) 5400 seconds 26/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20120223/IMOS_ANFOG_BCEOPSTUV_20120223T051836Z_SL209_FV01_timeseries_END-20120318T001719Z.nc 2012-02-23T06:10:00.000000000 2012-03-18T00:10:00.000000000 (71,) 2008-06-21T04:50:00.000000000 2011-12-15T17:50:00.000000000 (950,) 600 seconds 27/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20120517/IMOS_ANFOG_BCEOPSTUV_20120517T063406Z_SL248_FV01_timeseries_END-20120531T033618Z.nc 2012-05-19T00:50:00.000000000 2012-05-30T19:40:00.000000000 (55,) 2008-06-21T04:50:00.000000000 2012-03-18T00:10:00.000000000 (1021,) 7200 seconds 28/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20120802/IMOS_ANFOG_BCEOPSTUV_20120802T032144Z_SL209_FV01_timeseries_END-20120818T222644Z.nc 2012-08-02T07:30:00.000000000 2012-08-15T14:00:00.000000000 (45,) 2008-06-21T04:50:00.000000000 2012-05-30T19:40:00.000000000 (1076,) 7200 seconds 29/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20120824/IMOS_ANFOG_BCEOPSTUV_20120824T031255Z_SL248_FV01_timeseries_END-20120914T035136Z.nc 2012-08-24T05:10:00.000000000 2012-09-14T03:40:00.000000000 (66,) 2008-06-21T04:50:00.000000000 2012-08-15T14:00:00.000000000 (1121,) 87600 seconds 30/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20130215/IMOS_ANFOG_BCEOPSTUV_20130215T031401Z_SL248_FV01_timeseries_END-20130311T201356Z.nc 2013-02-15T05:10:00.000000000 2013-03-11T18:10:00.000000000 (88,) 2008-06-21T04:50:00.000000000 2012-09-14T03:40:00.000000000 (1187,) 21600 seconds 31/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20130416/IMOS_ANFOG_BCEOPSTUV_20130416T010901Z_SL248_FV01_timeseries_END-20130505T032950Z.nc 2013-04-16T02:10:00.000000000 2013-05-05T02:00:00.000000000 (73,) 2008-06-21T04:50:00.000000000 2013-03-11T18:10:00.000000000 (1275,) 7800 seconds 32/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20131017/IMOS_ANFOG_BCEOPSTUV_20131017T012116Z_SL239_FV01_timeseries_END-20131107T001750Z.nc 2013-10-17T03:20:00.000000000 2013-11-07T00:10:00.000000000 (84,) 2008-06-21T04:50:00.000000000 2013-05-05T02:00:00.000000000 (1348,) 15000 seconds 33/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20140213/IMOS_ANFOG_BCEOPSTUV_20140213T044158Z_SL281_FV01_timeseries_END-20140304T212833Z.nc 2014-02-13T05:40:00.000000000 2014-03-04T13:20:00.000000000 (66,) 2008-06-21T04:50:00.000000000 2013-11-07T00:10:00.000000000 (1432,) 4200 seconds 34/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20140516/IMOS_ANFOG_BCEOPSTUV_20140516T062515Z_SL281_FV01_timeseries_END-20140602T025421Z.nc 2014-05-17T03:30:00.000000000 2014-06-02T02:40:00.000000000 (52,) 2008-06-21T04:50:00.000000000 2014-03-04T13:20:00.000000000 (1498,) 22200 seconds 35/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20140808/IMOS_ANFOG_BCEOPSTUV_20140808T024806Z_SL281_FV01_timeseries_END-20140824T223908Z.nc 2014-08-08T13:00:00.000000000 2014-08-24T20:40:00.000000000 (39,) 2008-06-21T04:50:00.000000000 2014-06-02T02:40:00.000000000 (1550,) 14400 seconds 36/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20141111/IMOS_ANFOG_BCEOPSTUV_20141113T053347Z_SL239_FV01_timeseries_END-20141201T225746Z.nc 2014-11-13T07:30:00.000000000 2014-12-01T22:30:00.000000000 (65,) 2008-06-21T04:50:00.000000000 2014-08-24T20:40:00.000000000 (1589,) 600 seconds 37/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20150203/IMOS_ANFOG_BCEOPSTUV_20150203T051811Z_SL281_FV01_timeseries_END-20150225T024709Z.nc 2015-02-03T06:50:00.000000000 2015-02-25T01:00:00.000000000 (102,) 2008-06-21T04:50:00.000000000 2014-12-01T22:30:00.000000000 (1654,) 78000 seconds 38/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20150305/IMOS_ANFOG_BCEOPSTUV_20150305T020550Z_SL281_FV01_timeseries_END-20150327T030527Z.nc 2015-03-05T03:00:00.000000000 2015-03-26T10:10:00.000000000 (74,) 2008-06-21T04:50:00.000000000 2015-02-25T01:00:00.000000000 (1756,) 80400 seconds 39/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20150526/IMOS_ANFOG_BCEOPSTUV_20150526T015723Z_SL502_FV01_timeseries_END-20150614T233556Z.nc 2015-05-26T01:50:00.000000000 2015-06-14T21:40:00.000000000 (94,) 2008-06-21T04:50:00.000000000 2015-03-26T10:10:00.000000000 (1830,) 15600 seconds 40/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20151014/IMOS_ANFOG_BCEOPSTUV_20151015T014701Z_SL209_FV01_timeseries_END-20151112T004920Z.nc 2015-10-16T13:00:00.000000000 2015-11-12T00:10:00.000000000 (107,) 2008-06-21T04:50:00.000000000 2015-06-14T21:40:00.000000000 (1924,) 7200 seconds 41/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20160408/IMOS_ANFOG_BCEOPSTUV_20160408T072602Z_SL287_FV01_timeseries_END-20160509T055452Z.nc 2016-04-08T10:00:00.000000000 2016-04-28T18:40:00.000000000 (49,) 2008-06-21T04:50:00.000000000 2015-11-12T00:10:00.000000000 (2031,) 600 seconds 42/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20160512/IMOS_ANFOG_BCEOPSTUV_20160512T034541Z_SL502_FV01_timeseries_END-20160530T020243Z.nc 2016-05-12T04:40:00.000000000 2016-05-30T01:50:00.000000000 (87,) 2008-06-21T04:50:00.000000000 2016-04-28T18:40:00.000000000 (2080,) 3600 seconds 43/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20160712/IMOS_ANFOG_BCEOPSTUV_20160712T030412Z_SL209_FV01_timeseries_END-20160725T002823Z.nc 2016-07-12T04:00:00.000000000 2016-07-24T22:20:00.000000000 (81,) 2008-06-21T04:50:00.000000000 2016-05-30T01:50:00.000000000 (2167,) 7200 seconds 44/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20161105/IMOS_ANFOG_BCEOPSTUV_20161105T073456Z_SL287_FV01_timeseries_END-20161106T220725Z.nc 2016-11-05T08:30:00.000000000 2016-11-06T22:00:00.000000000 (16,) 2008-06-21T04:50:00.000000000 2016-07-24T22:20:00.000000000 (2248,) 7200 seconds 45/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20161111/IMOS_ANFOG_BCEOPSTUV_20161111T010818Z_SL287_FV01_timeseries_END-20161209T001520Z.nc 2016-11-11T05:20:00.000000000 2016-12-08T18:10:00.000000000 (116,) 2008-06-21T04:50:00.000000000 2016-11-06T22:00:00.000000000 (2264,) 7200 seconds 46/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20170120/IMOS_ANFOG_BCEOPSTUV_20170120T022742Z_SL287_FV01_timeseries_END-20170212T003005Z.nc 2017-01-20T04:20:00.000000000 2017-01-26T03:40:00.000000000 (35,) 2008-06-21T04:50:00.000000000 2016-12-08T18:10:00.000000000 (2380,) 8400 seconds 47/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20170512/IMOS_ANFOG_BCEOPSTUV_20170512T052323Z_SL239_FV01_timeseries_END-20170612T053013Z.nc 2017-05-12T05:40:00.000000000 2017-06-12T04:30:00.000000000 (58,) 2008-06-21T04:50:00.000000000 2017-01-26T03:40:00.000000000 (2415,) 7200 seconds 48/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20170725/IMOS_ANFOG_BCEOPSTUV_20170725T060752Z_SL239_FV01_timeseries_END-20170821T045629Z.nc 2017-07-25T07:00:00.000000000 2017-08-21T04:10:00.000000000 (126,) 2008-06-21T04:50:00.000000000 2017-06-12T04:30:00.000000000 (2473,) 9000 seconds 49/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20171012/IMOS_ANFOG_BCEOPSTUV_20171012T013516Z_SL248_FV01_timeseries_END-20171030T010521Z.nc 2017-10-12T02:30:00.000000000 2017-10-30T00:40:00.000000000 (92,) 2008-06-21T04:50:00.000000000 2017-08-21T04:10:00.000000000 (2599,) 3600 seconds 50/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20180503/IMOS_ANFOG_BCEOPSTUV_20180503T061400Z_SL286_FV01_timeseries_END-20180523T030110Z.nc 2018-05-03T07:10:00.000000000 2018-05-22T16:30:00.000000000 (77,) 2008-06-21T04:50:00.000000000 2017-10-30T00:40:00.000000000 (2691,) 4200 seconds 51/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20180503a/IMOS_ANFOG_BCEOPSTUV_20180503T080042Z_SL210_FV01_timeseries_END-20180505T054942Z.nc 2018-05-03T11:10:00.000000000 2018-05-04T17:00:00.000000000 (7,) 2008-06-21T04:50:00.000000000 2018-05-22T16:30:00.000000000 (2768,) 13800 seconds 52/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20180615/IMOS_ANFOG_BCEOPSTUV_20180608T083723Z_SL210_FV01_timeseries_END-20180711T053604Z.nc 2018-06-15T08:40:00.000000000 2018-07-11T01:40:00.000000000 (103,) 2008-06-21T04:50:00.000000000 2018-05-04T17:00:00.000000000 (2775,) 10800 seconds 53/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20180817/IMOS_ANFOG_BCEOPSTUV_20180817T023958Z_SL248_FV01_timeseries_END-20180912T032502Z.nc 2018-08-17T04:50:00.000000000 2018-09-12T03:10:00.000000000 (71,) 2008-06-21T04:50:00.000000000 2018-07-11T01:40:00.000000000 (2878,) 3600 seconds 54/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20181030/IMOS_ANFOG_BCEOPSTUV_20181030T021121Z_SL248_FV01_timeseries_END-20181126T073524Z.nc 2018-10-30T02:10:00.000000000 2018-11-26T01:20:00.000000000 (53,) 2008-06-21T04:50:00.000000000 2018-09-12T03:10:00.000000000 (2949,) 3600 seconds 55/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20190321/IMOS_ANFOG_BCEOPSTUV_20190321T025617Z_SL210_FV01_timeseries_END-20190407T093336Z.nc 2019-03-21T04:40:00.000000000 2019-04-07T00:30:00.000000000 (82,) 2008-06-21T04:50:00.000000000 2018-11-26T01:20:00.000000000 (3002,) 4200 seconds 56/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20190625/IMOS_ANFOG_BCEOPSTUV_20190625T071857Z_SL248_FV01_timeseries_END-20190723T040704Z.nc 2019-06-25T10:30:00.000000000 2019-07-23T02:50:00.000000000 (93,) 2008-06-21T04:50:00.000000000 2019-04-07T00:30:00.000000000 (3084,) 3600 seconds 57/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20190913/IMOS_ANFOG_BCEOPSTUV_20190913T040605Z_SL248_FV01_timeseries_END-20191008T021018Z.nc 2019-09-13T05:00:00.000000000 2019-10-08T02:00:00.000000000 (82,) 2008-06-21T04:50:00.000000000 2019-07-23T02:50:00.000000000 (3177,) 7200 seconds 58/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20191129/IMOS_ANFOG_BCEOPSTUV_20191129T062113Z_SL248_FV01_timeseries_END-20191216T010823Z.nc 2019-11-29T06:20:00.000000000 2019-12-16T00:40:00.000000000 (106,) 2008-06-21T04:50:00.000000000 2019-10-08T02:00:00.000000000 (3259,) 7800 seconds 59/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20200110/IMOS_ANFOG_BCEOPSTUV_20200110T041738Z_SL209_FV01_timeseries_END-20200206T035846Z.nc 2020-01-10T05:10:00.000000000 2020-02-06T02:20:00.000000000 (77,) 2008-06-21T04:50:00.000000000 2019-12-16T00:40:00.000000000 (3365,) 1800 seconds 60/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20200625/IMOS_ANFOG_BCEOPSTUV_20200625T074407Z_SL248_FV01_timeseries_END-20200721T053759Z.nc 2020-06-25T17:40:00.000000000 2020-07-21T03:10:00.000000000 (66,) 2008-06-21T04:50:00.000000000 2020-02-06T02:20:00.000000000 (3442,) 14400 seconds 61/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20201120/IMOS_ANFOG_BCEOPSTUV_20201120T040120Z_SL209_FV01_timeseries_END-20201214T004019Z.nc 2020-11-20T05:10:00.000000000 2020-12-14T00:30:00.000000000 (79,) 2008-06-21T04:50:00.000000000 2020-07-21T03:10:00.000000000 (3508,) 6600 seconds 62/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20210118/IMOS_ANFOG_BCEOPSTUV_20210118T034439Z_SL248_FV01_timeseries_END-20210202T202731Z.nc 2021-01-18T04:40:00.000000000 2021-01-27T08:10:00.000000000 (50,) 2008-06-21T04:50:00.000000000 2020-12-14T00:30:00.000000000 (3587,) 3600 seconds 63/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20210719/IMOS_ANFOG_BCEOPSTUV_20210719T073121Z_SL248_FV01_timeseries_END-20210805T054450Z.nc 2021-07-19T08:50:00.000000000 2021-08-05T05:30:00.000000000 (1370,) 2008-06-21T04:50:00.000000000 2021-01-27T08:10:00.000000000 (3637,) 2400 seconds 64/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20210811/IMOS_ANFOG_BCEOPSTUV_20210812T100016Z_SL209_FV01_timeseries_END-20210816T043002Z.nc 2021-08-12T12:10:00.000000000 2021-08-15T21:00:00.000000000 (28,) 2008-06-21T04:50:00.000000000 2021-08-05T05:30:00.000000000 (5007,) 3600 seconds 65/66 imos-data/IMOS/ANFOG/slocum_glider/TwoRocks20210914/IMOS_ANFOG_BCEOPSTUV_20210914T033022Z_SL286_FV01_timeseries_END-20211006T031737Z.nc 2021-09-14T05:40:00.000000000 2021-10-06T02:10:00.000000000 (68,) 2008-06-21T04:50:00.000000000 2021-08-15T21:00:00.000000000 (5035,) 3600 seconds
alltemp
<xarray.DataArray 'TEMP' (TIME: 5103)> array([19.68346882, 19.67666758, 19.66706525, ..., 18.61328935, 18.56409847, 18.69615674]) Coordinates: * TIME (TIME) datetime64[ns] 2008-06-21T04:50:00 ... 2021-10-06T02:10:00
array([19.68346882, 19.67666758, 19.66706525, ..., 18.61328935, 18.56409847, 18.69615674])
array(['2008-06-21T04:50:00.000000000', '2008-06-21T05:00:00.000000000', '2008-06-21T05:10:00.000000000', ..., '2021-10-05T21:10:00.000000000', '2021-10-05T23:20:00.000000000', '2021-10-06T02:10:00.000000000'], dtype='datetime64[ns]')
alltemp.to_netcdf('Paul_glider.nc')
# if you have saved file just load it into Xarray
alltemp = xr.open_dataset('Paul_glider.nc')
alltemp
<xarray.Dataset> Dimensions: (TIME: 5103) Coordinates: * TIME (TIME) datetime64[ns] 2008-06-21T04:50:00 ... 2021-10-06T02:10:00 Data variables: TEMP (TIME) float64 19.68 19.68 19.67 19.64 ... 18.64 18.61 18.56 18.7
array(['2008-06-21T04:50:00.000000000', '2008-06-21T05:00:00.000000000', '2008-06-21T05:10:00.000000000', ..., '2021-10-05T21:10:00.000000000', '2021-10-05T23:20:00.000000000', '2021-10-06T02:10:00.000000000'], dtype='datetime64[ns]')
array([19.683469, 19.676668, 19.667065, ..., 18.613289, 18.564098, 18.696157])
# Plot the quality controlled depth data
%matplotlib inline
fig, ax = plt.subplots(figsize=(13,4))
ax.scatter(alltemp['TIME'].values, alltemp['TEMP'].values, c=alltemp['TEMP'].values, cmap = 'jet' )
plt.grid();
ax.set_xlabel('Year')
ax.set_ylabel('Mean 10m depth temeperature')
plt.title('Glider data TwoRocks for Perth region');
climatology_mean = alltemp['TEMP'].groupby("TIME.month").mean("TIME")
climatology_mean
<xarray.DataArray 'TEMP' (month: 12)> array([21.58923108, 22.30858523, 22.98569443, 22.69587102, 21.55811613, 20.81099823, 19.33947989, 19.12770212, 19.00245402, 19.25965043, 20.00145835, 20.86383616]) Coordinates: * month (month) int64 1 2 3 4 5 6 7 8 9 10 11 12
array([21.58923108, 22.30858523, 22.98569443, 22.69587102, 21.55811613, 20.81099823, 19.33947989, 19.12770212, 19.00245402, 19.25965043, 20.00145835, 20.86383616])
array([ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12])
import matplotlib.pyplot as plt
fig, ax = plt.subplots(figsize=(13,4))
ax.bar(climatology_mean['month'].values,climatology_mean.values)
ax.set_ylim(18, 25)
plt.grid(True)
ax.set_xlabel('Months')
ax.set_ylabel('Monthly mean 10m depth temeperature')
plt.title('Glider data TwoRocks for Perth region')
plt.show()