This repository contains example models for the anira library, designed for validation and demonstration purposes.
SimpleGainNetwork: This folder contains an example model, designed for multichannel audio inference. It includes:- Inputs:
- Audio data: A multichannel input array representing the audio signal. Models are generated for
1(mono),2(stereo),4and16channels. - Gain parameter: A parameter to apply gain (amplification) to the input audio.
- Audio data: A multichannel input array representing the audio signal. Models are generated for
- Outputs:
- Processed audio: The input audio after applying the gain.
- Peak gain: The maximum absolute gain measured across all channels.
- Formats: Each channel count is exported to TorchScript (
.pt), ONNX (.onnx), TFLite (.tflite), and ExecuTorch (.pte). The build script cross-checks that all four runtimes produce consistent outputs.
- Inputs:
To (re)generate the models:
pip install -r requirements.txt
python SimpleGainNetwork/simple_gain_network.pyBy default this builds the (1, 2, 4, 16) channel set; edit the channel_counts argument to main() to change it.