Skip to main content

Finite Field Library

Project description

fifi-python contains a set of high-level Python bindings for the Fifi finite field C++ library. The bindings provide access to the arithmetic operations provided by Fifi. The examples folder provides sample applications showing the usage of the Python API.

Buildbot status Downloads Supported Python versions Download format License


A valid license is required if you wish to use and install this library. Please request a license by filling out the license request form.

This project is available under a research- and education-friendly license, see the details in the LICENSE.rst file.

If you have any questions or suggestions about this library, please contact us at our developer mailing list (hosted at Google Groups):


We provide a pip package for the easy installation of the fifi-python library.

To install this you’ll need python and pip installed:

You will need a set of tools and packages to build the library.

On all platforms, you will need a recent C++11 compiler. The compilers used by Steinwurf are listed on our buildbot page.

In the following we provide platform specific installation instructions.


These steps may not work with your specific Linux distribution, but they may guide you in the right direction.

First, acquire the required packages from your package management system:

sudo apt-get update
sudo apt-get install python git build-essential libpython-dev

If you are using Python 3, you’ll need to install libpython3-dev instead.

When you are ready to install the package, you can simply type:

sudo pip install fifi


Follow this guide to install git.

Install the latest XCode and Command-line Tools from the Mac App Store.

When you are ready to install the package, you can simply type:

sudo pip install fifi


Install Python 2.7 (32-bit) and Visual Studio Express 2013 for Windows Desktop. Then set the VS90COMNTOOLS environment variable to:

C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\Tools\

so that Python distutils can detect your new compiler.

To enable the use of pip from the command line, ensure that the Scripts subdirectory of your Python installation is available on the system PATH. (This is not done automatically.)

When you are ready to install the package, you can simply type:

pip install fifi

Building From Source

You can also build the bindings from source, if you don’t want to use pip.

Before doing anything, please install the requirements specified in the previous section (you can ignore the parts about pip).

After that you can clone the project:

git clone

Configure and build the project:

cd fifi-python
python waf configure
python waf build

Now the project is built and you should be able to find the resulting or fifi.pyd file here (the actual path and extension is dependent on your OS and Python version):


To use the bindings in your Python project you can do the following:


You can add the build/platform/src/fifi_python/ path to your PYTHONPATH and import the module in your Python script:

>>> import fifi

Copy the bindings to your project

Another option is to copy the built bindings e.g. build/linux/src/fifi_python/ (for Linux) to your project directory. As an example if your script is stored in /path/to/, then copy the bindings to /path/to/ and you should be able to import fifi from within the script.

Project details

Release history Release notifications

This version
History Node


History Node


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Filename, size & hash SHA256 hash help File type Python version Upload date
fifi-3.0.0.tar.gz (6.0 kB) Copy SHA256 hash SHA256 Source None May 7, 2015

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging CloudAMQP CloudAMQP RabbitMQ AWS AWS Cloud computing Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page