<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0">
<channel>
<title>TransportMaps Q&amp;A - Recent questions and answers in theory</title>
<link>https://transportmaps.mit.edu/qa/index.php?qa=qa&amp;qa_1=theory</link>
<description>Powered by Question2Answer</description>
<item>
<title>Answered: applying optimal tranport map to filtering theory</title>
<link>https://transportmaps.mit.edu/qa/index.php?qa=251&amp;qa_1=applying-optimal-tranport-map-to-filtering-theory&amp;show=256#a256</link>
<description>&lt;p&gt;Hello Peng,&lt;/p&gt;&lt;p&gt;There are mainly two lines of work regarding filtering/smoothing/parameter estimation (or more in general data assimilation):&lt;/p&gt;&lt;ul&gt;&lt;li&gt;The first one is along the lines of &lt;strong&gt;variational&lt;/strong&gt; filters/smoothers and is presented in&amp;nbsp;&lt;a rel=&quot;nofollow&quot; href=&quot;http://jmlr.org/papers/v19/17-747.html&quot;&gt;&amp;quot;Inference via low-dimensional couplings&amp;quot;&lt;/a&gt;. It is already implemented in TransportMaps 2.0, in the version described in the paper.&lt;/li&gt;&lt;li&gt;The second one is along the lines of &lt;strong&gt;ensemble&lt;/strong&gt; filters/smoothers and is presented in &lt;a rel=&quot;nofollow&quot; href=&quot;https://arxiv.org/abs/1907.00389&quot;&gt;&amp;quot;Coupling techniques for nonlinear ensemble filtering&amp;quot;&lt;/a&gt; . The lead in this case is Ricardo Baptista, and you should contact him for more details. These versions of filters are not included in the code yet (I know Ricardo has some software for it). It might be included in future releases of TransportMaps.&lt;/li&gt;&lt;/ul&gt;&lt;div&gt;On both fornts there are many open questions and new challenges which we could discuss off-line.&lt;/div&gt;&lt;div&gt;&amp;nbsp;&lt;/div&gt;&lt;div&gt;Best,&lt;/div&gt;&lt;div&gt;&amp;nbsp; Daniele&lt;/div&gt;</description>
<category>theory</category>
<guid isPermaLink="true">https://transportmaps.mit.edu/qa/index.php?qa=251&amp;qa_1=applying-optimal-tranport-map-to-filtering-theory&amp;show=256#a256</guid>
<pubDate>Fri, 16 Aug 2019 15:32:26 +0000</pubDate>
</item>
<item>
<title>Answered: constructing transport map from given samples and use it to get/samples from standard normal</title>
<link>https://transportmaps.mit.edu/qa/index.php?qa=205&amp;qa_1=constructing-transport-given-samples-samples-standard-normal&amp;show=232#a232</link>
<description>&lt;p&gt;Hi Saad, your question got cut out for some reasons, but I imagine you are referring to the rescaling done by the map \(L\), which (practically) takes the original sample and scales it to get a mean 0 and variance 0 sample. This is done because the map \(S\) is going to use polynomials orthogonal with respect ot \(N(0,1)\), which implies that they are mostly &amp;quot;accurate&amp;quot; on the bulk of \(N(0,1)\).&lt;/p&gt;&lt;p&gt;This question is similar to the issue described &lt;a rel=&quot;nofollow&quot; href=&quot;https://transportmaps.mit.edu/qa/index.php?qa=5&amp;amp;qa_1=cant-build-standard-normal-distribution-gumbel-distribution&quot;&gt;here&lt;/a&gt;&lt;/p&gt;&lt;p&gt;I hope this helps,&lt;/p&gt;&lt;p&gt;&amp;nbsp;Daniele&lt;/p&gt;</description>
<category>theory</category>
<guid isPermaLink="true">https://transportmaps.mit.edu/qa/index.php?qa=205&amp;qa_1=constructing-transport-given-samples-samples-standard-normal&amp;show=232#a232</guid>
<pubDate>Tue, 23 Jul 2019 15:43:39 +0000</pubDate>
</item>
<item>
<title>Answered: Composition of maps and order adaptativity</title>
<link>https://transportmaps.mit.edu/qa/index.php?qa=36&amp;qa_1=composition-of-maps-and-order-adaptativity&amp;show=37#a37</link>
<description>&lt;p&gt;Hi Paul,&lt;/p&gt;&lt;p&gt;I don&amp;#39;t have personal experience with the approach described in [TM1] &amp;quot;Bayesian inference with optimal maps&amp;quot;, but here are my insights with regard to map composition and tempering. In the following I assume that you have whitened the posterior, so that the prior distribution is a Standard Normal and tempering is applied to the whitened likelihood (either by noise covariance progression, data injection or forward accuracy).&lt;/p&gt;&lt;ul&gt;&lt;li&gt;I would say that the progression of the noise covariance should be slow enough so that at each step the map is able to capture most of the relation between reference (Standard Normal) and the tempered posterior. You should measure this using the variance diagnostic.&lt;/li&gt;&lt;li&gt;Regarding computational cost: if the maps are simple enough (at least order two or three for accuracy) then the approach can result in something more efficient than directly computing a transport map of high-order. You can think to the final map as many layer of a neural network with each layer corresponding to a map in the composition. This can help explain the expressivity of the representation. On the upside, of using compositions of monotone triangular maps is that the transformation is invertible (a property sometimes needed).&lt;/li&gt;&lt;li&gt;The composition of maps should take the prior/reference \(\nu_\rho\) to posterior \(\nu_\pi\) progressively, but it should not result in the &amp;quot;optimal composition&amp;quot; due to the inherent sequential construction. One could correct the maps in a final sweep over the maps to improve them, e.g. solving the \(n\) problems:&lt;br&gt;\[ T_i = \arg\min_{T\in \mathcal{T}_&amp;gt;} \mathcal{D}_{\text{KL}}\left( (T_1\circ T_{i-1})_\sharp \nu_\rho \middle\Vert T^\sharp (T_{i+1}\circ T_n)^\sharp \nu_\pi \right) \]&lt;br&gt;warm started at the \(T_i\) already learned through the tempering procedure.&lt;/li&gt;&lt;/ul&gt;&lt;div&gt;Can you clarify what you mean with &amp;quot;first map to get low-rank coupling&amp;quot;? Do you mean to find the rotation such that the next maps become the identity almost everywhere (like Likelihood Informed sub-spaces or Active sub-spaces)?&lt;/div&gt;&lt;div&gt;&amp;nbsp;&lt;/div&gt;&lt;div&gt;Also what do you mean with &amp;quot;unscaled&amp;quot;? Usually the scaling problem can arise when one tries to find &lt;a target=&quot;_blank&quot; rel=&quot;nofollow&quot; href=&quot;https://transportmaps.mit.edu/docs/examples-transport-from-samples.html&quot;&gt;maps from samples&lt;/a&gt; not when constructing &lt;a target=&quot;_blank&quot; rel=&quot;nofollow&quot; href=&quot;https://transportmaps.mit.edu/docs/examples-direct-transport.html&quot;&gt;maps from densities &lt;/a&gt;. So using a linear map at the beginning is not strictly necessary, but it shouldn&amp;#39;t hurt either.&lt;/div&gt;&lt;div&gt;&amp;nbsp;&lt;/div&gt;&lt;div&gt;I hope to have addressed some of your questions.&lt;/div&gt;&lt;div&gt;I will try to gather more insights from my collegues in the coming days.&lt;/div&gt;&lt;div&gt;&amp;nbsp;&lt;/div&gt;&lt;div&gt;Best,&lt;/div&gt;&lt;div&gt;&amp;nbsp;Daniele&lt;/div&gt;</description>
<category>theory</category>
<guid isPermaLink="true">https://transportmaps.mit.edu/qa/index.php?qa=36&amp;qa_1=composition-of-maps-and-order-adaptativity&amp;show=37#a37</guid>
<pubDate>Fri, 22 Jun 2018 10:02:17 +0000</pubDate>
</item>
<item>
<title>Answered: Why I can't build TM from non standard normal distribution to Gumbel distribution ?</title>
<link>https://transportmaps.mit.edu/qa/index.php?qa=5&amp;qa_1=cant-build-standard-normal-distribution-gumbel-distribution&amp;show=7#a7</link>
<description>&lt;p&gt;Hi Paul, Youssef&amp;#39;s comment is spot on. Here is the code implementing his suggestion:&lt;/p&gt;&lt;pre&gt;&lt;code class=&quot;language-python&quot;&gt;import matplotlib.pyplot as plt
import numpy as np
import scipy.stats as stats
import TransportMaps as TM
import TransportMaps.Functionals as FUNC
import TransportMaps.Maps as MAPS

import TransportMaps.Distributions as DIST
    
class GumbelDistribution(DIST.Distribution):
    def __init__(self, mu, beta):
        super(GumbelDistribution,self).__init__(1)
        self.mu = mu
        self.beta = beta
        self.dist = stats.gumbel_r(loc=mu, scale=beta)
    def pdf(self, x, params=None):
        return self.dist.pdf(x).flatten()
    def log_pdf(self, x, params=None):
        return self.dist.logpdf(x).flatten()
    def grad_x_log_pdf(self, x, params=None):
        m = self.mu
        b = self.beta
        z = (x-m)/b
        return (np.exp(-z)-1.)/b
    def hess_x_log_pdf(self, x, params=None):
        m = self.mu
        b = self.beta
        z = (x-m)/b
        return (-np.exp(-z)/b**2.)[:,:,np.newaxis]

mu = -63.
beta = 3.
pi = GumbelDistribution(mu,beta)

M=np.array([[-50],[-70],[-60]])

xnew=np.linspace(-70,-50,201)[:,np.newaxis]

mu = np.array([-60])
sigma = np.array([[8]])

rho=DIST.StandardNormalDistribution(1)

# Linear map
L = MAPS.LinearTransportMap(mu, sigma)
# New target (pullback of pi through L)
pull_L_pi = DIST.PullBackTransportMapDistribution(L, pi)

x = np.linspace(-70., -50., 100).reshape((100,1))

order=7
T = TM.Default_IsotropicIntegratedSquaredTriangularTransportMap(
    1, order, 'full')

push_rho=DIST.PushForwardTransportMapDistribution(T,rho)


qtype = 3      # Gauss quadrature
qparams =[20] # Quadrature order
reg = None     # No regularization
tol = 1e-6    # Optimization tolerance
ders = 2       # Use gradient and Hessian

# Solve D_KL(T_\sharp \rho || L^\sharp \pi)
log = push_rho.minimize_kl_divergence(
    pull_L_pi, qtype=qtype, qparams=qparams, regularization=reg,
    tol=tol, ders=ders)

# Obtain \pi \approx L_\sharp T_\sharp \rho
push_LT_rho = DIST.PushForwardTransportMapDistribution(L, push_rho)

plt.figure()
plt.plot(x, push_LT_rho.pdf(x),'b',label=r'pushrho');
plt.plot(x, pi.pdf(x),'g',label=r'π');
plt.legend();

&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;To know more on composition of maps, you can see &lt;a target=&quot;_blank&quot; rel=&quot;nofollow&quot; href=&quot;http://transportmaps.mit.edu/docs/example-beta-1d.html&quot;&gt;this&lt;/a&gt; page of the tutorial.&lt;/p&gt;&lt;p&gt;Best,&lt;/p&gt;&lt;p&gt;&amp;nbsp;Daniele&lt;/p&gt;</description>
<category>theory</category>
<guid isPermaLink="true">https://transportmaps.mit.edu/qa/index.php?qa=5&amp;qa_1=cant-build-standard-normal-distribution-gumbel-distribution&amp;show=7#a7</guid>
<pubDate>Fri, 03 Nov 2017 15:26:16 +0000</pubDate>
</item>
</channel>
</rss>