Coder Social home page Coder Social logo

aus-senate-audit's Introduction

aus-senate-audit

The Australian Senate Audit can be run in three different modes.

  1. Simulation Mode: Runs a simulated audit on fake data using Borda Count.

aus-senate-audit simulation --seed SEED --num-candidates NUM_CANDIDATES --num-ballots NUM_BALLOTS

where

SEED is the starting value of the RNG used by the program. NUM_CANDIDATES is the number of candidates in the simulation (default: 100). NUM_BALLOTS is the number of cast ballots in the simulation (default: 1000000).

  1. Quick Mode: Runs a Bayesian audit on real data and automates reading paper ballots.

aus-senate-audit quick --seed SEED --state STATE --data DATA

where

SEED is the starting value of the RNG used by the program. STATE is the abbreviated name of the Australian state to run the audit for (e.g. TAS). DATA is the file path to all Australian senate election data.

  1. Real Mode: Runs a Bayesian audit on real data.

Running a real audit requires two steps. First, the formal preferences must be sampled using

aus-senate-audit real --seed SEED --state STATE --data DATA

This command will generate a selected_ballots.csv file containing a sample of ballots that do not contain formal preferences. The auditor must use the information in the file to retrieve the paper preferences and enter them into the CSV file. For example, suppose a line in the selected_ballots.csv file appears as

Denison,POSTAL 3,311,19,42,

The auditor would retrieve that exact ballot and then add the preferences read from that ballot to the selected_ballots.csv, as shown below.

Denison,POSTAL 3,311,19,42,",1,2,3,,6,,,,4,,,5,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,"

Upon completing the selected_ballots.csv, the auditor should run

aus-senate-audit real --seed SEED --state STATE --selected-ballots SELECTED_BALLOTS_FILE --data DATA

SELECTED_BALLOTS_FILE is the path to the selected_ballots.csv file.

This command will run one audit stage on the sample of ballots audited thus far. One should continue the audit in this manner (repeating step 3), until the audit terminates (as will be indicated in the printout by the audit).

There are a handful of other options for fine tuning the audit. These can be seen by running

aus-senate-audit -h

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.