Skip to content

Repository files navigation

DOI

Logo BaseAL - Active Learning Baseline

BaseAL is a framework for developing and evaluating active learning methods. BaseAL (v1) currently focuses on audio and bioacoustic data.

The tool provides a complete pipeline for evaluating sampling strategies and 3D visualisation.

Demo Demo of 3D visualisation.

Key Features

  • Experiment Management: Track and compare different active learning configurations
  • Interactive 3D Visualisation: Explore high-dimensional embeddings using PCA/UMAP reduction with an interactive Three.js interface
  • Multiple Sampling Strategies: Compare different sampling and diversification strategies
  • Model Integration: Simulates transfer learning of embeddings using an adjustable classification head.

**For BaseAL compatible dataset generation see the dataset generator. This is built on Bacpipe for seamless integration with bioacoustic models

Setup

1. Clone the Repository

git clone https://github.com/benmcewen1/BaseAL.git
cd BaseAL

2. Set Up Python Dependencies (Core dependencies)

uv sync

Make sure you activate the env source .venv/bin/activate or select via Ctrl + Shift + P in VSCode.

See the Dependencies list in pyproject.toml.

Get Started

See the docs to get started working with the BaseAL framework, and developing active learning sampling strategies.

Running Tests

uv sync --extra test
uv run pytest -v

Tests run against small synthetic embedding datasets generated on the fly (no demo data download required) and cover the sampling strategies, warm-up strategies, the neural network model, the ActiveLearner/Manager pipeline, and the embedding visualisation utilities in core/.

If you are a participating in the BioDCASE data challenge, an biodcase_example.ipynb is setup here with everything needed to get started.


Optional:

The following is optional and only required for the web app.

3. Set Up the Frontend (Web Interface)

cd app
npm install

(Optional) Run Web App

1. Start the API Server

cd api
python main.py

The API will be available at http://localhost:8000

You can verify it's running by visiting http://localhost:8000/docs for the interactive API documentation.

2. Start the Web Interface

Open a new terminal window and run:

cd ../app
npm run dev

The web interface will be available at http://localhost:5173

3. Explore Embeddings

  1. Open http://localhost:5173 in your browser
  2. Click "Get Started".
  3. Select "Use Config File" and "Load Config", this will select the default options.
  4. Use Run Cycle/Run All Cycles buttons to step through AL cycles
  5. Interact with the 3D scatter plot to explore your data

To run BaseAL using an Apptainer container on an HPC system, follow these steps:

1. Build the Apptainer Image

cd /path/to/BaseAL
apptainer build --fakeroot baseal.sif apptainer_build/baseal.def

2. Start shell within the Apptainer container

apptainer shell --bind /any/required/paths:/mnt baseal.sif

3. run the same commands as in the setup section above.

Citation

If you use this software, please cite:

@software{mcewen_baseal,
  author={McEwen, Ben and Zhang, Shiqi},
  title={{BaseAL}: Active Learning Baseline},
  year=2026,
  version={v1.2},
  publisher={Zenodo},
  doi={10.5281/zenodo.21806638},
  url={https://doi.org/10.5281/zenodo.21806638}
}

Contributions and Authorship

Contributions are welcome! Please contact Ben McEwen to discuss potential contributions.

Authors of substantial contributions will be recognised as authors in the citable DOI for subsequent releases.

Substantial contributions include:

  • Implementing a major feature or new functionality
  • Significant refactoring or performance improvements
  • Comprehensive documentation or tutorials
  • Bug fixes that resolve critical issues

Minor contributions (small bug fixes, typos, formatting) will be acknowledged in the release notes.

Acknowledgments

BaseAL uses embeddings pre-generated by Bacpipe developed by Vincent Kather.

About

A modular active learning evaluation framework

Topics

Resources

Stars

6 stars

Watchers

0 watching

Forks

Releases

Contributors

Languages