https://software.intel.com/fr-fr/forums/topic/365581/feed
frHi Vineet,
https://software.intel.com/fr-fr/comment/1758565#comment-1758565
<a id="comment-1758565"></a>
<div class="field field-name-comment-body field-type-text-long field-label-hidden"><div class="field-items"><div class="field-item even" property="content:encoded"><p>Hi Vineet,</p>
<p>I have a couple of questions regarding application of your algorithm. I've sent you a private message with more details. Please respond me as soon as you have time.</p>
<p>Best regards,<br />
Sergey</p>
</div></div></div>Tue, 08 Oct 2013 22:25:00 +0000Sergey Kostrovcomment 1758565 at https://software.intel.com>>Technical Note: Improving
https://software.intel.com/fr-fr/comment/1724240#comment-1724240
<a id="comment-1724240"></a>
<div class="field field-name-comment-body field-type-text-long field-label-hidden"><div class="field-items"><div class="field-item even" property="content:encoded"><p>>><strong>Technical Note:</strong> Improving computational efficiency in large linear inverse problems: an example from carbon<br />
>>dioxide flux estimation.<br />
>><br />
>><strong>Abstract.</strong> Addressing a variety of questions within Earth science disciplines entails the inference<br />
>>of the spatio-temporal distribution of parameters of interest based on observations of related<br />
>>quantities. Such estimation problems often represent inverse problems that are formulated as<br />
>>linear optimization problems. Computational limitations arise when the number of observations and/or<br />
>>the size of the discretized state space become large, especially if the inverse problem is<br />
>>formulated in a probabilistic framework and therefore aims to assess the uncertainty associated<br />
>>with the estimates. This work proposes two approaches to lower the computational costs and memory<br />
>>requirements for large linear space-time inverse problems, taking the Bayesian approach for<br />
>>estimating carbon dioxide (CO2) emissions and uptake (a.k.a. fluxes) as a prototypical example.<br />
>>The first algorithm can be used to efficiently multiply two matrices, as long as one can be<br />
>>expressed as a Kronecker product of two smaller matrices, a condition that is typical when<br />
>>multiplying a sensitivity matrix by a covariance matrix in the solution of inverse problems.<br />
>>The second algorithm can be used to compute a posteriori uncertainties directly at aggregated<br />
>>spatio-temporal scales, which are the scales of most interest in many inverse problems. Both<br />
>>algorithms have significantly lower memory requirements and computational complexity relative to<br />
>>direct computation of the same quantities (O(n2.5) vs. O(n3)). For an examined benchmark problem,<br />
>>the two algorithms yielded a three and six order of magnitude increase in computational efficiency,<br />
>>respectively, relative to direct computation of the same quantities. Sample computer code is<br />
>>provided for assessing the computational and memory efficiency of the proposed algorithms for<br />
>>matrices of different dimensions.</p>
<p>Hi Vineet,</p>
<p>I've read abstract, downloaded 3 docs related to your R&D ( will spend some time on reading next week... ) and I wonder if I could ask some set of questions? Does it make sense to start using Private Messaging of IDZ website because it won't be related to MKL?</p>
<p>Best regards,<br />
Sergey</p>
</div></div></div>Sun, 10 Feb 2013 21:08:45 +0000Sergey Kostrovcomment 1724240 at https://software.intel.comHiSergey
https://software.intel.com/fr-fr/comment/1724197#comment-1724197
<a id="comment-1724197"></a>
<div class="field field-name-comment-body field-type-text-long field-label-hidden"><div class="field-items"><div class="field-item even" property="content:encoded"><p>Hi<br />Sergey</p>
<p>I completely agree with you that ~2.5% gain in performance is important especially when sometimes in my applications the matrices are huge reaching ~ million*million in dimensions in which case out of core operations becomes a necessity. I think the concept of <br />symmetry can be useful in improving performance in case of Strassen's algorithm and theoretically it is easy to show this performance gain. However, given the recursive nature of the algorithm programmatically designing it efficiently might be tricky. </p>
<p>For performance reasons in our applications, for toeplitz matrices we have now started using discrete fourier transform where we have to perform only o(n2logn) operations for obtaining the result of matrix multiplication.</p>
<p>Sometimes where absolute accuracy is not important we have also started using hierarchical matrices for matrix multiplication that again requires o(n2 logn) operations.</p>
<p>However both these methods can only be used in specific circumstances but still are extremely useful</p>
<p>(These algorithms I think are not available in MKL as they can only be used in very specific circumstances)</p>
<p>vineet</p>
</div></div></div>Sat, 09 Feb 2013 15:19:58 +0000Vineet Y.comment 1724197 at https://software.intel.comHi Vineet,
https://software.intel.com/fr-fr/comment/1724171#comment-1724171
<a id="comment-1724171"></a>
<div class="field field-name-comment-body field-type-text-long field-label-hidden"><div class="field-items"><div class="field-item even" property="content:encoded"><p>Hi Vineet,</p>
<p>I did a very simple test to verify if application of a <strong>Symmetry</strong> concept ( however in a different way... ) improves performance.</p>
<p>The test is very simple:</p>
<p>If <strong>A</strong> is some matrix and <strong>B</strong> is a symmetric matrix than instead of a <strong>Classic</strong> matrix multiplication algorithm a <strong>Classic Transpose</strong> based algorithm could be used to calculate the product <strong>C</strong>.</p>
<p>Here are results:</p>
<p>For a <strong>32x32</strong> matrix a performace improvement was ~<strong>2.5%</strong>. Is it a good number? I think Yes, because sometimes even a <strong>0.5%</strong> speed up makes a difference.</p>
<p>Situation is different if more complex algorithms, like <strong>Strassen</strong> ( recursive by design with partitioning of the source matrices ) are used but the same concept also could be used for all partitioned matrices at a <strong>Threshold Level</strong>!</p>
</div></div></div>Sat, 09 Feb 2013 03:00:00 +0000Sergey Kostrovcomment 1724171 at https://software.intel.comHi
https://software.intel.com/fr-fr/comment/1724164#comment-1724164
<a id="comment-1724164"></a>
<div class="field field-name-comment-body field-type-text-long field-label-hidden"><div class="field-items"><div class="field-item even" property="content:encoded"><p>Hi</p>
<p>Sergey </p>
<p>I think, last time I did not answer your question in the context of real-time dynamic computing environment. <strong>I agree that there exists no method to find out in a real time dynamic computing environment</strong> if the output of the matrix multiplication of two arbitrary matrices would be a symmetric matrix. However, in case of three matrices where the central matrix is a symmetric matrix and left and right hand side matrices are transposes of each other this would always be true. For e.g. assume ‘a’ to be arbitrary and ‘q’ to be symmetric then a*q*a’ would be symmetric.</p>
<p>Application </p>
<p>Let’s think of a simple application of computing regression coefficients where q is a full covariance matrix and a is a matrix of independent variables, then the most fundamental operation to get regression coefficient is to multiply a*q*a’ where q is mostly symmetric and these kinds of multiplications are quite common in statistics, econometrics, weather prediction, inverse modeling and maybe more‼</p>
<p> Many thanks for responding and initiating a healthy discussion</p>
<p> Vineet</p>
</div></div></div>Fri, 08 Feb 2013 22:35:17 +0000Vineet Y.comment 1724164 at https://software.intel.com>>...I have also raised this
https://software.intel.com/fr-fr/comment/1724115#comment-1724115
<a id="comment-1724115"></a>
<div class="field field-name-comment-body field-type-text-long field-label-hidden"><div class="field-items"><div class="field-item even" property="content:encoded"><p>>>...I have also raised this issue about BLAS in my recently submitted paper titled “Technical Note: Improving computational<br />
>>efficiency in large linear inverse problems: an example from carbon dioxide flux estimation” (Search on Google; freely<br />
>>available; see section 2.3).</p>
<p>Thanks, Vineet for the feedback! I'll take a look at the paper.</p>
</div></div></div>Fri, 08 Feb 2013 18:21:26 +0000Sergey Kostrovcomment 1724115 at https://software.intel.comI understand that it is
https://software.intel.com/fr-fr/comment/1724109#comment-1724109
<a id="comment-1724109"></a>
<div class="field field-name-comment-body field-type-text-long field-label-hidden"><div class="field-items"><div class="field-item even" property="content:encoded"><p>I understand that it is difficult for a software subsystem to know in advance that the output of the matrix multiplication of two matrices would result in a symmetric matrix. However, don’t you think so that a similar situation arises in case of using SSYMM as the routine does not know that the input left or right hand side matrix is a symmetric matrix (of course it would be square) and it is up to the user to make sure to input a symmetric matrix otherwise the output would be incorrect.</p>
<p>Now in the case mentioned by me in my earlier post it is also up to the user to make sure that the resulting matrix of the matrix multiplication would be a symmetric matrix.</p>
<p>A slight modification of DGEMM can fix this by only computing upper or lower triangular part of the matrix. Additionally, similar modification to sparse routines like MKL_DCSMM can fix this problem for sparse matrices. I have also raised this issue about BLAS in my recently submitted paper titled “Technical Note: Improving computational efficiency in large linear inverse problems: an example from carbon dioxide flux estimation” (Search on Google; freely available; see section 2.3).</p>
</div></div></div>Fri, 08 Feb 2013 17:59:00 +0000Vineet Y.comment 1724109 at https://software.intel.comI understand that it is
https://software.intel.com/fr-fr/comment/1724098#comment-1724098
<a id="comment-1724098"></a>
<div class="field field-name-comment-body field-type-text-long field-label-hidden"><div class="field-items"><div class="field-item even" property="content:encoded"><p>I understand that it is difficult for the software system to anticipate that the product of two matrices would be symmetric, but don't you think that it also applies to other routines. For ex in MKL_SCOOMM a user has to tell the routine that the left or /right hand side matrix would be symmetric (of course it has to be square but it need not be symmetric !) so that she/he can get some comupational benefit. Now in this case it is upto the user to make sure that the output would be a symmetric matrix. </p>
<p>In terms of above given terminology I can efficiently do H*Q from mkl but I cannot further reduce the cost of matrix multiplication by taking advantage of the fact that the output of HQ*H' would be a symmetric matrix. For small cases this is not even important, however it becomes an important issue when you are dealing with matrices that would be million by million in dimensions; of course such an operation would be done through Scalapack.</p>
<p> As far as the applications are concerned see paper (freely available online) <a href="http://www.geosci-model-dev-discuss.net/5/3325/2012/gmdd-5-3325-2012-print.pdf">http://www.geosci-model-dev-discuss.net/5/3325/2012/gmdd-5-3325-2012-pri...</a> (the matrix multiplication algorithm is described for the Kronecker Product forms).For resons for dealing with these large dimensions see: <a href="http://onlinelibrary.wiley.com/doi/10.1029/2011WR011778/abstract">http://onlinelibrary.wiley.com/doi/10.1029/2011WR011778/abstract</a> </p>
</p>
<p>Lastly :The matrix multiplication of two sparse matrices has been raised earlier in the forum!: In some cases (~70 %) both (HQ) and H' are sparse matrices.</p>
<p> </p>
</div></div></div>Fri, 08 Feb 2013 17:00:43 +0000Vineet Y.comment 1724098 at https://software.intel.comHi, I have a couple of
https://software.intel.com/fr-fr/comment/1724073#comment-1724073
<a id="comment-1724073"></a>
<div class="field field-name-comment-body field-type-text-long field-label-hidden"><div class="field-items"><div class="field-item even" property="content:encoded"><p>Hi, I have a couple of questions ( sorry, more generic and not related to MKL ) regarding your statement:</p>
<p>>>...the product (matrix multiplication) of two different matrices would be <strong>symmetric</strong> so that matrix multiplication<br />
>><strong>happens faster</strong>...</p>
<p>I do specialize on high-performance matrix multiplication algorithms for embedded platforms ( Strassen Heap Based Complete and Incomplete algorithms ) and I'd like to understand:</p>
<p>- How matrix multiplication should be changed in that case?</p>
<p>- How some software subsystem could evaluate in advance, especially in a <strong>real-time dynamic</strong> enviroment, that the product of two matricies will be symmetric?</p>
</div></div></div>Fri, 08 Feb 2013 15:03:00 +0000Sergey Kostrovcomment 1724073 at https://software.intel.com