Batch Analytics
PySpark-based analytics pipeline for ClickHouse data: Extract → Transform → Stage → Analytics. Designed to run as the main application inside a Spark driver container (invoked by analytics_runners via SparkApplication CRD).
Bundle contents
Only the files required for the batch analytics job runner:
analytics/
├── pyproject.toml
├── requirements.txt # core + scipy + boto3 + clickhouse-connect (single-file install)
├── requirements-batch.txt # includes requirements.txt
├── README.md
└── src/
└── batch_analytics/
├── __init__.py
├── __main__.py # python -m batch_analytics
├── job_runner.py # Entry point
├── config.py
├── extract.py
├── transform.py
├── log.py
├── README.md
└── analytics/
├── __init__.py
├── linear_regression.py
├── correlation.py
├── pca_clustering.py
└── t_test.py
Install
pip install batch-analytics— core (numpy only)pip install batch-analytics[spark]— PySpark ETL + job runner + SciPy (t-test / ANOVA)pip install batch-analytics[autogluon]— AutoGluon + I/O (Gluon image; no PySpark)pip install batch-analytics[full]— PySpark + AutoGluon + I/O
pip install -e ".[spark]" # dev
Run
# Via module
python -m batch_analytics
# Via CLI (after pip install -e .)
batch-analytics
# Full pipeline
batch-analytics
# Analytics only (from staged ClickHouse table)
batch-analytics --from-stage --modules lr corr pca ttest
Configuration
See src/batch_analytics/README.md for environment variables and usage.
Docker image
For Spark on Kubernetes, build an image that includes this package and exposes job_runner.py at the path used by mainApplicationFile (e.g. local:///opt/analytics/job_runner.py).
Metadata
Release files for batch-analytics 0.3.37
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| batch_analytics-0.3.37.tar.gz | 46.3 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| batch_analytics-0.3.37-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 99.0 kB
Release files / batch_analytics-0.3.37.tar.gz
| Download URL | batch_analytics-0.3.37.tar.gz |
|---|---|
| Size | 46.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
8ce841c65862efcd5a7e82d28dfc66eb192a8cc15ff5c68b50d6d312e94af32f
|
|
BLAKE2b-256 checksum How to use checksums |
84627ffd543663c006d57644f47360170c28dc69f429ea4ac5a680902f5be3e0
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.4
|
Release files / batch_analytics-0.3.37-py3-none-any.whl
| Download URL | batch_analytics-0.3.37-py3-none-any.whl |
|---|---|
| Size | 52.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
52b5b22d1cfe54d3996a2c144f066a4a6661f69482f46bc7d04687b5df0ccf2d
|
|
BLAKE2b-256 checksum How to use checksums |
f4e510b0e39de52c0711f51e54ab8ca5d27e0be33e71e387ec5d04191c483211
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.4
|