---
title: 执行proto合并时提示ERROR信息-昇腾社区
description: (待补充)
keywords: proto
url: https://www.hiascend.com/document/caselibrary/detail/atlasamct_16_0374
section: (其他)
---

# 执行proto合并时提示ERROR信息-昇腾社区

URL: https://www.hiascend.com/document/caselibrary/detail/atlasamct_16_0374
描述: (待补充)
关键词: proto

昇腾文档 [了解详情](https://www.hiascend.com/document)

故障案例 [了解详情](https://www.hiascend.com/document/caselibrary)

执行proto合并时提示ERROR信息

执行proto合并时提示ERROR信息

2025/04/17

473

问题信息

| 问题来源 | 产品大类 | 产品子类 | 关键字 |
| --- | --- | --- | ---|
| 官方 | 应用开发 | CANN | proto |

#### 问题现象描述1：用户message定义和AMCT自定义层冲突

用户自定义custom.proto内容如下，其中定义的QuantParameter层信息与amct_custom.proto中定义的重复：

```
message LayerParameter {
  optional QuantParameter quant_param = 208;
  optional ReLU6Parameter relu6_param = 1000000;
  optional ROIPoolingParameter roi_pooling_param = 8266711;
}

message ReLU6Parameter {
  optional float negative_slope = 1 [default = 0];
}

message ROIPoolingParameter {
  // Pad, kernel size, and stride are all given as a single value for equal
  // dimensions in height and width or as Y, X pairs.
  optional uint32 pooled_h = 1 [default = 0]; // The pooled output height
  optional uint32 pooled_w = 2 [default = 0]; // The pooled output width
  // Multiplicative spatial scale factor to translate ROI coords from their
  // input scale to the scale used when pooling
  optional float spatial_scale = 3 [default = 1];
}

message QuantParameter {  
  optional bool with_offset = 1;
  optional float scale = 2;
  optional bytes offset = 3;
  optional string object_layer = 4;
}
```

执行proto合并时报错信息如下：

#### 解决措施1

根据提示信息，用户自行修改自定义的message信息。

#### 问题现象描述2：用户自定义在LayerParameter中编号和AMCT编号冲突

用户自定义custom.proto内容如下，其中定义的LayerParameter编号与amct_custom.proto中编号重复：

```
message LayerParameter {
  optional QuantParameter quant_param = 208;
  optional ReLU6Parameter relu6_param = 1000000;
  optional ROIPoolingParameter roi_pooling_param = 8266711;
}

message ReLU6Parameter {
  optional float negative_slope = 1 [default = 0];
}

message ROIPoolingParameter {
  // Pad, kernel size, and stride are all given as a single value for equal
  // dimensions in height and width or as Y, X pairs.
  optional uint32 pooled_h = 1 [default = 0]; // The pooled output height
  optional uint32 pooled_w = 2 [default = 0]; // The pooled output width
  // Multiplicative spatial scale factor to translate ROI coords from their
  // input scale to the scale used when pooling
  optional float spatial_scale = 3 [default = 1];
}
```

执行proto合并时报错信息如下：

#### 解决措施2

用户根据提示信息修改custom.proto中自定义的算子编号。

#### 问题现象描述3：用户自定义在LayerParameter中编号和ATC编号冲突

用户自定义custom.proto内容如下，其中定义的LayerParameter编号与ATC中的caffe.proto中编号重复：

```
message LayerParameter {
  optional ReLU6Parameter relu6_param = 206;
  optional ROIPoolingParameter roi_pooling_param = 8266711;
}

message ReLU6Parameter {
  optional float negative_slope = 1 [default = 0];
}

message ROIPoolingParameter {
  // Pad, kernel size, and stride are all given as a single value for equal
  // dimensions in height and width or as Y, X pairs.
  optional uint32 pooled_h = 1 [default = 0]; // The pooled output height
  optional uint32 pooled_w = 2 [default = 0]; // The pooled output width
  // Multiplicative spatial scale factor to translate ROI coords from their
  // input scale to the scale used when pooling
  optional float spatial_scale = 3 [default = 1];
}
```

执行proto合并时报错信息如下：

#### 解决措施3

用户根据提示信息修改custom.proto中自定义的算子编号。

#### 问题现象描述4：用户message定义和ATC自定义层冲突

用户自定义custom.proto内容如下，其中定义的NormalizeParameter层信息与caffe.proto中定义的重复：

```
message LayerParameter {
  optional ReLU6Parameter relu6_param = 1000000;
  optional ROIPoolingParameter roi_pooling_param = 8266711;
  optional NormalizeParameter norm_param = 206; 
}

message ReLU6Parameter {
  optional float negative_slope = 1 [default = 0];
}

message ROIPoolingParameter {
  // Pad, kernel size, and stride are all given as a single value for equal
  // dimensions in height and width or as Y, X pairs.
  optional uint32 pooled_h = 1 [default = 0]; // The pooled output height
  optional uint32 pooled_w = 2 [default = 0]; // The pooled output width
  // Multiplicative spatial scale factor to translate ROI coords from their
  // input scale to the scale used when pooling
  optional float spatial_scale = 3 [default = 1];
}
message NormalizeParameter {  
    optional bool across_spatial = 1 [default = true];  
    // Initial value of scale. Default is 1.0 for all  
    optional FillerParameter scale_filler = 2;  
    // Whether or not scale parameters are shared across channels.  
    optional bool channel_shared = 3 [default = true];  
    // Epsilon for not dividing by zero while normalizing variance  
    optional float eps = 4 [default = 1e-10]; 
}
```

执行proto合并时无错误提示信息，默认会覆盖ATC内置message定义，以custom.proto为准，提示信息如下：

#### 解决措施4

无。

本页内容

- 问题信息
- 问题现象描述1：用户message定义和AMCT自定义层冲突
- 解决措施1
- 问题现象描述2：用户自定义在LayerParameter中编号和AMCT编号冲突
- 解决措施2
- 问题现象描述3：用户自定义在LayerParameter中编号和ATC编号冲突
- 解决措施3
- 问题现象描述4：用户message定义和ATC自定义层冲突
- 解决措施4
