Cette référence de plate-forme RKNN2 V2.5.0 aide les développeurs ArmSoM à sélectionner et adapter les modèles. Il n’établit pas de support sur chaque carte ArmSoM: vérifier la carte SoC, Toolkit2, Runtime, pilote NPU et versions BSP. La source ne spécifie aucune version universelle du noyau Linux. Aucune validation matérielle ArmSoM n’a été effectuée.
Source: RKNN2 chinois et anglais, respectivement, pour les opérateurs et les contraintes. Le chinois suit l’édition chinoise; l’anglais, le russe et l’allemand suivent l’édition anglaise. Les contraintes liées à la plate-forme demeurent distinctes. Le PDF anglais contient des chiffres d’entrées-sorties et des tableaux de sortie chinois; leur provenance est conservée avec des tableaux localisés modifiables. Les orthographes sources comme ConvTranpose et les équations LSTM/GRU originales sont conservées; ces équations ne sont pas des corrections aux implémentations SDK.
Pages sources: CN 332-343; EN 341-353.
Série de référence de l'opérateur
RKNN2 V2.5.0 · RK3566/RK3568: Bases et convolution
RKNN2 V2.5.0 · RK3566/RK3568:Réseaux renouvelables, arithmétiques et mise en commun
RKNN2 V2.5.0 · RK3566/RK3568: Formes, slices et transposes
RKNN2 V2.5.0 · RK3566/RK3568:Activités, normalisation et extensions
RKNN2 V2.5.0 · RK3588: Bases et convolution
RKNN2 V2.5.0 · RK3588:Réseaux renouvelables, arithmétiques et mise en commun
RKNN2 V2.5.0 · RK3588: Formes, slices et transposes
RKNN2 V2.5.0 · RK3588:Activités, normalisation et extensions
RKNN2 V2.5.0 · RK3562: Bases et convolution
RKNN2 V2.5.0 · RK3562:Réseaux renouvelables, arithmétiques et mise en commun
RKNN2 V2.5.0 · RK3562: Formes, slices et transposes
RKNN2 V2.5.0 · RK3562:Activités, normalisation et extensions
RKNN2 V2.5.0 · RV1103/RV1106: Bases et convolution
RKNN2 V2.5.0 · RV1103/RV1106:Réseaux renouvelables, arithmétiques et mise en commun
RKNN2 V2.5.0 · RV1103/RV1106: Formes, slices et transposes
RKNN2 V2.5.0 · RV1103/RV1106:Activités, normalisation et extensions
RKNN2 V2.5.0 · RK3576/RV1126B: Bases et convolution
RKNN2 V2.5.0 · RK3576/RV1126B:Réseaux renouvelables, arithmétiques et mise en commun
RKNN2 V2.5.0 · RK3576/RV1126B: Formes, slices et transposes
RKNN2 V2.5.0 · RK3576/RV1126B:Activités, normalisation et extensions
RKNN2 V2.5.0 · RK2118: Bases et convolution
RKNN2 V2.5.0 · RK2118:Réseaux renouvelables, arithmétiques et mise en commun
RKNN2 V2.5.0 · RK2118: Formes, slices et transposes
RKNN2 V2.5.0 · RK2118:Activités, normalisation et extensions
RKNN2 V2.5.0 · RV1103B/RV1106B: Bases et convolution
RKNN2 V2.5.0 · RV1103B/RV1106B:Réseaux renouvelables, arithmétiques et mise en commun
RKNN2 V2.5.0 · RV1103B/RV1106B: Formes, slices et transpos
RKNN2 V2.5.0 · RV1103B/RV1106B:Activités, normalisation et extensions
RKNN2 V2.5.0 · Prise en charge et contraintes de l’opérateur CPU
RKNN2 V2.5.0 · Support et contraintes de l’opérateur GPU
RKNN2 V2.5.0 · Modèle I/O, limites d’alignement et de convolution
Relu
Définit les valeurs négatives du tenseur d’entrée à zéro, en maintenant les valeurs positives inchangées
Entrées
- entrée:T1
- shape:[batch,channel,height,width]
- Quantization support
- per-layer
- Broadcasting support
- None
Produits
- sortie:T1
- shape:[batch,channel,height,width]
- Quantization support
- per-layer
Type de données Contraintes
- T1:int8(Teneur)
Autres services d ‘ appui
- Multi-core : Pas encore pris en charge
Clip/ReLU6
Copie les valeurs du tenseur d’entrée vers la plage [0,6]
Entrées
- entrée:T1
- shape:[batch,channel,height,width]
- Quantization support
- per-layer
- Broadcasting support
- None
Produits
- sortie:T1
- shape:[batch,channel,height,width]
- Quantization support
- per-layer
Type de données Contraintes
- T1:int8(Teneur)
Autres services d ‘ appui
- Multi-core : Pas encore pris en charge
PRelu
Échelle les valeurs négatives du tenseur d’entrée par un paramètre apprenant, en maintenant des valeurs positives inchangées
Entrées
- entrée:T1
- shape:[batch,channel,height,width]
- Quantization support
- per-layer/per-channel
- Broadcasting support
- None
Produits
- sortie:T1
- shape:[batch,channel,height,width]
- Quantization support
- per-layer/per-channel
Attributs
- pente: coefficient de PRelu
- Only a single scalar or C-dimension coefficients are supported
Type de données Contraintes
- T1:int8(Teneur)
Autres services d ‘ appui
- Multi-core : Pas encore pris en charge
Fuite
Échelle les valeurs négatives du tenseur d’entrée par un rapport fixe, en maintenant les valeurs positives inchangées
Entrées
- entrée:T1
- shape:[batch,channel,height,width]
- Quantization support
- per-layer
- Broadcasting support
- None
Produits
- sortie:T1
- shape:[batch,channel,height,width]
- Quantization support
- per-layer
Type de données Contraintes
- T1:int8(Teneur)
Autres services d ‘ appui
- Multi-core : Pas encore pris en charge
Remodeler
Renvoie un tenseur avec la forme spécifiée sans changer les données d’entrée ou le nombre d’éléments.
Entrées
- entrée:T1
- shape:[batch,channel,height,width]
- Quantization support
- per-layer
Produits
- sortie:T1
- shape:[batch,channel,height,width]
- Quantization support
- per-layer
Type de données Contraintes
- T1:int8(Teneur)
Attributs
- forme:int
- Specifies the shape of the output tensor
Autres services d ‘ appui
- Multi-core : Pas encore pris en charge
Redimensionner
Redimensionne le tenseur d’entrée. En général, il calcule chaque valeur dans le tenseur de sortie comme une moyenne pondérée des valeurs de tenseur d’entrée dans le voisinage (c.-à-d., les emplacements d’échantillonnage) de la position correspondante
Entrées
- X:T1
- shape:[batch,channel,height,width]
- Quantization support
- per-layer
- (facultatif):T2
- Currently not supported
- échelles (facultative):T2
- The array of scale factors along each dimension
- tailles(facultatif):T3
- The target size of the output tensor
Produits
- Y:T1
- shape:[batch,channel,height,width]
- Quantization support
- per-layer
Type de données Contraintes
- T1:int8(Teneur)
- T2:flux(Teneur)
- T3:int64(Teneur)
Attributs
- antialias: int (valeur par défaut 0)
- Currently not supported to set
- les axes:int[]
- Currently not supported to set
- coordin_transformation_mode: chaînes (valeur par défaut “mi-_pixel”)
- Currently only half_pixel, pytorch_half_pixel, and align_corners are supported
- cubic_coeff_a: flotteur (par défaut -0,75)
- Currently not supported to set
- exclusion_hors-tout: int (valeur par défaut 0)
- Currently not supported to set
- extrapolation_value: flotteur (par défaut 0)
- Currently not supported to set
- keep_aspect_ratio_policy: chaînes (valeur par défaut “stret”)
- Currently not supported to set
- mode: chaînes (valeur par défaut “nearest”)
- Currently only nearest and linear are configurable
- mode__ le plus proche: chaînes (valeur par défaut “round_prefer_floor”)
- Currently not supported to set Support Note Currently only integer scaling in width/height direction is supported, and the scale factor must be an integer multiple of 2-8. If the input is (1,c,1,1), it can be scaled up to (1,c,h,w)
Tranche
Obtient une tranche du vecteur actuel, avec les mêmes règles que le slice numpy
Entrées
- input_tensor:T
- shape:[batch,channel,height,width]
- Quantization support
- per-layer
Produits
- sortie :T
- shape:[batch,channel,height,width]
- Quantization support
- per-layer
Type de données Contraintes
- T:int8(Teneur)
Attributs
- commence:int(Teneur)
- The start position of the split: No limitation
- fin:int(Teneur)
- The end position of the split: No limitation
- axes:int(Teneur)
- The axis to split: any axis 0~3 is supported, and multiple axes can be selected simultaneously
- étapes:int(Teneur)
- The step size of the corresponding axis for splitting
- When height*width==1&&channel%subc==0&&starts[1]%subc==0&&ends[1]% when subc==0&&steps[1]<=subc, steps can be other than 1; otherwise, Slice OP can only run on the NPU when steps==[1,1,1,1]
Souplemax
Cet opérateur calcule la valeur exponentielle normalisée de l’entrée donnée:
Softmax(entrée, axe) = exp(entrée − max(entrée, axe)) / –axe exp(entrée − max(entrée, axe))
L’attribut « axe » indique la dimension à laquelle Softmax est exécuté. Le tenseur de sortie a la même forme et contient les valeurs Softmax de l’entrée correspondante.
Entrées
- entrée:T1
- shape:[batch,channel,height,width]
- Subject to the transpose specification constraints
- shape:[batch,channel,height,width]
Produits
- sortie:T1
- shape:[batch,channel,height,width]
Type de données Contraintes
- T1:int8(Teneur)
Attributs
- axe:int64
- The axis for softmax: 1,3, i.e., channel and width directions
exSoftmax13
Cet opérateur calcule la valeur exponentielle normalisée de l’entrée donnée:
exSoftmax13(entrée, axe) = exp(entrée − max(entrée, axe)) / –axe exp(entrée − max(entrée, axe))
L’attribut « axe » indique la dimension à laquelle Softmax est exécuté. Le tenseur de sortie a la même forme et contient les valeurs Softmax de l’entrée correspondante.
Entrées
- entrée:T1
- shape:[batch,channel,height,width]
- Subject to the transpose specification constraints
- shape:[batch,channel,height,width]
Produits
- sortie:T1
- shape:[batch,channel,height,width]
Type de données Contraintes
- T1:int8(Teneur)
Attributs
- axe:int64
- The axis for softmax: 1,3, i.e., channel and width directions
exSoftmaxMask
- Pas encore pris en charge
Séparer
Sépare le vecteur en vecteurs num_outputs le long de la direction de l’axe. split spécifie la taille de chaque vecteur fractionné le long de l’axe
Entrées
- input_tensor:T
- shape:[batch,channel,height,width]
- Quantization support
- per-layer
Produits
- sortie :T
- One or more output vectors, determined by the num_outputs attribute
- shape: determined by the splitting situation
- Quantization support
- per-layer
Type de données Contraintes
- T:int8(Teneur)
Attributs
- axe:int
- axis∈{0,1,2,3}
- _sorties:int
- Fendue:int(Teneur)
Sous-programme
- Effectue la soustraction binaire par élément (C=A-B), supportant la radiodiffusion multidirectionnelle de style NumPy
Entrées
- A:T1,T2
- shape:[batch,channel,height,width]
- Quantization support
- per-layer
- Broadcasting support
- [b,c,1,1]
- [scalar]
- B:T1,T2
- shape:[batch,channel,height,width]
- Quantization support
- per-layer
- Broadcasting support
- [b,c,1,1]
- [scalar]
Produits
- C:T1
- shape:[batch,channel,height,width]
- Quantization support
- per-layer
Type de données Contraintes
- T1:int8(Teneur)
- T2: flocons(constTensor)
Tuile
Construit un tenseur en dormant un tenseur donné. C’est la même chose que la fonction de tuile dans Numpy, mais sans radiodiffusion
Entrées
- entrée:T1
- shape:[batch,channel,height,width]
- Quantization support
- per-layer
- répéter:T2
- shape:[batch,channel,height,width]
Produits
- sortie:T1
- shape:[batch,channel,height,width]
- Quantization support
- per-layer
Type de données Contraintes
- T1:int8(Tensor), flocons16(Tensor)
- T2:int64(Teneur)
Transpose
Transpose le tenseur d’entrée
Entrées
- X:T1
- shape:[n1,c1,h1,w1]
- See Attributes for detailed constraint rules
- Quantization support
- per-layer
- shape:[n1,c1,h1,w1]
Produits
- Y:T1,T2
- shape:[n2,c2,h2,w2]
- See Attributes for detailed constraint rules
- Quantization support
- per-layer
- shape:[n2,c2,h2,w2]
Attributs
- L’ordre de l’axe de la perm transpose: Les restrictions des paramètres de perm sont les suivantes: (où p=268435456, q=65536)
- perm=[0,1,2,3]
- No limitation
- perm=[0,1,3,2]
- T1:h1%16=0,h1w1<16p,h1w1<2q
- T2:h1%8=0,h1w1<8p,h1w1<2q
- perm=[0,2,3,1]
- T1:c1<8192,h1w1%8=0,w1c1<p*16
- T2:c1<8192,h1w1%8=0,w1c1<p*8
- perm=[0,2,1,3]
- T1:h1%16=0,h1w1<16p,h1w1<2q,c1*w1<p
- T2:h1%8=0,h1w1<8p,h1w1<2q,c1*w1<p
- perm=[0,3,1,2]
- T1,T2:h1w1<p,w1<8192,h1c1<p
- perm=[0,3,2,1]
- T1:h1%16=0,h1w1<16p,h1w1<2q,c1<p*16
- T2:h1%8=0,h1w1<8p,h1w1<2q,c1<p*8
- perm=[1,0,2,3]
- T1:h1w1<16p,n1<8192,h1*w1<p
- T2:h1w1<8p,n1<8192,h1*w1<p
- perm=[1,0,3,2]
- T1:h1%16=0,c1h1w1<16p,h1w1<2*q
- T2:h1%8=0,c1h1w1<8p,h1w1<2*q
- perm=[1,2,0,3]
- T1:n1w1<p16,c1h1w1<p,w1%16=0
- T2:n1w1<p8,c1h1w1p,w1%8=0
- perm=[1,2,3,0]
- T1:h1w1<p,n1<p16,c1h1w1<p16,n1w1<p*16
- T2:h1w1<p,n1<p8,c1h1w1<p8,n1w1<p*8
- perm=[1,3,0,2]
- T1:c1w1<8192,n1h1<p,w1%16=0
- T2:c1w1<8192,n1h1<p,w1%8=0
- perm=[1,3,2,0]
- T1:c1h1w1<p,n1*h1<p,w1<8192,w1%16=0
- T2:c1h1w1<p,n1*h1<p,w1<8192,w1%8=0
- perm=[2,1,0,3]
- T1,T2:c1<8192,c1h1w1<p,n1*w1<p
- perm=[2,1,3,0]
- T1:c1h1w1<p,n1w1<p16,c1<8192,n1*w1%4=0
- T2:c1h1w1<p,n1w1<p8,c1<8192,n1*w1%4=0
- perm=[2,0,3,1]
- T1,T2:c1<8192,c1h1w1<p
- perm=[2,0,1,3]
- T1:n1c1h1w1<p,h1w1%16=0
- T2:n1c1h1w1<p,h1w1%8=0
- perm=[2,3,1,0]
- T1:c1h1w1<p,n1c1<p,h1w1<8192,h1*w1%16=0
- T2:c1h1w1<p,n1c1<p,h1w1<8192,h1*w1%8=0
- perm=[2,3,0,1]
- T1,T2:h1w1<8192,n1c1<p
- perm=[3,0,2,1]
- T1:h1w1<p,n1c1<8192,c1h1<p,n1w1<8192,n1*w1%16=0
- T2:h1w1<p,n1c1<8192,c1h1<p,n1w1<8192,n1*w1%8=0
- perm=[3,0,1,2]
- T1:h1w1<p,n1c1<8192,c1h1<p,n1w1<8192,n1h1w1%16=0
- T2:h1w1<p,n1c1<8192,c1h1<p,n1w1<8192,n1h1w1%8=0
- perm=[3,2,0,1]
- T1,T2:h1w1<p,n1c1<8192,n1c1w1<p
- perm=[3,2,1,0]
- T1:c1h1w1<p,h1w1<8192,2h1w1<q,n1c1<p*16,h1%16=0
- T2:c1h1w1<p,h1w1<8192,2h1w1<q,n1c1<p*8,h1%8=0
- perm=[3,1,0,2]
- T1,T2:h1w1<p,c1w1<8192,n1*h1<p
- perm=[3,1,2,0]
- T1,T2:h1w1<p,n1c1<8192,n1h1<p,n1c1*w1<p
- perm=[0,1,2,3]
Type de données Contraintes
- T1:int8(Teneur)
- T2:int16(Teneur)
Autres services d ‘ appui
- Multi-core : Pas encore pris en charge
