MCPcopy Create free account
hub / github.com/pytorch/executorch / export_processor

Function export_processor

extension/audio/mel_spectrogram.py:238–250  ·  view source on GitHub ↗

Export a WhisperAudioProcessor to a .pte file. Args: output_file: Output .pte file path. backend: Backend for partitioning ("xnnpack" or "mlx"). **model_kwargs: Passed to WhisperAudioProcessor constructor (e.g. feature_size, max_audio_len, stack_output, strea

(
    output_file="whisper_preprocess.pte", backend="xnnpack", **model_kwargs
)

Source from the content-addressed store, hash-verified

236
237
238def export_processor(
239 output_file="whisper_preprocess.pte", backend="xnnpack", **model_kwargs
240):
241 """Export a WhisperAudioProcessor to a .pte file.
242
243 Args:
244 output_file: Output .pte file path.
245 backend: Backend for partitioning ("xnnpack" or "mlx").
246 **model_kwargs: Passed to WhisperAudioProcessor constructor
247 (e.g. feature_size, max_audio_len, stack_output, streaming).
248 """
249 model = WhisperAudioProcessor(**model_kwargs)
250 _export_processor_model(model, output_file, backend)
251
252
253def main():

Callers 2

export_voxtral_hfFunction · 0.90
mainFunction · 0.85

Calls 2

_export_processor_modelFunction · 0.85

Tested by

no test coverage detected