Qualcomm AI Engine Direct: HTP float16 Concat reads a static bool input of all True as False

Abierto
#24,750 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
4/5
Tiempo estimado
3-5 días
Aptitud para principiantes
45/100
Tipo de issue
Error
Claridad
Bastante claro
Estado de actividad
Activo
Stack tecnológico
python

Línea de trabajo

Start with CatBoolConstant in test_qnn_backend_cat and reproduce the reported case on the QNN SDK 2.51 x86 simulator. Compare HTP float16 Concat output with the static bool input and inspect the QNN Saver tensor values. Done means identifying why the constant is read as False and confirming correct output; the issue says the partitioner workaround can then be removed.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

module: qnn partner: qualcomm

In HTP float16, Concat can read a static bool input of all True as False, with
no error:

class CatBoolConstant(torch.nn.Module):
    def forward(self, x, y):
        return torch.cat((x > 0, torch.full((1, 1, 2, 2), True)), axis=3)

On the x86 simulator of QNN SDK 2.51, with a positive x, the part that comes
from the constant comes back as False. QNN Saver shows the static tensor holds
0x01 for every element, so the input given to QNN is right. The wrong result
depends on the shapes and on where the static input is. Quantized graphs, float
and int32 cats, and constants with mixed values come out right. Not checked on a
device yet.

The QNN partitioner now keeps every such bool cat on CPU in HTP float16. That
also moves cats that would come out right, and can split a graph into 2
delegates. CatBoolConstant in test_qnn_backend_cat checks the values, so the
rule can be removed once HTP reads the input right.

cc @cccclai @winskuo-quic @shewu-quic @haowhsu-quic @DannyYuyang-quic @qti-horodnic @cbilgin @abhinaykukkadapu @psiddh

Lenguaje dominante
Python
Estrellas
5.2k
Forks
1.2k
Merge medio
1 d 23 h
PR fusionados (30 d)
696

Preparar el entorno

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de pytorch/executorch

Todos los issues de pytorch/executorch

Issues similares

Más issues de Python

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.