Skip to content

Commit

Permalink
Merge branch 'main-upstream' into stable
Browse files Browse the repository at this point in the history
  • Loading branch information
leewujung committed Oct 26, 2023
2 parents 12b042b + 593a7e1 commit fa390c9
Show file tree
Hide file tree
Showing 14 changed files with 30 additions and 29 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ jobs:
- 8080:80
steps:
- name: Checkout repo
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-depth: 0 # Fetch all history for all branches and tags.
- name: Set environment variables
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/docker.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
image_name: ["minioci", "http"]
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Retrieve test data
if: matrix.image_name == 'http'
uses: ./.github/actions/gdrive-rclone
Expand All @@ -32,17 +32,17 @@ jobs:
echo "IMAGE_SPEC=${IMAGE_SPEC}" >> $GITHUB_ENV
echo "DATE_TAG=${DATE_TAG}" >> $GITHUB_ENV
- name: Set up QEMU
uses: docker/setup-qemu-action@v2
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
uses: docker/setup-buildx-action@v3
- name: Login to DockerHub
uses: docker/login-action@v2
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_TOKEN }}
- name: Build and push
id: docker_build_push
uses: docker/build-push-action@v4
uses: docker/build-push-action@v5
with:
context: ./
file: ./.ci_helpers/docker/${{ matrix.image_name }}.dockerfile
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ep-install.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
os: ["ubuntu-latest", "macos-latest", "windows-latest"]
steps:
- name: Checkout repo
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Setup miniconda
uses: conda-incubator/setup-miniconda@v2
with:
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/packit.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,13 @@ jobs:
if: github.repository == 'OSOceanAcoustics/echopype'
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
# fetch all history so that setuptools-scm works
fetch-depth: 0

- name: Set up Python
uses: actions/setup-python@v4.7.0
uses: actions/setup-python@v4.7.1
with:
python-version: 3.9

Expand Down Expand Up @@ -52,7 +52,7 @@ jobs:
needs: build-artifact
runs-on: ubuntu-20.04
steps:
- uses: actions/setup-python@v4.7.0
- uses: actions/setup-python@v4.7.1
name: Install Python
with:
python-version: 3.9
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pr.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ jobs:
- 8080:80
steps:
- name: Checkout repo
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-depth: 0 # Fetch all history for all branches and tags.
- name: Set environment variables
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/pypi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,13 @@ jobs:
if: github.repository == 'OSOceanAcoustics/echopype'
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
# fetch all history so that setuptools-scm works
fetch-depth: 0

- name: Set up Python
uses: actions/setup-python@v4.7.0
uses: actions/setup-python@v4.7.1
with:
python-version: 3.9

Expand Down Expand Up @@ -56,7 +56,7 @@ jobs:
needs: build-artifact
runs-on: ubuntu-20.04
steps:
- uses: actions/setup-python@v4.7.0
- uses: actions/setup-python@v4.7.1
name: Install Python
with:
python-version: 3.9
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/windows-utils.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jobs:
shell: powershell
steps:
- name: Checkout repo
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-depth: 0 # Fetch all history for all branches and tags.
- name: Set environment variables
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/windows.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ jobs:
- 8080:80
steps:
- name: Checkout repo
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Copying test data to http server
run: |
rm .\echopype\test_data -r -fo
Expand All @@ -46,12 +46,12 @@ jobs:
# Check data endpoint
curl http://localhost:8080/data/
- name: Setup Python
uses: actions/setup-python@v4.7.0
uses: actions/setup-python@v4.7.1
with:
python-version: ${{ matrix.python-version }}
architecture: x64
- name: Cache conda
uses: actions/cache@v3.3.1
uses: actions/cache@v3.3.2
env:
# Increase this value to reset cache if '.ci_helpers/py{0}.yaml' has not changed
CACHE_NUMBER: 0
Expand Down
6 changes: 3 additions & 3 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ exclude: |
)
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
rev: v4.5.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
Expand All @@ -24,7 +24,7 @@ repos:
args: ["--profile", "black", "--filter-files"]

- repo: https://github.com/psf/black
rev: 23.7.0
rev: 23.9.1
hooks:
- id: black

Expand All @@ -34,7 +34,7 @@ repos:
- id: flake8

- repo: https://github.com/codespell-project/codespell
rev: v2.2.5
rev: v2.2.6
hooks:
- id: codespell
# Checks spelling in `docs/source` and `echopype` dirs ONLY
Expand Down
3 changes: 2 additions & 1 deletion docs/source/_config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ bibtex_bibfiles:
# Information about where the book exists on the web
repository:
url: https://github.com/OSOceanAcoustics/echopype # Online location of your book
path_to_book: docs # Optional path to your book, relative to the repository root
path_to_book: docs/source # Optional path to your book, relative to the repository root
branch: main # Which branch of the repository should be used when creating links (optional)

# Add GitHub buttons to your book
Expand All @@ -33,6 +33,7 @@ html:
home_page_in_navbar: false
use_issues_button: true
use_repository_button: true
use_edit_page_button: true

sphinx:
extra_extensions: [
Expand Down
4 changes: 2 additions & 2 deletions docs/source/contributing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ This diagram depicts the complete workflow we use in the source GitHub repositor
- ``doc patch``: Updates to the documentation that refer to the current ``echopype``
release can be pushed out immediately to the
`echopype documentation site <https://echopype.readthedocs.io>`_
by contibuting patches (PRs) to the ``stable`` branch. See `Documentation development`_
by contributing patches (PRs) to the ``stable`` branch. See `Documentation development`_
below for more details.
- ``code patch``: Code development is carried out as patches (PRs) to the ``dev``
branch; changes in the documentation corresponding to changes in the code can be
Expand Down Expand Up @@ -224,7 +224,7 @@ To view the HTML files generated by Jupyter Book, open the
``docs/_build/html/index.html`` in your browser.

Jupyter Book `configurations <https://jupyterbook.org/en/stable/customize/config.html>`_ can be found in the ``docs/source/_config.yml`` file.
The `table of contents <https://jupyterbook.org/en/stable/structure/toc.html>`_ arragements for the sidebar can be found in ``docs/source/_toc.yml`` file.
The `table of contents <https://jupyterbook.org/en/stable/structure/toc.html>`_ arrangements for the sidebar can be found in ``docs/source/_toc.yml`` file.

When ready to commit your changes, please pull request your changes to the `stable` branch. Once the PR is submitted, the `pre-commit` CI will run for basic spelling and formatting check (See the `pre-commit hooks section <contributing.html#pre-commit-hooks>`_ for more details). Any changes from the `pre-commit` check have to be pulled to your branch (via `git pull`) before your push further commits. You will also be able to view the newly built doc in the PR via the "docs/readthedocs.org:echopype" entry shown below.

Expand Down
4 changes: 2 additions & 2 deletions docs/source/data-proc.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Data processing

Echopype data processing funcionalities are structured into different subpackages with expandability and a series of [data processing levels](processing-levels) in mind. Once the data is converted from the raw instrument data files to standardized [`EchoData` objects](data-format:echodata-object) (or stored in `.zarr` or `.nc` format) and calibrated, the core input and output of most subsequent functions are generic [xarray `Datasets`](https://docs.xarray.dev/en/stable/generated/xarray.Dataset.html). This design allows new processing functions be easily added without needing to understand specialized objects, other than functions needing access of data stored only in the raw-converted `EchoData` objects.
Echopype data processing functionalities are structured into different subpackages with expandability and a series of [data processing levels](processing-levels) in mind. Once the data is converted from the raw instrument data files to standardized [`EchoData` objects](data-format:echodata-object) (or stored in `.zarr` or `.nc` format) and calibrated, the core input and output of most subsequent functions are generic [xarray `Datasets`](https://docs.xarray.dev/en/stable/generated/xarray.Dataset.html). This design allows new processing functions be easily added without needing to understand specialized objects, other than functions needing access of data stored only in the raw-converted `EchoData` objects.

The section [**Data processing functionalities**](data-proc:functions) provides information for current processing functions and their usage.

Expand All @@ -9,6 +9,6 @@ The section [**Additional information for processed data**](data-proc:additional
(data-proc:format)=
## Format of processed data

Once raw data (represented by the `EchoData` objects) are calibrated (via [`compute_Sv`](echopype.calibrate.compute_Sv)), the calibrated data and the outputs of all subsequent [processing functions](data-process:funcionalities) are generic [xarray Datasets](https://docs.xarray.dev/en/stable/user-guide/data-structures.html#dataset).
Once raw data (represented by the `EchoData` objects) are calibrated (via [`compute_Sv`](echopype.calibrate.compute_Sv)), the calibrated data and the outputs of all subsequent [processing functions](data-process:functionalities) are generic [xarray Datasets](https://docs.xarray.dev/en/stable/user-guide/data-structures.html#dataset).
We currently do not follow any specific conventions for processed data, but we retain provenance information in the dataset, including the [data processing levels](./processing-levels.md).
However, whether and how data variables used in the processing will be stored remain to be determined.
Original file line number Diff line number Diff line change
Expand Up @@ -753,7 +753,7 @@ def _rename_and_add_time_vars_ek60(ed_obj):
the variable time3, renames the variable ``water_level``
time coordinate to time3, and changes ``ping_time`` to
``time2`` for the variables ``pitch/roll/vertical_offset``.
2. For EK60's ``Envrionment`` group this function renames
2. For EK60's ``Environment`` group this function renames
``ping_time`` to ``time1``.
Parameters
Expand Down
4 changes: 2 additions & 2 deletions echopype/tests/calibrate/test_cal_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ def test_param2da(p_val, channel, da_output):
marks=pytest.mark.xfail(strict=True, reason="input sa_correction does not contain a 'channel' coordinate"),
),
# input individual param:
# - with channel cooridinate but not identical to argin channel: fail with value error
# - with channel coordinate but not identical to argin channel: fail with value error
pytest.param(
"EK80",
{"sa_correction": xr.DataArray([1, 1], dims=["channel"], coords={"channel": ["chA", "B"]})},
Expand All @@ -157,7 +157,7 @@ def test_param2da(p_val, channel, da_output):
reason="input sa_correction contains a 'channel' coordinate but it is not identical with input channel"),
),
# input individual param:
# - with channel cooridinate identical to argin channel: should pass
# - with channel coordinate identical to argin channel: should pass
pytest.param(
"EK80",
{"sa_correction": xr.DataArray([1, 1], dims=["channel"], coords={"channel": ["chA", "chB"]})},
Expand Down

0 comments on commit fa390c9

Please sign in to comment.