Got it

Mindspore C++ Development issues

Created: Sep 22, 2021 17:58:06Latest reply: Oct 25, 2021 10:44:15 655 16 2 0 0
  HiCoins as reward: 1 (problem unresolved)

Hello, everyone.


I uploaded the MindSpore repository from the official github repository. I use tag r1.3 due to some (and I don't think I can switch to the later or earlier versions).

I am using Ubuntu 18. I prepared the virtual environment according to the official instructions and even checked that MindSpore Python library works fine in the installed virtual environment.


If I build the project, using the build.sh file, it successfully yields a python package with *.whl extension.


All that points out that the standard installation works as intended.


The issues occur when I try to prepare my C++ IDE for development. I use CLion (JetBrains).

  1. The first issue is that there is no C++ development guides. It is actually my first time working with such a large-scale C++ project, so it really makes me feel a little bit overwhelmed.

  2. The second issue is that the success of the CMake execution somehow depends on the actual path to the output directory. (right now it functions only if the output directory set to (root)/build/mindspore)

  3. And the main issue is the coverage of the CMakeList(s). Some *.c, *.cc files from the ccsrc and core folders are not included by the CMakeList(s). And I cannot figure out if it works as intended or not. Moreover, some files like "onnx.pb.h" are missing from the original repository, so I cannot work with onnx_exporter.cc. And developing the onnx exporter is like super important to me.


onnx exported missing source


Can anyone, please, help me with some advice, about how should I approach the C++ development for the MindSpore. What IDE do people usually use for MindSpore?


I would really appreciate if someone could point out some c++ developer guide for MindSpore.


Thank you in advance,

Andrey.  


Featured Answers

Recommended answer

user_4147187
MVE Created Sep 23, 2021 12:16:11

Hello, I would like to add a method, can you try using absolute path reference?
thank you
View more
  • x
  • convention:

denisovap2013
denisovap2013 Created Sep 23, 2021 18:01:48 (0) (0)
Hello.

I'm not sure what you mean by the "absolute path reference". If you mean the path to the onnx source files, I'm afraid there are no such files in the MindSpore repository to begin with. I wonder how it even builds using the provided ./build.sh script.  
PanchakS
PanchakS Created Sep 25, 2021 02:30:59 (0) (0)
 
user_4147187
user_4147187 Reply denisovap2013  Created Sep 28, 2021 01:49:47 (0) (0)
https://gitee.com/mindspore/mindspore/pulls/9117/files
I found this one. I hope you can refer to it.  
denisovap2013
denisovap2013 Reply user_4147187  Created Sep 30, 2021 17:01:47 (0) (0)
Thank you for your answer.

I actually also found a lot of PRs, where the C++ code is modified. But it realy works if the IDE is setup well.
As far as I manage to get, my IDE (CLion) cannot correctly parse all the CMakeList.txt files. The thing that is missing is the actual instructions for the C++ programmers, which want to contribute to the MindSpore framework.  
All Answers
Hello! Thank you for contacting us.
We are working on an answer for you.
View more
  • x
  • convention:

denisovap2013
denisovap2013 Created Sep 30, 2021 17:05:27 (1) (0)
Hello!

I'm not sure this problem can be resolved here.
Is there a special forum, where I can ask this question to Mindspore C++ developers from the Huawei team?
I would really appreciate your help. Thanks in advance!  
AndresMoreno
AndresMoreno Reply denisovap2013  Created Sep 30, 2021 17:21:32 (0) (0)
You can contact Technical support in the official Website using Live Chat or Mail:

https://e.huawei.com/en/products/cloud-computing-dc/atlas/mindspore  
amr_rashedy
amr_rashedy MVE Author Created Sep 22, 2021 20:59:17

The following link has full-stack solution and introduces the position of MindSpore in the solution. Developers who are interested in MindSpore


https://www.mindspore.cn/tutorials/en/r1.3/introduction.html
View more
  • x
  • convention:

denisovap2013
denisovap2013 Created Sep 23, 2021 02:49:37 (0) (0)
Thank you, for your answer. But I am afraid that the lnk you provided leads to the default MindSpore introduction page for Python ML/DL developers, which does not cover any of the issues I mentioned.  
user_4397771
user_4397771 Created Sep 23, 2021 03:14:42 (0) (0)
 
PanchakS
PanchakS Created Sep 25, 2021 02:30:54 (0) (0)
 
Note
View more
  • x
  • convention:

Hello, I would like to add a method, can you try using absolute path reference?
thank you
View more
  • x
  • convention:

denisovap2013
denisovap2013 Created Sep 23, 2021 18:01:48 (0) (0)
Hello.

I'm not sure what you mean by the "absolute path reference". If you mean the path to the onnx source files, I'm afraid there are no such files in the MindSpore repository to begin with. I wonder how it even builds using the provided ./build.sh script.  
PanchakS
PanchakS Created Sep 25, 2021 02:30:59 (0) (0)
 
user_4147187
user_4147187 Reply denisovap2013  Created Sep 28, 2021 01:49:47 (0) (0)
https://gitee.com/mindspore/mindspore/pulls/9117/files
I found this one. I hope you can refer to it.  
denisovap2013
denisovap2013 Reply user_4147187  Created Sep 30, 2021 17:01:47 (0) (0)
Thank you for your answer.

I actually also found a lot of PRs, where the C++ code is modified. But it realy works if the IDE is setup well.
As far as I manage to get, my IDE (CLion) cannot correctly parse all the CMakeList.txt files. The thing that is missing is the actual instructions for the C++ programmers, which want to contribute to the MindSpore framework.  
good
View more
  • x
  • convention:

MahMush
MahMush Moderator Author Created Oct 25, 2021 05:19:42

good
View more
  • x
  • convention:

Good answer
View more
  • x
  • convention:

Comment

You need to log in to comment to the post Login | Register
Comment

Notice: To protect the legitimate rights and interests of you, the community, and third parties, do not release content that may bring legal risks to all parties, including but are not limited to the following:
  • Politically sensitive content
  • Content concerning pornography, gambling, and drug abuse
  • Content that may disclose or infringe upon others ' commercial secrets, intellectual properties, including trade marks, copyrights, and patents, and personal privacy
Do not share your account and password with others. All operations performed using your account will be regarded as your own actions and all consequences arising therefrom will be borne by you. For details, see " User Agreement."

My Followers

Login and enjoy all the member benefits

Login

Block
Are you sure to block this user?
Users on your blacklist cannot comment on your post,cannot mention you, cannot send you private messages.
Reminder
Please bind your phone number to obtain invitation bonus.