Skip to content

Commit

Permalink
fix batched + update modal window
Browse files Browse the repository at this point in the history
  • Loading branch information
vorozhkog committed Dec 2, 2024
1 parent fc3e137 commit 2f9a044
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
4 changes: 3 additions & 1 deletion src/convert_sly_to_yolov5.py
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,9 @@ def _add_to_split(image_id, img_name, split_ids, split_image_paths, labels_dir,
ids_to_download = train_ids + val_ids
paths_to_download = train_image_paths + val_image_paths
progress = sly.Progress("Downloading images...")
for batch_ids, batch_paths in sly.batched(zip(ids_to_download, paths_to_download)):
for batch_ids, batch_paths in zip(
sly.batched(ids_to_download), sly.batched(paths_to_download)
):
with Timer("Images downloading", len(batch_ids)):
coro = api.image.download_paths_async(
batch_ids, batch_paths, progress_cb=progress.iters_done_report
Expand Down
10 changes: 4 additions & 6 deletions src/modal.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,15 +9,13 @@
title="Process shapes"
description="Select how to process shapes that are not supported by the current application."
>
<div>
<div style="margin-top: 1em;">
<el-radio-group v-model="state.processShapes" size="normal">
<div>
<el-radio label="transform">
<span>transform to Rectangle (bbox)</span></el-radio
>
<div style="margin-top: 1em;">
<el-radio label="skip"><span>Skip objects of unsupported geometries</span></el-radio>
</div>
<div>
<el-radio label="skip"><span>skip</span></el-radio>
<el-radio label="transform"><span>Transform shapes to Rectangle (bbox)</span></el-radio>
</div>
</el-radio-group>
</div>
Expand Down

0 comments on commit 2f9a044

Please sign in to comment.