US 11,928,446 B2
Multi-level intermediate representation decoder for heterogeneous platforms
Zhen Peng, Palo Alto, CA (US); Yang Liu, San Jose, CA (US); Hanxian Huang, Palo Alto, CA (US); Yongxiong Ren, San Jose, CA (US); Jishen Yang, Palo Alto, CA (US); Lingzhi Liu, San Jose, CA (US); and Xin Chen, Palo Alto, CA (US)
Assigned to KWAI INC., Palo Alto, CA (US)
Filed by KWAI INC., Palo Alto, CA (US)
Filed on Nov. 11, 2021, as Appl. No. 17/524,619.
Prior Publication US 2023/0143291 A1, May 11, 2023
Int. Cl. G06F 8/41 (2018.01); G06N 3/04 (2023.01); G06N 3/063 (2023.01); G06N 3/08 (2023.01); G06N 3/10 (2006.01)
CPC G06F 8/443 (2013.01) [G06N 3/04 (2013.01); G06N 3/063 (2013.01); G06N 3/08 (2013.01); G06N 3/105 (2013.01)] 18 Claims
OG exemplary drawing
 
1. A method for generating heterogenous platform code comprising:
obtaining a neural network model, wherein the neural network model is programed to run on at least one platform;
obtaining an initial intermediate representation (IR) code by encoding the neural network model, and obtaining a target IR code by adding decorations to the initial IR code based on a target platform; and
outputting an executable code optimized to run on the target platform by decoding the target IR code, wherein outputting the executable code optimized to run on the target platform by decoding the target IR code comprises:
obtaining multiple graph objects based on a scan of the target IR code, and
outputting the executable code based on a traverse of the multiple graph objects.