etsi.etna
High-Performance Neural Networks. Rust Core. Python Ease.
What if machine learning felt effortless?
etsi.etna is a minimalistic, dependency-light neural network library
designed to make training and evaluating models on structured data fast,
interpretable and beginner-friendly. It focuses on auto-preprocessing,
simple linear networks, and core metrics - ideal for research
prototyping, learning, and quick deployments.
Features • Installation • MVP Demo • Quickstart • Experiment Tracking
Why Etna?
Machine learning libraries often force a trade-off: simplicity or speed. Etna removes that barrier.
- Blazing Fast: The heavy lifting (Linear layers, ReLU, Softmax, Backprop) is handled by a highly optimized Rust core (
etna_core). - Pythonic API: Users interact with a familiar, Scikit-learn-like Python interface.
- Arbitrary Depth: Etna now supports sequential multi-layer architectures.
- Stateful Optimization: Advanced optimizers like Adam maintain momentum and moment estimates across training sessions.
Key Features
- Sequential Multi-Layer Architecture: Define any number of hidden layers using a simple list (e.g.,
[64, 32, 16]). - Hybrid Architecture:
pyo3bindings bridge Python ease with Rust performance. - Auto-Preprocessing: Automatic scaling and categorical encoding based on column types.
- Persistent Training: Save and load models while preserving weight values and optimizer states.
- Flexible MLflow Tracking: Single-line experiment tracking that is now safely optional for local-only use.
Installation
Prerequisites
- Python (3.8 or later)
- Rust (1.70 or later)
From Source (Development)
Etna uses maturin to build the Rust extensions.
-
Clone the repository
git clone https://github.com/etsi-ai/etna.git cd etna
-
Set up a Virtual Environment (Recommended)
python -m venv .venv # Activate the environment source .venv/bin/activate # Linux/macOS # .venv\Scripts\activate # Windows
-
Install dependencies & build
# Install build tools pip install -r requirements.txt # Build and install locally maturin develop --release
Run the MVP Demo
The best way to see Etna in action is to run our interactive MVP notebook. This notebook verifies your installation by performing an end-to-end test of the entire system.
It will automatically:
- Generate Dummy Data: Creates synthetic datasets for both classification and regression.
- Train Models: Trains the Rust backend on both tasks.
- Track Experiments: Logs loss curves and artifacts to a local MLflow server.
To run it:
jupyter notebook mvp_testing.ipynb
Quickstart
If you prefer to start coding immediately, here are the basics:
- Classification with Deep Architecture Etna now supports any network depth. The example below initializes a 4-layer network.
from etna import Model
# Initialize model with 3 hidden layers: 64 -> 32 -> 16
model = Model(
file_path="iris.csv",
target="species",
hidden_layers=[64, 32, 16],
activation="leaky_relu"
)
# Train with Adam optimizer
model.train(epochs=100, lr=0.01, optimizer="adam")
# Predict original class labels
predictions = model.predict()
- Regression & Incremental Training Because optimizer states are persistent, you can resume training smoothly.
model = Model("housing.csv", target="price", task_type="regression")
# First training phase
model.train(epochs=50)
# Resume training: Adam momentum is preserved!
model.train(epochs=50)
Experiment Tracking
Etna includes native MLflow integration. To use it, simply provide your tracking URI when saving.
# Save locally AND log to MLflow in one step
model.save_model(
path="my_model_v1.json",
run_name="Deep_Run_01",
mlflow_tracking_uri="http://localhost:5000"
)
What happens automatically:
- Model artifact saved to
my_model_v1.json - Parameters (
task_type,target) logged to MLflow - Training Loss history logged as metrics
- Artifacts uploaded to the MLflow run
View your dashboard by running mlflow ui in your terminal and visiting http://localhost:5000
Contributing
Pull requests are welcome!
Please refer to CONTRIBUTING.md and CODE_OF_CONDUCT.md before submitting a Pull Request.
Join the Community
Connect with the etsi.ai team and other contributors on our Discord.
License
This project is distributed under the BSD-2-Clause License. See the LICENSE for details.
Built with ❤️ by etsi.ai
Metadata
Release files for etsi-etna 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| etsi_etna-0.1.0-cp314-cp314-win_amd64.whl | CPython 3.14 | CPython 3.14 | Windows x86-64 | Details for etsi_etna-0.1.0-cp314-cp314-win_amd64.whl |
Release files / etsi_etna-0.1.0-cp314-cp314-win_amd64.whl
| Download URL | etsi_etna-0.1.0-cp314-cp314-win_amd64.whl |
|---|---|
| Size | 262.0 kB |
| Tags | CPython 3.14 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
e915cff9ca29718243e2cb4cc43fdee28a45ce828c83f34198794d143a5722a4
|
|
BLAKE2b-256 checksum How to use checksums |
2d3256173f3f5064f942cf42b5ba73d7e58921d9402d9a1ae0d936261cd0c0f0
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.2
|
Security for etsi-etna 0.1.0
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.