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.8-cp39-cp39-win_amd64.whl (17.6 MB view details)

Uploaded CPython 3.9 Windows x86-64

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

Uploaded CPython 3.9 manylinux: glibc 2.12+ x86-64

qif-1.1.8-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.8-cp38-cp38-win_amd64.whl (17.6 MB view details)

Uploaded CPython 3.8 Windows x86-64

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

Uploaded CPython 3.8 manylinux: glibc 2.12+ x86-64

qif-1.1.8-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.8-cp37-cp37m-win_amd64.whl (17.6 MB view details)

Uploaded CPython 3.7m Windows x86-64

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

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

qif-1.1.8-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.8-cp36-cp36m-win_amd64.whl (17.6 MB view details)

Uploaded CPython 3.6m Windows x86-64

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

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

qif-1.1.8-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.8-cp39-cp39-win_amd64.whl.

File metadata

  • Download URL: qif-1.1.8-cp39-cp39-win_amd64.whl
  • Upload date:
  • Size: 17.6 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.8-cp39-cp39-win_amd64.whl
Algorithm Hash digest
SHA256 6c6e74a63c7e4ed7be9e693186ba1b5285d3d0ec04ef0b7c3336fffb3fdac072
MD5 40794ac224fa38ed492bc182bcd4ef6b
BLAKE2b-256 016e5559cc5afed5b544068f395ce9632fed3ad643e363845ef5d1b4983ab948

See more details on using hashes here.

File details

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

File metadata

  • Download URL: qif-1.1.8-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.8-cp39-cp39-manylinux2010_x86_64.whl
Algorithm Hash digest
SHA256 626492f83ca7506ced065ddd39903dc77bc250de372f55c9169944df67d14a94
MD5 d982bed3e22b8fb9719c0e1195f1cc78
BLAKE2b-256 05f5499d93f00e152b5be0f5a2dc6b7f0479ed3b0886da6137d4023df24644ae

See more details on using hashes here.

File details

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

File metadata

  • Download URL: qif-1.1.8-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.8-cp39-cp39-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 9e6a6016f941858a58ce2e8c9276a635bcd2373fe883a2fd3e3a0ed3f73bd563
MD5 35c8e40f6180e2acf1fa84e2cf173428
BLAKE2b-256 d1a6f47f3b486912858b50b206a363f65954687396d49f5ea746d51dc498b8f7

See more details on using hashes here.

File details

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

File metadata

  • Download URL: qif-1.1.8-cp38-cp38-win_amd64.whl
  • Upload date:
  • Size: 17.6 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.8-cp38-cp38-win_amd64.whl
Algorithm Hash digest
SHA256 a21645093db64f05288115901638dc44ce94b006a2f76451b94cf527629a00db
MD5 6523d1ee2fd08b913834e026a7937a41
BLAKE2b-256 876082cdd0b5df77c3d787be487f5ce664fac17c0b471171ad5056ce1d84049c

See more details on using hashes here.

File details

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

File metadata

  • Download URL: qif-1.1.8-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.8-cp38-cp38-manylinux2010_x86_64.whl
Algorithm Hash digest
SHA256 fedc80bc9292bd55a57f3b52877c3db8ba1ea9fbe8df4c0215806e8b4faed772
MD5 2361022a43c7640092836a08bf9e4131
BLAKE2b-256 207d3f57f665985702f773a70842bafdd5277b2c17ba1149edd477fab10c3ded

See more details on using hashes here.

File details

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

File metadata

  • Download URL: qif-1.1.8-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.8-cp38-cp38-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 006bfba210d976c1d7a5cfaebb3b5fee04a04e094e4ea3659ac74849dafceaa6
MD5 e921deb6dd48121df2783c62efbfba7f
BLAKE2b-256 458652e391e7ea4a4c7f866eec1d548cabf612c103ffc5537292544980233a32

See more details on using hashes here.

File details

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

File metadata

  • Download URL: qif-1.1.8-cp37-cp37m-win_amd64.whl
  • Upload date:
  • Size: 17.6 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.8-cp37-cp37m-win_amd64.whl
Algorithm Hash digest
SHA256 004e89878f9d42e06d13688a7c9fb29ad8fdb3671caf8a500951f4766fe44516
MD5 e834ffa7f789bb255c14c7f01204de36
BLAKE2b-256 9867a649e5db57f2260fa929e59746404cfef2822ece4f0d06887483b3548c34

See more details on using hashes here.

File details

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

File metadata

  • Download URL: qif-1.1.8-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.8-cp37-cp37m-manylinux2010_x86_64.whl
Algorithm Hash digest
SHA256 c6515e0bd7489c7fc46aa2906e7010a088f1882a92d09ca3828a6bdcb740b9ba
MD5 fcfdc88bfb1e3ed23b9e945263f84ef0
BLAKE2b-256 b01437538f64e0f98de6399fa026af4717630cb617199148ad138ca7f984555a

See more details on using hashes here.

File details

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

File metadata

  • Download URL: qif-1.1.8-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.8-cp37-cp37m-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 01af43eb266f073e6ba442e8bf5a4e18d54932a2e82c9174f1220240dcd4111b
MD5 dce11d4d9c9a340667ed73043f5dc324
BLAKE2b-256 688cce8bc7aa785a97728297b16c32e01ab88f6de7cfa579101ff386c377603e

See more details on using hashes here.

File details

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

File metadata

  • Download URL: qif-1.1.8-cp36-cp36m-win_amd64.whl
  • Upload date:
  • Size: 17.6 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.8-cp36-cp36m-win_amd64.whl
Algorithm Hash digest
SHA256 be21e668bb2e9d96a7418b82cb87d7645d46594b12ca061154d23db927f6da30
MD5 ddaa3f9b15e7ddb393af72577a1e01ab
BLAKE2b-256 c7ab852b03591f7f37a02da383528891614c679074e585f4eaca648b05b2d93a

See more details on using hashes here.

File details

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

File metadata

  • Download URL: qif-1.1.8-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.8-cp36-cp36m-manylinux2010_x86_64.whl
Algorithm Hash digest
SHA256 e5a3b26d6aef33bb01b301488f5bcd6df6f1d0cdd945547445fa04cb8c338e2b
MD5 5df471f96fca1705c83d2254667028fd
BLAKE2b-256 a937c8c24872f2946529832dbfccc55a5cd1e4e6dc8441693d058bf53b2d3c27

See more details on using hashes here.

File details

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

File metadata

  • Download URL: qif-1.1.8-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.8-cp36-cp36m-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 7d74bf3d22d2efb87416203149eca47b539323bfb3de99928b0825fb9d474993
MD5 026cb534659ed8920bd09361881e6087
BLAKE2b-256 25a40e45cbd1b082e0bce4b2974e3c4c2238ac9912429130f12ba158bc5f476f

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