Skip to content

Commit 223446c

Browse files
committed
style(batch_crop_images): reorder parameters in batch_crop_images
1 parent ae35cf8 commit 223446c

2 files changed

Lines changed: 5 additions & 4 deletions

File tree

‎.gitignore‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,3 +15,4 @@ site/
1515
notebooks/*
1616
tests/test.py
1717
.codegraph/*
18+
.understand-anything/*

‎src/plotfig/brain_connection.py‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -323,21 +323,21 @@ def save_brain_connection_frames(
323323
def batch_crop_images(
324324
directory_path: Path,
325325
suffix: str = "_cropped",
326-
left_frac: float = 0.25,
327326
top_frac: float = 0.25,
328-
right_frac: float = 0.25,
329327
bottom_frac: float = 0.25,
328+
left_frac: float = 0.25,
329+
right_frac: float = 0.25,
330330
):
331331
"""
332332
批量裁剪指定目录下的图像文件。
333333
334334
Args:
335335
directory_path (Path): 图像文件所在的目录路径。
336336
suffix (str, optional): 新文件名后缀。默认为 "_cropped"。
337-
left_frac (float, optional): 左侧裁剪比例(0-1)。默认为 0.2。
338337
top_frac (float, optional): 上侧裁剪比例(0-1)。默认为 0.15。
339-
right_frac (float, optional): 右侧裁剪比例(0-1)。默认为 0.2。
340338
bottom_frac (float, optional): 下侧裁剪比例(0-1)。默认为 0.15。
339+
left_frac (float, optional): 左侧裁剪比例(0-1)。默认为 0.2。
340+
right_frac (float, optional): 右侧裁剪比例(0-1)。默认为 0.2。
341341
342342
Notes:
343343
支持常见图像格式 (PNG, JPG, JPEG, BMP, TIFF)。

0 commit comments

Comments
 (0)