Skip to content

Commit d1c2610

Browse files
committed
add layout
1 parent fde079c commit d1c2610

File tree

4 files changed

+43
-4
lines changed

4 files changed

+43
-4
lines changed

configs/cls/mobilenetv3/cls_mv3.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@ eval:
146146
predict:
147147
backend: MindSpore
148148
deive_target: Ascend
149-
device_id: 0
149+
device_id: 1
150150
max_device_memory: 8GB
151151
amp_level: O0
152152
mode: 0

configs/layout/yolov8/yolov8n.yaml

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -151,3 +151,42 @@ eval:
151151
drop_remainder: False
152152
max_rowsize: 12
153153
num_workers: 8
154+
155+
predict:
156+
backend: MindSpore
157+
deive_target: Ascend
158+
device_id: 3
159+
max_device_memory: 8GB
160+
amp_level: O0
161+
mode: 0
162+
ckpt_load_path: /root/.mindspore/models/dbnet_resnet50-c3a4aa24.ckpt
163+
dataset_sink_mode: False
164+
dataset:
165+
type: PublayNetDataset
166+
dataset_path: publaynet/val.txt
167+
annotations_path: *annotations_path
168+
img_size: 800
169+
transform_pipeline:
170+
- func_name: letterbox
171+
scaleup: False
172+
- func_name: label_norm
173+
xyxy2xywh_: True
174+
- func_name: label_pad
175+
padding_size: 160
176+
padding_value: -1
177+
- func_name: image_norm
178+
scale: 255.
179+
- func_name: image_transpose
180+
bgr2rgb: True
181+
hwc2chw: True
182+
batch_size: &refine_batch_size 13
183+
stride: 64
184+
output_columns: ['image', 'labels', 'image_ids', 'hw_ori', 'hw_scale', 'pad']
185+
net_input_column_index: [ 0 ] # input indices for network forward func in output_columns
186+
meta_data_column_index: [ 2, 3, 4, 5 ] # input indices marked as label
187+
loader:
188+
shuffle: False
189+
batch_size: *refine_batch_size
190+
drop_remainder: False
191+
max_rowsize: 12
192+
num_workers: 8

configs/rec/crnn/crnn_resnet34.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ eval:
152152
predict:
153153
backend: MindSpore
154154
deive_target: Ascend
155-
device_id: 0
155+
device_id: 2
156156
max_device_memory: 8GB
157157
amp_level: O3
158158
mode: 0

mindocr/postprocess/det_db_postprocess.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -222,8 +222,8 @@ def __init__(
222222

223223
def __call__(
224224
self,
225-
pred: Union[ms.Tensor, Tuple[ms.Tensor], np.ndarray],
226-
shape_list: Union[np.ndarray, ms.Tensor] = None,
225+
pred: Union[Tensor, Tuple[Tensor], np.ndarray],
226+
shape_list: Union[np.ndarray, Tensor] = None,
227227
**kwargs,
228228
) -> dict:
229229
if isinstance(shape_list, Tensor):

0 commit comments

Comments
 (0)