Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Precommit updates #40

Merged
merged 2 commits into from
May 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
exclude: "GEM-ML"
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
rev: v4.6.0
hooks:
- id: end-of-file-fixer
- id: requirements-txt-fixer
Expand All @@ -14,19 +14,19 @@ repos:
- id: debug-statements

- repo: https://github.com/psf/black
rev: 23.1.0
rev: 24.4.2
hooks:
- id: black
language_version: python3

- repo: https://github.com/pycqa/isort
rev: 5.12.0
rev: 5.13.2
hooks:
- id: isort
name: isort (python)

- repo: https://github.com/PyCQA/autoflake
rev: v2.0.1
rev: v2.3.1
hooks:
- id: autoflake
args:
Expand All @@ -37,7 +37,7 @@ repos:
]

- repo: https://github.com/pycqa/flake8
rev: 6.0.0
rev: 7.0.0
hooks:
- id: flake8
additional_dependencies:
Expand All @@ -47,7 +47,7 @@ repos:
- flake8-typing-imports==1.14.0

- repo: https://github.com/nbQA-dev/nbQA
rev: 1.6.3
rev: 1.8.5
hooks:
- id: nbqa-black
additional_dependencies:
Expand Down
8 changes: 4 additions & 4 deletions AgriDataValue/data_search.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -494,7 +494,7 @@
"source": [
"collections = catalog.get_collections()\n",
"\n",
"collections = [collection for collection in collections if collection[\"title\"].startswith((\"ADV - indicators\"))]\n",
"collections = [collection for collection in collections if collection[\"title\"].startswith(\"ADV - indicators\")]\n",
"collections"
]
},
Expand Down Expand Up @@ -701,7 +701,7 @@
}
],
"source": [
"from sentinelhub import MimeType, SentinelHubDownloadClient, SentinelHubRequest, bbox_to_dimensions, filter_times\n",
"from sentinelhub import MimeType, SentinelHubDownloadClient, SentinelHubRequest, filter_times\n",
"\n",
"time_difference = dt.timedelta(hours=1)\n",
"\n",
Expand Down Expand Up @@ -757,7 +757,7 @@
" ],\n",
" responses=[SentinelHubRequest.output_response(\"default\", MimeType.TIFF)],\n",
" bbox=bbox,\n",
" resolution=(10000, 10000), \n",
" resolution=(10000, 10000),\n",
" config=config,\n",
" )\n",
" process_requests.append(request)"
Expand Down Expand Up @@ -842,7 +842,7 @@
}
],
"source": [
"fig, ax = plt.subplots(figsize=(10 ,10))\n",
"fig, ax = plt.subplots(figsize=(10, 10))\n",
"plt.imshow(indicator, vmin=0, vmax=20, cmap=\"RdYlBu_r\")\n",
"ax.set_title(\"Average Temperature (Historical 1995-2015)\")"
]
Expand Down
1 change: 1 addition & 0 deletions GEM-data/meteoblue.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

import datetime as dt
Expand Down
1 change: 1 addition & 0 deletions extra-tasks/blob/blob.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

import itertools as it
Expand Down
1 change: 1 addition & 0 deletions extra-tasks/blob/test_blob.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

import os
Expand Down
1 change: 1 addition & 0 deletions extra-tasks/class_frequency/class_frequency.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

from typing import Iterator
Expand Down
1 change: 1 addition & 0 deletions extra-tasks/class_frequency/test_class_frequency.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

import numpy as np
Expand Down
1 change: 1 addition & 0 deletions extra-tasks/cloud_mask/cloud_mask.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

import logging
Expand Down
1 change: 1 addition & 0 deletions extra-tasks/cloud_mask/test_cloud_mask.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

import os
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

import itertools as it
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

import os
Expand Down
1 change: 1 addition & 0 deletions extra-tasks/euclidean_norm/euclidean_norm.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

import numpy as np
Expand Down
1 change: 1 addition & 0 deletions extra-tasks/euclidean_norm/test_bands_extraction.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

import numpy as np
Expand Down
1 change: 1 addition & 0 deletions extra-tasks/geodb/geodb.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

from typing import Any
Expand Down
1 change: 1 addition & 0 deletions extra-tasks/geopedia/test_geopedia.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

import pytest
Expand Down
1 change: 1 addition & 0 deletions extra-tasks/haralick/haralick.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

import itertools as it
Expand Down
1 change: 1 addition & 0 deletions extra-tasks/haralick/test_haralick.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

import copy
Expand Down
1 change: 1 addition & 0 deletions extra-tasks/hog/hog.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

import itertools as it
Expand Down
1 change: 1 addition & 0 deletions extra-tasks/hog/test_hog.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

import copy
Expand Down
1 change: 1 addition & 0 deletions extra-tasks/linear_function/linear_function.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

import numpy as np
Expand Down
1 change: 1 addition & 0 deletions extra-tasks/local_binary_pattern/local_binary_pattern.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

import numpy as np
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

import copy
Expand Down
1 change: 1 addition & 0 deletions extra-tasks/meteoblue/meteoblue.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

import datetime as dt
Expand Down
1 change: 1 addition & 0 deletions extra-tasks/meteoblue/test_meteoblue.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

import datetime as dt
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

from abc import ABCMeta, abstractmethod
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

import copy
Expand Down
1 change: 1 addition & 0 deletions extra-tasks/superpixel/superpixel.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

import logging
Expand Down
1 change: 1 addition & 0 deletions extra-tasks/superpixel/test_superpixel.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

import os
Expand Down
1 change: 1 addition & 0 deletions extra-tasks/tdigest/tdigest.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

from functools import partial
Expand Down
1 change: 1 addition & 0 deletions extra-tasks/temporal_features/temporal_features.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

import itertools as it
Expand Down
1 change: 1 addition & 0 deletions extra-tasks/temporal_features/test_temporal_features.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

from datetime import date, timedelta
Expand Down
1 change: 1 addition & 0 deletions extra-tasks/theia_snow_mask/test_theia_snow_mask.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

import os
Expand Down
1 change: 1 addition & 0 deletions extra-tasks/theia_snow_mask/theia_snow_mask.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

import itertools
Expand Down
1 change: 1 addition & 0 deletions extra-tasks/train_test_split/test_train_test_split.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

from typing import Any
Expand Down
1 change: 1 addition & 0 deletions extra-tasks/train_test_split/train_test_split.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

from enum import Enum
Expand Down
1 change: 1 addition & 0 deletions extra-tasks/value_fillout/value_fillout.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@

This source code is licensed under the MIT license, see the LICENSE file in the root directory of this source tree.
"""

from __future__ import annotations

from typing import Literal, cast
Expand Down
1 change: 1 addition & 0 deletions poverty-detection-keras/pred_cong_pd.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

List some configuration parameters for prediction
"""

import os
from os import path as op

Expand Down
1 change: 1 addition & 0 deletions poverty-detection-keras/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@

Utility functions for printing training details
"""

import pprint

import train_config_pd as tcf
Expand Down
Loading