[Feature][Relax][ONNX] Support QLinearAveragePool operator in Relax ONNX frontend

Đang mở
#20,962 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 3 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
58/100
Loại issue
Tính năng
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
python
Lĩnh vực
backend, machine-learning

Hướng nghiên cứu

Start in python/tvm/relax/frontend/onnx/onnx_frontend.py and check how the frontend maps existing ONNX pooling operators, then review tests/python/relax/test_frontend_onnx.py for the ONNX Runtime comparison pattern. Implement support for the listed dimensions, attributes, padding modes, and quantization behavior; done means the tests verify numerical correctness against ONNX Runtime.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

Description

The ONNX QLinearAveragePool operator (opset 11) is currently missing from the Relax ONNX frontend (python/tvm/relax/frontend/onnx/onnx_frontend.py).

QLinearAveragePool performs 8-bit quantized average pooling over 1D, 2D, or 3D spatial dimensions, dequantizing the input tensor, performing average pooling, and requantizing the pooled output with the output scale and zero-point parameters.

Key Requirements
  • Support 1D, 2D, and 3D average pooling kernels.
  • Support kernel_shape, strides, pads, and count_include_pad attributes.
  • Support auto_pad modes (SAME_UPPER, SAME_LOWER, VALID, NOTSET).
  • Proper dequantization: X_f = (X - x_zp) * s_x.
  • Pooling computation and requantization: Y = clip(round(AvgPool(X_f) / s_y) + y_zp, min_val, max_val).
  • Numerical correctness verified against ONNX Runtime in tests/python/relax/test_frontend_onnx.py.
Triage
  • needs-triage
  • frontend:onnx
Ngôn ngữ chính
Python
Star
13.9k
Fork
4.1k
Merge trung bình
4 ngày 22 giờ
Pull request đã merge (30 ngày)
22

Chuẩn bị môi trường

Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của apache/tvm

Tất cả issue của apache/tvm

Issue tương tự

Thêm issue về Python

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.