大家好,我是刘明,明志科技创始人,华为昇思MindSpore布道师。
技术上主攻前端开发、鸿蒙开发和AI算法研究。
努力为大家带来持续的技术分享,如果你也喜欢我的文章,就点个关注吧
Main text begins
华为昇腾CANN训练营2024第二季已经开营了,参加训练营可以免费学习课程、参加认证考试、瓜分万元大奖。
如果还没报名训练营的同学可以点击以下链接报名:
华为昇腾CANN训练营2024第二季报名链接
An important part of the training camp is to take the Ascend C operator development capability certification (intermediate level). I would like to share some experience here for your reference. I hope you can pass the certification smoothly.
Certification Exam Description
Currently, the certification exam only has one programming question, no multiple choice questions or short answer questions.
The following is an introduction to the certification exam questions.
- Exam type: Programming questions
- Exam duration:
The exam time is only 2 hours. Please prepare the question synthesis file package before entering the exam and uploading it!
Key point: You must complete the questions first, then upload them to the exam. It only takes a few seconds to complete the questions and upload them, so 2 hours is not enough.
- 考试环境搭建要求:
环境上要有昇腾NPU,且CANN版本为8.0.RC2.alpha003。请开发者自行准备。
The test environment is not set up during the test. You need to use Orange Pi or Huawei Cloud ModelArts to set it up. The specific construction method will be documented after entering the training camp.
- Exam topic:
Implement the Ascend C operator Sinh, name the operator SinhCustom, write its kernel side code, host side code, and complete the aclnn operator call test.
Related algorithm: sinh(x) = (exp(x) - exp(-x)) / 2.0
Requirements:
4.1 Complete the code completion of the kernel function on the Sinh operator kernel side.
4.2 Complete the creation of the Tiling structure member variables on the Sinh operator host side, and complete the Tiling implementation function.
4.3 Support Float16 type input and output.
4.4 Do not use the Sinh high-level API, and you will not get any points if you use the high-level API .
This is the exam question, the most important part. There is no guarantee that the questions will not change later.
Some small experience
- The certification exam requires a registration fee of 38 yuan, but you can get the certification for free by getting a certification coupon before the exam. The number of coupons is limited and first come first served. If you don't get it, you can wait until next Monday and a new coupon will be added.
- It is recommended to complete the questions before certification and then start the exam. This makes it easier to upload the code directly.
- The exam has 10 chances to answer questions, which is a lot of opportunities. If you want to see what the exam system looks like, you can just click in and waste one chance.
- You can do real-name authentication before or after the exam. If you do it after the exam, you must do it within 10 days after the exam. If you do not do real-name authentication, you will not get a certificate.
- The marking is done manually, so teachers will mark the papers on weekdays. After marking, if the test results are passed, the certificate will be issued the next day. The personal center may show [Failed], which is a system problem, don't worry. It will be fine until the next day.
How to prepare for the exam
The exam requires the implementation of a sinh operator, which is not difficult in itself, but requires a basic understanding of Ascend operator development. It is recommended to study the official website documentation first.
Many students said that the official documentation has too much content and they don’t know which part to read. Let me recommend something directly related to the exam.
So, please go to the following link
Operator Development Based on Custom Operator Engineering
The original code project is provided in the exam. You only need to complete the key code supplement according to the comments in the original project.
The main completed parts include op_host
and op_kernel
. The link I gave above focuses on the functions and some codes of these two parts.