Giter Site home page Giter Site logo

johnlcaron / shangrla Goto Github PK

View Code? Open in Web Editor NEW

This project forked from pbstark/shangrla

0.0 0.0 0.0 8.95 MB

Sets of Half-Average Nulls Generate Risk-Limiting Audits: tools for assertion-based risk-limiting election audits

License: GNU Affero General Public License v3.0

Python 100.00%

shangrla's Introduction

Sets of Half-Average Nulls Generate Risk-Limiting Audits (SHANGRLA)

Risk-limiting audits (RLAs) offer a statistical guarantee: if a full manual tally of the paper ballots would show that the reported election outcome is wrong, an RLA has a known minimum chance of leading to a full manual tally. RLAs generally rely on random samples.

With SHANGRLA we introduce a very general method of auditing a variety of election types, by expressing an apparent election outcome as a series of assertions.
Each assertion is of the form "the mean of a list of non-negative numbers is greater than 1/2."

The lists of nonnegative numbers correspond to assorters, which assign a number to the selections made on each ballot (and to the cast vote record, for comparison audits). Each assertion is tested using a sequential test of the null hypothesis that its complement holds. If all the null hypotheses are rejected, the election outcome is confirmed. If not, we proceed to a full manual recount. SHANGRLA incorporates several different statistical risk-measurement algorithms and extends naturally to plurality and super-majority contests with various election types including Range and Approval voting and Borda count.

It can even incorporate Instant Runoff Voting (IRV) using the RAIRE assertion-generator. This produces a set of assertions sufficient to prove that the announced winner truly won. Observed paper ballots can be entered using Dan King and Laurent Sandrolini's tool for the San Francisco Election board.

We provide an open-source reference implementation and exemplar calculations in Jupyter notebooks.

Installation

Installing from GitHub

Main version:

pip install git+https://github.com/pbstark/SHANGRLA.git@main

Development version:

pip install git+https://github.com/dvukcevic/SHANGRLA.git@dev

Installing from a local copy (in development mode)

Install just the code:

pip install -e .

Also include the optional dependencies for tests and examples:

pip install -e .[test,examples]

Authors and contributors

The initial code was written by Michelle Blom, Andrew Conway, Philip B. Stark, Peter J. Stuckey and Vanessa Teague.

Additional development by Amanda Glazer, Jake Spertus, Ian Waudby-Smith, David Wu, Alexander Ek, Floyd Everest and Damjan Vukcevic.

Licences

Copyright (C) 2019-2024 Philip B. Stark, Vanessa Teague, Michelle Blom, Peter Stuckey, Ian Waudby-Smith, Jacob Spertus, Amanda Glazer, Damjan Vukcevic, David Wu, Alexander Ek, Floyd Everest.

Software

GNU AGPL
The software, and documentation of the software, in this repository is provided under the GNU Affero General Public License (AGPL). You can redistribute and/or modify the software and documentation under the terms of the AGPL as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

The software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the AGPL for more details. A copy of the AGPL is provided in LICENSE.

Other files

Creative Commons License
The other documents in this repository (not including the software and documentation of the software) are provided under a Creative Commons Attribution-NoDerivs 4.0 International License (CC BY-ND 4.0).

shangrla's People

Contributors

pbstark avatar spertus avatar wannabesmith avatar bsheehan-sf-rla avatar dvukcevic avatar fleverest avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.