Skip to main content

Gaussian Processes for orientation preference maps

Project description

Gaussian Processes for Orientation Preference Maps

This package is a Python implementation of a Gaussian Process (GP) method for inferring cortical maps (Macke et al., 2011), based on their original MATLAB-code. Compared to conventional (vector averaging) approaches, the method computes better maps from little data and can be used to quantify the uncertainty in an estimated orientation preference map (OPM). It also provides a principled way to choose the parameters in the smoothing step and incorporate inhomogeneous noise variances as well as noise correlations.

The basic idea is to specify a prior over OPMs as a GP. This means that a-priori assumptions about correlations of the pixels in a map are specified as a covariance function K. In this case, we use a Difference of Gaussians (DoG) kernel. This covariance function encodes our assumptions that OPMs are smooth and have a semi-periodic structure. This prior is then updated via Bayes' rule with imaging data to obtain a smooth posterior estimate of an OPM.

My notes on the method (including derivations not in the original paper) can be found here.

A number of notebooks illustrate how to use the package:

OPM.ipynb

contains basic functionality for handling OPMs:

  • sample from this prior to obtain a ground truth OPM
  • visualize OPMs
  • simulate neural responses given an OPM and a set of stimuli
  • compute maximum likelihood/vector averaging estimate of the OPM
  • smooth the OPM with a Gaussian kernel

BayesianOPM.ipynb

shows details about the GP method:

  • covariance function (DoG kernel)
  • estimate hyperparameters of the prior covariance function from the empirical map
  • learn noise model iteratively from data
  • posterior inference

FerretData.ipynb

serves as an illustration on how to use GPs to infer OPMs from real imaging data (replicating the results of Macke et al., 2011):

  • visualize inhomogeneous and correlated noise structure of the data
  • obtain smooth estimate based on "ground truth"
  • GP posterior inference on real data

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

gp-maps-python-0.0.1.tar.gz (17.9 kB view details)

Uploaded Source

Built Distribution

gp_maps_python-0.0.1-py3-none-any.whl (38.3 kB view details)

Uploaded Python 3

File details

Details for the file gp-maps-python-0.0.1.tar.gz.

File metadata

  • Download URL: gp-maps-python-0.0.1.tar.gz
  • Upload date:
  • Size: 17.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.42.1 CPython/3.8.1

File hashes

Hashes for gp-maps-python-0.0.1.tar.gz
Algorithm Hash digest
SHA256 228849e089ccd16e97c76134ea76ad3c006707389e298e19e48062aa17878cf2
MD5 4b87bb9985c86f171687639853633f60
BLAKE2b-256 d7ffeabbb2a645a3c573199444fce15cc43a2e5cc9765f34a1bff03dbea82abc

See more details on using hashes here.

File details

Details for the file gp_maps_python-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: gp_maps_python-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 38.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.42.1 CPython/3.8.1

File hashes

Hashes for gp_maps_python-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 f1be3f0d7eb57b68d9fafc3db337c535d6475a56c3e513f49890fe14c8584039
MD5 a656cd8969acd9123a2e2ded89a95b80
BLAKE2b-256 ac8b914c6e3399be2d450c173e018d045f7e4d95c38f06fcd4ea433e6b4565ec

See more details on using hashes here.

Supported by

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