cruiseplan 0.1.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- cruiseplan-0.1.0/.github/ISSUE_TEMPLATE.md +56 -0
- cruiseplan-0.1.0/.github/PULL_REQUEST_TEMPLATE.md +47 -0
- cruiseplan-0.1.0/.github/workflows/docs.yml +49 -0
- cruiseplan-0.1.0/.github/workflows/docs_deploy.yml +53 -0
- cruiseplan-0.1.0/.github/workflows/tests.yml +56 -0
- cruiseplan-0.1.0/.gitignore +174 -0
- cruiseplan-0.1.0/.pre-commit-config.yaml +57 -0
- cruiseplan-0.1.0/CITATION.cff +36 -0
- cruiseplan-0.1.0/CONTRIBUTING.md +88 -0
- cruiseplan-0.1.0/LICENSE +21 -0
- cruiseplan-0.1.0/PKG-INFO +191 -0
- cruiseplan-0.1.0/PROJECT_SPECS.md +1806 -0
- cruiseplan-0.1.0/README.md +119 -0
- cruiseplan-0.1.0/cruiseplan/__init__.py +0 -0
- cruiseplan-0.1.0/cruiseplan/_version.py +1 -0
- cruiseplan-0.1.0/cruiseplan/calculators/__init__.py +13 -0
- cruiseplan-0.1.0/cruiseplan/calculators/distance.py +133 -0
- cruiseplan-0.1.0/cruiseplan/calculators/duration.py +165 -0
- cruiseplan-0.1.0/cruiseplan/calculators/routing.py +66 -0
- cruiseplan-0.1.0/cruiseplan/calculators/scheduler.py +723 -0
- cruiseplan-0.1.0/cruiseplan/cli/__init__.py +18 -0
- cruiseplan-0.1.0/cruiseplan/cli/demo.py +67 -0
- cruiseplan-0.1.0/cruiseplan/cli/download.py +30 -0
- cruiseplan-0.1.0/cruiseplan/cli/enrich.py +131 -0
- cruiseplan-0.1.0/cruiseplan/cli/main.py +361 -0
- cruiseplan-0.1.0/cruiseplan/cli/pangaea.py +210 -0
- cruiseplan-0.1.0/cruiseplan/cli/schedule.py +148 -0
- cruiseplan-0.1.0/cruiseplan/cli/stations.py +257 -0
- cruiseplan-0.1.0/cruiseplan/cli/utils.py +296 -0
- cruiseplan-0.1.0/cruiseplan/cli/validate.py +127 -0
- cruiseplan-0.1.0/cruiseplan/core/__init__.py +15 -0
- cruiseplan-0.1.0/cruiseplan/core/cruise.py +236 -0
- cruiseplan-0.1.0/cruiseplan/core/leg.py +181 -0
- cruiseplan-0.1.0/cruiseplan/core/operations.py +449 -0
- cruiseplan-0.1.0/cruiseplan/core/validation.py +1254 -0
- cruiseplan-0.1.0/cruiseplan/data/__init__.py +12 -0
- cruiseplan-0.1.0/cruiseplan/data/bathymetry.py +368 -0
- cruiseplan-0.1.0/cruiseplan/data/cache.py +91 -0
- cruiseplan-0.1.0/cruiseplan/data/pangaea.py +670 -0
- cruiseplan-0.1.0/cruiseplan/interactive/__init__.py +13 -0
- cruiseplan-0.1.0/cruiseplan/interactive/campaign_selector.py +206 -0
- cruiseplan-0.1.0/cruiseplan/interactive/station_picker.py +854 -0
- cruiseplan-0.1.0/cruiseplan/interactive/widgets.py +268 -0
- cruiseplan-0.1.0/cruiseplan/output/__init__.py +15 -0
- cruiseplan-0.1.0/cruiseplan/output/csv_generator.py +168 -0
- cruiseplan-0.1.0/cruiseplan/output/html_generator.py +487 -0
- cruiseplan-0.1.0/cruiseplan/output/kml_generator.py +272 -0
- cruiseplan-0.1.0/cruiseplan/output/latex_generator.py +398 -0
- cruiseplan-0.1.0/cruiseplan/output/map_generator.py +134 -0
- cruiseplan-0.1.0/cruiseplan/output/netcdf_generator.py +1497 -0
- cruiseplan-0.1.0/cruiseplan/output/templates/stations_table.tex.j2 +36 -0
- cruiseplan-0.1.0/cruiseplan/output/templates/work_days_table.tex.j2 +24 -0
- cruiseplan-0.1.0/cruiseplan/utils/__init__.py +13 -0
- cruiseplan-0.1.0/cruiseplan/utils/activity_utils.py +138 -0
- cruiseplan-0.1.0/cruiseplan/utils/config.py +285 -0
- cruiseplan-0.1.0/cruiseplan/utils/constants.py +86 -0
- cruiseplan-0.1.0/cruiseplan/utils/coordinates.py +220 -0
- cruiseplan-0.1.0/cruiseplan.egg-info/PKG-INFO +191 -0
- cruiseplan-0.1.0/cruiseplan.egg-info/SOURCES.txt +131 -0
- cruiseplan-0.1.0/cruiseplan.egg-info/dependency_links.txt +1 -0
- cruiseplan-0.1.0/cruiseplan.egg-info/entry_points.txt +2 -0
- cruiseplan-0.1.0/cruiseplan.egg-info/requires.txt +32 -0
- cruiseplan-0.1.0/cruiseplan.egg-info/top_level.txt +1 -0
- cruiseplan-0.1.0/docs/Makefile +20 -0
- cruiseplan-0.1.0/docs/source/_static/cruise_plan_logo.png +0 -0
- cruiseplan-0.1.0/docs/source/_static/cruise_plan_logo2.png +0 -0
- cruiseplan-0.1.0/docs/source/_static/css/custom.css +48 -0
- cruiseplan-0.1.0/docs/source/_static/logo.png +0 -0
- cruiseplan-0.1.0/docs/source/api/cruiseplan.calculators.rst +38 -0
- cruiseplan-0.1.0/docs/source/api/cruiseplan.cli.rst +62 -0
- cruiseplan-0.1.0/docs/source/api/cruiseplan.core.rst +45 -0
- cruiseplan-0.1.0/docs/source/api/cruiseplan.data.rst +31 -0
- cruiseplan-0.1.0/docs/source/api/cruiseplan.interactive.rst +33 -0
- cruiseplan-0.1.0/docs/source/api/cruiseplan.output.rst +57 -0
- cruiseplan-0.1.0/docs/source/api/cruiseplan.utils.rst +38 -0
- cruiseplan-0.1.0/docs/source/api/modules.rst +13 -0
- cruiseplan-0.1.0/docs/source/cli_reference.rst +194 -0
- cruiseplan-0.1.0/docs/source/conf.py +167 -0
- cruiseplan-0.1.0/docs/source/index.rst +39 -0
- cruiseplan-0.1.0/docs/source/installation.rst +49 -0
- cruiseplan-0.1.0/docs/source/netcdf_outputs.md +435 -0
- cruiseplan-0.1.0/docs/source/usage.rst +74 -0
- cruiseplan-0.1.0/environment.yml +10 -0
- cruiseplan-0.1.0/instructions_phase3.md +1299 -0
- cruiseplan-0.1.0/instructions_phase4.md +399 -0
- cruiseplan-0.1.0/notebooks/demo.ipynb +150 -0
- cruiseplan-0.1.0/pyproject.toml +110 -0
- cruiseplan-0.1.0/requirements-dev.txt +23 -0
- cruiseplan-0.1.0/requirements.txt +20 -0
- cruiseplan-0.1.0/run_latex_test.py +183 -0
- cruiseplan-0.1.0/setup.cfg +4 -0
- cruiseplan-0.1.0/tests/cli/__init__.py +3 -0
- cruiseplan-0.1.0/tests/cli/test_enrich.py +274 -0
- cruiseplan-0.1.0/tests/cli/test_integration.py +516 -0
- cruiseplan-0.1.0/tests/cli/test_main.py +243 -0
- cruiseplan-0.1.0/tests/cli/test_pangaea.py +243 -0
- cruiseplan-0.1.0/tests/cli/test_schedule.py +201 -0
- cruiseplan-0.1.0/tests/cli/test_stations.py +302 -0
- cruiseplan-0.1.0/tests/cli/test_utils.py +198 -0
- cruiseplan-0.1.0/tests/cli/test_validate.py +357 -0
- cruiseplan-0.1.0/tests/core/test_scheduler.py +225 -0
- cruiseplan-0.1.0/tests/core/test_validation_enrich.py +318 -0
- cruiseplan-0.1.0/tests/data/cruise_example.yaml +80 -0
- cruiseplan-0.1.0/tests/fixtures/cruise_mixed_ops.yaml +71 -0
- cruiseplan-0.1.0/tests/fixtures/cruise_multi_leg.yaml +73 -0
- cruiseplan-0.1.0/tests/fixtures/cruise_simple.yaml +48 -0
- cruiseplan-0.1.0/tests/fixtures/cruise_simple_no_depth.yaml +46 -0
- cruiseplan-0.1.0/tests/fixtures/pangaea_list_NAtl.txt +5 -0
- cruiseplan-0.1.0/tests/integration/test_geo_workflow.py +66 -0
- cruiseplan-0.1.0/tests/integration/test_latex_integration.py +133 -0
- cruiseplan-0.1.0/tests/integration/test_netcdf_integration.py +410 -0
- cruiseplan-0.1.0/tests/integration/test_pangaea_real.py +241 -0
- cruiseplan-0.1.0/tests/integration/test_scheduler_debug.py +240 -0
- cruiseplan-0.1.0/tests/integration/test_scheduler_yaml.py +165 -0
- cruiseplan-0.1.0/tests/integration/test_workflow_processing.py +183 -0
- cruiseplan-0.1.0/tests/unit/test_bathymetry.py +261 -0
- cruiseplan-0.1.0/tests/unit/test_calculators.py +140 -0
- cruiseplan-0.1.0/tests/unit/test_campaign_selector.py +169 -0
- cruiseplan-0.1.0/tests/unit/test_config_utils.py +274 -0
- cruiseplan-0.1.0/tests/unit/test_coordinates.py +193 -0
- cruiseplan-0.1.0/tests/unit/test_csv_generator.py +482 -0
- cruiseplan-0.1.0/tests/unit/test_data_layer.py +325 -0
- cruiseplan-0.1.0/tests/unit/test_explicit_coordinates.py +118 -0
- cruiseplan-0.1.0/tests/unit/test_html_generator.py +644 -0
- cruiseplan-0.1.0/tests/unit/test_kml_generator.py +618 -0
- cruiseplan-0.1.0/tests/unit/test_latex_generation.py +199 -0
- cruiseplan-0.1.0/tests/unit/test_operations_phase1.py +216 -0
- cruiseplan-0.1.0/tests/unit/test_scheduler_logic.py +424 -0
- cruiseplan-0.1.0/tests/unit/test_station_picker.py +377 -0
- cruiseplan-0.1.0/tests/unit/test_stations_cli.py +137 -0
- cruiseplan-0.1.0/tests/unit/test_validation_minimal.py +90 -0
- cruiseplan-0.1.0/tests/unit/test_validation_robustness.py +112 -0
- cruiseplan-0.1.0/tests/unit/test_widgets.py +201 -0
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: "🐛 Bug Report / 💡 Feature Request"
|
|
3
|
+
about: "Report a bug or suggest an improvement for the amocarray project"
|
|
4
|
+
title: "[Bug] <brief description>" or "[Feature] <brief description>"
|
|
5
|
+
labels: []
|
|
6
|
+
assignees: []
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
## Description
|
|
10
|
+
|
|
11
|
+
Please describe the bug or feature request clearly and concisely.
|
|
12
|
+
|
|
13
|
+
**For bugs:**
|
|
14
|
+
- What did you expect to happen?
|
|
15
|
+
- What actually happened?
|
|
16
|
+
- If applicable, include error messages or stack traces.
|
|
17
|
+
|
|
18
|
+
**For features:**
|
|
19
|
+
- What problem does this feature solve?
|
|
20
|
+
- How would this feature improve the project?
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
## Reproduction (for bugs)
|
|
24
|
+
|
|
25
|
+
Please provide steps to reproduce the issue, if possible:
|
|
26
|
+
|
|
27
|
+
1. Go to '...'
|
|
28
|
+
2. Run '...'
|
|
29
|
+
3. Observe '...'
|
|
30
|
+
|
|
31
|
+
If you can, include a minimal, reproducible example or link to a failing test.
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
## Environment
|
|
35
|
+
|
|
36
|
+
- OS: [e.g., macOS 13.3, Ubuntu 22.04, etc.]
|
|
37
|
+
- Python version: [e.g., 3.11]
|
|
38
|
+
- amocarray version: [if applicable]
|
|
39
|
+
- Virtualenv / Conda / System Python?: [env type]
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
## Checklist
|
|
43
|
+
|
|
44
|
+
- [ ] I have checked the existing [issues](https://github.com/AMOCcommunity/amocarray/issues) to avoid duplicates.
|
|
45
|
+
- [ ] I have included steps to reproduce the issue, if it's a bug.
|
|
46
|
+
- [ ] I have described the motivation clearly, if it's a feature request.
|
|
47
|
+
|
|
48
|
+
|
|
49
|
+
## Additional context
|
|
50
|
+
|
|
51
|
+
Add any other context or screenshots about the problem or feature request here.
|
|
52
|
+
|
|
53
|
+
---
|
|
54
|
+
|
|
55
|
+
*This issue template was prepared with assistance from ChatGPT to support clear and collaborative development.*
|
|
56
|
+
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
You can delete unused sections.
|
|
2
|
+
|
|
3
|
+
## PR Title Convention
|
|
4
|
+
|
|
5
|
+
Please prefix your pull request title with one of the following tags for clarity:
|
|
6
|
+
|
|
7
|
+
- `[DOC]` for documentation updates
|
|
8
|
+
- `[FIX]` for bug fixes
|
|
9
|
+
- `[FEAT]` for new features
|
|
10
|
+
- `[REFACTOR]` for code improvements
|
|
11
|
+
- `[TEST]` for tests
|
|
12
|
+
- `[CI]` for CI/CD or automation updates
|
|
13
|
+
- `[CLEANUP]` for general maintenance
|
|
14
|
+
|
|
15
|
+
Example:
|
|
16
|
+
> `[FIX] Correct dimension handling in OSNAP reader`
|
|
17
|
+
|
|
18
|
+
**Description:**
|
|
19
|
+
|
|
20
|
+
Please describe your changes clearly and concisely.
|
|
21
|
+
|
|
22
|
+
- What is the purpose of this pull request?
|
|
23
|
+
- What issue(s) does it address? Please link them (e.g., closes #12).
|
|
24
|
+
- Briefly explain the approach taken.
|
|
25
|
+
|
|
26
|
+
**Checklist:**
|
|
27
|
+
|
|
28
|
+
- [ ] I have followed the [coding conventions](https://amoccommunity.github.io/amocarray/conventions.html).
|
|
29
|
+
- [ ] I have updated or added tests to cover my changes.
|
|
30
|
+
- [ ] I have updated the documentation if needed.
|
|
31
|
+
- [ ] I have run `pytest` to check that all tests pass.
|
|
32
|
+
- [ ] I have run `pre-commit run --all-files` to lint and format the code.
|
|
33
|
+
|
|
34
|
+
**Related Issues / Pull Requests:**
|
|
35
|
+
|
|
36
|
+
Link any related issues, pull requests, or discussions:
|
|
37
|
+
- Fixes #
|
|
38
|
+
- Related to #
|
|
39
|
+
|
|
40
|
+
**Additional Notes:**
|
|
41
|
+
|
|
42
|
+
Include any additional information reviewers might need:
|
|
43
|
+
|
|
44
|
+
- Screenshots (if UI/outputs are affected)
|
|
45
|
+
- Design decisions or trade-offs
|
|
46
|
+
- Anything reviewers should look at closely
|
|
47
|
+
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
name: Test documentation build
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
pull_request:
|
|
5
|
+
paths:
|
|
6
|
+
- '**.py'
|
|
7
|
+
- '**.ipynb'
|
|
8
|
+
- '**.rst'
|
|
9
|
+
- '**.md'
|
|
10
|
+
|
|
11
|
+
jobs:
|
|
12
|
+
build-docs:
|
|
13
|
+
runs-on: ubuntu-latest
|
|
14
|
+
defaults:
|
|
15
|
+
run:
|
|
16
|
+
# Critical: "bash -l {0}" is required for Micromamba environments to activate
|
|
17
|
+
shell: bash -l {0}
|
|
18
|
+
permissions:
|
|
19
|
+
contents: read
|
|
20
|
+
|
|
21
|
+
steps:
|
|
22
|
+
- name: Checkout
|
|
23
|
+
uses: actions/checkout@v4
|
|
24
|
+
with:
|
|
25
|
+
fetch-depth: 0
|
|
26
|
+
|
|
27
|
+
- name: Set up Python
|
|
28
|
+
uses: actions/setup-python@v2
|
|
29
|
+
with:
|
|
30
|
+
python-version: "3.9"
|
|
31
|
+
|
|
32
|
+
- name: Setup Micromamba
|
|
33
|
+
uses: mamba-org/setup-micromamba@v1
|
|
34
|
+
with:
|
|
35
|
+
environment-file: environment.yml
|
|
36
|
+
cache-environment: true
|
|
37
|
+
|
|
38
|
+
- name: Install package
|
|
39
|
+
run: |
|
|
40
|
+
python -m pip install -e . --force-reinstall
|
|
41
|
+
|
|
42
|
+
- name: Build documentation
|
|
43
|
+
run: |
|
|
44
|
+
set -e
|
|
45
|
+
jupyter nbconvert --to notebook --execute notebooks/demo.ipynb --output=demo-output.ipynb --ExecutePreprocessor.allow_errors=True
|
|
46
|
+
mv notebooks/*output.ipynb docs/source/
|
|
47
|
+
pushd docs
|
|
48
|
+
make clean html
|
|
49
|
+
popd
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
name: Deploy Documentation
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches:
|
|
6
|
+
- main
|
|
7
|
+
workflow_dispatch:
|
|
8
|
+
|
|
9
|
+
jobs:
|
|
10
|
+
deploy-docs:
|
|
11
|
+
runs-on: ubuntu-latest
|
|
12
|
+
defaults:
|
|
13
|
+
run:
|
|
14
|
+
# Critical: "bash -l {0}" is required for Micromamba environments to activate
|
|
15
|
+
shell: bash -l {0}
|
|
16
|
+
permissions:
|
|
17
|
+
contents: write
|
|
18
|
+
|
|
19
|
+
steps:
|
|
20
|
+
- name: Checkout
|
|
21
|
+
uses: actions/checkout@v4
|
|
22
|
+
with:
|
|
23
|
+
fetch-depth: 0
|
|
24
|
+
|
|
25
|
+
- name: Set up Python
|
|
26
|
+
uses: actions/setup-python@v2
|
|
27
|
+
with:
|
|
28
|
+
python-version: "3.9"
|
|
29
|
+
|
|
30
|
+
- name: Setup Micromamba
|
|
31
|
+
uses: mamba-org/setup-micromamba@v1
|
|
32
|
+
with:
|
|
33
|
+
environment-file: environment.yml
|
|
34
|
+
cache-environment: true
|
|
35
|
+
|
|
36
|
+
- name: Install package
|
|
37
|
+
run: |
|
|
38
|
+
python -m pip install -e . --force-reinstall
|
|
39
|
+
|
|
40
|
+
- name: Build documentation
|
|
41
|
+
run: |
|
|
42
|
+
set -e
|
|
43
|
+
jupyter nbconvert --to notebook --execute notebooks/demo.ipynb --output=demo-output.ipynb --ExecutePreprocessor.allow_errors=True
|
|
44
|
+
mv notebooks/*output.ipynb docs/source/
|
|
45
|
+
pushd docs
|
|
46
|
+
make clean html
|
|
47
|
+
popd
|
|
48
|
+
|
|
49
|
+
- name: Deploy to GitHub Pages
|
|
50
|
+
uses: peaceiris/actions-gh-pages@v4
|
|
51
|
+
with:
|
|
52
|
+
github_token: ${{ secrets.GITHUB_TOKEN }}
|
|
53
|
+
publish_dir: docs/build/html
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
name: Run tests
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: [ "main" ]
|
|
6
|
+
paths:
|
|
7
|
+
- '**.py'
|
|
8
|
+
- 'cruiseplan/**'
|
|
9
|
+
- 'tests/**'
|
|
10
|
+
- 'pyproject.toml'
|
|
11
|
+
- 'requirements*.txt'
|
|
12
|
+
- '.pre-commit-config.yaml'
|
|
13
|
+
pull_request:
|
|
14
|
+
branches: [ "main" ]
|
|
15
|
+
paths:
|
|
16
|
+
- '**.py'
|
|
17
|
+
- 'cruiseplan/**'
|
|
18
|
+
- 'tests/**'
|
|
19
|
+
- 'pyproject.toml'
|
|
20
|
+
- 'requirements*.txt'
|
|
21
|
+
- '.pre-commit-config.yaml'
|
|
22
|
+
|
|
23
|
+
jobs:
|
|
24
|
+
test:
|
|
25
|
+
name: ${{ matrix.os }} / Py ${{ matrix.python-version }}
|
|
26
|
+
runs-on: ${{ matrix.os }}
|
|
27
|
+
defaults:
|
|
28
|
+
run:
|
|
29
|
+
# Critical: "bash -l {0}" is required for Micromamba environments to activate
|
|
30
|
+
shell: bash -l {0}
|
|
31
|
+
strategy:
|
|
32
|
+
fail-fast: true
|
|
33
|
+
matrix:
|
|
34
|
+
os: [ubuntu-latest, windows-latest, macos-latest]
|
|
35
|
+
# Testing across all selected supported versions from your spec
|
|
36
|
+
python-version: ["3.9", "3.12"]
|
|
37
|
+
|
|
38
|
+
steps:
|
|
39
|
+
- name: Checkout code
|
|
40
|
+
uses: actions/checkout@v4
|
|
41
|
+
|
|
42
|
+
- name: Set up Python ${{ matrix.python-version }}
|
|
43
|
+
uses: actions/setup-python@v2
|
|
44
|
+
|
|
45
|
+
- name: Install dependencies
|
|
46
|
+
run: |
|
|
47
|
+
python -m pip install --upgrade pip
|
|
48
|
+
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
|
|
49
|
+
|
|
50
|
+
- name: Install package
|
|
51
|
+
run: |
|
|
52
|
+
python -m pip install -e .[dev] --force-reinstall
|
|
53
|
+
|
|
54
|
+
- name: Test with pytest
|
|
55
|
+
run: |
|
|
56
|
+
pytest
|
|
@@ -0,0 +1,174 @@
|
|
|
1
|
+
setup.sh
|
|
2
|
+
*/_version.py
|
|
3
|
+
data/temp.nc
|
|
4
|
+
tests_output/*
|
|
5
|
+
data/bathymetry/ETOPO_2022_v1_60s_N90W180_bed.nc
|
|
6
|
+
|
|
7
|
+
logs/*log
|
|
8
|
+
|
|
9
|
+
# VSCode settings
|
|
10
|
+
.vscode/*
|
|
11
|
+
|
|
12
|
+
# Byte-compiled / optimized / DLL files
|
|
13
|
+
__pycache__/
|
|
14
|
+
*.py[cod]
|
|
15
|
+
*$py.class
|
|
16
|
+
|
|
17
|
+
# C extensions
|
|
18
|
+
*.so
|
|
19
|
+
|
|
20
|
+
# Distribution / packaging
|
|
21
|
+
.Python
|
|
22
|
+
build/
|
|
23
|
+
develop-eggs/
|
|
24
|
+
dist/
|
|
25
|
+
downloads/
|
|
26
|
+
eggs/
|
|
27
|
+
.eggs/
|
|
28
|
+
lib/
|
|
29
|
+
lib64/
|
|
30
|
+
parts/
|
|
31
|
+
sdist/
|
|
32
|
+
var/
|
|
33
|
+
wheels/
|
|
34
|
+
share/python-wheels/
|
|
35
|
+
*.egg-info/
|
|
36
|
+
.installed.cfg
|
|
37
|
+
*.egg
|
|
38
|
+
MANIFEST
|
|
39
|
+
|
|
40
|
+
# PyInstaller
|
|
41
|
+
# Usually these files are written by a python script from a template
|
|
42
|
+
# before PyInstaller builds the exe, so as to inject date/other infos into it.
|
|
43
|
+
*.manifest
|
|
44
|
+
*.spec
|
|
45
|
+
|
|
46
|
+
# Installer logs
|
|
47
|
+
pip-log.txt
|
|
48
|
+
pip-delete-this-directory.txt
|
|
49
|
+
|
|
50
|
+
# Unit test / coverage reports
|
|
51
|
+
htmlcov/
|
|
52
|
+
.tox/
|
|
53
|
+
.nox/
|
|
54
|
+
.coverage
|
|
55
|
+
.coverage.*
|
|
56
|
+
.cache
|
|
57
|
+
nosetests.xml
|
|
58
|
+
coverage.xml
|
|
59
|
+
*.cover
|
|
60
|
+
*.py,cover
|
|
61
|
+
.hypothesis/
|
|
62
|
+
.pytest_cache/
|
|
63
|
+
cover/
|
|
64
|
+
|
|
65
|
+
# Translations
|
|
66
|
+
*.mo
|
|
67
|
+
*.pot
|
|
68
|
+
|
|
69
|
+
# Django stuff:
|
|
70
|
+
*.log
|
|
71
|
+
local_settings.py
|
|
72
|
+
db.sqlite3
|
|
73
|
+
db.sqlite3-journal
|
|
74
|
+
|
|
75
|
+
# Flask stuff:
|
|
76
|
+
instance/
|
|
77
|
+
.webassets-cache
|
|
78
|
+
|
|
79
|
+
# Scrapy stuff:
|
|
80
|
+
.scrapy
|
|
81
|
+
|
|
82
|
+
# Sphinx documentation
|
|
83
|
+
docs/_build/
|
|
84
|
+
|
|
85
|
+
# PyBuilder
|
|
86
|
+
.pybuilder/
|
|
87
|
+
target/
|
|
88
|
+
|
|
89
|
+
# Jupyter Notebook
|
|
90
|
+
.ipynb_checkpoints
|
|
91
|
+
|
|
92
|
+
# IPython
|
|
93
|
+
profile_default/
|
|
94
|
+
ipython_config.py
|
|
95
|
+
|
|
96
|
+
# pyenv
|
|
97
|
+
# For a library or package, you might want to ignore these files since the code is
|
|
98
|
+
# intended to run in multiple environments; otherwise, check them in:
|
|
99
|
+
.python-version
|
|
100
|
+
|
|
101
|
+
# pipenv
|
|
102
|
+
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
|
|
103
|
+
# However, in case of collaboration, if having platform-specific dependencies or dependencies
|
|
104
|
+
# having no cross-platform support, pipenv may install dependencies that don't work, or not
|
|
105
|
+
# install all needed dependencies.
|
|
106
|
+
Pipfile.lock
|
|
107
|
+
|
|
108
|
+
# poetry
|
|
109
|
+
# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
|
|
110
|
+
# This is especially recommended for binary packages to ensure reproducibility, and is more
|
|
111
|
+
# commonly ignored for libraries.
|
|
112
|
+
# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
|
|
113
|
+
poetry.lock
|
|
114
|
+
|
|
115
|
+
# pdm
|
|
116
|
+
# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
|
|
117
|
+
#pdm.lock
|
|
118
|
+
# pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it
|
|
119
|
+
# in version control.
|
|
120
|
+
# https://pdm.fming.dev/latest/usage/project/#working-with-version-control
|
|
121
|
+
.pdm.toml
|
|
122
|
+
.pdm-python
|
|
123
|
+
.pdm-build/
|
|
124
|
+
|
|
125
|
+
# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
|
|
126
|
+
__pypackages__/
|
|
127
|
+
|
|
128
|
+
# Celery stuff
|
|
129
|
+
celerybeat-schedule
|
|
130
|
+
celerybeat.pid
|
|
131
|
+
|
|
132
|
+
# SageMath parsed files
|
|
133
|
+
*.sage.py
|
|
134
|
+
|
|
135
|
+
# Environments
|
|
136
|
+
.env
|
|
137
|
+
.venv
|
|
138
|
+
env/
|
|
139
|
+
venv/
|
|
140
|
+
ENV/
|
|
141
|
+
env.bak/
|
|
142
|
+
venv.bak/
|
|
143
|
+
|
|
144
|
+
# Spyder project settings
|
|
145
|
+
.spyderproject
|
|
146
|
+
.spyproject
|
|
147
|
+
|
|
148
|
+
# Rope project settings
|
|
149
|
+
.ropeproject
|
|
150
|
+
|
|
151
|
+
# mkdocs documentation
|
|
152
|
+
/site
|
|
153
|
+
|
|
154
|
+
# mypy
|
|
155
|
+
.mypy_cache/
|
|
156
|
+
.dmypy.json
|
|
157
|
+
dmypy.json
|
|
158
|
+
|
|
159
|
+
# Pyre type checker
|
|
160
|
+
.pyre/
|
|
161
|
+
|
|
162
|
+
# pytype static type analyzer
|
|
163
|
+
.pytype/
|
|
164
|
+
|
|
165
|
+
# Cython debug symbols
|
|
166
|
+
cython_debug/
|
|
167
|
+
|
|
168
|
+
# PyCharm
|
|
169
|
+
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
|
|
170
|
+
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
|
|
171
|
+
# and can be added to the global gitignore or merged into this file. For a more nuclear
|
|
172
|
+
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
|
|
173
|
+
.idea/
|
|
174
|
+
test_output/test_map_VA176.html
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
repos:
|
|
2
|
+
- repo: https://github.com/psf/black
|
|
3
|
+
rev: 24.3.0
|
|
4
|
+
hooks:
|
|
5
|
+
- id: black
|
|
6
|
+
language_version: python3
|
|
7
|
+
files: \.(py|ipynb)$
|
|
8
|
+
exclude: ^data/
|
|
9
|
+
|
|
10
|
+
- repo: https://github.com/codespell-project/codespell
|
|
11
|
+
rev: v2.2.6 # Check for the latest version
|
|
12
|
+
hooks:
|
|
13
|
+
- id: codespell
|
|
14
|
+
args: ["--ignore-words-list", "nd"] # Optional: ignore some false positives
|
|
15
|
+
|
|
16
|
+
# - repo: https://github.com/pycqa/isort
|
|
17
|
+
# rev: 5.13.2
|
|
18
|
+
# hooks:
|
|
19
|
+
# - id: isort
|
|
20
|
+
# language_version: python3
|
|
21
|
+
# files: \.(py|ipynb)$
|
|
22
|
+
# exclude: ^data/
|
|
23
|
+
|
|
24
|
+
- repo: https://github.com/pre-commit/pre-commit-hooks
|
|
25
|
+
rev: v4.5.0
|
|
26
|
+
hooks:
|
|
27
|
+
- id: end-of-file-fixer
|
|
28
|
+
files: \.(py|yaml|yml|ipynb)$
|
|
29
|
+
exclude: ^data/
|
|
30
|
+
- id: trailing-whitespace
|
|
31
|
+
files: \.(py|yaml|yml|ipynb)$
|
|
32
|
+
exclude: ^data/
|
|
33
|
+
- id: check-yaml
|
|
34
|
+
files: \.(yaml|yml)$
|
|
35
|
+
exclude: ^data/
|
|
36
|
+
- id: check-added-large-files
|
|
37
|
+
|
|
38
|
+
- repo: local
|
|
39
|
+
hooks:
|
|
40
|
+
- id: pytest
|
|
41
|
+
name: pytest
|
|
42
|
+
entry: pytest -q
|
|
43
|
+
language: system
|
|
44
|
+
types: [python]
|
|
45
|
+
exclude: ^data/
|
|
46
|
+
|
|
47
|
+
- repo: https://github.com/charliermarsh/ruff-pre-commit
|
|
48
|
+
rev: v0.3.0
|
|
49
|
+
hooks:
|
|
50
|
+
- id: ruff
|
|
51
|
+
args: [
|
|
52
|
+
"--fix",
|
|
53
|
+
"--exit-zero",
|
|
54
|
+
"--select",
|
|
55
|
+
"E,F,W,C90,ANN,B,BLE,TRY,ARG,SLF",
|
|
56
|
+
]
|
|
57
|
+
exclude: ^data/
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
cff-version: 1.2.0
|
|
2
|
+
title: "CruisePlan: A Tool for Oceanographic Cruise Planning"
|
|
3
|
+
message: "If you use this software, please cite it as below."
|
|
4
|
+
type: software
|
|
5
|
+
authors:
|
|
6
|
+
- family-names: Frajka-Williams
|
|
7
|
+
given-names: Eleanor
|
|
8
|
+
orcid: "https://orcid.org/0000-0001-8773-7838"
|
|
9
|
+
affiliation: "University of Hamburg, Institute of Oceanography"
|
|
10
|
+
- family-names: Sorge
|
|
11
|
+
given-names: Yves
|
|
12
|
+
orcid: https://orcid.org/0009-0007-0043-9207
|
|
13
|
+
- family-names: Trace-Kleeberg
|
|
14
|
+
given-names: Sunke
|
|
15
|
+
orcid: https://orcid.org/0000-0002-5980-2492
|
|
16
|
+
repository-code: "https://github.com/ocean-uhh/cruiseplan"
|
|
17
|
+
url: "https://ocean-uhh.github.io/cruiseplan"
|
|
18
|
+
abstract: >-
|
|
19
|
+
CruisePlan is a Python package for planning and scheduling oceanographic
|
|
20
|
+
research cruises. It provides tools for station distribution calculation,
|
|
21
|
+
CTD profile timing estimation, mooring operation planning, travel time
|
|
22
|
+
calculations, and multi-format output generation including HTML schedules,
|
|
23
|
+
CSV data, KML visualization files, and NetCDF scientific data formats.
|
|
24
|
+
The package includes interactive station selection tools with PANGAEA
|
|
25
|
+
database integration for historical oceanographic data analysis.
|
|
26
|
+
keywords:
|
|
27
|
+
- oceanography
|
|
28
|
+
- cruise planning
|
|
29
|
+
- research vessels
|
|
30
|
+
- CTD
|
|
31
|
+
- moorings
|
|
32
|
+
- bathymetry
|
|
33
|
+
- station planning
|
|
34
|
+
license: MIT
|
|
35
|
+
version: "0.1.0"
|
|
36
|
+
date-released: "2025-01-02"
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
# Contributing to CruisePlan
|
|
2
|
+
|
|
3
|
+
Thank you for your interest in contributing to CruisePlan! This document provides guidelines and information for contributors.
|
|
4
|
+
|
|
5
|
+
## Development Setup
|
|
6
|
+
|
|
7
|
+
### Prerequisites
|
|
8
|
+
- Python 3.9 or later
|
|
9
|
+
- Git
|
|
10
|
+
|
|
11
|
+
### Installation for Development
|
|
12
|
+
|
|
13
|
+
1. Fork and clone the repository:
|
|
14
|
+
```bash
|
|
15
|
+
git clone https://github.com/ocean-uhh/cruiseplan.git
|
|
16
|
+
cd cruiseplan
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
2. Create a virtual environment:
|
|
20
|
+
```bash
|
|
21
|
+
python -m venv .venv
|
|
22
|
+
source .venv/bin/activate # On Windows: .venv\Scripts\activate
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
3. Install the package in development mode with all dependencies:
|
|
26
|
+
```bash
|
|
27
|
+
pip install -e .[dev]
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
4. Install pre-commit hooks:
|
|
31
|
+
```bash
|
|
32
|
+
pre-commit install
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
## Development Workflow
|
|
36
|
+
|
|
37
|
+
### Code Style
|
|
38
|
+
- We use [Ruff](https://github.com/astral-sh/ruff) for linting and formatting
|
|
39
|
+
- Follow [PEP 8](https://pep8.org/) style guidelines
|
|
40
|
+
- Use type hints where possible
|
|
41
|
+
- Write docstrings following [NumPy style](https://numpydoc.readthedocs.io/en/latest/format.html)
|
|
42
|
+
|
|
43
|
+
### Testing
|
|
44
|
+
- Write tests for new functionality
|
|
45
|
+
- Ensure all tests pass before submitting a PR
|
|
46
|
+
- Run tests with: `pytest`
|
|
47
|
+
- Check code coverage: `pytest --cov=cruiseplan`
|
|
48
|
+
|
|
49
|
+
### Documentation
|
|
50
|
+
- Update docstrings for any modified functions
|
|
51
|
+
- Add examples for new features in the demo notebook
|
|
52
|
+
- Build documentation locally: `cd docs && make html`
|
|
53
|
+
|
|
54
|
+
### Pull Requests
|
|
55
|
+
1. Create a feature branch from `main`
|
|
56
|
+
2. Make your changes
|
|
57
|
+
3. Run tests and linting: `pytest && ruff check .`
|
|
58
|
+
4. Update documentation if needed
|
|
59
|
+
5. Submit a pull request with a clear description
|
|
60
|
+
|
|
61
|
+
## Project Structure
|
|
62
|
+
|
|
63
|
+
```
|
|
64
|
+
cruiseplan/
|
|
65
|
+
├── cli/ # Command-line interface
|
|
66
|
+
├── core/ # Core cruise planning logic
|
|
67
|
+
├── calculators/ # Distance, duration, routing calculations
|
|
68
|
+
├── data/ # Data loading and caching
|
|
69
|
+
├── interactive/ # Interactive widgets and tools
|
|
70
|
+
├── output/ # Report generation (HTML, LaTeX, KML, NetCDF)
|
|
71
|
+
└── utils/ # Utilities and helpers
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
## Reporting Issues
|
|
75
|
+
|
|
76
|
+
When reporting bugs or requesting features:
|
|
77
|
+
- Use GitHub Issues
|
|
78
|
+
- Provide a clear description and steps to reproduce
|
|
79
|
+
- Include relevant error messages and system information
|
|
80
|
+
- For bugs, include a minimal reproducible example
|
|
81
|
+
|
|
82
|
+
## Code of Conduct
|
|
83
|
+
|
|
84
|
+
This project follows a code of conduct to ensure a welcoming environment for all contributors. Please be respectful and constructive in all interactions.
|
|
85
|
+
|
|
86
|
+
## License
|
|
87
|
+
|
|
88
|
+
By contributing to CruisePlan, you agree that your contributions will be licensed under the same license as the project (MIT License).
|
cruiseplan-0.1.0/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2024 Eleanor Frajka-Williams
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|