Skip to main content

Quantitative Information Flow library

Project description

Build Status PyPI version

libqif

Install

pip install qif
  • Needs python >= 3.6 and a sandybridge or later CPU
  • On linux pip >= 19 is needed (make sure to pip install -U pip)

A sample program

from qif import *

def compute_bayes(C):
	pi = probab.uniform(C.shape[0])

	print("Channel:\n", C)
	print("Prior:\n", pi)

	print("Bayes vulnerability", measure.bayes_vuln.posterior(pi, C))
	print("Bayes mult-capacity", measure.bayes_vuln.mult_capacity(C))

compute_bayes(channel.randu(5))

# same, but using rational arithmetic
qif.set_default_type(qif.rat)

C = np.array([
	[rat(1,2), rat(1,4), rat(1,4)],
	[rat(1,6), rat(3,6), rat(2,6)],
	[rat(1,2), rat(1,2), rat(0)],
])
compute_bayes(C)

Documentation

A list of methods provided by qif is available here.

Use libqif with C++

See the installation instructions.

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

qif-1.1.7-cp39-cp39-win_amd64.whl (17.5 MB view details)

Uploaded CPython 3.9 Windows x86-64

qif-1.1.7-cp39-cp39-manylinux2010_x86_64.whl (20.8 MB view details)

Uploaded CPython 3.9 manylinux: glibc 2.12+ x86-64

qif-1.1.7-cp39-cp39-macosx_10_9_x86_64.whl (13.0 MB view details)

Uploaded CPython 3.9 macOS 10.9+ x86-64

qif-1.1.7-cp38-cp38-win_amd64.whl (17.5 MB view details)

Uploaded CPython 3.8 Windows x86-64

qif-1.1.7-cp38-cp38-manylinux2010_x86_64.whl (20.8 MB view details)

Uploaded CPython 3.8 manylinux: glibc 2.12+ x86-64

qif-1.1.7-cp38-cp38-macosx_10_9_x86_64.whl (13.0 MB view details)

Uploaded CPython 3.8 macOS 10.9+ x86-64

qif-1.1.7-cp37-cp37m-win_amd64.whl (17.5 MB view details)

Uploaded CPython 3.7m Windows x86-64

qif-1.1.7-cp37-cp37m-manylinux2010_x86_64.whl (20.8 MB view details)

Uploaded CPython 3.7m manylinux: glibc 2.12+ x86-64

qif-1.1.7-cp37-cp37m-macosx_10_9_x86_64.whl (13.0 MB view details)

Uploaded CPython 3.7m macOS 10.9+ x86-64

qif-1.1.7-cp36-cp36m-win_amd64.whl (17.5 MB view details)

Uploaded CPython 3.6m Windows x86-64

qif-1.1.7-cp36-cp36m-manylinux2010_x86_64.whl (20.8 MB view details)

Uploaded CPython 3.6m manylinux: glibc 2.12+ x86-64

qif-1.1.7-cp36-cp36m-macosx_10_9_x86_64.whl (13.0 MB view details)

Uploaded CPython 3.6m macOS 10.9+ x86-64

File details

Details for the file qif-1.1.7-cp39-cp39-win_amd64.whl.

File metadata

  • Download URL: qif-1.1.7-cp39-cp39-win_amd64.whl
  • Upload date:
  • Size: 17.5 MB
  • Tags: CPython 3.9, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.0.0 requests-toolbelt/0.9.1 tqdm/4.54.1 CPython/3.8.6

File hashes

Hashes for qif-1.1.7-cp39-cp39-win_amd64.whl
Algorithm Hash digest
SHA256 ba5b18e1413137cf6521d438adda5bc8365b1b2223d1d2884ac9c667e3378d6e
MD5 ecb664e3f9000919c0ced4b7d7f23065
BLAKE2b-256 90e3f2507e63efa5b821e6948bbdebd69c0c507e2362292af99a1c336bba6a8b

See more details on using hashes here.

File details

Details for the file qif-1.1.7-cp39-cp39-manylinux2010_x86_64.whl.

File metadata

  • Download URL: qif-1.1.7-cp39-cp39-manylinux2010_x86_64.whl
  • Upload date:
  • Size: 20.8 MB
  • Tags: CPython 3.9, manylinux: glibc 2.12+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.0.0 requests-toolbelt/0.9.1 tqdm/4.54.1 CPython/3.8.6

File hashes

Hashes for qif-1.1.7-cp39-cp39-manylinux2010_x86_64.whl
Algorithm Hash digest
SHA256 de8c046049a39f190bb9ebb80c452322959b1e8d2e1bf95f3313e84f179c0d56
MD5 790926d56ddc4cfbf8ecf14b1578f5e9
BLAKE2b-256 9f0b58a7d07aa0a8d898de4b934249313fef36a6882da8b23843c7adb15d8c1b

See more details on using hashes here.

File details

Details for the file qif-1.1.7-cp39-cp39-macosx_10_9_x86_64.whl.

File metadata

  • Download URL: qif-1.1.7-cp39-cp39-macosx_10_9_x86_64.whl
  • Upload date:
  • Size: 13.0 MB
  • Tags: CPython 3.9, macOS 10.9+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.0.0 requests-toolbelt/0.9.1 tqdm/4.54.1 CPython/3.8.6

File hashes

Hashes for qif-1.1.7-cp39-cp39-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 c8565b1c35cbd21b82eb4bb0dfc579b8da6fcfd1b2680356b15189f842ea5086
MD5 dac1f6759845f15200dd8c4e9ca22481
BLAKE2b-256 c2b936750b1cfbd96a014f1cfa4fa3d7fda05d1e353d66f67ab21e2d3d5faed1

See more details on using hashes here.

File details

Details for the file qif-1.1.7-cp38-cp38-win_amd64.whl.

File metadata

  • Download URL: qif-1.1.7-cp38-cp38-win_amd64.whl
  • Upload date:
  • Size: 17.5 MB
  • Tags: CPython 3.8, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.0.0 requests-toolbelt/0.9.1 tqdm/4.54.1 CPython/3.8.6

File hashes

Hashes for qif-1.1.7-cp38-cp38-win_amd64.whl
Algorithm Hash digest
SHA256 6af6855a5b3bbd0c3d2d9ded3797990daa649aade838523c52830a683bad70a0
MD5 cd81898796d16d8aa2c909d42b4df2d5
BLAKE2b-256 df8dba9e0551013c0c2215f9de478f88a1d76fe44c64b33c5761e8c6c4fa20e5

See more details on using hashes here.

File details

Details for the file qif-1.1.7-cp38-cp38-manylinux2010_x86_64.whl.

File metadata

  • Download URL: qif-1.1.7-cp38-cp38-manylinux2010_x86_64.whl
  • Upload date:
  • Size: 20.8 MB
  • Tags: CPython 3.8, manylinux: glibc 2.12+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.0.0 requests-toolbelt/0.9.1 tqdm/4.54.1 CPython/3.8.6

File hashes

Hashes for qif-1.1.7-cp38-cp38-manylinux2010_x86_64.whl
Algorithm Hash digest
SHA256 d0c1d5db139f1247ca52069710fb28c7d022a2f93c313561d926d8b38b21c045
MD5 033d4ea38d78c370b055bd84dc55a55b
BLAKE2b-256 b8e666481ca48cbe9fcf9e48c51cb99e7b1f051b900f5a74e2026334da15898b

See more details on using hashes here.

File details

Details for the file qif-1.1.7-cp38-cp38-macosx_10_9_x86_64.whl.

File metadata

  • Download URL: qif-1.1.7-cp38-cp38-macosx_10_9_x86_64.whl
  • Upload date:
  • Size: 13.0 MB
  • Tags: CPython 3.8, macOS 10.9+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.0.0 requests-toolbelt/0.9.1 tqdm/4.54.1 CPython/3.8.6

File hashes

Hashes for qif-1.1.7-cp38-cp38-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 3700e70e3f3533140edb4f1c79b16be88d9e7a9b2a6c7dac58f00b59fbdfae8f
MD5 2d8b4c08e2e9de656c9bbbdcdf9946a7
BLAKE2b-256 80a849873fbf42fca7d9c0b42acb577cf746479f19bccc1c12c7bb17f1f930d3

See more details on using hashes here.

File details

Details for the file qif-1.1.7-cp37-cp37m-win_amd64.whl.

File metadata

  • Download URL: qif-1.1.7-cp37-cp37m-win_amd64.whl
  • Upload date:
  • Size: 17.5 MB
  • Tags: CPython 3.7m, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.0.0 requests-toolbelt/0.9.1 tqdm/4.54.1 CPython/3.8.6

File hashes

Hashes for qif-1.1.7-cp37-cp37m-win_amd64.whl
Algorithm Hash digest
SHA256 6505aaa401bc78aa882d4ad1ae8894844436854d7747c42525b0888b2c9b55fd
MD5 a0cac3e4dbd2c452d0bba079f3238761
BLAKE2b-256 bdd9c1462f153983f8a90f250cc129818729691ee8d66d940ba54805cba032bc

See more details on using hashes here.

File details

Details for the file qif-1.1.7-cp37-cp37m-manylinux2010_x86_64.whl.

File metadata

  • Download URL: qif-1.1.7-cp37-cp37m-manylinux2010_x86_64.whl
  • Upload date:
  • Size: 20.8 MB
  • Tags: CPython 3.7m, manylinux: glibc 2.12+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.0.0 requests-toolbelt/0.9.1 tqdm/4.54.1 CPython/3.8.6

File hashes

Hashes for qif-1.1.7-cp37-cp37m-manylinux2010_x86_64.whl
Algorithm Hash digest
SHA256 5d14121fdcdae51dc6a9154fe81caadb8ece984022db0cac9a64995b9c99d6c0
MD5 5d657a132053b235fb1bd2a6071ee0d2
BLAKE2b-256 b1fcd90b560faf3a842b251a72347d379bb73bbc55ada724e0e8f49fa2d7514e

See more details on using hashes here.

File details

Details for the file qif-1.1.7-cp37-cp37m-macosx_10_9_x86_64.whl.

File metadata

  • Download URL: qif-1.1.7-cp37-cp37m-macosx_10_9_x86_64.whl
  • Upload date:
  • Size: 13.0 MB
  • Tags: CPython 3.7m, macOS 10.9+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.0.0 requests-toolbelt/0.9.1 tqdm/4.54.1 CPython/3.8.6

File hashes

Hashes for qif-1.1.7-cp37-cp37m-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 3148e3c02b110fd42410a77760be634589581094b9fdb55cd672d30eb56ea040
MD5 8db53654c8aa2292b2e867edb2889469
BLAKE2b-256 1f8698c6c0b75479dabb7f9909295c354fbd5e69dc2a894e9b43c8b61c29b8a6

See more details on using hashes here.

File details

Details for the file qif-1.1.7-cp36-cp36m-win_amd64.whl.

File metadata

  • Download URL: qif-1.1.7-cp36-cp36m-win_amd64.whl
  • Upload date:
  • Size: 17.5 MB
  • Tags: CPython 3.6m, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.0.0 requests-toolbelt/0.9.1 tqdm/4.54.1 CPython/3.8.6

File hashes

Hashes for qif-1.1.7-cp36-cp36m-win_amd64.whl
Algorithm Hash digest
SHA256 5ec54343d5e651777538651b9454590b1d41a316627087bff99d4e3a3f1a4ee9
MD5 8db4a24205015db084d094190cf31120
BLAKE2b-256 a28c9738f6acc1f6bf0f04ca97732de5ab4d644bb7143bdb7943a4dc2153be0a

See more details on using hashes here.

File details

Details for the file qif-1.1.7-cp36-cp36m-manylinux2010_x86_64.whl.

File metadata

  • Download URL: qif-1.1.7-cp36-cp36m-manylinux2010_x86_64.whl
  • Upload date:
  • Size: 20.8 MB
  • Tags: CPython 3.6m, manylinux: glibc 2.12+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.0.0 requests-toolbelt/0.9.1 tqdm/4.54.1 CPython/3.8.6

File hashes

Hashes for qif-1.1.7-cp36-cp36m-manylinux2010_x86_64.whl
Algorithm Hash digest
SHA256 3c0e5b610d5035c712b19d928354d4e669fdd40ff4ac9ee97cfba70050a540d4
MD5 4fd0b44d194262a6c811813a1221f094
BLAKE2b-256 32b00501f5ce1a42c2e5f10381f768f2bf7c27d9e2372eb35feebdd267a909c8

See more details on using hashes here.

File details

Details for the file qif-1.1.7-cp36-cp36m-macosx_10_9_x86_64.whl.

File metadata

  • Download URL: qif-1.1.7-cp36-cp36m-macosx_10_9_x86_64.whl
  • Upload date:
  • Size: 13.0 MB
  • Tags: CPython 3.6m, macOS 10.9+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.0.0 requests-toolbelt/0.9.1 tqdm/4.54.1 CPython/3.8.6

File hashes

Hashes for qif-1.1.7-cp36-cp36m-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 01ca61022f67fbce28656c2d9f4285256fd4620ef193db0ca611c319ea67170a
MD5 6101eef561d9cddc0f55e7804b407a98
BLAKE2b-256 dfaca9ce9268edd337c01a0509b7a1bf2fbab492444487c0a0968aa87d41826d

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page