Open source. Open to your next idea. Explore EveryO 0.2.0

DEVELOPER DOCUMENTATION v0.2.0

Build with clarity.

Your guide from the first tensor to a complete training loop.
Read the code. Run the examples. Understand each step.

YOUR DEVELOPMENT TOOLKIT

Python 3.9–3.12NumPy + Matplotlib · CPU first

Local. Open. Inspectable.No account or API key required

Read upstream documentation

THE LEARNING PATH

One experiment, end to end.

New to EveryO? Follow the guide in order. Already comfortable? Jump to the API or bring an example into your editor.

01 / GETTING STARTED

Install from source.

Start with Python 3.9–3.12 and an isolated virtual environment. NumPy and Matplotlib power the core CPU workflow; no account or API key is required.

Terminal · bash / zsh
git clone https://github.com/krishanth7/EveryO.git
cd EveryO
python -m venv .venv
source .venv/bin/activate
python -m pip install -e .
everyo doctor
everyo demo
Terminal · PowerShell
git clone https://github.com/krishanth7/EveryO.git
cd EveryO
python -m venv .venv
.venv\Scripts\Activate.ps1
python -m pip install -e .
everyo doctor
everyo demo
Your first success check

everyo doctor runs a real gradient check and reports optional components. everyo demo trains a digit classifier. Installation may download dependencies; core experiments run locally once installed.

Do I need TensorFlow, ONNX, or CUDA?

No. Start with the NumPy CPU core. Optional integrations have their own prerequisites.

Terminal
python -m pip install -e ".[onnx]"
# Optional numerical reference:
python -m pip install -e ".[tensorflow]"

CUDA requires compatible hardware and a separate native extension build. Follow the CUDA setup guide. GPU runtime tests are not validated in project CI.

02 / THE NUMERICAL FOUNDATION

Think in tensors.

A tensor holds numerical data, its shape, and gradient state. Python lists use float32 by default; NumPy arrays retain their precision.

tensor_basics.py
import everyo as eo

x = eo.tensor([[1.0, 2.0]])
y = eo.tensor([[3.0], [4.0]])

print(x.shape)        # (1, 2)
print(eo.matmul(x, y))
# Tensor([[11.]], shape=(1, 1), dtype=float32)
shapeThe size of every dimension.
dtypeThe numerical precision.
requires_gradWhether operations build a gradient graph.
Explore the tensor API

03 / FOLLOW THE GRAPH

Meet your autograd engine.

EveryO records the multiplication because x requires gradients. The backward pass fills x.grad with [4.]: the derivative of x² at x = 2.

first_gradient.py
import everyo as eo

x = eo.tensor([2.0], requires_grad=True)
y = x * x
y.backward()

print(x.grad)  # [4.]
Understand graph traversal and accumulation

04 / COMPOSE LAYERS

A network you can inspect.

Connect a four-feature input to a three-class output with a hidden layer and ReLU activation. This model has 131 trainable parameters.

first_network.py
import everyo as eo

model = eo.Sequential(
    eo.Linear(4, 16, seed=0),
    eo.ReLU(),
    eo.Linear(16, 3, seed=1),
)

print(model.num_parameters())  # 131
Keep the output as logits.

CrossEntropyLoss applies log-softmax internally. End your classifier with a plain Linear layer.

05 / A COMPLETE EXPERIMENT

Generate data. Train. Evaluate.

This self-contained example creates a seeded dataset, holds out 20% for evaluation, and trains with Adam. Run it after installing EveryO.

train_classifier.py
import everyo as eo
from everyo.datasets import make_blobs

features, labels = make_blobs(
    n_samples=600, n_features=4, centers=3, seed=0
)
x_train, x_test, y_train, y_test = eo.stratified_split(
    features, labels, test_size=0.2, seed=0
)
model = eo.Sequential(
    eo.Linear(4, 16, seed=0), eo.ReLU(),
    eo.Linear(16, 3, seed=1),
)
trainer = eo.Trainer(
    model, eo.Adam(model.parameters(), lr=0.01),
    eo.CrossEntropyLoss(), metrics=["accuracy"],
)
train_loader = eo.DataLoader(
    eo.ArrayDataset(x_train, y_train),
    batch_size=32, shuffle=True, seed=0,
)
test_loader = eo.DataLoader(
    eo.ArrayDataset(x_test, y_test), batch_size=64,
)
history = trainer.fit(
    train_loader, epochs=20, validation_loader=test_loader
)
print(trainer.evaluate(test_loader))

Accuracy depends on the generated data and training run. Inspect the returned evaluation metrics rather than assuming a fixed result.

06 / KEEP YOUR WORK

Save the model. Keep the experiment.

EveryO stores model architecture and weights in a pickle-free .evo archive. After training the model above, save it and reload it for inference.

Continue train_classifier.py
from pathlib import Path

Path("artifacts").mkdir(exist_ok=True)
eo.save(model, "artifacts/model.evo")
restored = eo.load("artifacts/model.evo")
restored.eval()

with eo.no_grad():
    predictions = restored(eo.tensor(x_test[:3]))

print(predictions.shape)  # (3, 3)

For supported ONNX exports, validate the exported graph in your target runtime. The traced exporter specializes control flow to the recorded execution.

See the save/load example

07 / API REFERENCE

The essential API.

eo.tensor(data, ...)

Create a tensor. Set requires_grad=True to record operations.

Tensor.backward()

Differentiate a scalar result and accumulate gradients.

eo.Sequential(*layers)

Compose layers into a feed-forward model.

eo.Linear(in_features, out_features)

An affine layer with optional bias, initializer, and seed.

eo.Adam(parameters, lr=...)

Adaptive optimization with per-parameter state.

eo.Trainer(model, optimizer, loss_fn)

Train, evaluate, and predict with callbacks and history.

eo.save(model, path)

Write a pickle-free .evo archive.

eo.load(path)

Rebuild a supported model and restore its parameters.

Open the complete API map

08 / WHEN SOMETHING DOESN’T CLICK

A shorter path to the fix.

Start with everyo doctor, then check the environment, tensor shapes, and optional integrations.

Python cannot import everyo

Activate the same virtual environment used for installation, run python -m pip install -e . from the framework checkout, and use that interpreter to run your script.

My model reports a shape mismatch

Inspect x.shape and the input/output dimensions of each layer. Dense layers expect the last dimension to match in_features. Images use NHWC: batch, height, width, channels.

Gradients are accumulating between steps

Gradient accumulation is intentional. In a manual training loop, call optimizer.zero_grad() before computing the next backward pass. Trainer manages the standard training loop.

CUDA is unavailable

The CPU workflow still works. CUDA requires the native extension and compatible NVIDIA hardware. Review the CUDA guide and optional-component report from everyo doctor.

Where can I ask for help?

Use GitHub Discussions for usage questions. For a bug, include a minimal example, versions, hardware, and complete error text with private data removed.

Read the full troubleshooting guide

09 / KEEP EXPLORING

Go one level deeper.

GUIDE

Architecture

Follow the dependency layers from NumPy to Trainer.

Read the guide
GUIDE

Scaling & export

Understand mixed precision, ONNX, and distributed limitations.

Read the guide
HELP

Troubleshooting

Diagnose installation, shapes, devices, and optional components.

Find help
PRACTICE

Runnable examples

Go from a gradient to convolution and attention.

Pick an example
FOUNDATIONS

Getting started

The complete installation and first-model guide, including tensors, gradients, CNNs, charts, and model saving.

Read the complete guide →
INTERNALS

Automatic differentiation

Trace computation graphs, the reverse-mode backward pass, gradient accumulation, broadcasting, and finite-difference verification.

Read the complete guide →
REFERENCE

Full API reference

Explore the complete public API: tensors, layers, losses, optimizers, training, callbacks, serialization, profiling, and command-line tools.

Read the complete guide →
ADVANCED

CUDA & devices

Build the optional CUDA extension, understand fallback and strict mode, inspect kernels, and distinguish host-backed tensors from resident buffers.

Read the complete guide →

YOU HAVE THE FOUNDATIONS.

Make the next experiment yours.

Try a convolutional network, inspect attention, or change the classifier you just built.

Explore runnable examples Improve the upstream guide

Search documentation

Enter opens the first result · Tab moves through links · Esc closes