Skip to main content

LQG: Inverse Optimal Control for Continuous Psychophysics

Experimenter-actor-loop image

Static Badge PyPI - Version Static Badge

This repository contains the official JAX implementation of the inverse optimal control method presented in the paper:

Straub, D., & Rothkopf, C. A. (2022). Putting perception into action with inverse optimal control for continuous psychophysics. eLife, 11, e76635.

Installation

The package can be installed via pip

python -m pip install lqg

Since publication of our eLife paper, I have substantially updated the package. If you want to use the package as described in the paper, please install an older version <0.2.0:

python -m pip install lqg==0.1.9

If you want the latest development version, I recommend cloning the repository and installing locally in a virtual environment:

git clone git@github.com:dominikstrb/lqg.git
cd lqg
python -m venv env
source env/bin/activate
python -m pip install -e .

Usage examples

The notebooks in the documentation illustrate how to use the lqg package to define optimal control models, simulate trajectories, and infer parameters from observed data.

  • Overview explains the model and its parameters in more detail, including the extension to subjective internal models (based on my tutorial at CCN 2022)
  • Data applies the method to data from a tracking experiment

Citation

If you use our method or code in your research, please cite our paper:

@article{straub2022putting,
  title={Putting perception into action with inverse optimal control for continuous psychophysics},
  author={Straub, Dominik and Rothkopf, Constantin A},
  journal={eLife},
  volume={11},
  pages={e76635},
  year={2022},
  publisher={eLife Sciences Publications Limited}
}

Extensions

Signal-dependent noise

This implementation supports the basic LQG framework. For the extension to signal-dependent noise (Todorov, 2005), please see our NeurIPS 2021 paper and its implementation.

Non-linear dynamics

We have recently extended this approach to non-linear dynamics and non-quadratic costs. Please check out our NeurIPS 2023 paper and its implementation.

Metadata

Release files for lqg 0.3.1

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

Source distribution (sdist)

Source distribution for lqg 0.3.1
File Size Uploaded
lqg-0.3.1.tar.gz 19.9 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for lqg 0.3.1
File Interpreter ABI Platform
lqg-0.3.1-py3-none-any.whl Python 3 none any Details

Total release size: 46.6 kB

Release files / lqg-0.3.1.tar.gz

Download URL lqg-0.3.1.tar.gz
Size 19.9 kB
Tags Source
SHA-256 checksum
How to use checksums
3e26498cc1f97fcf5d135a494b212108cd0f6e32cc967d43d7d110e1c91c0769
BLAKE2b-256 checksum
How to use checksums
39b39ff5977e3e9ab43afbfdf9b5ea1b9fa73a17f98f7c087a9bb8bd85f7ba28
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.12.19 {"installer":{"name":"uv","version":"0.12.19","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

Release files / lqg-0.3.1-py3-none-any.whl

Download URL lqg-0.3.1-py3-none-any.whl
Size 26.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
ead3941980581df20bd75e6bc54ade78a90c8b3cef2d0e1cdb096cd77a134b27
BLAKE2b-256 checksum
How to use checksums
34c62d33335ab36965ac45f522dc81c6fe39bb6b2a049729f7bf10b94f5b9e56
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.12.19 {"installer":{"name":"uv","version":"0.12.19","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

Release history Release notifications | RSS feed

This release

0.3.1 This release

2 release files

0.3.0

2 release files

0.2.11

2 release files

0.2.9

2 release files

0.2.8

2 release files

0.2.7

2 release files

0.2.6

2 release files

0.2.5

2 release files

0.1.9

2 release files

0.1.8

2 release files

0.1.7

2 release files

0.1.6

2 release files

0.1.5

2 release files

0.1.4

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release files

0.0.2

1 release file

0.0.1

2 release files

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