📄 winnertoimgcoords.html
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd"><html><head> <title>Description of winnerToImgCoords</title> <meta name="keywords" content="winnerToImgCoords"> <meta name="description" content="winnerToImgCoords - converts winner location from map to image coordinates."> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> <meta name="generator" content="m2html © 2003 Guillaume Flandin"> <meta name="robots" content="index, follow"> <link type="text/css" rel="stylesheet" href="../m2html.css"></head><body><a name="_top"></a><div><a href="../index.html">Home</a> > <a href="#">mfiles</a> > winnerToImgCoords.m</div><!--<table width="100%"><tr><td align="left"><a href="../index.html"><img alt="<" border="0" src="../left.png"> Master index</a></td><td align="right"><a href="index.html">Index for .\mfiles <img alt=">" border="0" src="../right.png"></a></td></tr></table>--><h1>winnerToImgCoords</h1><h2><a name="_name"></a>PURPOSE <a href="#_top"><img alt="^" border="0" src="../up.png"></a></h2><div class="box"><strong>winnerToImgCoords - converts winner location from map to image coordinates.</strong></div><h2><a name="_synopsis"></a>SYNOPSIS <a href="#_top"><img alt="^" border="0" src="../up.png"></a></h2><div class="box"><strong>function winImgCo = winnerToImgCoords(winner,params) </strong></div><h2><a name="_description"></a>DESCRIPTION <a href="#_top"><img alt="^" border="0" src="../up.png"></a></h2><div class="fragment"><pre class="comment"> winnerToImgCoords - converts winner location from map to image coordinates. winImgCo = winnerToImgCoords(winner,salParams) Converts the winner location from saliency map coordinates to image coordinates, based on the pyramid type and the map level specified in salParams. See also <a href="defaultLevelParams.html" class="code" title="function levelParams = defaultLevelParams(pyramidType)">defaultLevelParams</a>, <a href="evolveWTA.html" class="code" title="function [wta,winner] = evolveWTA(wta)">evolveWTA</a>.</pre></div><!-- crossreference --><h2><a name="_cross"></a>CROSS-REFERENCE INFORMATION <a href="#_top"><img alt="^" border="0" src="../up.png"></a></h2>This function calls:<ul style="list-style-image:url(../matlabicon.gif)"><li><a href="fatal.html" class="code" title="function fatal(message)">fatal</a> fatal(message) - exits with a fatal error message.</li></ul>This function is called by:<ul style="list-style-image:url(../matlabicon.gif)"><li><a href="batchSaliency.html" class="code" title="function [salMaps,fixations] = batchSaliency(images,numFixations,params)">batchSaliency</a> batchSaliency - batch processing of lists of images.</li><li><a href="guiSaliency.html" class="code" title="function varargout = guiSaliency(varargin)">guiSaliency</a> guiSaliency - a graphical user interface (GUI) version of the saliency code.</li><li><a href="runSaliency.html" class="code" title="function runSaliency(inputImage,varargin)">runSaliency</a> runSaliency - compute and display saliency map and fixations.</li></ul><!-- crossreference --><h2><a name="_source"></a>SOURCE CODE <a href="#_top"><img alt="^" border="0" src="../up.png"></a></h2><div class="fragment"><pre>0001 <span class="comment">% winnerToImgCoords - converts winner location from map to image coordinates.</span>0002 <span class="comment">%</span>0003 <span class="comment">% winImgCo = winnerToImgCoords(winner,salParams)</span>0004 <span class="comment">% Converts the winner location from saliency map coordinates</span>0005 <span class="comment">% to image coordinates, based on the pyramid type and</span>0006 <span class="comment">% the map level specified in salParams.</span>0007 <span class="comment">%</span>0008 <span class="comment">% See also defaultLevelParams, evolveWTA.</span>0009 0010 <span class="comment">% This file is part of the SaliencyToolbox - Copyright (C) 2006-2007</span>0011 <span class="comment">% by Dirk B. Walther and the California Institute of Technology.</span>0012 <span class="comment">% See the enclosed LICENSE.TXT document for the license agreement.</span>0013 <span class="comment">% More information about this project is available at:</span>0014 <span class="comment">% http://www.saliencytoolbox.net</span>0015 0016 <a name="_sub0" href="#_subfunctions" class="code">function winImgCo = winnerToImgCoords(winner,params)</a>0017 0018 <span class="keyword">if</span> (params.useRandom)0019 winner = winner + rand(size(winner));0020 <span class="keyword">end</span>0021 0022 mLevel = params.levelParams.mapLevel - 1;0023 <span class="keyword">switch</span> params.pyramidType0024 <span class="keyword">case</span> <span class="string">'dyadic'</span>0025 winImgCo = round((winner - 1) * 2^mLevel + 1);0026 <span class="keyword">case</span> <span class="string">'sqrt2'</span>0027 winImgCo = round((winner - 1) * 2^(mLevel/2) + 1);0028 <span class="keyword">otherwise</span>0029 <a href="fatal.html" class="code" title="function fatal(message)">fatal</a>([<span class="string">'Unknown pyramidType: '</span> params.pyramidType]);0030 <span class="keyword">end</span>0031</pre></div><hr><address>Generated on Fri 07-Sep-2007 14:42:18 by <strong><a href="http://www.artefact.tk/software/matlab/m2html/">m2html</a></strong> © 2003</address></body></html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -