热门标签 | HotTags
当前位置:  开发笔记 > 编程语言 > 正文

ProbleminconvertingssdinceptionmodelfrommxnettoIR.

Platform(likeubuntu16.04):Pythonversion:2.7.12Sourceframeworkwithv

Platform (like ubuntu 16.04):

Python version: 2.7.12

Source framework with version: MXNET 1.0.0 with GPU

Destination framework with version: Tensorflow 1.4.1 with GPU

I was able to convert InceptionV3 (mxnet) to IR but I encounter a problem when I try to convert ssd InceptionV3 model(mxnet).

Running scripts:

1
root:/home/bomo/Desktop# python -m mmdnn.conversion._script.convertToIR -f mxnet -n ssd_inceptionv3_512-symbol.json -d ssd_inceptionv3_512 --inputShape 3 512 512

error:

1
2
3
4
5
6
7
8
9
10
11
12
13
[14:37:20] src/nnvm/legacy_json_util.cc:209: Loading symbol saved by previous version v0.12.0. Attempting to upgrade...

[14:37:20] src/nnvm/legacy_json_util.cc:217: Symbol successfully upgraded!

/mxnet/python/mxnet/module/base_module.py:53: UserWarning: You created Module with Module(..., label_names=['softmax_label']) but input with name 'softmax_label' is not found in symbol.list_arguments(). Did you mean one of:

    data

    label

  warnings.warn(msg)

Warning: MXNet Parser has not supported operator null with name data.

Warning: convert the null operator with name [data] into input layer.

Warning: MXNet Parser has not supported operator null with name label.

Warning: convert the null operator with name [label] into input layer.

[14:37:20] /mxnet/dmlc-core/include/dmlc/./logging.h:308: **[14:37:20] src/c_api/c_api_symbolic.cc:417: InferShapeKeyword argument name data not found.

Candidate arguments:

    [0]label**

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
infer_shape error. Arguments:

  data: (1, 3, 512, 512)

Traceback (most recent call last):

  File "/usr/lib/python2.7/runpy.py", line 174, in _run_module_as_main

    "__main__", fname, loader, pkg_name)

  File "/usr/lib/python2.7/runpy.py", line 72, in _run_code

    exec code in run_globals

  File "/usr/local/lib/python2.7/dist-packages/mmdnn/conversion/_script/convertToIR.py", line 159, in

    _main()

  File "/usr/local/lib/python2.7/dist-packages/mmdnn/conversion/_script/convertToIR.py", line 154, in _main

    ret = _convert(args)

  File "/usr/local/lib/python2.7/dist-packages/mmdnn/conversion/_script/convertToIR.py", line 95, in _convert

    parser.gen_IR()

  File "/usr/local/lib/python2.7/dist-packages/mmdnn/conversion/mxnet/mxnet_parser.py", line 269, in gen_IR

    self.rename_UNKNOWN(current_node)

  File "/usr/local/lib/python2.7/dist-packages/mmdnn/conversion/mxnet/mxnet_parser.py", line 388, in rename_UNKNOWN

    self.set_output_shape(source_node, IR_node)

  File "/usr/local/lib/python2.7/dist-packages/mmdnn/conversion/mxnet/mxnet_parser.py", line 285, in set_output_shape

    arg_shape, output_shape, aux_shape = sym.infer_shape(data = self.data_shape)

  File "/mxnet/python/mxnet/symbol/symbol.py", line 965, in infer_shape

    res = self._infer_shape_impl(False, *args, **kwargs)

  File "/mxnet/python/mxnet/symbol/symbol.py", line 1095, in _infer_shape_impl

    ctypes.byref(complete)))

  File "/mxnet/python/mxnet/base.py", line 146, in check_call

    raise MXNetError(py_str(_LIB.MXGetLastError()))

**mxnet.base.MXNetError: [14:37:20] src/c_api/c_api_symbolic.cc:417: InferShapeKeyword argument name data not found.

Candidate arguments:

    [0]label**

该提问来源于开源项目:microsoft/MMdnn

Hello, were you able to solve this issue?



I have trained a custom yolo3 darknet-53 (using gluon-cv mxnet)
I need to convert the model to tensorflow for final inference.

I am facing the same issue while converting yolo3_darknet-53 mxnet model to IR.




1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
ai-mxnet/lib/python3.6/site-packages/mxnet/module/base_module.py:55: UserWarning: You created Module with Module(..., label_names=['softmax_label']) but input with name 'softmax_label' is not found in symbol.list_arguments(). Did you mean one of:

        data

        _defaultpreprocess0_init_mean

        _defaultpreprocess0_init_scale

        yolov30_yolooutputv30_offset_0

        yolov30_yolooutputv30_anchor_0

        yolov30_yolooutputv31_offset_1

        yolov30_yolooutputv31_anchor_1

        yolov30_yolooutputv32_offset_2

        yolov30_yolooutputv32_anchor_2

  warnings.warn(msg)

Warning: MXNet Parser has not supported operator null with name data.

Warning: convert the null operator with name [data] into input layer.

Warning: MXNet Parser has not supported operator null with name _defaultpreprocess0_init_scale.

Warning: convert the null operator with name [_defaultpreprocess0_init_scale] into input layer.

infer_shape error. Arguments:

  data: (1, 3, 608, 608)

...

call

    raise MXNetError(py_str(_LIB.MXGetLastError()))

mxnet.base.MXNetError: [17:49:07] src/c_api/c_api_symbolic.cc:540: InferShapeKeyword argument name data not found.

Candidate arguments:

        [0]_defaultpreprocess0_init_scale

Thanks!


   



推荐阅读
  • 采用IKE方式建立IPsec安全隧道
    一、【组网和实验环境】按如上的接口ip先作配置,再作ipsec的相关配置,配置文本见文章最后本文实验采用的交换机是H3C模拟器,下载地址如 ... [详细]
  • 深入解析Spring启动过程
    本文详细介绍了Spring框架的启动流程,帮助开发者理解其内部机制。通过具体示例和代码片段,解释了Bean定义、工厂类、读取器以及条件评估等关键概念,使读者能够更全面地掌握Spring的初始化过程。 ... [详细]
  • 2017-2018年度《网络编程与安全》第五次实验报告
    本报告详细记录了2017-2018学年《网络编程与安全》课程第五次实验的具体内容、实验过程、遇到的问题及解决方案。 ... [详细]
  • 烤鸭|本文_Spring之Bean的生命周期详解
    烤鸭|本文_Spring之Bean的生命周期详解 ... [详细]
  • Keras 实战:自编码器入门指南
    本文介绍了使用 Keras 框架实现自编码器的基本方法。自编码器是一种用于无监督学习的神经网络模型,主要功能包括数据降维、特征提取等。通过实际案例,我们将展示如何使用全连接层和卷积层来构建自编码器,并讨论不同维度对重建效果的影响。 ... [详细]
  • 在Win10上利用VS2015构建Caffe2环境
    本文详细介绍如何在Windows 10操作系统上通过Visual Studio 2015编译Caffe2深度学习框架的过程。包括必要的软件安装、环境配置以及常见问题的解决方法。 ... [详细]
  • 在尝试使用C# Windows Forms客户端通过SignalR连接到ASP.NET服务器时,遇到了内部服务器错误(500)。本文将详细探讨问题的原因及解决方案。 ... [详细]
  • This post discusses an issue encountered while using the @name annotation in documentation generation, specifically regarding nested class processing and unexpected output. ... [详细]
  • ElasticSearch 集群监控与优化
    本文详细介绍了如何有效地监控 ElasticSearch 集群,涵盖了关键性能指标、集群健康状况、统计信息以及内存和垃圾回收的监控方法。 ... [详细]
  • thereissomethingstrangeinmycode.Imsuretoforgetsomethingbutidontknowwhat.Itryto ... [详细]
  • 本文探讨了如何利用HTML5和JavaScript在浏览器中进行本地文件的读取和写入操作,并介绍了获取本地文件路径的方法。HTML5提供了一系列API,使得这些操作变得更加简便和安全。 ... [详细]
  • 搭建Jenkins、Ant与TestNG集成环境
    本文详细介绍了如何在Ubuntu 16.04系统上配置Jenkins、Ant和TestNG的集成开发环境,涵盖从安装到配置的具体步骤,并提供了创建Windows Slave节点及项目构建的指南。 ... [详细]
  • 本文将详细探讨 Java 中提供的不可变集合(如 `Collections.unmodifiableXXX`)和同步集合(如 `Collections.synchronizedXXX`)的实现原理及使用方法,帮助开发者更好地理解和应用这些工具。 ... [详细]
  • 软件工程课堂测试2
    要做一个简单的保存网页界面,首先用jsp写出保存界面,本次界面比较简单,首先是三个提示语,后面是三个输入框,然 ... [详细]
  • 本文深入探讨了WebGL与Three.js在构建多样化3D场景中的应用,详细解析了两者如何协同工作以实现高性能的3D渲染,并提供了实践指南。 ... [详细]
author-avatar
红烧大青虫
这个家伙很懒,什么也没留下!
PHP1.CN | 中国最专业的PHP中文社区 | DevBox开发工具箱 | json解析格式化 |PHP资讯 | PHP教程 | 数据库技术 | 服务器技术 | 前端开发技术 | PHP框架 | 开发工具 | 在线工具
Copyright © 1998 - 2020 PHP1.CN. All Rights Reserved | 京公网安备 11010802041100号 | 京ICP备19059560号-4 | PHP1.CN 第一PHP社区 版权所有