Skip to main content

LAPLACE Optimizer (LAPLACE-LHC)

LAPLACE Optimizer is a Python desktop application for Bayesian optimization workflows, built with PyQt6 and BoTorch.

The application provides a graphical interface for configuring and running optimization experiments, monitoring inputs and objectives, and visualizing optimization results. It integrates with the laplace_server protocol and laplace_log logging system to support structured communication and logging throughout the optimization workflow.

Features

  • Graphical interface: Desktop application built with PyQt6.
  • Bayesian optimization: Optimization workflows powered by BoTorch and PyTorch.
  • Configurable models: Model construction resources for defining inputs, objectives, strategies, and acquisition functions.
  • Structured logging: Integration with laplace_log for experiment logging.
  • Server protocol integration: Communication based on the laplace_server protocol.
  • Result analysis: Tools for interpreting optimization results and visualizing model predictions.
  • Modular architecture: Separate components for the user interface, optimization logic, model construction, and post-analysis.

Installation

Prerequisites

Make sure Python and pip are installed in your environment. A virtual environment is recommended to isolate project dependencies.

Install dependencies

Install the required dependencies:

pip install PyQt6 qdarkstyle torch gpytorch botorch laplace-server laplace-log matplotlib

Install LAPLACE Optimizer

If the package is available on your configured Python package index, install it with:

pip install laplace-opt

If you are developing the project from its Git repository, see the source installation instructions below.

Getting Started

Option 1: Run the installed package

If you installed laplace-opt using pip:

  1. Copy the provided main.py example into your working directory, if required by your installation.
  2. Launch the application using this entry point.
  3. In the Model path field, specify the path to a model_construction/ directory containing the resources required for your optimization workflow.
  4. Your configuration will be loaded on the next application start.

The model construction directory defines the experiment-specific configuration, including inputs, objectives, optimization strategies, and acquisition functions.

Note: The exact contents of model_construction/ depend on the model and configuration expected by the application. You can copy/paste the default one and modify it according to your needs.

Option 2: Run from the Git repository

Clone the repository and navigate to the project directory:

git clone https://github.com/LOA-APPLI/laplace_opt
cd laplace_opt

Install the dependencies, then launch the application as a Python module:

python -m laplace_opt.main

Project Structure

laplace_opt/
├── laplace_opt/
│   ├── main.py                 # Application entry point
│   ├── app_config.ini          # Default configuration
│   ├── interface/              # GUI implementation
│   ├── core/                   # Optimization logic
│   ├── model_construction/     # Default model resources
│   ├── post_analysis/          # Result interpretation and analysis
│   └── utils/                  # Shared utilities
├── benchmark/                  # Benchmarking and algorithmic evaluation
├── examples/                   # Test-function data and usage examples
├── tests/                      # Developer-oriented tests
├── requirements.txt            # Package requirements
├── LICENSE                     # GPL-3.0 license
└── README.md                   # Project documentation

Development Roadmap

The following improvements are planned:

  • Post-analysis: Correct and adapt PostAnalysis, particularly to account for the updated model-saving workflow.
  • Input and output monitoring: Add the ability to track selected inputs or outputs without including them in the optimization process.
  • Visualization improvements: Improve PlotWidget and posterior plots, including 3D visualization and model-related bug fixes.
  • Suggestion representation: Replace the current sparse-list representation (e.g., [None, None, position, ..., None]) with a clearer and more robust data structure.
  • Acquisition function visualization: Consider adding acquisition function plots to PlotWindow.
  • Examples and post-analysis workflows: Review and update the examples based on saved .pt data for test functions, including the associated procedures for loading, interpreting, and analyzing results. This work should be aligned with the planned changes to PostAnalysis.
  • Benchmarking: Revisit the benchmark framework and assess the feasibility of completing and validating the intended algorithmic evaluation workflow. The current implementation is incomplete and is not yet a reliable basis for benchmarking results.

Development and Testing

The tests/ directory contains developer-oriented tests intended to support implementation, debugging, and regression checks during development. These tests are generally quicker to run than a full benchmarking workflow and are primarily intended for contributors rather than end users.

The tests and benchmark serve different purposes: tests help identify implementation issues, whereas benchmarking is intended to evaluate optimization performance under defined experimental conditions. Neither should be interpreted as comprehensive validation of the application in its current state.

The examples provide complementary reference material for working with saved test-function data and analyzing optimization results. Their compatibility with the current implementation still needs to be reviewed, particularly in light of the planned post-analysis changes.

License

This project is distributed under the GNU General Public License v3.0.

Project Status

LAPLACE Optimizer is actively used within the LAPLACE ecosystem for optimization experiments. It is intended for controlled research environments and scientific workflows.

Metadata

Release files for laplace-opt 0.1.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for laplace-opt 0.1.3
File Size Uploaded Provenance
laplace_opt-0.1.3.tar.gz 2.9 MB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for laplace-opt 0.1.3
File Interpreter ABI Platform
laplace_opt-0.1.3-py3-none-any.whl Python 3 none any Details

Total release size: 5.9 MB

Release files / laplace_opt-0.1.3.tar.gz

Download URL laplace_opt-0.1.3.tar.gz
Size 2.9 MB
Tags Source
SHA-256 checksum
How to use checksums
e4e2ca9e17e2bc11de7628bd3ca09a6fa36c8f18f3f23ad5151ee6c4ffa46ac0
BLAKE2b-256 checksum
How to use checksums
4d9975ed9b476fb2c9d56ee7e510bacc610ff6588b982f55ba58fab411661739
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.12

Release files / laplace_opt-0.1.3-py3-none-any.whl

Download URL laplace_opt-0.1.3-py3-none-any.whl
Size 3.0 MB
Tags Python 3
SHA-256 checksum
How to use checksums
ba16a29b406b9dd7a0db40ff91f3c976d8b062ef8ca5fa78ebd6a8c733c0c0d7
BLAKE2b-256 checksum
How to use checksums
3fc85c4de294118c9d6f62bbeadfbcfb4eae060c51ea67de4bcf4cf64a07424e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.12

Security for laplace-opt 0.1.3

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.

Release history Release notifications | RSS feed

This release

0.1.3 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page