Skip to content

Commit

Permalink
refactor: fix mypy issues
Browse files Browse the repository at this point in the history
  • Loading branch information
12rambau authored Oct 7, 2024
1 parent a465bc8 commit 14a4133
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions geetools/batch/Export/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ def toDrive(
# sanity check on parameters
# renaming them for mypy type reassignment and compactness
desc = description or folder
folder or description
fid = folder or description

# loop over the collection and export each image
nb_images = imagecollection.size().getInfo()
Expand All @@ -149,7 +149,7 @@ def toDrive(
# override the parameters related to the image itself
# the folder will be created by the first task
kwargs["image"] = locImage
kwargs["folder"] = utils.format_asset_id(folder)
kwargs["folder"] = utils.format_asset_id(f"{fid}")
kwargs["description"] = utils.format_description(f"{desc}_{loc_id}")

# create the task
Expand Down Expand Up @@ -199,7 +199,7 @@ def toCloudStorage(
# sanity check on parameters
# renaming them for mypy type reassignment and compactness
desc = description or folder
folder or description
fid = folder or description

# loop over the collection and export each image
nb_images = imagecollection.size().getInfo()
Expand All @@ -213,7 +213,7 @@ def toCloudStorage(
# override the parameters related to the image itself
# the folder will be created by the first task
kwargs["image"] = locImage
kwargs["fileNamePrefix"] = f"{utils.format_asset_id(folder)}/"
kwargs["fileNamePrefix"] = utils.format_asset_id(f"{fid}") + "/"
kwargs["description"] = utils.format_description(f"{desc}_{loc_id}")

# create the task
Expand Down

0 comments on commit 14a4133

Please sign in to comment.