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

オープン
#20,970 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 3 日以内に返信

まだ誰も着手していません。

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
55/100
issue の種類
機能追加
明瞭さ
おおむね明確
活発さ
活発
技術スタック
python

調査の方向性

Start with python/tvm/relax/frontend/onnx/onnx_frontend.py and the ONNX operator coverage RFC issue #20124, then check how the frontend handles operators with scalar inputs and output datatype attributes. Implement support for ONNX MelWeightMatrix and verify that its output has shape (dft_length // 2 + 1, num_mel_bins) and contains the specified triangular Mel filterbank weights.

索引モデルが issue の本文から書いたものです。

説明

Feature Description

Support the ONNX MelWeightMatrix operator in the Apache TVM Relax ONNX frontend (python/tvm/relax/frontend/onnx/onnx_frontend.py).

Motivation

MelWeightMatrix generates the triangular filterbank weight matrix used to transform linear-frequency discrete Fourier transform spectra into the perceptual Mel scale. It is a fundamental feature extraction stage in modern end-to-end speech and audio models (such as OpenAI Whisper, Conformer, and wav2vec 2.0).

Introduced in ONNX opset 17+, MelWeightMatrix is currently unsupported in the Relax ONNX frontend:

NotImplementedError: The following operators are not supported: ['MelWeightMatrix']

This operator was also highlighted in the ONNX operator coverage RFC tracking issue #20124 under Signal Processing operators.

Operator Specification (ONNX Opset 17+)
  • Inputs:
    1. num_mel_bins: Scalar integer specifying the number of Mel frequency bands.
    2. dft_length: Scalar integer representing the length of the DFT window.
    3. sample_rate: Scalar integer representing the sampling rate in Hertz.
    4. lower_edge_hertz: Scalar float specifying the lower boundary of the filterbank in Hz.
    5. upper_edge_hertz: Scalar float specifying the upper boundary of the filterbank in Hz.
  • Attributes:
    • output_datatype: int (default TensorProto.FLOAT) - output numeric precision.
  • Outputs:
    1. output: 2D tensor of shape (dft_length // 2 + 1, num_mel_bins) containing the Mel filterbank matrix.
Expected Behavior

The Relax ONNX frontend should implement MelWeightMatrix by evaluating the triangular Mel filterbank matrix (either statically when inputs are constant initializers, or dynamically via Relax tensor operations).

主要言語
Python
スター
13.9k
フォーク
4.1k
平均マージ
4日 22時間
マージ済み PR(30日)
22

環境構築

このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

apache/tvm のほかの issue

apache/tvm の issue をすべて見る

似ている issue

Python の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。