No project description provided
Project description
randomread
Read a random subset of a text file in an efficient manner.
use
from randomread import sample
# Read randomly picked 10-word snippet from a large text file
text = sample("large_textfile.txt", 10)
# Read 100 randomly picked 2000-word chunks
text = sample("large_textfile.txt", 200000, chunk_size=2000)
install
pip install randomread
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
randomread-0.2.0.tar.gz
(1.5 kB
view details)
Built Distribution
File details
Details for the file randomread-0.2.0.tar.gz
.
File metadata
- Download URL: randomread-0.2.0.tar.gz
- Upload date:
- Size: 1.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.13 CPython/3.9.13 Darwin/22.3.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e0047321b6699d051959137f3e020c22e4443e2085ddd9b7cc8c6952224845cd |
|
MD5 | 193a4d891136850d0e6a39be9ffc3d4d |
|
BLAKE2b-256 | 58d7cb61b11b0d1ad155c7ab6c6c9ce83935c56d28e7f20b81fcf56870497912 |
File details
Details for the file randomread-0.2.0-py3-none-any.whl
.
File metadata
- Download URL: randomread-0.2.0-py3-none-any.whl
- Upload date:
- Size: 1.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.13 CPython/3.9.13 Darwin/22.3.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1b30656c6fe3354bc4d7275927fb4576ca891067490ea6b52c36a7e61eb4bdfe |
|
MD5 | 49a7527c7e70a632b938d5169038fdbb |
|
BLAKE2b-256 | d94ed93124b580d2a66708c70c808023c860da73055fb534e68cfc3e7ba1c0d5 |