Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
Philippe Miron committed Dec 9, 2023
1 parent 30d43d2 commit 4ba3a93
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions clouddrift/adapters/mosaic.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,16 @@
>>> ds = mosaic.to_xarray()
"""
from concurrent.futures import ThreadPoolExecutor
from datetime import datetime
import numpy as np
import pandas as pd
import requests
from tqdm import tqdm
import xarray as xr
import xml.etree.ElementTree as ET

MOSAIC_VERSION = "2022"


def get_dataframes() -> tuple[pd.DataFrame, pd.DataFrame]:
"""Get the MOSAiC data (obs dimension in the target Dataset) and metadata
Expand Down Expand Up @@ -137,4 +140,14 @@ def to_xarray():
"units": "degrees_north",
}

# global attributes
ds.attrs = {
"title": "Multidisciplinary drifting Observatory for the Study of Arctic Climate (MOSAiC) expedition 2019 - 2021",
"history": f"Dataset updated in {MOSAIC_VERSION}",
"date_created": datetime.now().isoformat(),
"publisher_name": "NSF Arctic Data Center",
"publisher_url": "https://arcticdata.io/catalog/view/doi:10.18739/A2KP7TS83",
"license": "Creative Commons Attribution 4.0 International License (http://creativecommons.org/licenses/by/4.0/)",
}

return ds

0 comments on commit 4ba3a93

Please sign in to comment.