Ryan OShea | de36e4a | 2020-03-13 16:26:19 +0000 | [diff] [blame] | 1 | <!-- Copyright (c) 2020 ARM Limited. --> |
| 2 | <!-- --> |
| 3 | <!-- SPDX-License-Identifier: MIT --> |
| 4 | <!-- --> |
| 5 | <!-- HTML header for doxygen 1.8.13--> |
| 6 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> |
| 7 | <html xmlns="http://www.w3.org/1999/xhtml"> |
| 8 | <head> |
| 9 | <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> |
| 10 | <meta http-equiv="X-UA-Compatible" content="IE=9"/> |
| 11 | <meta name="generator" content="Doxygen 1.8.13"/> |
| 12 | <meta name="robots" content="NOINDEX, NOFOLLOW" /> |
| 13 | <meta name="viewport" content="width=device-width, initial-scale=1"/> |
| 14 | <title>ArmNN: src/backends/backendsCommon/test/layerTests/ArgMinMaxTestImpl.hpp File Reference</title> |
| 15 | <link href="tabs.css" rel="stylesheet" type="text/css"/> |
| 16 | <script type="text/javascript" src="jquery.js"></script> |
| 17 | <script type="text/javascript" src="dynsections.js"></script> |
| 18 | <link href="navtree.css" rel="stylesheet" type="text/css"/> |
| 19 | <script type="text/javascript" src="resize.js"></script> |
| 20 | <script type="text/javascript" src="navtreedata.js"></script> |
| 21 | <script type="text/javascript" src="navtree.js"></script> |
| 22 | <script type="text/javascript"> |
| 23 | $(document).ready(initResizable); |
| 24 | </script> |
| 25 | <link href="search/search.css" rel="stylesheet" type="text/css"/> |
| 26 | <script type="text/javascript" src="search/searchdata.js"></script> |
| 27 | <script type="text/javascript" src="search/search.js"></script> |
| 28 | <script type="text/x-mathjax-config"> |
| 29 | MathJax.Hub.Config({ |
| 30 | extensions: ["tex2jax.js"], |
| 31 | jax: ["input/TeX","output/HTML-CSS"], |
| 32 | }); |
| 33 | </script><script type="text/javascript" src="http://cdn.mathjax.org/mathjax/latest/MathJax.js"></script> |
| 34 | <link href="doxygen.css" rel="stylesheet" type="text/css" /> |
| 35 | <link href="stylesheet.css" rel="stylesheet" type="text/css"/> |
| 36 | </head> |
| 37 | <body> |
| 38 | <div id="top"><!-- do not remove this div, it is closed by doxygen! --> |
| 39 | <div id="titlearea"> |
| 40 | <table cellspacing="0" cellpadding="0"> |
| 41 | <tbody> |
| 42 | <tr style="height: 56px;"> |
| 43 | <img alt="ArmNN" src="Arm_NN_horizontal_blue.png" style="max-width: 10rem; margin-top: .5rem; margin-left 10px"/> |
| 44 | <td style="padding-left: 0.5em;"> |
| 45 | <div id="projectname"> |
| 46 |  <span id="projectnumber">20.02</span> |
| 47 | </div> |
| 48 | </td> |
| 49 | </tr> |
| 50 | </tbody> |
| 51 | </table> |
| 52 | </div> |
| 53 | <!-- end header part --> |
| 54 | <!-- Generated by Doxygen 1.8.13 --> |
| 55 | <script type="text/javascript"> |
| 56 | var searchBox = new SearchBox("searchBox", "search",false,'Search'); |
| 57 | </script> |
| 58 | <script type="text/javascript" src="menudata.js"></script> |
| 59 | <script type="text/javascript" src="menu.js"></script> |
| 60 | <script type="text/javascript"> |
| 61 | $(function() { |
| 62 | initMenu('',true,false,'search.php','Search'); |
| 63 | $(document).ready(function() { init_search(); }); |
| 64 | }); |
| 65 | </script> |
| 66 | <div id="main-nav"></div> |
| 67 | </div><!-- top --> |
| 68 | <div id="side-nav" class="ui-resizable side-nav-resizable"> |
| 69 | <div id="nav-tree"> |
| 70 | <div id="nav-tree-contents"> |
| 71 | <div id="nav-sync" class="sync"></div> |
| 72 | </div> |
| 73 | </div> |
| 74 | <div id="splitbar" style="-moz-user-select:none;" |
| 75 | class="ui-resizable-handle"> |
| 76 | </div> |
| 77 | </div> |
| 78 | <script type="text/javascript"> |
| 79 | $(document).ready(function(){initNavTree('_arg_min_max_test_impl_8hpp.xhtml','');}); |
| 80 | </script> |
| 81 | <div id="doc-content"> |
| 82 | <!-- window showing the filter options --> |
| 83 | <div id="MSearchSelectWindow" |
| 84 | onmouseover="return searchBox.OnSearchSelectShow()" |
| 85 | onmouseout="return searchBox.OnSearchSelectHide()" |
| 86 | onkeydown="return searchBox.OnSearchSelectKey(event)"> |
| 87 | </div> |
| 88 | |
| 89 | <!-- iframe showing the search results (closed by default) --> |
| 90 | <div id="MSearchResultsWindow"> |
| 91 | <iframe src="javascript:void(0)" frameborder="0" |
| 92 | name="MSearchResults" id="MSearchResults"> |
| 93 | </iframe> |
| 94 | </div> |
| 95 | |
| 96 | <div class="header"> |
| 97 | <div class="summary"> |
| 98 | <a href="#func-members">Functions</a> </div> |
| 99 | <div class="headertitle"> |
| 100 | <div class="title">ArgMinMaxTestImpl.hpp File Reference</div> </div> |
| 101 | </div><!--header--> |
| 102 | <div class="contents"> |
| 103 | <div class="textblock"><code>#include "<a class="el" href="_layer_test_result_8hpp_source.xhtml">LayerTestResult.hpp</a>"</code><br /> |
| 104 | <code>#include <<a class="el" href="_resolve_type_8hpp_source.xhtml">ResolveType.hpp</a>></code><br /> |
| 105 | <code>#include <<a class="el" href="include_2armnn_2backends_2_i_backend_internal_8hpp_source.xhtml">armnn/backends/IBackendInternal.hpp</a>></code><br /> |
| 106 | <code>#include <<a class="el" href="_workload_factory_8hpp_source.xhtml">backendsCommon/WorkloadFactory.hpp</a>></code><br /> |
| 107 | </div> |
| 108 | <p><a href="_arg_min_max_test_impl_8hpp_source.xhtml">Go to the source code of this file.</a></p> |
| 109 | <table class="memberdecls"> |
| 110 | <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a> |
| 111 | Functions</h2></td></tr> |
| 112 | <tr class="memitem:a6e5d88259b3850369b5a20071011df8d"><td class="memTemplParams" colspan="2">template<armnn::DataType ArmnnType, typename T = armnn::ResolveType<ArmnnType>> </td></tr> |
| 113 | <tr class="memitem:a6e5d88259b3850369b5a20071011df8d"><td class="memTemplItemLeft" align="right" valign="top"><a class="el" href="struct_layer_test_result.xhtml">LayerTestResult</a>< int32_t, 3 > </td><td class="memTemplItemRight" valign="bottom"><a class="el" href="_arg_min_max_test_impl_8hpp.xhtml#a6e5d88259b3850369b5a20071011df8d">ArgMaxSimpleTest</a> (<a class="el" href="classarmnn_1_1_i_workload_factory.xhtml">armnn::IWorkloadFactory</a> &workloadFactory, const <a class="el" href="classarmnn_1_1_i_backend_internal.xhtml#a693b40e6b94e958836aeb0410ca186bd">armnn::IBackendInternal::IMemoryManagerSharedPtr</a> &memoryManager)</td></tr> |
| 114 | <tr class="separator:a6e5d88259b3850369b5a20071011df8d"><td class="memSeparator" colspan="2"> </td></tr> |
| 115 | <tr class="memitem:a1fc3e309bafd760c40cec0e98d995529"><td class="memTemplParams" colspan="2">template<armnn::DataType ArmnnType, typename T = armnn::ResolveType<ArmnnType>> </td></tr> |
| 116 | <tr class="memitem:a1fc3e309bafd760c40cec0e98d995529"><td class="memTemplItemLeft" align="right" valign="top"><a class="el" href="struct_layer_test_result.xhtml">LayerTestResult</a>< int32_t, 3 > </td><td class="memTemplItemRight" valign="bottom"><a class="el" href="_arg_min_max_test_impl_8hpp.xhtml#a1fc3e309bafd760c40cec0e98d995529">ArgMinSimpleTest</a> (<a class="el" href="classarmnn_1_1_i_workload_factory.xhtml">armnn::IWorkloadFactory</a> &workloadFactory, const <a class="el" href="classarmnn_1_1_i_backend_internal.xhtml#a693b40e6b94e958836aeb0410ca186bd">armnn::IBackendInternal::IMemoryManagerSharedPtr</a> &memoryManager)</td></tr> |
| 117 | <tr class="separator:a1fc3e309bafd760c40cec0e98d995529"><td class="memSeparator" colspan="2"> </td></tr> |
| 118 | <tr class="memitem:ad1a3228fc6f2d00c816a6f11ff1092ec"><td class="memTemplParams" colspan="2">template<armnn::DataType ArmnnType, typename T = armnn::ResolveType<ArmnnType>> </td></tr> |
| 119 | <tr class="memitem:ad1a3228fc6f2d00c816a6f11ff1092ec"><td class="memTemplItemLeft" align="right" valign="top"><a class="el" href="struct_layer_test_result.xhtml">LayerTestResult</a>< int32_t, 3 > </td><td class="memTemplItemRight" valign="bottom"><a class="el" href="_arg_min_max_test_impl_8hpp.xhtml#ad1a3228fc6f2d00c816a6f11ff1092ec">ArgMinChannelTest</a> (<a class="el" href="classarmnn_1_1_i_workload_factory.xhtml">armnn::IWorkloadFactory</a> &workloadFactory, const <a class="el" href="classarmnn_1_1_i_backend_internal.xhtml#a693b40e6b94e958836aeb0410ca186bd">armnn::IBackendInternal::IMemoryManagerSharedPtr</a> &memoryManager)</td></tr> |
| 120 | <tr class="separator:ad1a3228fc6f2d00c816a6f11ff1092ec"><td class="memSeparator" colspan="2"> </td></tr> |
| 121 | <tr class="memitem:abecc0d9c322f12e6318c71e1b2743c4d"><td class="memTemplParams" colspan="2">template<armnn::DataType ArmnnType, typename T = armnn::ResolveType<ArmnnType>> </td></tr> |
| 122 | <tr class="memitem:abecc0d9c322f12e6318c71e1b2743c4d"><td class="memTemplItemLeft" align="right" valign="top"><a class="el" href="struct_layer_test_result.xhtml">LayerTestResult</a>< int32_t, 3 > </td><td class="memTemplItemRight" valign="bottom"><a class="el" href="_arg_min_max_test_impl_8hpp.xhtml#abecc0d9c322f12e6318c71e1b2743c4d">ArgMaxChannelTest</a> (<a class="el" href="classarmnn_1_1_i_workload_factory.xhtml">armnn::IWorkloadFactory</a> &workloadFactory, const <a class="el" href="classarmnn_1_1_i_backend_internal.xhtml#a693b40e6b94e958836aeb0410ca186bd">armnn::IBackendInternal::IMemoryManagerSharedPtr</a> &memoryManager)</td></tr> |
| 123 | <tr class="separator:abecc0d9c322f12e6318c71e1b2743c4d"><td class="memSeparator" colspan="2"> </td></tr> |
| 124 | <tr class="memitem:a90b0a2e001da0237a81ea1ae918d767e"><td class="memTemplParams" colspan="2">template<armnn::DataType ArmnnType, typename T = armnn::ResolveType<ArmnnType>> </td></tr> |
| 125 | <tr class="memitem:a90b0a2e001da0237a81ea1ae918d767e"><td class="memTemplItemLeft" align="right" valign="top"><a class="el" href="struct_layer_test_result.xhtml">LayerTestResult</a>< int32_t, 3 > </td><td class="memTemplItemRight" valign="bottom"><a class="el" href="_arg_min_max_test_impl_8hpp.xhtml#a90b0a2e001da0237a81ea1ae918d767e">ArgMaxHeightTest</a> (<a class="el" href="classarmnn_1_1_i_workload_factory.xhtml">armnn::IWorkloadFactory</a> &workloadFactory, const <a class="el" href="classarmnn_1_1_i_backend_internal.xhtml#a693b40e6b94e958836aeb0410ca186bd">armnn::IBackendInternal::IMemoryManagerSharedPtr</a> &memoryManager)</td></tr> |
| 126 | <tr class="separator:a90b0a2e001da0237a81ea1ae918d767e"><td class="memSeparator" colspan="2"> </td></tr> |
| 127 | <tr class="memitem:aba0c3336ffd8a44dc4ab7d61a32fd5c2"><td class="memTemplParams" colspan="2">template<armnn::DataType ArmnnType, typename T = armnn::ResolveType<ArmnnType>> </td></tr> |
| 128 | <tr class="memitem:aba0c3336ffd8a44dc4ab7d61a32fd5c2"><td class="memTemplItemLeft" align="right" valign="top"><a class="el" href="struct_layer_test_result.xhtml">LayerTestResult</a>< int32_t, 3 > </td><td class="memTemplItemRight" valign="bottom"><a class="el" href="_arg_min_max_test_impl_8hpp.xhtml#aba0c3336ffd8a44dc4ab7d61a32fd5c2">ArgMinWidthTest</a> (<a class="el" href="classarmnn_1_1_i_workload_factory.xhtml">armnn::IWorkloadFactory</a> &workloadFactory, const <a class="el" href="classarmnn_1_1_i_backend_internal.xhtml#a693b40e6b94e958836aeb0410ca186bd">armnn::IBackendInternal::IMemoryManagerSharedPtr</a> &memoryManager)</td></tr> |
| 129 | <tr class="separator:aba0c3336ffd8a44dc4ab7d61a32fd5c2"><td class="memSeparator" colspan="2"> </td></tr> |
| 130 | </table> |
| 131 | <h2 class="groupheader">Function Documentation</h2> |
| 132 | <a id="abecc0d9c322f12e6318c71e1b2743c4d"></a> |
| 133 | <h2 class="memtitle"><span class="permalink"><a href="#abecc0d9c322f12e6318c71e1b2743c4d">◆ </a></span>ArgMaxChannelTest()</h2> |
| 134 | |
| 135 | <div class="memitem"> |
| 136 | <div class="memproto"> |
| 137 | <table class="memname"> |
| 138 | <tr> |
| 139 | <td class="memname"><a class="el" href="struct_layer_test_result.xhtml">LayerTestResult</a><int32_t, 3> ArgMaxChannelTest </td> |
| 140 | <td>(</td> |
| 141 | <td class="paramtype"><a class="el" href="classarmnn_1_1_i_workload_factory.xhtml">armnn::IWorkloadFactory</a> & </td> |
| 142 | <td class="paramname"><em>workloadFactory</em>, </td> |
| 143 | </tr> |
| 144 | <tr> |
| 145 | <td class="paramkey"></td> |
| 146 | <td></td> |
| 147 | <td class="paramtype">const <a class="el" href="classarmnn_1_1_i_backend_internal.xhtml#a693b40e6b94e958836aeb0410ca186bd">armnn::IBackendInternal::IMemoryManagerSharedPtr</a> & </td> |
| 148 | <td class="paramname"><em>memoryManager</em> </td> |
| 149 | </tr> |
| 150 | <tr> |
| 151 | <td></td> |
| 152 | <td>)</td> |
| 153 | <td></td><td></td> |
| 154 | </tr> |
| 155 | </table> |
| 156 | </div><div class="memdoc"> |
| 157 | |
| 158 | <p class="definition">Definition at line <a class="el" href="_arg_min_max_test_impl_8cpp_source.xhtml#l00153">153</a> of file <a class="el" href="_arg_min_max_test_impl_8cpp_source.xhtml">ArgMinMaxTestImpl.cpp</a>.</p> |
| 159 | |
| 160 | <p class="reference">References <a class="el" href="namespacearmnn.xhtml#ae7e8cbf71db6a490789ca6dcaa8deeaea6a061313d22e51e0f25b7cd4dc065233">armnn::Max</a>, <a class="el" href="_tensor_8cpp_source.xhtml#l00275">TensorInfo::SetQuantizationOffset()</a>, <a class="el" href="_tensor_8cpp_source.xhtml#l00259">TensorInfo::SetQuantizationScale()</a>, and <a class="el" href="namespacearmnn.xhtml#ad8ed01ff3ff33333d8e19db4d2818bb6accedffbc6e5308e33d3843e8bdc0dad7">armnn::Signed32</a>.</p> |
| 161 | <div class="fragment"><div class="line"><a name="l00156"></a><span class="lineno"> 156</span> {</div><div class="line"><a name="l00157"></a><span class="lineno"> 157</span>  <span class="keyword">const</span> <a class="code" href="classarmnn_1_1_tensor_shape.xhtml">armnn::TensorShape</a> inputShape{ 1, 3, 2, 4};</div><div class="line"><a name="l00158"></a><span class="lineno"> 158</span>  <span class="keyword">const</span> <a class="code" href="classarmnn_1_1_tensor_shape.xhtml">armnn::TensorShape</a> outputShape{ 1, 2, 4 };</div><div class="line"><a name="l00159"></a><span class="lineno"> 159</span> </div><div class="line"><a name="l00160"></a><span class="lineno"> 160</span>  <a class="code" href="classarmnn_1_1_tensor_info.xhtml">armnn::TensorInfo</a> inputTensorInfo(inputShape, ArmnnType);</div><div class="line"><a name="l00161"></a><span class="lineno"> 161</span> </div><div class="line"><a name="l00162"></a><span class="lineno"> 162</span>  <span class="keywordflow">if</span> (armnn::IsQuantizedType<T>())</div><div class="line"><a name="l00163"></a><span class="lineno"> 163</span>  {</div><div class="line"><a name="l00164"></a><span class="lineno"> 164</span>  inputTensorInfo.SetQuantizationScale(1.0f);</div><div class="line"><a name="l00165"></a><span class="lineno"> 165</span>  inputTensorInfo.SetQuantizationOffset(0);</div><div class="line"><a name="l00166"></a><span class="lineno"> 166</span>  }</div><div class="line"><a name="l00167"></a><span class="lineno"> 167</span> </div><div class="line"><a name="l00168"></a><span class="lineno"> 168</span>  <a class="code" href="classarmnn_1_1_tensor_info.xhtml">armnn::TensorInfo</a> outputTensorInfo(outputShape, <a class="code" href="namespacearmnn.xhtml#ad8ed01ff3ff33333d8e19db4d2818bb6accedffbc6e5308e33d3843e8bdc0dad7">armnn::DataType::Signed32</a>);</div><div class="line"><a name="l00169"></a><span class="lineno"> 169</span> </div><div class="line"><a name="l00170"></a><span class="lineno"> 170</span>  std::vector<float> inputValues({ 1.0f, 2.0f, 3.0f, 4.0f,</div><div class="line"><a name="l00171"></a><span class="lineno"> 171</span>  5.0f, 6.0f, 7.0f, 8.0f,</div><div class="line"><a name="l00172"></a><span class="lineno"> 172</span> </div><div class="line"><a name="l00173"></a><span class="lineno"> 173</span>  10.0f, 20.0f, 30.0f, 40.0f,</div><div class="line"><a name="l00174"></a><span class="lineno"> 174</span>  50.0f, 60.0f, 70.0f, 80.0f,</div><div class="line"><a name="l00175"></a><span class="lineno"> 175</span> </div><div class="line"><a name="l00176"></a><span class="lineno"> 176</span>  100.0f, 200.0f, 300.0f, 400.0f,</div><div class="line"><a name="l00177"></a><span class="lineno"> 177</span>  500.0f, 600.0f, 700.0f, 800.0f });</div><div class="line"><a name="l00178"></a><span class="lineno"> 178</span>  std::vector<int32_t> outputValues({ 2, 2, 2, 2,</div><div class="line"><a name="l00179"></a><span class="lineno"> 179</span>  2, 2, 2, 2 });</div><div class="line"><a name="l00180"></a><span class="lineno"> 180</span> </div><div class="line"><a name="l00181"></a><span class="lineno"> 181</span>  <span class="keywordflow">return</span> ArgMinMaxTestCommon<ArmnnType>(workloadFactory, memoryManager,</div><div class="line"><a name="l00182"></a><span class="lineno"> 182</span>  <a class="code" href="namespacearmnn.xhtml#ae7e8cbf71db6a490789ca6dcaa8deeaea6a061313d22e51e0f25b7cd4dc065233">armnn::ArgMinMaxFunction::Max</a>,</div><div class="line"><a name="l00183"></a><span class="lineno"> 183</span>  inputTensorInfo, outputTensorInfo,</div><div class="line"><a name="l00184"></a><span class="lineno"> 184</span>  inputValues, outputValues, 1);</div><div class="line"><a name="l00185"></a><span class="lineno"> 185</span> }</div><div class="ttc" id="classarmnn_1_1_tensor_info_xhtml"><div class="ttname"><a href="classarmnn_1_1_tensor_info.xhtml">armnn::TensorInfo</a></div><div class="ttdef"><b>Definition:</b> <a href="_tensor_8hpp_source.xhtml#l00053">Tensor.hpp:53</a></div></div> |
| 162 | <div class="ttc" id="namespacearmnn_xhtml_ad8ed01ff3ff33333d8e19db4d2818bb6accedffbc6e5308e33d3843e8bdc0dad7"><div class="ttname"><a href="namespacearmnn.xhtml#ad8ed01ff3ff33333d8e19db4d2818bb6accedffbc6e5308e33d3843e8bdc0dad7">armnn::DataType::Signed32</a></div></div> |
| 163 | <div class="ttc" id="classarmnn_1_1_tensor_shape_xhtml"><div class="ttname"><a href="classarmnn_1_1_tensor_shape.xhtml">armnn::TensorShape</a></div><div class="ttdef"><b>Definition:</b> <a href="_tensor_8hpp_source.xhtml#l00020">Tensor.hpp:20</a></div></div> |
| 164 | <div class="ttc" id="namespacearmnn_xhtml_ae7e8cbf71db6a490789ca6dcaa8deeaea6a061313d22e51e0f25b7cd4dc065233"><div class="ttname"><a href="namespacearmnn.xhtml#ae7e8cbf71db6a490789ca6dcaa8deeaea6a061313d22e51e0f25b7cd4dc065233">armnn::ArgMinMaxFunction::Max</a></div></div> |
| 165 | </div><!-- fragment --> |
| 166 | </div> |
| 167 | </div> |
| 168 | <a id="a90b0a2e001da0237a81ea1ae918d767e"></a> |
| 169 | <h2 class="memtitle"><span class="permalink"><a href="#a90b0a2e001da0237a81ea1ae918d767e">◆ </a></span>ArgMaxHeightTest()</h2> |
| 170 | |
| 171 | <div class="memitem"> |
| 172 | <div class="memproto"> |
| 173 | <table class="memname"> |
| 174 | <tr> |
| 175 | <td class="memname"><a class="el" href="struct_layer_test_result.xhtml">LayerTestResult</a><int32_t, 3> ArgMaxHeightTest </td> |
| 176 | <td>(</td> |
| 177 | <td class="paramtype"><a class="el" href="classarmnn_1_1_i_workload_factory.xhtml">armnn::IWorkloadFactory</a> & </td> |
| 178 | <td class="paramname"><em>workloadFactory</em>, </td> |
| 179 | </tr> |
| 180 | <tr> |
| 181 | <td class="paramkey"></td> |
| 182 | <td></td> |
| 183 | <td class="paramtype">const <a class="el" href="classarmnn_1_1_i_backend_internal.xhtml#a693b40e6b94e958836aeb0410ca186bd">armnn::IBackendInternal::IMemoryManagerSharedPtr</a> & </td> |
| 184 | <td class="paramname"><em>memoryManager</em> </td> |
| 185 | </tr> |
| 186 | <tr> |
| 187 | <td></td> |
| 188 | <td>)</td> |
| 189 | <td></td><td></td> |
| 190 | </tr> |
| 191 | </table> |
| 192 | </div><div class="memdoc"> |
| 193 | |
| 194 | <p class="definition">Definition at line <a class="el" href="_arg_min_max_test_impl_8cpp_source.xhtml#l00188">188</a> of file <a class="el" href="_arg_min_max_test_impl_8cpp_source.xhtml">ArgMinMaxTestImpl.cpp</a>.</p> |
| 195 | |
| 196 | <p class="reference">References <a class="el" href="namespacearmnn.xhtml#ae7e8cbf71db6a490789ca6dcaa8deeaea6a061313d22e51e0f25b7cd4dc065233">armnn::Max</a>, <a class="el" href="_tensor_8cpp_source.xhtml#l00275">TensorInfo::SetQuantizationOffset()</a>, <a class="el" href="_tensor_8cpp_source.xhtml#l00259">TensorInfo::SetQuantizationScale()</a>, and <a class="el" href="namespacearmnn.xhtml#ad8ed01ff3ff33333d8e19db4d2818bb6accedffbc6e5308e33d3843e8bdc0dad7">armnn::Signed32</a>.</p> |
| 197 | <div class="fragment"><div class="line"><a name="l00191"></a><span class="lineno"> 191</span> {</div><div class="line"><a name="l00192"></a><span class="lineno"> 192</span>  <span class="keyword">const</span> <a class="code" href="classarmnn_1_1_tensor_shape.xhtml">armnn::TensorShape</a> inputShape{ 1, 3, 2, 4};</div><div class="line"><a name="l00193"></a><span class="lineno"> 193</span>  <span class="keyword">const</span> <a class="code" href="classarmnn_1_1_tensor_shape.xhtml">armnn::TensorShape</a> outputShape{ 1, 3, 4 };</div><div class="line"><a name="l00194"></a><span class="lineno"> 194</span> </div><div class="line"><a name="l00195"></a><span class="lineno"> 195</span>  <a class="code" href="classarmnn_1_1_tensor_info.xhtml">armnn::TensorInfo</a> inputTensorInfo(inputShape, ArmnnType);</div><div class="line"><a name="l00196"></a><span class="lineno"> 196</span>  <a class="code" href="classarmnn_1_1_tensor_info.xhtml">armnn::TensorInfo</a> outputTensorInfo(outputShape, <a class="code" href="namespacearmnn.xhtml#ad8ed01ff3ff33333d8e19db4d2818bb6accedffbc6e5308e33d3843e8bdc0dad7">armnn::DataType::Signed32</a>);</div><div class="line"><a name="l00197"></a><span class="lineno"> 197</span> </div><div class="line"><a name="l00198"></a><span class="lineno"> 198</span>  <span class="keywordflow">if</span> (armnn::IsQuantizedType<T>())</div><div class="line"><a name="l00199"></a><span class="lineno"> 199</span>  {</div><div class="line"><a name="l00200"></a><span class="lineno"> 200</span>  inputTensorInfo.SetQuantizationScale(1.0f);</div><div class="line"><a name="l00201"></a><span class="lineno"> 201</span>  inputTensorInfo.SetQuantizationOffset(0);</div><div class="line"><a name="l00202"></a><span class="lineno"> 202</span>  }</div><div class="line"><a name="l00203"></a><span class="lineno"> 203</span> </div><div class="line"><a name="l00204"></a><span class="lineno"> 204</span>  std::vector<float> inputValues({ 1.0f, 2.0f, 3.0f, 4.0f,</div><div class="line"><a name="l00205"></a><span class="lineno"> 205</span>  5.0f, 6.0f, 7.0f, 8.0f,</div><div class="line"><a name="l00206"></a><span class="lineno"> 206</span> </div><div class="line"><a name="l00207"></a><span class="lineno"> 207</span>  10.0f, 20.0f, 30.0f, 40.0f,</div><div class="line"><a name="l00208"></a><span class="lineno"> 208</span>  50.0f, 60.0f, 70.0f, 80.0f,</div><div class="line"><a name="l00209"></a><span class="lineno"> 209</span> </div><div class="line"><a name="l00210"></a><span class="lineno"> 210</span>  100.0f, 200.0f, 300.0f, 400.0f,</div><div class="line"><a name="l00211"></a><span class="lineno"> 211</span>  500.0f, 600.0f, 700.0f, 800.0f });</div><div class="line"><a name="l00212"></a><span class="lineno"> 212</span>  std::vector<int32_t> outputValues({ 1, 1, 1, 1,</div><div class="line"><a name="l00213"></a><span class="lineno"> 213</span>  1, 1, 1, 1,</div><div class="line"><a name="l00214"></a><span class="lineno"> 214</span>  1, 1, 1, 1 });</div><div class="line"><a name="l00215"></a><span class="lineno"> 215</span> </div><div class="line"><a name="l00216"></a><span class="lineno"> 216</span>  <span class="keywordflow">return</span> ArgMinMaxTestCommon<ArmnnType>(workloadFactory, memoryManager,</div><div class="line"><a name="l00217"></a><span class="lineno"> 217</span>  <a class="code" href="namespacearmnn.xhtml#ae7e8cbf71db6a490789ca6dcaa8deeaea6a061313d22e51e0f25b7cd4dc065233">armnn::ArgMinMaxFunction::Max</a>,</div><div class="line"><a name="l00218"></a><span class="lineno"> 218</span>  inputTensorInfo, outputTensorInfo,</div><div class="line"><a name="l00219"></a><span class="lineno"> 219</span>  inputValues, outputValues, 2);</div><div class="line"><a name="l00220"></a><span class="lineno"> 220</span> }</div><div class="ttc" id="classarmnn_1_1_tensor_info_xhtml"><div class="ttname"><a href="classarmnn_1_1_tensor_info.xhtml">armnn::TensorInfo</a></div><div class="ttdef"><b>Definition:</b> <a href="_tensor_8hpp_source.xhtml#l00053">Tensor.hpp:53</a></div></div> |
| 198 | <div class="ttc" id="namespacearmnn_xhtml_ad8ed01ff3ff33333d8e19db4d2818bb6accedffbc6e5308e33d3843e8bdc0dad7"><div class="ttname"><a href="namespacearmnn.xhtml#ad8ed01ff3ff33333d8e19db4d2818bb6accedffbc6e5308e33d3843e8bdc0dad7">armnn::DataType::Signed32</a></div></div> |
| 199 | <div class="ttc" id="classarmnn_1_1_tensor_shape_xhtml"><div class="ttname"><a href="classarmnn_1_1_tensor_shape.xhtml">armnn::TensorShape</a></div><div class="ttdef"><b>Definition:</b> <a href="_tensor_8hpp_source.xhtml#l00020">Tensor.hpp:20</a></div></div> |
| 200 | <div class="ttc" id="namespacearmnn_xhtml_ae7e8cbf71db6a490789ca6dcaa8deeaea6a061313d22e51e0f25b7cd4dc065233"><div class="ttname"><a href="namespacearmnn.xhtml#ae7e8cbf71db6a490789ca6dcaa8deeaea6a061313d22e51e0f25b7cd4dc065233">armnn::ArgMinMaxFunction::Max</a></div></div> |
| 201 | </div><!-- fragment --> |
| 202 | </div> |
| 203 | </div> |
| 204 | <a id="a6e5d88259b3850369b5a20071011df8d"></a> |
| 205 | <h2 class="memtitle"><span class="permalink"><a href="#a6e5d88259b3850369b5a20071011df8d">◆ </a></span>ArgMaxSimpleTest()</h2> |
| 206 | |
| 207 | <div class="memitem"> |
| 208 | <div class="memproto"> |
| 209 | <table class="memname"> |
| 210 | <tr> |
| 211 | <td class="memname"><a class="el" href="struct_layer_test_result.xhtml">LayerTestResult</a><int32_t, 3> ArgMaxSimpleTest </td> |
| 212 | <td>(</td> |
| 213 | <td class="paramtype"><a class="el" href="classarmnn_1_1_i_workload_factory.xhtml">armnn::IWorkloadFactory</a> & </td> |
| 214 | <td class="paramname"><em>workloadFactory</em>, </td> |
| 215 | </tr> |
| 216 | <tr> |
| 217 | <td class="paramkey"></td> |
| 218 | <td></td> |
| 219 | <td class="paramtype">const <a class="el" href="classarmnn_1_1_i_backend_internal.xhtml#a693b40e6b94e958836aeb0410ca186bd">armnn::IBackendInternal::IMemoryManagerSharedPtr</a> & </td> |
| 220 | <td class="paramname"><em>memoryManager</em> </td> |
| 221 | </tr> |
| 222 | <tr> |
| 223 | <td></td> |
| 224 | <td>)</td> |
| 225 | <td></td><td></td> |
| 226 | </tr> |
| 227 | </table> |
| 228 | </div><div class="memdoc"> |
| 229 | |
| 230 | <p class="definition">Definition at line <a class="el" href="_arg_min_max_test_impl_8cpp_source.xhtml#l00064">64</a> of file <a class="el" href="_arg_min_max_test_impl_8cpp_source.xhtml">ArgMinMaxTestImpl.cpp</a>.</p> |
| 231 | |
| 232 | <p class="reference">References <a class="el" href="namespacearmnn.xhtml#ae7e8cbf71db6a490789ca6dcaa8deeaea6a061313d22e51e0f25b7cd4dc065233">armnn::Max</a>, <a class="el" href="_tensor_8cpp_source.xhtml#l00275">TensorInfo::SetQuantizationOffset()</a>, <a class="el" href="_tensor_8cpp_source.xhtml#l00259">TensorInfo::SetQuantizationScale()</a>, and <a class="el" href="namespacearmnn.xhtml#ad8ed01ff3ff33333d8e19db4d2818bb6accedffbc6e5308e33d3843e8bdc0dad7">armnn::Signed32</a>.</p> |
| 233 | <div class="fragment"><div class="line"><a name="l00067"></a><span class="lineno"> 67</span> {</div><div class="line"><a name="l00068"></a><span class="lineno"> 68</span>  <span class="keyword">const</span> <a class="code" href="classarmnn_1_1_tensor_shape.xhtml">armnn::TensorShape</a> inputShape{ 1, 1, 1, 5 };</div><div class="line"><a name="l00069"></a><span class="lineno"> 69</span>  <span class="keyword">const</span> <a class="code" href="classarmnn_1_1_tensor_shape.xhtml">armnn::TensorShape</a> outputShape{ 1, 1, 1 };</div><div class="line"><a name="l00070"></a><span class="lineno"> 70</span> </div><div class="line"><a name="l00071"></a><span class="lineno"> 71</span>  <a class="code" href="classarmnn_1_1_tensor_info.xhtml">armnn::TensorInfo</a> inputTensorInfo(inputShape, ArmnnType);</div><div class="line"><a name="l00072"></a><span class="lineno"> 72</span> </div><div class="line"><a name="l00073"></a><span class="lineno"> 73</span>  <span class="keywordflow">if</span> (armnn::IsQuantizedType<T>())</div><div class="line"><a name="l00074"></a><span class="lineno"> 74</span>  {</div><div class="line"><a name="l00075"></a><span class="lineno"> 75</span>  inputTensorInfo.SetQuantizationScale(1.0f);</div><div class="line"><a name="l00076"></a><span class="lineno"> 76</span>  inputTensorInfo.SetQuantizationOffset(0);</div><div class="line"><a name="l00077"></a><span class="lineno"> 77</span>  }</div><div class="line"><a name="l00078"></a><span class="lineno"> 78</span> </div><div class="line"><a name="l00079"></a><span class="lineno"> 79</span>  <a class="code" href="classarmnn_1_1_tensor_info.xhtml">armnn::TensorInfo</a> outputTensorInfo(outputShape, <a class="code" href="namespacearmnn.xhtml#ad8ed01ff3ff33333d8e19db4d2818bb6accedffbc6e5308e33d3843e8bdc0dad7">armnn::DataType::Signed32</a>);</div><div class="line"><a name="l00080"></a><span class="lineno"> 80</span> </div><div class="line"><a name="l00081"></a><span class="lineno"> 81</span>  std::vector<float> inputValues({ 5.0f, 2.0f, 8.0f, 10.0f, 9.0f });</div><div class="line"><a name="l00082"></a><span class="lineno"> 82</span>  std::vector<int32_t> outputValues({ 3 });</div><div class="line"><a name="l00083"></a><span class="lineno"> 83</span> </div><div class="line"><a name="l00084"></a><span class="lineno"> 84</span>  <span class="keywordflow">return</span> ArgMinMaxTestCommon<ArmnnType>(workloadFactory, memoryManager,</div><div class="line"><a name="l00085"></a><span class="lineno"> 85</span>  <a class="code" href="namespacearmnn.xhtml#ae7e8cbf71db6a490789ca6dcaa8deeaea6a061313d22e51e0f25b7cd4dc065233">armnn::ArgMinMaxFunction::Max</a>,</div><div class="line"><a name="l00086"></a><span class="lineno"> 86</span>  inputTensorInfo, outputTensorInfo,</div><div class="line"><a name="l00087"></a><span class="lineno"> 87</span>  inputValues, outputValues, -1); <span class="comment">// axis -1 === 3</span></div><div class="line"><a name="l00088"></a><span class="lineno"> 88</span> }</div><div class="ttc" id="classarmnn_1_1_tensor_info_xhtml"><div class="ttname"><a href="classarmnn_1_1_tensor_info.xhtml">armnn::TensorInfo</a></div><div class="ttdef"><b>Definition:</b> <a href="_tensor_8hpp_source.xhtml#l00053">Tensor.hpp:53</a></div></div> |
| 234 | <div class="ttc" id="namespacearmnn_xhtml_ad8ed01ff3ff33333d8e19db4d2818bb6accedffbc6e5308e33d3843e8bdc0dad7"><div class="ttname"><a href="namespacearmnn.xhtml#ad8ed01ff3ff33333d8e19db4d2818bb6accedffbc6e5308e33d3843e8bdc0dad7">armnn::DataType::Signed32</a></div></div> |
| 235 | <div class="ttc" id="classarmnn_1_1_tensor_shape_xhtml"><div class="ttname"><a href="classarmnn_1_1_tensor_shape.xhtml">armnn::TensorShape</a></div><div class="ttdef"><b>Definition:</b> <a href="_tensor_8hpp_source.xhtml#l00020">Tensor.hpp:20</a></div></div> |
| 236 | <div class="ttc" id="namespacearmnn_xhtml_ae7e8cbf71db6a490789ca6dcaa8deeaea6a061313d22e51e0f25b7cd4dc065233"><div class="ttname"><a href="namespacearmnn.xhtml#ae7e8cbf71db6a490789ca6dcaa8deeaea6a061313d22e51e0f25b7cd4dc065233">armnn::ArgMinMaxFunction::Max</a></div></div> |
| 237 | </div><!-- fragment --> |
| 238 | </div> |
| 239 | </div> |
| 240 | <a id="ad1a3228fc6f2d00c816a6f11ff1092ec"></a> |
| 241 | <h2 class="memtitle"><span class="permalink"><a href="#ad1a3228fc6f2d00c816a6f11ff1092ec">◆ </a></span>ArgMinChannelTest()</h2> |
| 242 | |
| 243 | <div class="memitem"> |
| 244 | <div class="memproto"> |
| 245 | <table class="memname"> |
| 246 | <tr> |
| 247 | <td class="memname"><a class="el" href="struct_layer_test_result.xhtml">LayerTestResult</a><int32_t, 3> ArgMinChannelTest </td> |
| 248 | <td>(</td> |
| 249 | <td class="paramtype"><a class="el" href="classarmnn_1_1_i_workload_factory.xhtml">armnn::IWorkloadFactory</a> & </td> |
| 250 | <td class="paramname"><em>workloadFactory</em>, </td> |
| 251 | </tr> |
| 252 | <tr> |
| 253 | <td class="paramkey"></td> |
| 254 | <td></td> |
| 255 | <td class="paramtype">const <a class="el" href="classarmnn_1_1_i_backend_internal.xhtml#a693b40e6b94e958836aeb0410ca186bd">armnn::IBackendInternal::IMemoryManagerSharedPtr</a> & </td> |
| 256 | <td class="paramname"><em>memoryManager</em> </td> |
| 257 | </tr> |
| 258 | <tr> |
| 259 | <td></td> |
| 260 | <td>)</td> |
| 261 | <td></td><td></td> |
| 262 | </tr> |
| 263 | </table> |
| 264 | </div><div class="memdoc"> |
| 265 | |
| 266 | <p class="definition">Definition at line <a class="el" href="_arg_min_max_test_impl_8cpp_source.xhtml#l00118">118</a> of file <a class="el" href="_arg_min_max_test_impl_8cpp_source.xhtml">ArgMinMaxTestImpl.cpp</a>.</p> |
| 267 | |
| 268 | <p class="reference">References <a class="el" href="namespacearmnn.xhtml#ae7e8cbf71db6a490789ca6dcaa8deeaea78d811e98514cd165dda532286610fd2">armnn::Min</a>, <a class="el" href="_tensor_8cpp_source.xhtml#l00275">TensorInfo::SetQuantizationOffset()</a>, <a class="el" href="_tensor_8cpp_source.xhtml#l00259">TensorInfo::SetQuantizationScale()</a>, and <a class="el" href="namespacearmnn.xhtml#ad8ed01ff3ff33333d8e19db4d2818bb6accedffbc6e5308e33d3843e8bdc0dad7">armnn::Signed32</a>.</p> |
| 269 | <div class="fragment"><div class="line"><a name="l00121"></a><span class="lineno"> 121</span> {</div><div class="line"><a name="l00122"></a><span class="lineno"> 122</span>  <span class="keyword">const</span> <a class="code" href="classarmnn_1_1_tensor_shape.xhtml">armnn::TensorShape</a> inputShape{ 1, 3, 2, 4};</div><div class="line"><a name="l00123"></a><span class="lineno"> 123</span>  <span class="keyword">const</span> <a class="code" href="classarmnn_1_1_tensor_shape.xhtml">armnn::TensorShape</a> outputShape{ 1, 2, 4 };</div><div class="line"><a name="l00124"></a><span class="lineno"> 124</span> </div><div class="line"><a name="l00125"></a><span class="lineno"> 125</span>  <a class="code" href="classarmnn_1_1_tensor_info.xhtml">armnn::TensorInfo</a> inputTensorInfo(inputShape, ArmnnType);</div><div class="line"><a name="l00126"></a><span class="lineno"> 126</span> </div><div class="line"><a name="l00127"></a><span class="lineno"> 127</span>  <span class="keywordflow">if</span> (armnn::IsQuantizedType<T>())</div><div class="line"><a name="l00128"></a><span class="lineno"> 128</span>  {</div><div class="line"><a name="l00129"></a><span class="lineno"> 129</span>  inputTensorInfo.SetQuantizationScale(1.0f);</div><div class="line"><a name="l00130"></a><span class="lineno"> 130</span>  inputTensorInfo.SetQuantizationOffset(0);</div><div class="line"><a name="l00131"></a><span class="lineno"> 131</span>  }</div><div class="line"><a name="l00132"></a><span class="lineno"> 132</span> </div><div class="line"><a name="l00133"></a><span class="lineno"> 133</span>  <a class="code" href="classarmnn_1_1_tensor_info.xhtml">armnn::TensorInfo</a> outputTensorInfo(outputShape, <a class="code" href="namespacearmnn.xhtml#ad8ed01ff3ff33333d8e19db4d2818bb6accedffbc6e5308e33d3843e8bdc0dad7">armnn::DataType::Signed32</a>);</div><div class="line"><a name="l00134"></a><span class="lineno"> 134</span> </div><div class="line"><a name="l00135"></a><span class="lineno"> 135</span>  std::vector<float> inputValues({ 1.0f, 2.0f, 3.0f, 4.0f,</div><div class="line"><a name="l00136"></a><span class="lineno"> 136</span>  5.0f, 6.0f, 7.0f, 8.0f,</div><div class="line"><a name="l00137"></a><span class="lineno"> 137</span> </div><div class="line"><a name="l00138"></a><span class="lineno"> 138</span>  10.0f, 20.0f, 30.0f, 40.0f,</div><div class="line"><a name="l00139"></a><span class="lineno"> 139</span>  50.0f, 60.0f, 70.0f, 80.0f,</div><div class="line"><a name="l00140"></a><span class="lineno"> 140</span> </div><div class="line"><a name="l00141"></a><span class="lineno"> 141</span>  100.0f, 200.0f, 300.0f, 400.0f,</div><div class="line"><a name="l00142"></a><span class="lineno"> 142</span>  500.0f, 600.0f, 700.0f, 800.0f });</div><div class="line"><a name="l00143"></a><span class="lineno"> 143</span>  std::vector<int32_t> outputValues({ 0, 0, 0, 0,</div><div class="line"><a name="l00144"></a><span class="lineno"> 144</span>  0, 0, 0, 0 });</div><div class="line"><a name="l00145"></a><span class="lineno"> 145</span> </div><div class="line"><a name="l00146"></a><span class="lineno"> 146</span>  <span class="keywordflow">return</span> ArgMinMaxTestCommon<ArmnnType>(workloadFactory, memoryManager,</div><div class="line"><a name="l00147"></a><span class="lineno"> 147</span>  <a class="code" href="namespacearmnn.xhtml#ae7e8cbf71db6a490789ca6dcaa8deeaea78d811e98514cd165dda532286610fd2">armnn::ArgMinMaxFunction::Min</a>,</div><div class="line"><a name="l00148"></a><span class="lineno"> 148</span>  inputTensorInfo, outputTensorInfo,</div><div class="line"><a name="l00149"></a><span class="lineno"> 149</span>  inputValues, outputValues, 1);</div><div class="line"><a name="l00150"></a><span class="lineno"> 150</span> }</div><div class="ttc" id="classarmnn_1_1_tensor_info_xhtml"><div class="ttname"><a href="classarmnn_1_1_tensor_info.xhtml">armnn::TensorInfo</a></div><div class="ttdef"><b>Definition:</b> <a href="_tensor_8hpp_source.xhtml#l00053">Tensor.hpp:53</a></div></div> |
| 270 | <div class="ttc" id="namespacearmnn_xhtml_ad8ed01ff3ff33333d8e19db4d2818bb6accedffbc6e5308e33d3843e8bdc0dad7"><div class="ttname"><a href="namespacearmnn.xhtml#ad8ed01ff3ff33333d8e19db4d2818bb6accedffbc6e5308e33d3843e8bdc0dad7">armnn::DataType::Signed32</a></div></div> |
| 271 | <div class="ttc" id="classarmnn_1_1_tensor_shape_xhtml"><div class="ttname"><a href="classarmnn_1_1_tensor_shape.xhtml">armnn::TensorShape</a></div><div class="ttdef"><b>Definition:</b> <a href="_tensor_8hpp_source.xhtml#l00020">Tensor.hpp:20</a></div></div> |
| 272 | <div class="ttc" id="namespacearmnn_xhtml_ae7e8cbf71db6a490789ca6dcaa8deeaea78d811e98514cd165dda532286610fd2"><div class="ttname"><a href="namespacearmnn.xhtml#ae7e8cbf71db6a490789ca6dcaa8deeaea78d811e98514cd165dda532286610fd2">armnn::ArgMinMaxFunction::Min</a></div></div> |
| 273 | </div><!-- fragment --> |
| 274 | </div> |
| 275 | </div> |
| 276 | <a id="a1fc3e309bafd760c40cec0e98d995529"></a> |
| 277 | <h2 class="memtitle"><span class="permalink"><a href="#a1fc3e309bafd760c40cec0e98d995529">◆ </a></span>ArgMinSimpleTest()</h2> |
| 278 | |
| 279 | <div class="memitem"> |
| 280 | <div class="memproto"> |
| 281 | <table class="memname"> |
| 282 | <tr> |
| 283 | <td class="memname"><a class="el" href="struct_layer_test_result.xhtml">LayerTestResult</a><int32_t, 3> ArgMinSimpleTest </td> |
| 284 | <td>(</td> |
| 285 | <td class="paramtype"><a class="el" href="classarmnn_1_1_i_workload_factory.xhtml">armnn::IWorkloadFactory</a> & </td> |
| 286 | <td class="paramname"><em>workloadFactory</em>, </td> |
| 287 | </tr> |
| 288 | <tr> |
| 289 | <td class="paramkey"></td> |
| 290 | <td></td> |
| 291 | <td class="paramtype">const <a class="el" href="classarmnn_1_1_i_backend_internal.xhtml#a693b40e6b94e958836aeb0410ca186bd">armnn::IBackendInternal::IMemoryManagerSharedPtr</a> & </td> |
| 292 | <td class="paramname"><em>memoryManager</em> </td> |
| 293 | </tr> |
| 294 | <tr> |
| 295 | <td></td> |
| 296 | <td>)</td> |
| 297 | <td></td><td></td> |
| 298 | </tr> |
| 299 | </table> |
| 300 | </div><div class="memdoc"> |
| 301 | |
| 302 | <p class="definition">Definition at line <a class="el" href="_arg_min_max_test_impl_8cpp_source.xhtml#l00091">91</a> of file <a class="el" href="_arg_min_max_test_impl_8cpp_source.xhtml">ArgMinMaxTestImpl.cpp</a>.</p> |
| 303 | |
| 304 | <p class="reference">References <a class="el" href="namespacearmnn.xhtml#ae7e8cbf71db6a490789ca6dcaa8deeaea78d811e98514cd165dda532286610fd2">armnn::Min</a>, <a class="el" href="_tensor_8cpp_source.xhtml#l00275">TensorInfo::SetQuantizationOffset()</a>, <a class="el" href="_tensor_8cpp_source.xhtml#l00259">TensorInfo::SetQuantizationScale()</a>, and <a class="el" href="namespacearmnn.xhtml#ad8ed01ff3ff33333d8e19db4d2818bb6accedffbc6e5308e33d3843e8bdc0dad7">armnn::Signed32</a>.</p> |
| 305 | <div class="fragment"><div class="line"><a name="l00094"></a><span class="lineno"> 94</span> {</div><div class="line"><a name="l00095"></a><span class="lineno"> 95</span>  <span class="keyword">const</span> <a class="code" href="classarmnn_1_1_tensor_shape.xhtml">armnn::TensorShape</a> inputShape{ 1, 1, 1, 5 };</div><div class="line"><a name="l00096"></a><span class="lineno"> 96</span>  <span class="keyword">const</span> <a class="code" href="classarmnn_1_1_tensor_shape.xhtml">armnn::TensorShape</a> outputShape{ 1, 1, 1 };</div><div class="line"><a name="l00097"></a><span class="lineno"> 97</span> </div><div class="line"><a name="l00098"></a><span class="lineno"> 98</span>  <a class="code" href="classarmnn_1_1_tensor_info.xhtml">armnn::TensorInfo</a> inputTensorInfo(inputShape, ArmnnType);</div><div class="line"><a name="l00099"></a><span class="lineno"> 99</span> </div><div class="line"><a name="l00100"></a><span class="lineno"> 100</span>  <span class="keywordflow">if</span> (armnn::IsQuantizedType<T>())</div><div class="line"><a name="l00101"></a><span class="lineno"> 101</span>  {</div><div class="line"><a name="l00102"></a><span class="lineno"> 102</span>  inputTensorInfo.SetQuantizationScale(1.0f);</div><div class="line"><a name="l00103"></a><span class="lineno"> 103</span>  inputTensorInfo.SetQuantizationOffset(0);</div><div class="line"><a name="l00104"></a><span class="lineno"> 104</span>  }</div><div class="line"><a name="l00105"></a><span class="lineno"> 105</span> </div><div class="line"><a name="l00106"></a><span class="lineno"> 106</span>  <a class="code" href="classarmnn_1_1_tensor_info.xhtml">armnn::TensorInfo</a> outputTensorInfo(outputShape, <a class="code" href="namespacearmnn.xhtml#ad8ed01ff3ff33333d8e19db4d2818bb6accedffbc6e5308e33d3843e8bdc0dad7">armnn::DataType::Signed32</a>);</div><div class="line"><a name="l00107"></a><span class="lineno"> 107</span> </div><div class="line"><a name="l00108"></a><span class="lineno"> 108</span>  std::vector<float> inputValues({ 5.0f, 2.0f, 8.0f, 10.0f, 9.0f });</div><div class="line"><a name="l00109"></a><span class="lineno"> 109</span>  std::vector<int32_t> outputValues({ 1 });</div><div class="line"><a name="l00110"></a><span class="lineno"> 110</span> </div><div class="line"><a name="l00111"></a><span class="lineno"> 111</span>  <span class="keywordflow">return</span> ArgMinMaxTestCommon<ArmnnType>(workloadFactory, memoryManager,</div><div class="line"><a name="l00112"></a><span class="lineno"> 112</span>  <a class="code" href="namespacearmnn.xhtml#ae7e8cbf71db6a490789ca6dcaa8deeaea78d811e98514cd165dda532286610fd2">armnn::ArgMinMaxFunction::Min</a>,</div><div class="line"><a name="l00113"></a><span class="lineno"> 113</span>  inputTensorInfo, outputTensorInfo,</div><div class="line"><a name="l00114"></a><span class="lineno"> 114</span>  inputValues, outputValues, 3);</div><div class="line"><a name="l00115"></a><span class="lineno"> 115</span> }</div><div class="ttc" id="classarmnn_1_1_tensor_info_xhtml"><div class="ttname"><a href="classarmnn_1_1_tensor_info.xhtml">armnn::TensorInfo</a></div><div class="ttdef"><b>Definition:</b> <a href="_tensor_8hpp_source.xhtml#l00053">Tensor.hpp:53</a></div></div> |
| 306 | <div class="ttc" id="namespacearmnn_xhtml_ad8ed01ff3ff33333d8e19db4d2818bb6accedffbc6e5308e33d3843e8bdc0dad7"><div class="ttname"><a href="namespacearmnn.xhtml#ad8ed01ff3ff33333d8e19db4d2818bb6accedffbc6e5308e33d3843e8bdc0dad7">armnn::DataType::Signed32</a></div></div> |
| 307 | <div class="ttc" id="classarmnn_1_1_tensor_shape_xhtml"><div class="ttname"><a href="classarmnn_1_1_tensor_shape.xhtml">armnn::TensorShape</a></div><div class="ttdef"><b>Definition:</b> <a href="_tensor_8hpp_source.xhtml#l00020">Tensor.hpp:20</a></div></div> |
| 308 | <div class="ttc" id="namespacearmnn_xhtml_ae7e8cbf71db6a490789ca6dcaa8deeaea78d811e98514cd165dda532286610fd2"><div class="ttname"><a href="namespacearmnn.xhtml#ae7e8cbf71db6a490789ca6dcaa8deeaea78d811e98514cd165dda532286610fd2">armnn::ArgMinMaxFunction::Min</a></div></div> |
| 309 | </div><!-- fragment --> |
| 310 | </div> |
| 311 | </div> |
| 312 | <a id="aba0c3336ffd8a44dc4ab7d61a32fd5c2"></a> |
| 313 | <h2 class="memtitle"><span class="permalink"><a href="#aba0c3336ffd8a44dc4ab7d61a32fd5c2">◆ </a></span>ArgMinWidthTest()</h2> |
| 314 | |
| 315 | <div class="memitem"> |
| 316 | <div class="memproto"> |
| 317 | <table class="memname"> |
| 318 | <tr> |
| 319 | <td class="memname"><a class="el" href="struct_layer_test_result.xhtml">LayerTestResult</a><int32_t, 3> ArgMinWidthTest </td> |
| 320 | <td>(</td> |
| 321 | <td class="paramtype"><a class="el" href="classarmnn_1_1_i_workload_factory.xhtml">armnn::IWorkloadFactory</a> & </td> |
| 322 | <td class="paramname"><em>workloadFactory</em>, </td> |
| 323 | </tr> |
| 324 | <tr> |
| 325 | <td class="paramkey"></td> |
| 326 | <td></td> |
| 327 | <td class="paramtype">const <a class="el" href="classarmnn_1_1_i_backend_internal.xhtml#a693b40e6b94e958836aeb0410ca186bd">armnn::IBackendInternal::IMemoryManagerSharedPtr</a> & </td> |
| 328 | <td class="paramname"><em>memoryManager</em> </td> |
| 329 | </tr> |
| 330 | <tr> |
| 331 | <td></td> |
| 332 | <td>)</td> |
| 333 | <td></td><td></td> |
| 334 | </tr> |
| 335 | </table> |
| 336 | </div><div class="memdoc"> |
| 337 | |
| 338 | <p class="definition">Definition at line <a class="el" href="_arg_min_max_test_impl_8cpp_source.xhtml#l00223">223</a> of file <a class="el" href="_arg_min_max_test_impl_8cpp_source.xhtml">ArgMinMaxTestImpl.cpp</a>.</p> |
| 339 | |
| 340 | <p class="reference">References <a class="el" href="namespacearmnn.xhtml#ae7e8cbf71db6a490789ca6dcaa8deeaea78d811e98514cd165dda532286610fd2">armnn::Min</a>, <a class="el" href="_tensor_8cpp_source.xhtml#l00275">TensorInfo::SetQuantizationOffset()</a>, <a class="el" href="_tensor_8cpp_source.xhtml#l00259">TensorInfo::SetQuantizationScale()</a>, and <a class="el" href="namespacearmnn.xhtml#ad8ed01ff3ff33333d8e19db4d2818bb6accedffbc6e5308e33d3843e8bdc0dad7">armnn::Signed32</a>.</p> |
| 341 | <div class="fragment"><div class="line"><a name="l00226"></a><span class="lineno"> 226</span> {</div><div class="line"><a name="l00227"></a><span class="lineno"> 227</span>  <span class="keyword">const</span> <a class="code" href="classarmnn_1_1_tensor_shape.xhtml">armnn::TensorShape</a> inputShape{ 1, 3, 2, 4};</div><div class="line"><a name="l00228"></a><span class="lineno"> 228</span>  <span class="keyword">const</span> <a class="code" href="classarmnn_1_1_tensor_shape.xhtml">armnn::TensorShape</a> outputShape{ 1, 3, 2 };</div><div class="line"><a name="l00229"></a><span class="lineno"> 229</span> </div><div class="line"><a name="l00230"></a><span class="lineno"> 230</span>  <a class="code" href="classarmnn_1_1_tensor_info.xhtml">armnn::TensorInfo</a> inputTensorInfo(inputShape, ArmnnType);</div><div class="line"><a name="l00231"></a><span class="lineno"> 231</span>  <a class="code" href="classarmnn_1_1_tensor_info.xhtml">armnn::TensorInfo</a> outputTensorInfo(outputShape, <a class="code" href="namespacearmnn.xhtml#ad8ed01ff3ff33333d8e19db4d2818bb6accedffbc6e5308e33d3843e8bdc0dad7">armnn::DataType::Signed32</a>);</div><div class="line"><a name="l00232"></a><span class="lineno"> 232</span> </div><div class="line"><a name="l00233"></a><span class="lineno"> 233</span>  <span class="keywordflow">if</span> (armnn::IsQuantizedType<T>())</div><div class="line"><a name="l00234"></a><span class="lineno"> 234</span>  {</div><div class="line"><a name="l00235"></a><span class="lineno"> 235</span>  inputTensorInfo.SetQuantizationScale(1.0f);</div><div class="line"><a name="l00236"></a><span class="lineno"> 236</span>  inputTensorInfo.SetQuantizationOffset(0);</div><div class="line"><a name="l00237"></a><span class="lineno"> 237</span>  }</div><div class="line"><a name="l00238"></a><span class="lineno"> 238</span> </div><div class="line"><a name="l00239"></a><span class="lineno"> 239</span>  std::vector<float> inputValues({ 1.0f, 2.0f, 3.0f, 4.0f,</div><div class="line"><a name="l00240"></a><span class="lineno"> 240</span>  5.0f, 6.0f, 7.0f, 8.0f,</div><div class="line"><a name="l00241"></a><span class="lineno"> 241</span> </div><div class="line"><a name="l00242"></a><span class="lineno"> 242</span>  10.0f, 20.0f, 30.0f, 40.0f,</div><div class="line"><a name="l00243"></a><span class="lineno"> 243</span>  50.0f, 60.0f, 70.0f, 80.0f,</div><div class="line"><a name="l00244"></a><span class="lineno"> 244</span> </div><div class="line"><a name="l00245"></a><span class="lineno"> 245</span>  100.0f, 200.0f, 300.0f, 400.0f,</div><div class="line"><a name="l00246"></a><span class="lineno"> 246</span>  500.0f, 600.0f, 700.0f, 800.0f });</div><div class="line"><a name="l00247"></a><span class="lineno"> 247</span>  std::vector<int32_t> outputValues({ 0, 0,</div><div class="line"><a name="l00248"></a><span class="lineno"> 248</span>  0, 0,</div><div class="line"><a name="l00249"></a><span class="lineno"> 249</span>  0, 0 });</div><div class="line"><a name="l00250"></a><span class="lineno"> 250</span> </div><div class="line"><a name="l00251"></a><span class="lineno"> 251</span>  <span class="keywordflow">return</span> ArgMinMaxTestCommon<ArmnnType>(workloadFactory, memoryManager,</div><div class="line"><a name="l00252"></a><span class="lineno"> 252</span>  <a class="code" href="namespacearmnn.xhtml#ae7e8cbf71db6a490789ca6dcaa8deeaea78d811e98514cd165dda532286610fd2">armnn::ArgMinMaxFunction::Min</a>,</div><div class="line"><a name="l00253"></a><span class="lineno"> 253</span>  inputTensorInfo, outputTensorInfo,</div><div class="line"><a name="l00254"></a><span class="lineno"> 254</span>  inputValues, outputValues, 3);</div><div class="line"><a name="l00255"></a><span class="lineno"> 255</span> }</div><div class="ttc" id="classarmnn_1_1_tensor_info_xhtml"><div class="ttname"><a href="classarmnn_1_1_tensor_info.xhtml">armnn::TensorInfo</a></div><div class="ttdef"><b>Definition:</b> <a href="_tensor_8hpp_source.xhtml#l00053">Tensor.hpp:53</a></div></div> |
| 342 | <div class="ttc" id="namespacearmnn_xhtml_ad8ed01ff3ff33333d8e19db4d2818bb6accedffbc6e5308e33d3843e8bdc0dad7"><div class="ttname"><a href="namespacearmnn.xhtml#ad8ed01ff3ff33333d8e19db4d2818bb6accedffbc6e5308e33d3843e8bdc0dad7">armnn::DataType::Signed32</a></div></div> |
| 343 | <div class="ttc" id="classarmnn_1_1_tensor_shape_xhtml"><div class="ttname"><a href="classarmnn_1_1_tensor_shape.xhtml">armnn::TensorShape</a></div><div class="ttdef"><b>Definition:</b> <a href="_tensor_8hpp_source.xhtml#l00020">Tensor.hpp:20</a></div></div> |
| 344 | <div class="ttc" id="namespacearmnn_xhtml_ae7e8cbf71db6a490789ca6dcaa8deeaea78d811e98514cd165dda532286610fd2"><div class="ttname"><a href="namespacearmnn.xhtml#ae7e8cbf71db6a490789ca6dcaa8deeaea78d811e98514cd165dda532286610fd2">armnn::ArgMinMaxFunction::Min</a></div></div> |
| 345 | </div><!-- fragment --> |
| 346 | </div> |
| 347 | </div> |
| 348 | </div><!-- contents --> |
| 349 | </div><!-- doc-content --> |
| 350 | <!-- start footer part --> |
| 351 | <div id="nav-path" class="navpath"><!-- id is needed for treeview function! --> |
| 352 | <ul> |
| 353 | <li class="navelem"><a class="el" href="dir_68267d1309a1af8e8297ef4c3efbcdba.xhtml">src</a></li><li class="navelem"><a class="el" href="dir_0f3cdec46afbc61a1ded8e1687c9c9a0.xhtml">backends</a></li><li class="navelem"><a class="el" href="dir_797a213d7d01b98ef12d53b0820ea64e.xhtml">backendsCommon</a></li><li class="navelem"><a class="el" href="dir_28bfe507f7e135bdae07c2a6b7f66696.xhtml">test</a></li><li class="navelem"><a class="el" href="dir_99a30439342d160875b21dac3498ad7f.xhtml">layerTests</a></li><li class="navelem"><a class="el" href="_arg_min_max_test_impl_8hpp.xhtml">ArgMinMaxTestImpl.hpp</a></li> |
| 354 | <li class="footer">Generated on Fri Mar 13 2020 16:09:14 for ArmNN by |
| 355 | <a href="http://www.doxygen.org/index.html"> |
| 356 | <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.13 </li> |
| 357 | </ul> |
| 358 | </div> |
| 359 | </body> |
| 360 | </html> |