A Python interface to the ANU Quantum Random Numbers Server
Project description
This module provides a Python interface to The ANU Quantum Random Number Generator JSON API.
Usage
>>> import quantumrandom >>> quantumrandom.get_data() [26646] >>> quantumrandom.get_data(data_type='hex16', array_length=5, block_size=2) [u'46db', u'9a11', u'ab24', u'510a', u'a69a'] >>> quantumrandom.get_data(data_type='uint16', array_length=5, block_size=5) [42796, 32457, 9242, 11316, 21078]
Valid data_type values are uint16 and hex16, and the array_length cannot be larger than 100. If for some reason the API call is not successful, or the incorrect amount of data is returned, this function will raise an exception.
- warning:
Due to the lack of an SSL/TLS interface at the moment, all data is sent over the wire in clear text.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
quantumrandom-1.1.tar.gz
(2.6 kB
view details)
File details
Details for the file quantumrandom-1.1.tar.gz
.
File metadata
- Download URL: quantumrandom-1.1.tar.gz
- Upload date:
- Size: 2.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5157137146d705f39aec20cc8cefc24ea0916eb8d2beab374c870b0e337e89a1 |
|
MD5 | 90483928b96fd8443a39325ca8d708f4 |
|
BLAKE2b-256 | 014110821f524092947952debb8aa66760430b8d8d7622c4c255762d9c6c69be |