Comments (4)
batch_size: 64 #设定batch_size的值即为迭代一次送入网络的图片数量,一般显卡显存越大,batch_size的值可以越大。如果使用多卡训练,总得batch size等于该batch size乘以卡数。
iters: 10000 #模型训练迭代的轮数
train_dataset: #训练数据设置
type: Dataset #指定加载数据集的类。数据集类的代码在PaddleSeg/paddleseg/datasets
目录下。
dataset_root: /home/aistudio/data/carlane/
train_path: /home/aistudio/data/carlane/train_list.txt #数据集中用于训练的标识文件
num_classes: 7 #指定类别个数(背景也算为一类)
mode: train #表示用于训练
transforms:
- type: ResizeStepScaling
min_scale_factor: 0.5
max_scale_factor: 2.0
scale_step_size: 0.25
- type: RandomPaddingCrop
crop_size: [512, 512]
- type: RandomHorizontalFlip
- type: RandomDistort
brightness_range: 0.5
contrast_range: 0.5
saturation_range: 0.5
- type: Normalize
mode: train
val_dataset: #验证数据设置
type: Dataset #指定加载数据集的类。数据集类的代码在PaddleSeg/paddleseg/datasets
目录下。
dataset_root: /home/aistudio/data/carlane/ #数据集路径
val_path: /home/aistudio/data/carlane/val_list.txt #数据集中用于验证的标识文件
num_classes: 7 #指定类别个数(背景也算为一类)
mode: val #表示用于验证
transforms: #模型验证的数据预处理的方式
- type: Normalize #对原始图像进行归一化,标注图像保持不变
optimizer:
type: AdamW
weight_decay: 0.01
lr_scheduler:
type: PolynomialDecay
learning_rate: 0.01
end_lr: 0
power: 0.9
loss:
types:
- type: OhemCrossEntropyLoss
min_kept: 130000 # batch_size * 1024 * 512 // 16
- type: OhemCrossEntropyLoss
min_kept: 130000
- type: OhemCrossEntropyLoss
min_kept: 130000
coef: [1, 1, 1]
model:
type: PPLiteSeg
num_classes: 7
backbone:
type: STDC1
pretrained: https://bj.bcebos.com/paddleseg/dygraph/PP_STDCNet1.tar.gz
arm_out_chs: [32, 64, 128]
seg_head_inter_chs: [32, 64, 64]
这个是 在paddleseg 上训练的yml
from paddle2onnx.
! python tools/export.py
--config ../DeeplabV3.yml
--model_path output/iter_100/model.pdparams
--input_shape -1 3 512 512
!paddle2onnx --model_dir ./output/inference_model/
--model_filename model.pdmodel
--params_filename model.pdiparams
--save_file segonnx/model.onnx
--opset_version 12
--enable_dev_version True
!python -m paddle2onnx.optimize --input_model segonnx/model.onnx
--output_model segonnx/PP_seg.onnx
--input_shape_dict "{'x':[1,3,512,512]}"
from paddle2onnx.
这个是输出paddle 输出的模型也是固定的shape最后输出还是有问题
from paddle2onnx.
请问解决了吗
from paddle2onnx.
Related Issues (20)
- 将apollo-model-centerpoint训练的模型转onnx时,报算子不支持的问题 HOT 1
- custom_ops映射使用问题 HOT 7
- unsupported ops: conditional_block,select_input,tril_triu HOT 1
- 量化paddle模型后通过Paddle2Onnx导出onnx存在的问题 HOT 29
- 能否指定 IR representation的版本 HOT 18
- 量化的飞桨模型部署正常,但是转化为onnx模型出现问题(非量化的模型转为onnx可以正常部署) HOT 3
- 编译Paddle2ONNX出现报错 HOT 2
- 请问如何将onnx的输入的batch size 固定为1,现在是动态输入的batch size HOT 1
- Paddle2ONNX New and Upgraded Plan HOT 6
- ModuleNotFoundError: No module named 'paddle2onnx_cpp2py_export' HOT 8
- 转换成onnx后使用netron可视化尺寸不是-1而是p2o.DynamicDimension.0-5 HOT 2
- 希望提供C API HOT 3
- Test tool bug : onnxbase.py does not support "tensorlist" as input when testing operators HOT 1
- [Split] operators bug : In ONNX opset version 18, there is a bug when inferring models with the [Split] operator. HOT 1
- depthwise_conv2d, this model cannot be exported to ONNX. HOT 4
- paddleocr DBnet 转成onnx 后 reshape2 丢了 HOT 1
- 某计算设备支持的ReduceProd算子与P2O支持的ReduceProd算子不兼容
- 模型推理报错:Greater OP 的输入参数(bitwise_and_5.tmp_0)的类型'tensor(bool)'无效。
- UIE多输入转onnx后输入结构与原模型不符 HOT 1
- Paddle OCR 推理模型转ONNX,固定shape后,ONNX结果相差很大,不固定shape,结果与paddle推理模型保持一致 HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from paddle2onnx.