:orphan:
=============================================
Examples
=============================================
.. raw:: html
.. thumbnail-parent-div-open
.. thumbnail-parent-div-close
.. raw:: html
########
Examples
########
Some introduction to the encoding/decoding framework.
.. raw:: html
.. thumbnail-parent-div-open
.. raw:: html
.. only:: html
.. image:: /auto_examples/00_encodingdecoding/images/thumb/sphx_glr_fit_residuals_thumb.png
:alt:
:doc:`/auto_examples/00_encodingdecoding/fit_residuals`
.. raw:: html
Fit the residual covariance matrix
.. raw:: html
.. only:: html
.. image:: /auto_examples/00_encodingdecoding/images/thumb/sphx_glr_masked_stimulus_decoding_thumb.png
:alt:
:doc:`/auto_examples/00_encodingdecoding/masked_stimulus_decoding`
.. raw:: html
Stimulus decoding using stimulus mask
.. raw:: html
.. only:: html
.. image:: /auto_examples/00_encodingdecoding/images/thumb/sphx_glr_linear_encoding_model_thumb.png
:alt:
:doc:`/auto_examples/00_encodingdecoding/linear_encoding_model`
.. raw:: html
Linear encoding model
.. raw:: html
.. only:: html
.. image:: /auto_examples/00_encodingdecoding/images/thumb/sphx_glr_encoding_model_thumb.png
:alt:
:doc:`/auto_examples/00_encodingdecoding/encoding_model`
.. raw:: html
Create a simple Gaussian Prf encoding model
.. raw:: html
.. only:: html
.. image:: /auto_examples/00_encodingdecoding/images/thumb/sphx_glr_invert_model_thumb.png
:alt:
:doc:`/auto_examples/00_encodingdecoding/invert_model`
.. raw:: html
Invert encoding model
.. raw:: html
.. only:: html
.. image:: /auto_examples/00_encodingdecoding/images/thumb/sphx_glr_decode_thumb.png
:alt:
:doc:`/auto_examples/00_encodingdecoding/decode`
.. raw:: html
Decoding of stimuli from neural data
.. raw:: html
.. only:: html
.. image:: /auto_examples/00_encodingdecoding/images/thumb/sphx_glr_decode_v1_thumb.png
:alt:
:doc:`/auto_examples/00_encodingdecoding/decode_v1`
.. raw:: html
Recontruct a 2D visual stimulus from real fMRI data
.. raw:: html
.. only:: html
.. image:: /auto_examples/00_encodingdecoding/images/thumb/sphx_glr_decode_visual_thumb.png
:alt:
:doc:`/auto_examples/00_encodingdecoding/decode_visual`
.. raw:: html
Fit a 2D PRF model
.. raw:: html
.. only:: html
.. image:: /auto_examples/00_encodingdecoding/images/thumb/sphx_glr_fisher_information_thumb.png
:alt:
:doc:`/auto_examples/00_encodingdecoding/fisher_information`
.. raw:: html
Fisher information to estimate precision of encoding parameters across stimulus space
.. raw:: html
.. only:: html
.. image:: /auto_examples/00_encodingdecoding/images/thumb/sphx_glr_fit_prf_thumb.png
:alt:
:doc:`/auto_examples/00_encodingdecoding/fit_prf`
.. raw:: html
Different flavors of visual population receptive field models
.. raw:: html
.. only:: html
.. image:: /auto_examples/00_encodingdecoding/images/thumb/sphx_glr_decode2d_thumb.png
:alt:
:doc:`/auto_examples/00_encodingdecoding/decode2d`
.. raw:: html
Decoding 2D stimuli from neural data
.. thumbnail-parent-div-close
.. raw:: html
######################################
End-to-end decoding pipeline on real data
######################################
Three connected examples that walk through a full encoding-model decoding
pipeline on a small extract of single-trial fMRI data (numerosity task,
right numerosity-tuned parietal cortex):
1. Select responsive voxels from whole-brain R² by fitting a 2-component
mixture and picking a threshold (FDR or posterior).
2. Decode trial-wise stimulus posteriors using a noise model whose
covariance is regularised by *geodesic* distance on the cortical surface.
3. Quantify *expected* decoding uncertainty by simulating from the fitted
model and re-decoding.
Each example is self-contained but share the same demo dataset, which is
downloaded on first run via ``braincoder.utils.data.load_dehollander2024_npc``.
.. raw:: html
.. thumbnail-parent-div-open
.. raw:: html
.. only:: html
.. image:: /auto_examples/01_decoding_pipeline/images/thumb/sphx_glr_01_voxel_selection_fdr_thumb.png
:alt:
:doc:`/auto_examples/01_decoding_pipeline/01_voxel_selection_fdr`
.. raw:: html
Voxel selection via a 2-component R² mixture model
.. raw:: html
.. only:: html
.. image:: /auto_examples/01_decoding_pipeline/images/thumb/sphx_glr_03_expected_uncertainty_thumb.png
:alt:
:doc:`/auto_examples/01_decoding_pipeline/03_expected_uncertainty`
.. raw:: html
Expected decoding uncertainty via simulate + decode
.. raw:: html
.. only:: html
.. image:: /auto_examples/01_decoding_pipeline/images/thumb/sphx_glr_02_geodesic_decoder_thumb.png
:alt:
:doc:`/auto_examples/01_decoding_pipeline/02_geodesic_decoder`
.. raw:: html
Geodesic-regularised noise model for trial-wise decoding
.. thumbnail-parent-div-close
.. raw:: html
.. toctree::
:hidden:
:includehidden:
/auto_examples/00_encodingdecoding/index.rst
/auto_examples/01_decoding_pipeline/index.rst
.. only:: html
.. container:: sphx-glr-footer sphx-glr-footer-gallery
.. container:: sphx-glr-download sphx-glr-download-python
:download:`Download all examples in Python source code: auto_examples_python.zip `
.. container:: sphx-glr-download sphx-glr-download-jupyter
:download:`Download all examples in Jupyter notebooks: auto_examples_jupyter.zip `
.. only:: html
.. rst-class:: sphx-glr-signature
`Gallery generated by Sphinx-Gallery