Skip to content

Commit

Permalink
merge main
Browse files Browse the repository at this point in the history
  • Loading branch information
nilsleh committed Nov 13, 2023
2 parents 67954d7 + 996412a commit 5c99a2f
Show file tree
Hide file tree
Showing 489 changed files with 8,483 additions and 6,345 deletions.
3 changes: 3 additions & 0 deletions .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,6 @@ contact_links:
- name: ❓ Questions
url: https://github.com/microsoft/torchgeo/discussions
about: Ask questions or discuss ideas with other TorchGeo users
- name: 💬 Chat
url: https://join.slack.com/t/torchgeo/shared_invite/zt-22rse667m-eqtCeNW0yI000Tl4B~2PIw
about: Chat with fellow TorchGeo users and developers on Slack
6 changes: 3 additions & 3 deletions .github/labeler.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,13 @@ transforms:

# Other
dependencies:
- "environment.yml"
- "setup.cfg"
- "pyproject.toml"
- "requirements/**"
documentation:
- "docs/**"
scripts:
- "*.py"
- "torchgeo/__main__.py"
- "torchgeo/main.py"
- "experiments/**"
testing:
- "tests/**"
Expand Down
50 changes: 31 additions & 19 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,70 +12,82 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Clone repo
uses: actions/checkout@v4.0.0
uses: actions/checkout@v4.1.1
- name: Set up python
uses: actions/[email protected].0
uses: actions/[email protected].1
with:
python-version: '3.11'
- name: Cache dependencies
uses: actions/[email protected].1
uses: actions/[email protected].2
id: cache
with:
path: ${{ env.pythonLocation }}
key: ${{ env.pythonLocation }}-${{ hashFiles('setup.cfg') }}
key: ${{ env.pythonLocation }}-${{ hashFiles('pyproject.toml') }}-datasets
- name: Install pip dependencies
if: steps.cache.outputs.cache-hit != 'true'
run: |
pip install .[tests]
pip list
pip cache purge
- name: List pip dependencies
run: pip list
- name: Run pytest checks
run: pytest --cov=torchgeo --cov-report=xml --durations=10
run: |
pytest --cov=torchgeo --cov-report=xml --durations=10
python -m torchgeo --help
torchgeo --help
integration:
name: integration
runs-on: ubuntu-latest
steps:
- name: Clone repo
uses: actions/checkout@v4.0.0
uses: actions/checkout@v4.1.1
- name: Set up python
uses: actions/[email protected].0
uses: actions/[email protected].1
with:
python-version: '3.11'
- name: Cache dependencies
uses: actions/[email protected].1
uses: actions/[email protected].2
id: cache
with:
path: ${{ env.pythonLocation }}
key: ${{ env.pythonLocation }}-${{ hashFiles('setup.cfg') }}
key: ${{ env.pythonLocation }}-${{ hashFiles('pyproject.toml') }}-integration
- name: Install pip dependencies
if: steps.cache.outputs.cache-hit != 'true'
run: |
pip install .[datasets,tests]
pip list
pip cache purge
- name: List pip dependencies
run: pip list
- name: Run integration checks
run: pytest -m slow --durations=10
run: |
pytest -m slow --durations=10
python -m torchgeo --help
torchgeo --help
notebooks:
name: notebooks
runs-on: ubuntu-latest
steps:
- name: Clone repo
uses: actions/checkout@v4.0.0
uses: actions/checkout@v4.1.1
- name: Set up python
uses: actions/[email protected].0
uses: actions/[email protected].1
with:
python-version: '3.11'
- name: Cache dependencies
uses: actions/[email protected].1
uses: actions/[email protected].2
id: cache
with:
path: ${{ env.pythonLocation }}
key: ${{ env.pythonLocation }}-${{ hashFiles('setup.cfg') }}
key: ${{ env.pythonLocation }}-${{ hashFiles('pyproject.toml') }}-tutorials
- name: Install pip dependencies
if: steps.cache.outputs.cache-hit != 'true'
run: |
pip install .[docs,tests] planetary_computer pystac pytest-rerunfailures
pip list
pip install .[docs,tests] planetary_computer pystac
pip cache purge
- name: List pip dependencies
run: pip list
- name: Run notebook checks
run: pytest --nbmake --durations=10 --reruns=10 docs/tutorials
run: pytest --nbmake --durations=10 docs/tutorials
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.head.label || github.head_ref || github.ref }}
cancel-in-progress: true
50 changes: 30 additions & 20 deletions .github/workflows/style.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,13 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Clone repo
uses: actions/checkout@v4.0.0
uses: actions/checkout@v4.1.1
- name: Set up python
uses: actions/[email protected].0
uses: actions/[email protected].1
with:
python-version: '3.11'
- name: Cache dependencies
uses: actions/[email protected].1
uses: actions/[email protected].2
id: cache
with:
path: ${{ env.pythonLocation }}
Expand All @@ -29,21 +29,23 @@ jobs:
if: steps.cache.outputs.cache-hit != 'true'
run: |
pip install -r requirements/style.txt
pip list
pip cache purge
- name: List pip dependencies
run: pip list
- name: Run black checks
run: black . --check --diff
flake8:
name: flake8
runs-on: ubuntu-latest
steps:
- name: Clone repo
uses: actions/checkout@v4.0.0
uses: actions/checkout@v4.1.1
- name: Set up python
uses: actions/[email protected].0
uses: actions/[email protected].1
with:
python-version: '3.11'
- name: Cache dependencies
uses: actions/[email protected].1
uses: actions/[email protected].2
id: cache
with:
path: ${{ env.pythonLocation }}
Expand All @@ -52,21 +54,23 @@ jobs:
if: steps.cache.outputs.cache-hit != 'true'
run: |
pip install -r requirements/style.txt
pip list
pip cache purge
- name: List pip dependencies
run: pip list
- name: Run flake8 checks
run: flake8
isort:
name: isort
runs-on: ubuntu-latest
steps:
- name: Clone repo
uses: actions/checkout@v4.0.0
uses: actions/checkout@v4.1.1
- name: Set up python
uses: actions/[email protected].0
uses: actions/[email protected].1
with:
python-version: '3.11'
- name: Cache dependencies
uses: actions/[email protected].1
uses: actions/[email protected].2
id: cache
with:
path: ${{ env.pythonLocation }}
Expand All @@ -75,21 +79,23 @@ jobs:
if: steps.cache.outputs.cache-hit != 'true'
run: |
pip install -r requirements/style.txt
pip list
pip cache purge
- name: List pip dependencies
run: pip list
- name: Run isort checks
run: isort . --check --diff
pydocstyle:
name: pydocstyle
runs-on: ubuntu-latest
steps:
- name: Clone repo
uses: actions/checkout@v4.0.0
uses: actions/checkout@v4.1.1
- name: Set up python
uses: actions/[email protected].0
uses: actions/[email protected].1
with:
python-version: '3.11'
- name: Cache dependencies
uses: actions/[email protected].1
uses: actions/[email protected].2
id: cache
with:
path: ${{ env.pythonLocation }}
Expand All @@ -98,21 +104,23 @@ jobs:
if: steps.cache.outputs.cache-hit != 'true'
run: |
pip install -r requirements/style.txt
pip list
pip cache purge
- name: List pip dependencies
run: pip list
- name: Run pydocstyle checks
run: pydocstyle
pyupgrade:
name: pyupgrade
runs-on: ubuntu-latest
steps:
- name: Clone repo
uses: actions/checkout@v4.0.0
uses: actions/checkout@v4.1.1
- name: Set up python
uses: actions/[email protected].0
uses: actions/[email protected].1
with:
python-version: '3.11'
- name: Cache dependencies
uses: actions/[email protected].1
uses: actions/[email protected].2
id: cache
with:
path: ${{ env.pythonLocation }}
Expand All @@ -121,7 +129,9 @@ jobs:
if: steps.cache.outputs.cache-hit != 'true'
run: |
pip install -r requirements/style.txt
pip list
pip cache purge
- name: List pip dependencies
run: pip list
- name: Run pyupgrade checks
run: pyupgrade --py39-plus $(find . -path ./docs/src -prune -o -name "*.py" -print)
concurrency:
Expand Down
40 changes: 25 additions & 15 deletions .github/workflows/tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,13 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Clone repo
uses: actions/checkout@v4.0.0
uses: actions/checkout@v4.1.1
- name: Set up python
uses: actions/[email protected].0
uses: actions/[email protected].1
with:
python-version: '3.11'
- name: Cache dependencies
uses: actions/[email protected].1
uses: actions/[email protected].2
id: cache
with:
path: ${{ env.pythonLocation }}
Expand All @@ -29,7 +29,9 @@ jobs:
if: steps.cache.outputs.cache-hit != 'true'
run: |
pip install -r requirements/required.txt -r requirements/datasets.txt -r requirements/tests.txt
pip list
pip cache purge
- name: List pip dependencies
run: pip list
- name: Run mypy checks
run: mypy .
pytest:
Expand All @@ -43,13 +45,13 @@ jobs:
python-version: ['3.9', '3.10', '3.11']
steps:
- name: Clone repo
uses: actions/checkout@v4.0.0
uses: actions/checkout@v4.1.1
- name: Set up python
uses: actions/[email protected].0
uses: actions/[email protected].1
with:
python-version: ${{ matrix.python-version }}
- name: Cache dependencies
uses: actions/[email protected].1
uses: actions/[email protected].2
id: cache
with:
path: ${{ env.pythonLocation }}
Expand All @@ -66,15 +68,19 @@ jobs:
run: brew install rar
if: ${{ runner.os == 'macOS' }}
- name: Install choco dependencies (Windows)
run: choco install unrar
run: choco install 7zip
if: ${{ runner.os == 'Windows' }}
- name: Install pip dependencies
if: steps.cache.outputs.cache-hit != 'true'
run: |
pip install -r requirements/required.txt -r requirements/datasets.txt -r requirements/tests.txt
pip list
pip cache purge
- name: List pip dependencies
run: pip list
- name: Run pytest checks
run: pytest --cov=torchgeo --cov-report=xml --durations=10
run: |
pytest --cov=torchgeo --cov-report=xml --durations=10
python3 -m torchgeo --help
- name: Report coverage
uses: codecov/[email protected]
with:
Expand All @@ -86,13 +92,13 @@ jobs:
MPLBACKEND: Agg
steps:
- name: Clone repo
uses: actions/checkout@v4.0.0
uses: actions/checkout@v4.1.1
- name: Set up python
uses: actions/[email protected].0
uses: actions/[email protected].1
with:
python-version: '3.9'
- name: Cache dependencies
uses: actions/[email protected].1
uses: actions/[email protected].2
id: cache
with:
path: ${{ env.pythonLocation }}
Expand All @@ -107,9 +113,13 @@ jobs:
if: steps.cache.outputs.cache-hit != 'true'
run: |
pip install -r requirements/min-reqs.old -c requirements/min-cons.old
pip list
pip cache purge
- name: List pip dependencies
run: pip list
- name: Run pytest checks
run: pytest --cov=torchgeo --cov-report=xml --durations=10
run: |
pytest --cov=torchgeo --cov-report=xml --durations=10
python3 -m torchgeo --help
- name: Report coverage
uses: codecov/[email protected]
with:
Expand Down
Loading

0 comments on commit 5c99a2f

Please sign in to comment.