Data Transformation Library
About
This project is an exercise primarily focused on building Python libraries, publishing packages to PyPI and dependency management using Poetry.
The task is to implement three data transformation functions:
- Transpose - flipping of the input matrix diagonally, meaning that the row and column indices of a matrix are switched and a new matrix is produced.
- Time Series Windowing - producing lists or numpy arrays containing a subset of elements of the input list or numpy array. The size of the window is defined by passing size, stride and shift parameters. Time series windowing is used for making informed decisions in economics, climate, epidemiology and many other fields.
- Cross-Correlation (Convolution) - used in convolutional neural networks in machine learning libraries. Cross-correlation and convolution are both operations applied to images. Cross-correlation means sliding a kernel (filter) across an image. Convolution means sliding a flipped kernel across an image. In practice using one over the other does not change the result, just the resulting values are learned in a flipped orientation. 2D Convolutions are essential in the advancement of convolutional neural networks and various image processing filters such as blurring, sharpening, edge detection, and others.
Functions were built using Python and Numpy (as per requirements of this task). Having the knowledge of how to build such functions by yourself provides the flexibility in ones specific uses cases, as some times the already built functions in various libraries (PyTorch, cv2, etc.) have constraints and changing them can be difficult or even impossible and impractical.
For package management we were required to use Poetry.
Libraries Used
For this project only Python's standard library as well as Numpy (were it was required) were used.
For package management Poetry was used.
How to Use
As this project is an exercise on building Python libraries, the built library can be installed from PyPI, were it is being published.
To do so in the terminal window type pip install dtl_functions_rd.
To quickly test this library, download the library files from https://pypi.org/project/dtl-functions-rd/. Open the .tar file with WinRAR or similar document extraction program and copy examples.py file that is located in the main project directory src/dtl_functions_rd/examples.py to your project and run the file to see a few examples and outputs of the functions of this data transformation library.
Possible Future Improvements
- Version handling
Metadata
Release files for dtl-functions-rd 0.1.4
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 |
|---|---|---|---|---|
| dtl_functions_rd-0.1.4.tar.gz | 3.8 kB | Without provenance | Details for dtl_functions_rd-0.1.4.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| dtl_functions_rd-0.1.4-py3-none-any.whl | Python 3 | none | any | Details for dtl_functions_rd-0.1.4-py3-none-any.whl |
Total release size: 8.5 kB
Release files / dtl_functions_rd-0.1.4.tar.gz
| Download URL | dtl_functions_rd-0.1.4.tar.gz |
|---|---|
| Size | 3.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
41f229ea47513d8be7066637a21da0a79b6795178189a844a1fa085ceae12d18
|
|
BLAKE2b-256 checksum How to use checksums |
0353588da03de240d58e5abceb5d98db1c016a1d88f3cf08a89a167ea93c6e04
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.11.4
|
Release files / dtl_functions_rd-0.1.4-py3-none-any.whl
| Download URL | dtl_functions_rd-0.1.4-py3-none-any.whl |
|---|---|
| Size | 4.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
bd3263206bc1ff338cf6d7d755882ca1347ee6542bddc65f4fd4470be51635e6
|
|
BLAKE2b-256 checksum How to use checksums |
6359ee3792de2b054a4d6f5b981e536a60f6ea06833b23efdcb574b9c1d4c3f9
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.11.4
|
Security for dtl-functions-rd 0.1.4
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.