Light-weight Python OLAP framework for multi-dimensional data analysis
Python Other
Latest commit f3364d9 Aug 22, 2016 @Stiivi Stiivi committed on GitHub Merge pull request #368 from mintbridge/patch-1
parse the config file before passing to create server
Failed to load latest commit information.
bin fix typo Jun 28, 2016
cubes parse the config file before passing to create server Jul 25, 2016
doc Added release notes file (empty) Jul 4, 2016
examples Merge pull request #365 from BetterWorks/typo Jul 2, 2016
goodies Added some syntax candy Feb 18, 2014
models Renamed date/time to base_date/base_time and moved to internal dir Feb 13, 2014
tests Restructured into metadata and query module Jul 4, 2016
.coverage Added 1.0.1 changes and bumped version to 1.0.1 Mar 27, 2015
.coveragerc [tests] added .coveragerc for python test coverage Jan 28, 2015
.gitignore [tests] added .coveragerc for python test coverage Jan 28, 2015
.hgignore initial commit after extraction from brewery Jan 10, 2011
.hgtags Added tag v0.6 for changeset 39416fc0d89e Apr 25, 2011
.travis.yml added core requirements install for travis; added sqlite3 <3.7.11 com… Jun 9, 2015
AUTHORS Update AUTHORS with correct email Dec 2, 2015
CHANGES No CHANGES file any more. Nov 6, 2013
LICENSE moved cross_table to aggregation results; minor fixes Jul 3, 2012 Updated readme about versioning. Jun 2, 2016 Added brief roadmap of major features Mar 20, 2015 Added visualizer instructions Aug 28, 2014
requirements-optional.txt Updated requirements (added expressions, grako, flask) Mar 29, 2015
requirements.txt [change] slicer is now using Click library instead of argparse Apr 6, 2015 Added dependency on fixed expressions, fixes #355 Jul 2, 2016

Cubes - Online Analytical Processing Framework for Python

Join the chat at

Flattr this git repo

Cubes is a light-weight Python framework and set of tools for Online Analytical Processing (OLAP), multidimensional analysis and browsing of aggregated data.

Focus on data analysis, in human way


Purpose is to provide a framework for giving analyst or any application end-user understandable and natural way of presenting the multidimensional data. One of the main features is the logical model, which serves as abstraction over physical data to provide end-user layer.


  • OLAP and aggregated browsing (default backend is for relational databse - ROLAP)
  • multidimensional analysis
  • logical view of analysed data - how analysts look at data, how they think of data, not not how the data are physically implemented in the data stores
  • hierarchical dimensions (attributes that have hierarchical dependencies, such as category-subcategory or country-region)
  • localizable metadata and data
  • SQL query generator for multidimensional aggregation queries
  • OLAP server – HTTP server based on Flask Blueprint, can be easily integrated into your application.


Current recommended version is 1.1.x. It hasn't been yet tagged so please use the master branch. This version includes SQL backend support out of the box, and other backends have been moved to separate projects (ie. MongoDB). This branch (currently master) will be soon tagged as 1.1 release.

Previous stable version was 1.0.1. This version included all backend types, but no further development will be done on this branch.


Latest documentation


See examples directory in the source code repository for simple examples and use-cases.

See for more complex examples.


For cubes models see


Source code is in a Git repository on GitHub

git clone git://

After you've cloned, you might want to install all of the development dependencies.

pip install -e .[dev]

Build the documentation like so. ::

cd doc
make help
make html

Outputs will go in doc/_*.


Python >= 2.7 and Python >= 3.4.1

Most of the requirements are soft (optional) and need to be satisfied only if certain parts of cubes are being used.


If you have questions, problems or suggestions, you can send a message to the Google group cubes-discuss.

IRC channel #databrewery on server

Report bugs using github issue tracking.


If you are browsing the code and you find something that:

  • is over-complicated or not obvious
  • is redundant
  • can be done in better Python-way

... please let it be known.


Cubes is written and maintained by Stefan Urbanek (@Stiivi on Twitter) and various contributors. See AUTHORS file for more information.


Cubes is licensed under MIT license. For full license see the LICENSE file.