Skip to content

Commit

Permalink
Merge branch 'master' into thull-dive_number_depth
Browse files Browse the repository at this point in the history
  • Loading branch information
MartinMohrmann authored Jul 17, 2023
2 parents 6b5fc69 + e58fef1 commit dbb6bbb
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 0 deletions.
12 changes: 12 additions & 0 deletions docs/contributing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -163,3 +163,15 @@ Preparing Pull Requests
$ git rebase upstream/master # Apply the changes that have been made to central repo,
$ # since your last fetch, onto you master.
$ git branch -d your-bugfix-feature-branch-name # to delete the branch after PR is approved

Release Instructions
--------------------

This is a documentation repo for people in the group on how to do the integrated deployment.

NB RULE! Never commit to master.

1. Change the version in the setup.py file. Must be format YYYY.<release number>
2. Create a release with a tag that has the same format as the version above.
3. The distribution will be built automatically and pushed to PyPi
4. The DOI will also be updated on Zenodo. (untested, see #165)
10 changes: 10 additions & 0 deletions glidertools/load/voto_seaexplorer.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,16 @@ def voto_concat_datasets(datasets):
xarray.Dataset
concatenated Dataset containing all the data from the list of datasets
"""
# in case the datasets have a different set of variables, emtpy variables are created
# to allow for concatenation (concat with different set of variables leads to error)
mlist = [set(dataset.variables.keys()) for dataset in datasets]
allvariables = set.union(*mlist)
for dataset in datasets:
missing_vars = allvariables - set(dataset.variables.keys())
for missing_var in missing_vars:
dataset[missing_var] = np.nan

# renumber profiles, so that profile_num still is unique in concat-dataset
for index in range(1, len(datasets)):
datasets[index]["profile_num"] += (
datasets[index - 1].copy()["profile_num"].max()
Expand Down

0 comments on commit dbb6bbb

Please sign in to comment.