{"id":26740628,"url":"https://github.com/piras-s/tuningcurvesnestedbayesianinference","last_synced_at":"2026-05-18T09:05:01.796Z","repository":{"id":284712893,"uuid":"955817804","full_name":"Piras-S/TuningCurvesNestedBayesianInference","owner":"Piras-S","description":"Bayesian inference of neural tuning curves using nested sampling (PyMultiNest), with theory, simulation, and diagnostic visualizations.","archived":false,"fork":false,"pushed_at":"2025-03-27T09:14:17.000Z","size":747,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-09-05T13:57:31.572Z","etag":null,"topics":["bayesian-inference","data-visualization","machine-learning","model-evaluation","nested-sampling","neuroscience","pymultinest","python3","simulation"],"latest_commit_sha":null,"homepage":"","language":"Jupyter Notebook","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Piras-S.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2025-03-27T08:45:57.000Z","updated_at":"2025-03-27T09:32:00.000Z","dependencies_parsed_at":"2025-03-27T09:43:43.806Z","dependency_job_id":"185d74b5-75f7-4b29-a30b-68d669971da4","html_url":"https://github.com/Piras-S/TuningCurvesNestedBayesianInference","commit_stats":null,"previous_names":["piras-s/tuningcurvesnestedbayesianinference"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Piras-S/TuningCurvesNestedBayesianInference","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Piras-S%2FTuningCurvesNestedBayesianInference","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Piras-S%2FTuningCurvesNestedBayesianInference/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Piras-S%2FTuningCurvesNestedBayesianInference/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Piras-S%2FTuningCurvesNestedBayesianInference/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Piras-S","download_url":"https://codeload.github.com/Piras-S/TuningCurvesNestedBayesianInference/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Piras-S%2FTuningCurvesNestedBayesianInference/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279002623,"owners_count":26083425,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-10T02:00:06.843Z","response_time":62,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bayesian-inference","data-visualization","machine-learning","model-evaluation","nested-sampling","neuroscience","pymultinest","python3","simulation"],"created_at":"2025-03-28T05:20:14.480Z","updated_at":"2025-10-10T03:34:02.063Z","avatar_url":"https://github.com/Piras-S.png","language":"Jupyter Notebook","funding_links":[],"categories":[],"sub_categories":[],"readme":"#  Bayesian Inference of Neural Tuning Curves with Nested Sampling\n\nThis project demonstrates how to simulate and analyze neural tuning curve data using **Bayesian inference** via **nested sampling**. It combines theory, code, and visual intuition to explain how posterior distributions are obtained, and why they should be interpreted with care.\n\n---\n\n## Project Overview\n\nI simulate the firing response of a neuron to different stimulus angles (e.g., orientation of a visual stimulus), assuming a Gaussian-shaped tuning curve. Using synthetic data, I then perform **Bayesian parameter estimation** with PyMultiNest to recover the model parameters:\n- $r_{\\text{max}}$: maximum firing rate,\n- $s_{\\text{max}}$: preferred stimulus orientation,\n- $\\sigma_f$: tuning width.\n\n\n---\n\n## Concepts Covered\n\n- Bayesian inference: likelihood, priors, posteriors, evidence\n- Nested sampling algorithm (with theory + toy implementation)\n- Parameter estimation in a neural tuning model\n- Posterior uncertainty, model mismatch, and identifiability\n- Practical diagnostics for PyMultiNest fits\n\n---\n\n## Visual Highlights\n\n### Toy Nested Sampling Animation\nA minimal 2D implementation of nested sampling illustrates the algorithm’s core idea: removing low-likelihood regions and progressively zooming in on high-probability space.\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"nested_sampling.gif\" width=\"400\"/\u003e\n\u003c/p\u003e\n\n\n---\n\n**Dependencies**:\n   numpy matplotlib pandas pymultinest corner imageio\n   \n   \n\n**References**\n\nDayan, P., \u0026 Abbott, L. F. (2001). Theoretical Neuroscience: Computational and Mathematical Modeling of Neural Systems. MIT Press.\n\nFeroz, F., Hobson, M. P., \u0026 Bridges, M. (2009). MultiNest: an efficient and robust Bayesian inference tool for cosmology and particle physics.\n\n---\n\n## Project Structure\n```bash\n├── simulation.ipynb # Generate and visualize synthetic data \n├── fitting.ipynb # Educational toy example of nested sampling  + Run and analyze full model fitting \n├── run_pymultinest_fit.py # Script to perform inference with PyMultiNest \n├── tuning_data.csv # Simulated dataset \n├── figures/\n├── chains/\n└── nested_sampling.gif # Animation of toy nested sampling\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpiras-s%2Ftuningcurvesnestedbayesianinference","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpiras-s%2Ftuningcurvesnestedbayesianinference","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpiras-s%2Ftuningcurvesnestedbayesianinference/lists"}