Models (Machine Gnostics MAGNET)¶
The machinegnostics.magnet module provides model containers and neural network architectures for building deep learning pipelines on gnostic algebra.
Key Model Classes¶
- Model β Abstract base container with
compile(),fit(),predict(),evaluate(),summary(), and weight management APIs - Sequential β Linear stack of layers with straightforward forward propagation
- GnosticNeuron β MAGNETβspecific neuron implementing gnostic algebra transformations (
fi,fj,hi,hj,ei)
Model Utilities¶
get_model(name)β Resolve model name to instanceload_model(filepath)β Load a saved model from disksave_model(model, filepath)β Persist a model to disk
Callbacks & History¶
- Callback β Base callback class for training hooks
- EarlyStopping β Stop training when monitored metric stops improving
- History β Automatically tracks epoch-level metrics during training
Key Concepts¶
Model Lifecycle¶
- Construction β Define layer architecture
- Compilation β Configure loss and optimizer via
compile() - Training β Fit on data via
fit(X, y, epochs, batch_size, callbacks) - Evaluation β Validate performance via
evaluate(X, y) - Inference β Generate predictions via
predict(X)
Gnostic Parameter Handling¶
MAGNET models provide specialized handling for gnostic parameters:
- s β Scale parameter for coordinate transformation
- z0 β Center parameter for coordinate origin
- *_s, *_z0 β Layer-specific scale/center variants
Optimizers automatically apply adaptive scaling to these parameters during training.
Author: Nirmal Parmar