retrieve
No-frills library to download pre-trained models, cache it and return the local path.
Installation
pip install -U retrieve
Motivation
When using pre-trained ML models in your projects, majority of them require you to manually download the data/model weights and then specify the path in your code. Everyone in your team has to go through the same trouble of manually setting this up before they can run your models.
The idea with this library is automate this and make using pre-trained models as easy as possible.
Usage
Pass the pre-trained model path to the retrieve.url(...) method and it will return you a filepath to the file. If the file is not already download, it is fetched and shows a progress of download.
import retrieve
# URL for the pre-trained model
pretrained_model_url = '...'
# Get local path to the pre-trained model
path = retrieve.url(pretrained_model_url)
If source is a zip file, it's automatically extracted out and the extracted folder path is returned.
Metadata
Release files for retrieve 0.0.8
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 | |
|---|---|---|---|---|
| retrieve-0.0.8.tar.gz | 2.4 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| retrieve-0.0.8-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 6.0 kB
Release files / retrieve-0.0.8.tar.gz
| Download URL | retrieve-0.0.8.tar.gz |
|---|---|
| Size | 2.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
36bc84b75910a136e6a3bcb8efd51b4df122f7a8ad5cd0a592d06916b427a549
|
|
BLAKE2b-256 checksum How to use checksums |
de185cc25f9b612d9975bbf457e34f750fc69d9b5088b48a5927b8a825f6463e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.1 importlib_metadata/4.5.0 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.0 CPython/3.9.5
|
Release files / retrieve-0.0.8-py3-none-any.whl
| Download URL | retrieve-0.0.8-py3-none-any.whl |
|---|---|
| Size | 3.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
e958d62b23295e8b1447d19ae8c0fb09ff7b08f04fc37e02a326753c777d2463
|
|
BLAKE2b-256 checksum How to use checksums |
fa715f63bf678567339a34369ee3815ff351646801319c26fd0ebfc2c923c124
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.1 importlib_metadata/4.5.0 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.0 CPython/3.9.5
|
Security for retrieve 0.0.8
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.
To learn more about protecting yourself from malicious actors, visit our package security documentation.