Skip to content
Nils Schimmelmann edited this page Apr 8, 2026 · 1 revision

Welcome to the faac-benchmark wiki!

Jules Environment

sudo apt-get update && sudo apt-get install -y meson ninja-build bc ffmpeg curl gnupg python3-numpy

sudo curl -L https://github.com/bazelbuild/bazelisk/releases/latest/download/bazelisk-linux-amd64 -o /usr/local/bin/bazel
sudo chmod +x /usr/local/bin/bazel
bazel --version

export PYTHON_BIN_PATH=/usr/bin/python3
export PYTHON_LIB_PATH=/usr/lib/python3/dist-packages

sudo mkdir -p /opt/faac-benchmark
sudo chown -R $(whoami):$(whoami) /opt/faac-benchmark
cd /opt/faac-benchmark
git clone --depth 1 https://github.com/nschimme/faac-benchmark .
pip install -r requirements.txt
python3 setup_datasets.py

sudo mkdir -p /opt/visqol
sudo chown -R $(whoami):$(whoami) /opt/visqol
cd /opt/visqol
git clone --depth 1 https://github.com/google/visqol.git .
# 1. First, perform the fetch with the experimental flag.
# This downloads the dependencies into the cache.
bazel fetch --experimental_repo_remote_exec :visqol

# 2. Now that the files are downloaded, find and patch spectrogram.cc
TFLITE_FILE=$(find $(bazel info output_base)/external -name spectrogram.cc | grep "internal/spectrogram.cc" | head -n 1)

if [ -n "$TFLITE_FILE" ]; then
    echo "Patching $TFLITE_FILE..."
    # Add the missing header required for GCC 11+
    sed -i '1i #include <cstdint>' "$TFLITE_FILE"
else
    echo "Error: spectrogram.cc not found. Check if the fetch step failed."
fi

# 3. Finally, run the build
bazel build :visqol -c opt --copt=-w --experimental_repo_remote_exec

# 4. Save space
#bazel clean --expunge

echo 'export PATH="$PATH:/opt/visqol/bazel-bin"' >> ~/.bashrc
source ~/.bashrc

cd /app

Clone this wiki locally