Metadata-Version: 2.4
Name: waveletvit
Version: 0.0.1
Summary: Multilevel Wavelet-Band Transformer layers
Project-URL: Homepage, https://github.com/kkt-ee/waveletvit
Project-URL: Issues, https://github.com/kkt-ee/waveletvit/issues
Author-email: Kishore Kumar Tarafdar <kishorektarafdar@gmail.com>
License-Expression: Apache-2.0
License-File: LICENSE
Classifier: Intended Audience :: Science/Research
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Topic :: Scientific/Engineering
Requires-Python: >=3.9
Requires-Dist: tensorflow>=2.13
Requires-Dist: tfdwt>=0.0.1
Description-Content-Type: text/markdown

# waveletvit: Multilevel Wavelet-Band Transformer Layers

[![PyPI Version](https://img.shields.io/pypi/v/waveletvit?label=PyPI&color=gold)](https://pypi.org/project/waveletvit/)
[![Python Versions](https://img.shields.io/pypi/pyversions/waveletvit)](https://pypi.org/project/waveletvit/)
[![TensorFlow](https://img.shields.io/badge/tensorflow-required-darkorange)](https://www.tensorflow.org/)
[![License](https://img.shields.io/badge/license-Apache--2.0-deepgreen.svg?style=flat)](LICENSE)

`waveletvit` provides TensorFlow/Keras WaveletViT layers for 1D, 2D, and 3D multilevel wavelet-band tokenization, attention, and reconstruction.

## Capabilities

- `WaveletTokenizer1D`, `WaveletTokenizer2D`, and `WaveletTokenizer3D`.
- `WaveletViTBlock1D`, `WaveletViTBlock2D`, and `WaveletViTBlock3D`.
- `WaveletAssembler1D`, `WaveletAssembler2D`, and `WaveletAssembler3D`.
- `UWaveletViTNet3D` for a 3D U-Net with a WaveletViT bottleneck.

## Limitations

- Inputs are TensorFlow tensors with channel-last layout.
- Spatial sizes should be compatible with the configured DWT levels.

## Dependencies

- `tensorflow`
- `TFDWT`

## Installation

```bash
pip install waveletvit
```

## Minimal Example

```python
import tensorflow as tf
from waveletvit import UWaveletViTNet3D

model = UWaveletViTNet3D(
    input_shape=(32, 32, 32, 1),
    config=(16, 32, 64, 128),
    n_classes=4,
    levels=1,
    wave="haar",
)

x = tf.random.normal([1, 32, 32, 32, 1])
y = model(x)

print(y.shape)
```

## Citation

This software is released for broad research, educational, and engineering use. If this package helps your work, please cite the following paper:

```bibtex
@misc{tarafdar2026interpretablefrugallearningsystems,
      title={Interpretable and Frugal Learning Systems Employing Multiresolution Pyramids and Volterra Kernels},
      author={Kishore Kumar Tarafdar},
      year={2026},
      eprint={2606.15011},
      archivePrefix={arXiv},
      primaryClass={eess.SP},
      url={https://arxiv.org/abs/2606.15011},
}
```

## License

Apache License 2.0. See [`LICENSE`](LICENSE).

Copyright 2026 Kishore Kumar Tarafdar.
