Skip to main content

A machine learning library intended for surrogate modeling tasks.

Project description

IFE Surrogate GP

A flexible and extensible library for Gaussian Processes, built with performance and modularity in mind.
Models can be trained via maximum likelihood estimation or by baysian inference.

Features

  • High-performance kernels (JAX-compatible)
  • Composable API for building custom models
  • Multiple optimizers (Optax, Scipy, etc.)
  • Built in Baysian inference of the models with NumPyro
  • Automatic hyperparameter handling
  • Built-in training workflows

Installation

pip install ife_surrogate

Usage

Quickstart

import ife_surrogate


dataset = np.load("some_data.npy", allow_pickle=True).item()
X, Y, f = dataset["X"], dataset["Y"], dataset["f"]

key = jr.key(seed=42)
(X_train, Y_train), (X_test, Y_test), _= train_test_split(
    X=X, Y=Y, f=f, 
    split=(0.9, 0.1, 0), 
    key= key
)

d = X_train.shape[1]
priors = {"lengthscale": Uniform(1e-0, 1e1), "power": Uniform(1, 2)}
kernel = kernels.Kriging(lengthscale=jnp.ones(d), power=jnp.ones(d), priors=priors)

model = models.WidebandGP(X_train, Y_train, kernel, f)

trainer = trainers.SwarmTrainer(number_iterations=200, number_particles=100)
trainer.train(model)

pred, var = model.predict(X_test)

Documentation


Key Components

  • Kernels

    • Kriging
    • RBF
    • Matern
    • SumKernel
    • ProductKernel
    • Scale
    • RQ
    • Noise
  • Models

    • WidebandGP
    • ScalerGP
  • *Trainers

    • OptaxTrainer
    • SwarmTrainer

Roadmap



License

Distributed under the MIT License. See LICENSE for more information.

References

The mathematical background and implementation of these models are based on the following publications:

Gaussian Process & Student-t Theory

Wideband & Multi-output Modeling

  • Wideband Architecture: Rezende, R. S., Hansen, J., Piwonski, A., & Schuhmann, R. (2024). Wideband Kriging for Multiobjective Optimization of a High-Voltage EMI Filter. IEEE Transactions on Electromagnetic Compatibility, 66(4), 1116–1124.
  • Multi-output Separable GPs: Bilionis, I., Zabaras, N., Konomi, B. A., & Lin, G. (2013). Multi-output separable Gaussian process: Towards an efficient, fully Bayesian paradigm for uncertainty quantification. Journal of Computational Physics, 241, 212–239.
  • Vector-Valued Kernels: Alvarez, M. A., Rosasco, L., & Lawrence, N. D. (2012). Kernels for Vector-Valued Functions: A Review. [cite_start]Foundations and Trends in Machine Learning.

Inference & Software Stack

Acknowledgements

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ife_surrogate-0.2.4.tar.gz (38.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ife_surrogate-0.2.4-py3-none-any.whl (59.6 kB view details)

Uploaded Python 3

File details

Details for the file ife_surrogate-0.2.4.tar.gz.

File metadata

  • Download URL: ife_surrogate-0.2.4.tar.gz
  • Upload date:
  • Size: 38.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.7

File hashes

Hashes for ife_surrogate-0.2.4.tar.gz
Algorithm Hash digest
SHA256 e497b6cd8fc3d67500078d65af861abce1ee15c067618914b01a5f17c863b4df
MD5 1afc26b0d7c456c2bf4b5c46870a298e
BLAKE2b-256 bfe042a917c3ab1404b99c6a3d88f5a6b50fb78634d6b8ba1d04ec94cbf64255

See more details on using hashes here.

File details

Details for the file ife_surrogate-0.2.4-py3-none-any.whl.

File metadata

  • Download URL: ife_surrogate-0.2.4-py3-none-any.whl
  • Upload date:
  • Size: 59.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.7

File hashes

Hashes for ife_surrogate-0.2.4-py3-none-any.whl
Algorithm Hash digest
SHA256 d66555a9382b26c283969c43a3e8ebd22d2fc716cd24187f3347708cb439dbdc
MD5 93431f87597d7e727d898fe53b7ebba2
BLAKE2b-256 f72103b89ef12546f9bd4fbcc3286b8a2e38d658a84538d25ada308624560436

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page