Feyn

Feyn

  • Tutorials
  • Guides
  • API Reference
  • FAQ

›Primitive Operations

Getting Started

  • Quick start
  • Using Feyn
  • Installation
  • Transition to Feyn 3.0
  • What is a QLattice?
  • Community edition
  • Commercial use

Essentials

  • Auto Run
  • Visualise a model
  • Summary plot
  • Semantic types
  • Categorical features
  • Estimating priors
  • Model parameters
  • Predicting with a model
  • Saving and loading models
  • Filtering models
  • Seeding a QLattice
  • Privacy

Evaluate Regressors

  • Regression plot
  • Residuals plot

Evaluate Classifiers

  • ROC curve
  • Confusion matrix
  • Plot probability scores

Understand Your Models

  • Plot response
  • Plot response 2D
  • Model signal
  • Segmented loss
  • Interactive flow

Primitive Operations

  • Using the primitives
  • Updating priors
  • Sample models
  • Fitting models
  • Pruning models
  • Diverse models
  • Updating a QLattice
  • Validate data

Advanced

  • Converting a model to SymPy
  • Setting themes
  • Saving a graph as an image
  • Using the query language
  • Model complexity

Updating a QLattice

by: Kevin Broløs & Chris Cave
(Feyn version 3.0 or newer)

A QLattice can be considered as a probability distribution of Model structures, that can be sampled from with the sample_model function. A structure is defined as the input names, function names and their combinations inside a Model. This excludes its weights and biases.

When you update the QLattice with a list of Models, the probability density function is updated to encourage those structures. Without updating, the QLattice will keep generating models with a random structure.

import feyn
from feyn.datasets import make_classification

train, test = make_classification()

ql = feyn.QLattice()

models = ql.sample_models(train.columns, 'y', 'classification', max_complexity=10)

models = feyn.fit_models(models, train, 'binary_cross_entropy', 'bic', 4)

models = feyn.prune_models(models, True, True)

ql.update(
    models=models
)

models

The list of Models to update the QLattice with.

← Diverse modelsValidate data →
  • models
Copyright © 2023 Abzu.ai
Feyn®, QGraph®, and the QLattice® are registered trademarks of Abzu®