执行export_model.py转换成功后,目录下没有.pdmodel文件 #14295
-
根据 模型导出与预测 中说的应该是如下文件
但是我生成的是
并且使用我生成的文件执行 以下是我的 YAML配置 文件 Global:
debug: false
use_gpu: true
epoch_num: 800
log_smooth_window: 20
print_batch_step: 10
save_model_dir: ./output/v3_en_mobile
save_epoch_step: 10
eval_batch_step: [0, 2000]
cal_metric_during_train: true
pretrained_model: ./pretrain_models/en_PP-OCRv3_rec_train/best_accuracy
checkpoints: # ./output/v3_en_mobile/_checkpoints
save_inference_dir: ./output/_inference/v3_en_mobile/
use_visualdl: false
infer_img: ./train_data/rec/train
infer_list: ./train_data/rec/infer_list.txt
character_dict_path: ppocr/utils/en_dict.txt
max_text_length: &max_text_length 25
infer_mode: false
use_space_char: false
distributed: true
save_res_path: ./output/rec/predicts_ppocrv3_en_v2.txt
Optimizer:
name: Adam
beta1: 0.9
beta2: 0.999
lr:
name: Cosine
learning_rate: 0.0003
warmup_epoch: 5
regularizer:
name: L2
factor: 3.0e-05
Architecture:
model_type: rec
algorithm: SVTR_LCNet
Transform:
Backbone:
name: MobileNetV1Enhance
scale: 0.5
last_conv_stride: [1, 2]
last_pool_type: avg
last_pool_kernel_size: [2, 2]
Head:
name: MultiHead
head_list:
- CTCHead:
Neck:
name: svtr
dims: 64
depth: 2
hidden_dims: 120
use_guide: True
Head:
fc_decay: 0.00001
- SARHead:
enc_dim: 512
max_text_length: *max_text_length
Loss:
name: MultiLoss
loss_config_list:
- CTCLoss:
- SARLoss:
PostProcess:
name: CTCLabelDecode
Metric:
name: RecMetric
main_indicator: acc
ignore_space: False
Train:
dataset:
name: SimpleDataSet
data_dir: ./
ext_op_transform_idx: 1
label_file_list:
- ./train_data/rec/rec_gt_train_resized.txt
transforms:
- DecodeImage:
img_mode: BGR
channel_first: false
- RecConAug:
prob: 0.6
ext_data_num: 2
image_shape: [32, 92, 3]
max_text_length: *max_text_length
- RecAug:
- MultiLabelEncode:
- RecResizeImg:
image_shape: [3, 32, 92]
- KeepKeys:
keep_keys:
- image
- label_ctc
- label_sar
- length
- valid_ratio
loader:
shuffle: true
batch_size_per_card: 108
drop_last: true
num_workers: 4
Eval:
dataset:
name: SimpleDataSet
data_dir: ./
label_file_list:
- ./train_data/rec/rec_gt_test.txt
transforms:
- DecodeImage:
img_mode: BGR
channel_first: false
- MultiLabelEncode:
- RecResizeImg:
image_shape: [3, 32, 92]
- KeepKeys:
keep_keys:
- image
- label_ctc
- label_sar
- length
- valid_ratio
loader:
shuffle: false
drop_last: false
batch_size_per_card: 12
num_workers: 4 |
Beta Was this translation helpful? Give feedback.
Answered by
GreatV
Nov 29, 2024
Replies: 2 comments 4 replies
-
试试 |
Beta Was this translation helpful? Give feedback.
3 replies
Answer selected by
JesuisTong
-
我也遇到这个问题你解决了吗? |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
试试
export FLAGS_enable_pir_api=0