Skip to content

Commit

Permalink
chore: test with local dask executor
Browse files Browse the repository at this point in the history
  • Loading branch information
gabriel-milan committed Nov 15, 2023
1 parent fb81bc4 commit c2133ef
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 58 deletions.
9 changes: 5 additions & 4 deletions pipelines/rj_escritorio/flooding_detection/flows.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Flow definition for flooding detection using AI.
"""
from prefect import Parameter
from prefect.executors import DaskExecutor
from prefect.executors import LocalDaskExecutor
from prefect.run_configs import KubernetesRun
from prefect.storage import GCS
from prefect.tasks.control_flow.filter import FilterTask
Expand Down Expand Up @@ -107,9 +107,10 @@


rj_escritorio__flooding_detection__flow.storage = GCS(constants.GCS_FLOWS_BUCKET.value)
rj_escritorio__flooding_detection__flow.executor = DaskExecutor(
address="tcp://prefect-support-cluster-scheduler.dask.svc.cluster.local:8786"
)
# rj_escritorio__flooding_detection__flow.executor = DaskExecutor(
# address="tcp://prefect-support-cluster-scheduler.dask.svc.cluster.local:8786"
# )
rj_escritorio__flooding_detection__flow.executor = LocalDaskExecutor()
rj_escritorio__flooding_detection__flow.run_config = KubernetesRun(
image=constants.DOCKER_IMAGE.value,
labels=[constants.RJ_ESCRITORIO_AGENT_LABEL.value],
Expand Down
71 changes: 20 additions & 51 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 4 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ version = "0.1.0"
PyMySQL = { extras = ["rsa"], version = "^1.0.2" }
Shapely = "^1.8.1"
Unidecode = "^1.3.6"
basedosdados = {version = "2.0.0b14", extras = ["upload"]}
basedosdados = { version = "2.0.0b14", extras = ["upload"] }
black = "20.8b1"
bs4 = "^0.0.1"
croniter = "^1.3.5"
Expand All @@ -19,7 +19,7 @@ earthengine-api = "^0.1.334"
elasticsearch = "^8.2.0"
geobr = "^0.1.10"
geojsplit = "^0.1.2"
geopandas = ">=0.7.0,<0.8.0" # This version range is due to `geobr` package
geopandas = ">=0.7.0,<0.8.0" # This version range is due to `geobr` package
geopy = "^2.3.0"
google-api-python-client = "^2.56.0"
google-cloud-pubsub = "^2.17.1"
Expand All @@ -45,7 +45,7 @@ phonenumbers = "^8.12.57"
plotly = "^5.14.0"
prefect = "0.15.9"
pyproj = "^3.4.0"
python = ">=3.8.1,<3.11"
python = ">=3.9,<3.11"
python-telegram-bot = "^13.11"
pytz = "^2021.3"
rasterio = "1.3a3"
Expand All @@ -64,6 +64,7 @@ azure-storage-blob = "^12.17.0"
icecream = "^2.1.3"
pyodbc = "^5.0.1"
h3 = "^3.7.6"
dask = "^2023.11.0"

[tool.poetry.dev-dependencies]
pylint = "^2.12.2"
Expand Down

0 comments on commit c2133ef

Please sign in to comment.