Feather Helper
Feather Helper is a concise interface to cache and load numpy arrays and pandas dataframes. I use it with Pandoctools/Knitty.
Contents
Install
Via conda:
conda install -c defaults -c conda-forge featherhelper
Via pip:
pip install featherhelper
Usage example
import pandas as pd
import numpy as np
import featherhelper as fh
fh.setdir("~/feather/mydoc") # (optional)
# fh.exc(1, 2) # force raise exceptions for names (optional)
# %%
fh.name(1) # can also be fh.name('id1'), default is 'default', 1 is the same as '1'
try:
# raise fh.Err # (optional)
df, A, B = fh.pull() # control length can be set: fh.pull(N)
except fh.Err:
# calculate:
print('push')
df = pd.DataFrame(np.random.random(16).reshape(4, 4))
A = df.values
B = np.random.random(16 * 3).reshape(4, 2, 2, 3)
#
fh.push(df, A, B)
print(df, '\n', A, '\n', B)
A shorter example:
import numpy as np
import featherhelper as fh
# fh.exc()
# %%
try:
A = fh.pull()
except fh.Err:
A = np.random.random(16).reshape(4, 4)
fh.push(A)
Metadata
Release files for featherhelper 0.0.5
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| featherhelper-0.0.5.tar.gz | 20.4 kB | Without provenance | Details |
Release files / featherhelper-0.0.5.tar.gz
| Download URL | featherhelper-0.0.5.tar.gz |
|---|---|
| Size | 20.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
aa6a38812a6ed7c2efec976c8c4788a177f5ac06779731dc458323bc60bb97b8
|
|
BLAKE2b-256 checksum How to use checksums |
64b139866af6ebe459efe302d043e00afc67683c233a3b28df0a29b06cf9cafb
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.21.0 setuptools/40.6.3 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.7
|
Security for featherhelper 0.0.5
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.