skillfed

numbagg

Fast N-dimensional aggregation functions with Numba

numbagg v0.9.4 974.0K downloads/30d#4,601 on PyPI243
License unclear License ======= Numbagg is distributed under a BSD 3-clause license. It includes portions of Bottleneck, which is distributed under a Simplified BSD license. Numbagg license =============== BSD… (full text in the JSON record) Active released

What it is and what it does

Numbagg is a library of fast aggregation and moving-window functions for N-dimensional NumPy arrays, written in Numba and exposed as generalized ufuncs. It includes standard reductions (nansum, nanmean, nanstd, nanvar), grouping operations (group_nansum, group_nanmean, etc.), moving-window statistics (move_mean, move_std, move_corr), and fill operations (ffill, bfill). The library is designed to outperform pandas and NumPy on multi-core systems through Numba's JIT compilation and parallelization, though single-threaded performance is comparable to NumPy and the first call to any function incurs JIT overhead.

It targets scientific and data-analysis workflows where performance on large arrays matters and flexible axis handling across many dimensions is needed. The main trade-off is that functions are JIT-compiled on first use, so initial calls are slower; subsequent calls are fast. Dependencies are minimal (numpy and numba), and the package supports Python 3.10 and later.

Use it for:

  • Compute moving averages and standard deviations on time-series data with NaN handling faster than pandas.
  • Apply grouped aggregations (sum, mean, count) on multi-dimensional scientific data.
  • Calculate rolling correlations and covariances on financial or climate datasets.
  • Forward-fill or backward-fill missing values in large arrays with better performance than pandas.
  • Parallelize custom reductions across multiple cores on arrays too large for pure NumPy.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Numbagg provides fast N-dimensional aggregation and moving-window functions compiled with Numba, including reductions (nansum, nanmean, nanstd), grouping operations, and forward/backward fill, optimized for multi-core parallelization.

Yes. Numbagg is worth installing if you work with large N-dimensional NumPy arrays and need fast aggregations or moving-window functions, especially on multi-core systems. Low install friction, active maintenance, no known vulnerabilities, and permissive licensing make it a safe choice. The JIT compilation overhead on first call is a minor drawback but typical for Numba-based libraries and acceptable for most scientific workflows.

Install

numbagg on PyPI

pip

pip install numbagg

uv

uv add numbagg

poetry

poetry add numbagg

Installing numbagg

Before you install

Low install friction with a pure Python wheel and only two runtime dependencies (numpy and numba). Actively maintained with a recent release and no known vulnerabilities.

License in practice

BSD 3-Clause license with portions from Bottleneck (Simplified BSD). Permissive for commercial and private use; requires attribution and license notice in redistributions.

Quickstart

import numbagg
import numpy as np

arr = np.array([1.0, 2.0, np.nan, 4.0])
result = numbagg.nansum(arr)
# or for moving window:
window_result = numbagg.move_mean(arr, window=2)

Requires Python 3.10 or later. First execution of any function triggers JIT compilation, which adds startup latency.

Verify before relying

  • Whether all listed functions (move_corr, group_nansum, etc.) are fully stable or still experimental.
  • Exact memory overhead of JIT compilation relative to raw numpy for small arrays.
  • Whether axis parameter behavior is documented for >3 dimensions in current release.

Package facts

License License ======= Numbagg is distributed under a BSD 3-clause license. It includes portions of Bottleneck, which is distributed under a Simplified BSD license. Numbagg license =============== BSD… (full text in the JSON record) (unclear)
Python support supports the current Python release (>=3.10)
Install friction low — pure-Python wheel
Runtime dependencies 2 — numpy, numba
Maintenance actively maintained — 242 days since the last release
Last repo commit
First released
Downloads 974,005/month — #4,601 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: numbagg-0.9.4-py3-none-any.whl

Intended Audience :: Science/ResearchOperating System :: OS IndependentProgramming Language :: PythonProgramming Language :: Python :: 3Programming Language :: Python :: 3 :: OnlyProgramming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Topic :: Scientific/Engineering

Tags

fast n-dimensional aggregationnumba compiled array functionsmoving window statisticsparallel numpy operationshigh-performance reductionsgrouped array operationsjit compiled aggregations
jit-compiledparallel-computingscientific-computing

More Scientific/Engineering packages