This release is a pre-release and may not be stable for production use.
django-ndarrayfield
New Django field to store numpy ndarray.
Description
Store a numpy n-dimensional array in database (compatible with all database backend). Use numpy save/load, you can define a shape (not required), and a dtype (default float32).
Usage
import numpy as np
from django.db import models
from ndarraydjango.fields import NDArrayField
class MyModel(models.Model):
vec1 = NDArrayField(shape=(32, 4), dtype=np.float64)
date = models.DateTimeField(auto_now_add=True)
Parameters
- dtype: the ndarray dtype (default np.float32)
- shape: the ndarray shape (default None)
- binary_serialize: when dump data, serialize to binary (base64) or json lists (default False)
Warning
This field type does not replace a static file storage. The main goal is to store parameter data, results of algorithms and small and medium machine learning models. A good indication is the shape of the nd-array. It would be static, and with a reasonable size. The overrall data size should not exceed 1mb. For example a field of 300x400 of 2 float32 value ( (300, 400, 2) dtype=float32) should be a maximum.
Metadata
Release files for django-ndarrayfield 1.0.0rc4
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 | Actions |
|---|---|---|---|---|
| django-ndarrayfield-1.0.0rc4.tar.gz | 3.8 kB | Without provenance | Details for django-ndarrayfield-1.0.0rc4.tar.gz |
Release files / django-ndarrayfield-1.0.0rc4.tar.gz
| Download URL | django-ndarrayfield-1.0.0rc4.tar.gz |
|---|---|
| Size | 3.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
90dd4bbb06f8aa002863ffc631163b9deb544b9ce9fdd39d514396df1dcbee11
|
|
BLAKE2b-256 checksum How to use checksums |
e22ea1f2c8fa64da771a67912201dd713abad2a43e3bfd4624610503a62be332
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.2 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.62.0 CPython/3.8.10
|
Security for django-ndarrayfield 1.0.0rc4
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.