Optimal Transport Theory to Extract Spiking Motifs | Research Square window.SnipcartSettings = { analytics: { enabled: false } }; (function() { var accessVector = localStorage.getItem('access_vector') || ''; window.dataLayer = window.dataLayer || []; if (accessVector) { window.dataLayer.push({ user: { profile: { profileInfo: { snid: accessVector } } } }); } })(); (function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src='https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);})(window,document,'script','dataLayer','GTM-K279D39R'); Browse Preprints In Review Journals COVID-19 Preprints AJE Video Bytes Research Tools Research Promotion AJE Professional Editing AJE Rubriq About Preprint Platform In Review Editorial Policies Our Team Advisory Board Help Center Sign In Submit a Preprint Cite Share Download PDF Research Article Optimal Transport Theory to Extract Spiking Motifs Antoine Grimaldi, Boris Sotomayor-Gómez, Matthieu Gilson, Laurent Perrinet, and 2 more This is a preprint; it has not been peer reviewed by a journal. https://doi.org/ 10.21203/rs.3.rs-9518938/v1 This work is licensed under a CC BY 4.0 License Status: Posted Version 1 posted You are reading this latest preprint version Abstract Spatiotemporal spike motifs, i.e. repeating temporal sequences, of neural activity are thought to carry information beyond average firing rates, yet extracting such motifs from noisy spike trains remains challenging. In particular, most approaches rely on bin-by-bin comparisons that are sensitive to bin size and temporal jitter. Here, we investigate the use of the Earth Mover’s Distance (EMD), a metric from optimal transport theory, as a reconstruction loss for learning spiking motifs. We compare EMD to the conventional mean squared error (MSE) by training single-layer autoencoders with tied positive weights to reconstruct neural raster plots. Using synthetic spike trains with known ground-truth motifs, we systematically evaluate how each loss recovers spatiotemporal structure under varying numbers of training samples and different noise regimes, including temporal jitter, sequence warping, neuron dropout, and additive Poisson noise. We show that EMD-based training is more robust to temporal jitter and sequence warping, and more reliably estimates aligned spike timings when the number of training samples is limited. In contrast, MSE better captures the full spike distribution, i.e. the relative timing of the spikes as well as their temporal precision, when large datasets are available and is more resilient to additive noise. Applying the same framework to Neuropixels recordings from the Allen Institute visual coding dataset reveals that motifs learned with EMD are more discriminative of visual stimuli than those learned with MSE. Together, these results highlight the advantages of optimal transport–based losses for learning spatiotemporal motifs in neural population activity. Optimal Transport Theory Temporal Codes Spiking Motifs Neural Decoding Full Text Additional Declarations No competing interests reported. Cite Share Download PDF Status: Posted Version 1 posted You are reading this latest preprint version Research Square lets you share your work early, gain feedback from the community, and start making changes to your manuscript prior to peer review in a journal. As a division of Research Square Company, we’re committed to making research communication faster, fairer, and more useful. We do this by developing innovative software and high quality services for the global research community. Our growing team is made up of researchers and industry professionals working together to solve the most critical problems facing scientific publishing. Also discoverable on Platform About Our Team In Review Editorial Policies Advisory Board Help Center Resources Author Services Accessibility API Access RSS feed Manage Cookie Preferences © Research Square 2026 | ISSN 2693-5015 (online) Privacy Policy Terms of Service Do Not Sell My Personal Information {"props":{"pageProps":{"initialData":{"identity":"rs-9518938","acceptedTermsAndConditions":true,"allowDirectSubmit":false,"archivedVersions":[],"articleType":"Research Article","associatedPublications":[],"authors":[{"id":629309277,"identity":"524c7a67-f4b1-4d20-90cc-3e3c4be54da7","order_by":0,"name":"Antoine Grimaldi","email":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAZAAAAAyAQMAAABI0h/eAAAABlBMVEX///8AAABVwtN+AAAACXBIWXMAAA7EAAAOxAGVKw4bAAABBElEQVRIiWNgGAWjYLCCBDDJ2MDAUMDMww8Rk8OjnhlZiwEzj2QDmGeMXwsCGDAzGBwgoIV/dv/BBw932DDIRx9u3fDDwFrG+PjZYx9/MBjk49Iicecws0HimTQGw3OJbTd7DNJ5zM7kJc/mYTCwbMCl50Yym0Ri22EGwx7Gths8Bod5zG7wGAMd+8cAlw55iJb/YC03/wC1GM/gMWYEOgynFgOIlgMM8jyMbbdBthhI8Bgz8ODRYngj2dggsS2ZxwCkRQboF4kzOcbMPAa4tcjdSHz48GebnZx8D/uzm28qrO35288AHVaBWwsM8ECjA+5gQhqAQL6BCEWjYBSMglEwMgEA6IxMqx3QGPAAAAAASUVORK5CYII=","orcid":"","institution":"Brain and Cognition Research Center","correspondingAuthor":true,"prefix":"","firstName":"Antoine","middleName":"","lastName":"Grimaldi","suffix":""},{"id":629309278,"identity":"9acb29d8-5049-456f-a78a-548b0144c9c5","order_by":1,"name":"Boris Sotomayor-Gómez","email":"","orcid":"","institution":"Center for Neurology, Department of Parkinson, Sleep and Movement Disorders","correspondingAuthor":false,"prefix":"","firstName":"Boris","middleName":"","lastName":"Sotomayor-Gómez","suffix":""},{"id":629309280,"identity":"122b5001-b8fe-4726-8f5e-21f70d63cdd7","order_by":2,"name":"Matthieu Gilson","email":"","orcid":"","institution":"Institut de Neurosciences de la Timone","correspondingAuthor":false,"prefix":"","firstName":"Matthieu","middleName":"","lastName":"Gilson","suffix":""},{"id":629309281,"identity":"e25921da-4496-4d0d-b2df-2bab16e11afe","order_by":3,"name":"Laurent Perrinet","email":"","orcid":"","institution":"Institut de Neurosciences de la Timone","correspondingAuthor":false,"prefix":"","firstName":"Laurent","middleName":"","lastName":"Perrinet","suffix":""},{"id":629309282,"identity":"5afef656-fc8d-4815-9624-ae5c92554c8c","order_by":4,"name":"Andrea Alamia","email":"","orcid":"","institution":"Brain and Cognition Research Center","correspondingAuthor":false,"prefix":"","firstName":"Andrea","middleName":"","lastName":"Alamia","suffix":""},{"id":629309284,"identity":"a04d6fb3-b606-401e-9c8b-8cd3d38bb0ae","order_by":5,"name":"Martin Vinck","email":"","orcid":"","institution":"Ernst Strüngmann Institute for Neuroscience","correspondingAuthor":false,"prefix":"","firstName":"Martin","middleName":"","lastName":"Vinck","suffix":""}],"badges":[],"createdAt":"2026-04-24 15:38:30","currentVersionCode":1,"declarations":"","doi":"10.21203/rs.3.rs-9518938/v1","doiUrl":"https://doi.org/10.21203/rs.3.rs-9518938/v1","draftVersion":[],"editorialEvents":[],"editorialNote":"","failedWorkflow":false,"files":[{"id":108168299,"identity":"00565d3b-c2e1-4f7c-9feb-5bd23877ed23","added_by":"auto","created_at":"2026-04-30 06:25:53","extension":"pdf","order_by":1,"title":"","display":"","copyAsset":false,"role":"manuscript-pdf","size":479592,"visible":true,"origin":"","legend":"","description":"","filename":"bcsubmission.pdf","url":"https://assets-eu.researchsquare.com/files/rs-9518938/v1_covered_e207ecde-35f4-448c-9d52-6a9e7a78534b.pdf"}],"financialInterests":"No competing interests reported.","formattedTitle":"Optimal Transport Theory to Extract Spiking Motifs","fulltext":[],"fulltextSource":"","fullText":"","funders":[],"hasAdminPriorityOnWorkflow":false,"hasManuscriptDocX":false,"hasOptedInToPreprint":true,"hasPassedJournalQc":"","hasAnyPriority":true,"hideJournal":true,"highlight":"","institution":"","isAcceptedByJournal":false,"isAuthorSuppliedPdf":true,"isDeskRejected":"","isHiddenFromSearch":false,"isInQc":false,"isInWorkflow":false,"isPdf":true,"isPdfUpToDate":true,"isWithdrawnOrRetracted":false,"journal":{"display":true,"email":"
[email protected]","identity":"researchsquare","isNatureJournal":false,"hasQc":true,"allowDirectSubmit":true,"externalIdentity":"","sideBox":"","snPcode":"","submissionUrl":"/submission","title":"Research Square","twitterHandle":"researchsquare","acdcEnabled":true,"dfaEnabled":false,"editorialSystem":"","reportingPortfolio":"","inReviewEnabled":false,"inReviewRevisionsEnabled":true},"keywords":"Optimal Transport Theory, Temporal Codes, Spiking Motifs, Neural Decoding","lastPublishedDoi":"10.21203/rs.3.rs-9518938/v1","lastPublishedDoiUrl":"https://doi.org/10.21203/rs.3.rs-9518938/v1","license":{"name":"CC BY 4.0","url":"https://creativecommons.org/licenses/by/4.0/"},"manuscriptAbstract":"\u003cp\u003eSpatiotemporal spike motifs, i.e. repeating temporal sequences, of neural activity are thought to carry information beyond average firing rates, yet extracting such motifs from noisy spike trains remains challenging. In particular, most approaches rely on bin-by-bin comparisons that are sensitive to bin size and temporal jitter. Here, we investigate the use of the Earth Mover\u0026rsquo;s Distance (EMD), a metric from optimal transport theory, as a reconstruction loss for learning spiking motifs. We compare EMD to the conventional mean squared error (MSE) by training single-layer autoencoders with tied positive weights to reconstruct neural raster plots. Using synthetic spike trains with known ground-truth motifs, we systematically evaluate how each loss recovers spatiotemporal structure under varying numbers of training samples and different noise regimes, including temporal jitter, sequence warping, neuron dropout, and additive Poisson noise. We show that EMD-based training is more robust to temporal jitter and sequence warping, and more reliably estimates aligned spike timings when the number of training samples is limited. In contrast, MSE better captures the full spike distribution, i.e. the relative timing of the spikes as well as their temporal precision, when large datasets are available and is more resilient to additive noise. Applying the same framework to Neuropixels recordings from the Allen Institute visual coding dataset reveals that motifs learned with EMD are more discriminative of visual stimuli than those learned with MSE. Together, these results highlight the advantages of optimal transport\u0026ndash;based losses for learning spatiotemporal motifs in neural population activity.\u003c/p\u003e","manuscriptTitle":"Optimal Transport Theory to Extract Spiking Motifs","msid":"","msnumber":"","nonDraftVersions":[{"code":1,"date":"2026-04-30 06:24:55","doi":"10.21203/rs.3.rs-9518938/v1","editorialEvents":[{"type":"communityComments","content":0}],"status":"published","journal":{"display":true,"email":"
[email protected]","identity":"researchsquare","isNatureJournal":false,"hasQc":true,"allowDirectSubmit":true,"externalIdentity":"","sideBox":"","snPcode":"","submissionUrl":"/submission","title":"Research Square","twitterHandle":"researchsquare","acdcEnabled":true,"dfaEnabled":false,"editorialSystem":"","reportingPortfolio":"","inReviewEnabled":false,"inReviewRevisionsEnabled":true}}],"origin":"","ownerIdentity":"b559fc5e-8ffb-497b-9203-32b81a6ff631","owner":[],"postedDate":"April 30th, 2026","published":true,"recentEditorialEvents":[{"type":"editorAssigned","content":"","date":"2026-05-01T19:04:48+00:00","index":"","fulltext":""}],"rejectedJournal":[],"revision":"","amendment":"","status":"posted","subjectAreas":[],"tags":[],"updatedAt":"2026-04-30T06:24:55+00:00","versionOfRecord":[],"versionCreatedAt":"2026-04-30 06:24:55","video":"","vorDoi":"","vorDoiUrl":"","workflowStages":[]},"version":"v1","identity":"rs-9518938","journalConfig":"researchsquare"},"__N_SSP":true},"page":"/article/[identity]/[[...version]]","query":{"redirect":"/article/rs-9518938","identity":"rs-9518938","version":["v1"]},"buildId":"XKTyCvWXoU3ODBz1xrDgd","isFallback":false,"isExperimentalCompile":false,"dynamicIds":[84888],"gssp":true,"scriptLoader":[]}
Text is read by the "Ask this paper" AI Q&A widget below.
Extraction quality varies by source — PMC NXML preserves structure
cleanly, OA-HTML may include some navigation residue, and OA-PDF can
have broken hyphenation. The publisher copy
(via DOI)
is the canonical version.