Ryan OShea | de36e4a | 2020-03-13 16:26:19 +0000 | [diff] [blame] | 1 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> |
| 2 | <html xmlns="http://www.w3.org/1999/xhtml"> |
| 3 | <head> |
| 4 | <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> |
| 5 | <meta http-equiv="X-UA-Compatible" content="IE=9"/> |
| 6 | <meta name="generator" content="Doxygen 1.8.13"/> |
| 7 | <meta name="viewport" content="width=device-width, initial-scale=1"/> |
| 8 | <title>ArmNN: ClConvolution2dWorkload Class Reference</title> |
| 9 | <link href="tabs.css" rel="stylesheet" type="text/css"/> |
| 10 | <script type="text/javascript" src="jquery.js"></script> |
| 11 | <script type="text/javascript" src="dynsections.js"></script> |
| 12 | <link href="navtree.css" rel="stylesheet" type="text/css"/> |
| 13 | <script type="text/javascript" src="resize.js"></script> |
| 14 | <script type="text/javascript" src="navtreedata.js"></script> |
| 15 | <script type="text/javascript" src="navtree.js"></script> |
| 16 | <script type="text/javascript"> |
| 17 | $(document).ready(initResizable); |
| 18 | </script> |
| 19 | <link href="search/search.css" rel="stylesheet" type="text/css"/> |
| 20 | <script type="text/javascript" src="search/searchdata.js"></script> |
| 21 | <script type="text/javascript" src="search/search.js"></script> |
| 22 | <link href="doxygen.css" rel="stylesheet" type="text/css" /> |
| 23 | </head> |
| 24 | <body> |
| 25 | <div id="top"><!-- do not remove this div, it is closed by doxygen! --> |
| 26 | <div id="titlearea"> |
| 27 | <table cellspacing="0" cellpadding="0"> |
| 28 | <tbody> |
| 29 | <tr style="height: 56px;"> |
| 30 | <td id="projectalign" style="padding-left: 0.5em;"> |
| 31 | <div id="projectname">ArmNN |
| 32 |  <span id="projectnumber">NotReleased</span> |
| 33 | </div> |
| 34 | </td> |
| 35 | </tr> |
| 36 | </tbody> |
| 37 | </table> |
| 38 | </div> |
| 39 | <!-- end header part --> |
| 40 | <!-- Generated by Doxygen 1.8.13 --> |
| 41 | <script type="text/javascript"> |
| 42 | var searchBox = new SearchBox("searchBox", "search",false,'Search'); |
| 43 | </script> |
| 44 | <script type="text/javascript" src="menudata.js"></script> |
| 45 | <script type="text/javascript" src="menu.js"></script> |
| 46 | <script type="text/javascript"> |
| 47 | $(function() { |
| 48 | initMenu('',true,false,'search.php','Search'); |
| 49 | $(document).ready(function() { init_search(); }); |
| 50 | }); |
| 51 | </script> |
| 52 | <div id="main-nav"></div> |
| 53 | </div><!-- top --> |
| 54 | <div id="side-nav" class="ui-resizable side-nav-resizable"> |
| 55 | <div id="nav-tree"> |
| 56 | <div id="nav-tree-contents"> |
| 57 | <div id="nav-sync" class="sync"></div> |
| 58 | </div> |
| 59 | </div> |
| 60 | <div id="splitbar" style="-moz-user-select:none;" |
| 61 | class="ui-resizable-handle"> |
| 62 | </div> |
| 63 | </div> |
| 64 | <script type="text/javascript"> |
| 65 | $(document).ready(function(){initNavTree('classarmnn_1_1_cl_convolution2d_workload.html','');}); |
| 66 | </script> |
| 67 | <div id="doc-content"> |
| 68 | <!-- window showing the filter options --> |
| 69 | <div id="MSearchSelectWindow" |
| 70 | onmouseover="return searchBox.OnSearchSelectShow()" |
| 71 | onmouseout="return searchBox.OnSearchSelectHide()" |
| 72 | onkeydown="return searchBox.OnSearchSelectKey(event)"> |
| 73 | </div> |
| 74 | |
| 75 | <!-- iframe showing the search results (closed by default) --> |
| 76 | <div id="MSearchResultsWindow"> |
| 77 | <iframe src="javascript:void(0)" frameborder="0" |
| 78 | name="MSearchResults" id="MSearchResults"> |
| 79 | </iframe> |
| 80 | </div> |
| 81 | |
| 82 | <div class="header"> |
| 83 | <div class="summary"> |
| 84 | <a href="#pub-methods">Public Member Functions</a> | |
| 85 | <a href="classarmnn_1_1_cl_convolution2d_workload-members.html">List of all members</a> </div> |
| 86 | <div class="headertitle"> |
| 87 | <div class="title">ClConvolution2dWorkload Class Reference</div> </div> |
| 88 | </div><!--header--> |
| 89 | <div class="contents"> |
| 90 | |
| 91 | <p><code>#include <<a class="el" href="_cl_convolution2d_workload_8hpp_source.html">ClConvolution2dWorkload.hpp</a>></code></p> |
| 92 | <div class="dynheader"> |
| 93 | Inheritance diagram for ClConvolution2dWorkload:</div> |
| 94 | <div class="dyncontent"> |
| 95 | <div class="center"> |
| 96 | <img src="classarmnn_1_1_cl_convolution2d_workload.png" usemap="#ClConvolution2dWorkload_map" alt=""/> |
| 97 | <map id="ClConvolution2dWorkload_map" name="ClConvolution2dWorkload_map"> |
| 98 | <area href="classarmnn_1_1_base_workload.html" alt="BaseWorkload< Convolution2dQueueDescriptor >" shape="rect" coords="0,56,295,80"/> |
| 99 | <area href="classarmnn_1_1_i_workload.html" title="Workload interface to enqueue a layer computation. " alt="IWorkload" shape="rect" coords="0,0,295,24"/> |
| 100 | </map> |
| 101 | </div></div> |
| 102 | <table class="memberdecls"> |
| 103 | <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a> |
| 104 | Public Member Functions</h2></td></tr> |
| 105 | <tr class="memitem:a3896d678476c5f966a32c806a8fda937"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classarmnn_1_1_cl_convolution2d_workload.html#a3896d678476c5f966a32c806a8fda937">ClConvolution2dWorkload</a> (const <a class="el" href="structarmnn_1_1_convolution2d_queue_descriptor.html">Convolution2dQueueDescriptor</a> &descriptor, const <a class="el" href="structarmnn_1_1_workload_info.html">WorkloadInfo</a> &<a class="el" href="namespacearmnn.html#a4dc0adc6737b5944e7671bee71788407acaf9b6b99962bf5c2264824231d7a40c">info</a>, std::shared_ptr< arm_compute::MemoryManagerOnDemand > &memoryManager)</td></tr> |
| 106 | <tr class="separator:a3896d678476c5f966a32c806a8fda937"><td class="memSeparator" colspan="2"> </td></tr> |
| 107 | <tr class="memitem:ae071e8822437c78baea75c3aef3a263a"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classarmnn_1_1_cl_convolution2d_workload.html#ae071e8822437c78baea75c3aef3a263a">Execute</a> () const override</td></tr> |
| 108 | <tr class="separator:ae071e8822437c78baea75c3aef3a263a"><td class="memSeparator" colspan="2"> </td></tr> |
| 109 | <tr class="inherit_header pub_methods_classarmnn_1_1_base_workload"><td colspan="2" onclick="javascript:toggleInherit('pub_methods_classarmnn_1_1_base_workload')"><img src="closed.png" alt="-"/> Public Member Functions inherited from <a class="el" href="classarmnn_1_1_base_workload.html">BaseWorkload< Convolution2dQueueDescriptor ></a></td></tr> |
| 110 | <tr class="memitem:af2ef420610280dc5a661cd3d4836d5a2 inherit pub_methods_classarmnn_1_1_base_workload"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classarmnn_1_1_base_workload.html#af2ef420610280dc5a661cd3d4836d5a2">BaseWorkload</a> (const <a class="el" href="structarmnn_1_1_convolution2d_queue_descriptor.html">Convolution2dQueueDescriptor</a> &descriptor, const <a class="el" href="structarmnn_1_1_workload_info.html">WorkloadInfo</a> &info)</td></tr> |
| 111 | <tr class="separator:af2ef420610280dc5a661cd3d4836d5a2 inherit pub_methods_classarmnn_1_1_base_workload"><td class="memSeparator" colspan="2"> </td></tr> |
| 112 | <tr class="memitem:a81627f96ba06d76e147f7d392a8117ed inherit pub_methods_classarmnn_1_1_base_workload"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classarmnn_1_1_base_workload.html#a81627f96ba06d76e147f7d392a8117ed">PostAllocationConfigure</a> () override</td></tr> |
| 113 | <tr class="separator:a81627f96ba06d76e147f7d392a8117ed inherit pub_methods_classarmnn_1_1_base_workload"><td class="memSeparator" colspan="2"> </td></tr> |
| 114 | <tr class="memitem:a965cf380c7adf547d0f14b3f6d1da249 inherit pub_methods_classarmnn_1_1_base_workload"><td class="memItemLeft" align="right" valign="top">const <a class="el" href="structarmnn_1_1_convolution2d_queue_descriptor.html">Convolution2dQueueDescriptor</a> & </td><td class="memItemRight" valign="bottom"><a class="el" href="classarmnn_1_1_base_workload.html#a965cf380c7adf547d0f14b3f6d1da249">GetData</a> () const</td></tr> |
| 115 | <tr class="separator:a965cf380c7adf547d0f14b3f6d1da249 inherit pub_methods_classarmnn_1_1_base_workload"><td class="memSeparator" colspan="2"> </td></tr> |
| 116 | <tr class="memitem:a29c2c6dd77c6fe10674fc6876751cbce inherit pub_methods_classarmnn_1_1_base_workload"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classarmnn_1_1profiling_1_1_profiling_guid.html">profiling::ProfilingGuid</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classarmnn_1_1_base_workload.html#a29c2c6dd77c6fe10674fc6876751cbce">GetGuid</a> () const final</td></tr> |
| 117 | <tr class="separator:a29c2c6dd77c6fe10674fc6876751cbce inherit pub_methods_classarmnn_1_1_base_workload"><td class="memSeparator" colspan="2"> </td></tr> |
| 118 | <tr class="inherit_header pub_methods_classarmnn_1_1_i_workload"><td colspan="2" onclick="javascript:toggleInherit('pub_methods_classarmnn_1_1_i_workload')"><img src="closed.png" alt="-"/> Public Member Functions inherited from <a class="el" href="classarmnn_1_1_i_workload.html">IWorkload</a></td></tr> |
| 119 | <tr class="memitem:a69c83c02ae8de866bc7a46c49e69c1ba inherit pub_methods_classarmnn_1_1_i_workload"><td class="memItemLeft" align="right" valign="top">virtual </td><td class="memItemRight" valign="bottom"><a class="el" href="classarmnn_1_1_i_workload.html#a69c83c02ae8de866bc7a46c49e69c1ba">~IWorkload</a> ()</td></tr> |
| 120 | <tr class="separator:a69c83c02ae8de866bc7a46c49e69c1ba inherit pub_methods_classarmnn_1_1_i_workload"><td class="memSeparator" colspan="2"> </td></tr> |
| 121 | <tr class="memitem:ab81312bd5e64cbae2803de9f243bdb32 inherit pub_methods_classarmnn_1_1_i_workload"><td class="memItemLeft" align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="classarmnn_1_1_i_workload.html#ab81312bd5e64cbae2803de9f243bdb32">RegisterDebugCallback</a> (const <a class="el" href="namespacearmnn.html#a15f3ad9b5e4e3d46b0a6dda246a7bc28">DebugCallbackFunction</a> &)</td></tr> |
| 122 | <tr class="separator:ab81312bd5e64cbae2803de9f243bdb32 inherit pub_methods_classarmnn_1_1_i_workload"><td class="memSeparator" colspan="2"> </td></tr> |
| 123 | </table><table class="memberdecls"> |
| 124 | <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="inherited"></a> |
| 125 | Additional Inherited Members</h2></td></tr> |
| 126 | <tr class="inherit_header pro_attribs_classarmnn_1_1_base_workload"><td colspan="2" onclick="javascript:toggleInherit('pro_attribs_classarmnn_1_1_base_workload')"><img src="closed.png" alt="-"/> Protected Attributes inherited from <a class="el" href="classarmnn_1_1_base_workload.html">BaseWorkload< Convolution2dQueueDescriptor ></a></td></tr> |
| 127 | <tr class="memitem:a0a487c549c63319505095b855ea3c195 inherit pro_attribs_classarmnn_1_1_base_workload"><td class="memItemLeft" align="right" valign="top">const <a class="el" href="structarmnn_1_1_convolution2d_queue_descriptor.html">Convolution2dQueueDescriptor</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classarmnn_1_1_base_workload.html#a0a487c549c63319505095b855ea3c195">m_Data</a></td></tr> |
| 128 | <tr class="separator:a0a487c549c63319505095b855ea3c195 inherit pro_attribs_classarmnn_1_1_base_workload"><td class="memSeparator" colspan="2"> </td></tr> |
| 129 | <tr class="memitem:a902044db290170b8467ed4697b7fed24 inherit pro_attribs_classarmnn_1_1_base_workload"><td class="memItemLeft" align="right" valign="top">const <a class="el" href="classarmnn_1_1profiling_1_1_profiling_guid.html">profiling::ProfilingGuid</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classarmnn_1_1_base_workload.html#a902044db290170b8467ed4697b7fed24">m_Guid</a></td></tr> |
| 130 | <tr class="separator:a902044db290170b8467ed4697b7fed24 inherit pro_attribs_classarmnn_1_1_base_workload"><td class="memSeparator" colspan="2"> </td></tr> |
| 131 | </table> |
| 132 | <a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2> |
| 133 | <div class="textblock"> |
| 134 | <p class="definition">Definition at line <a class="el" href="_cl_convolution2d_workload_8hpp_source.html#l00027">27</a> of file <a class="el" href="_cl_convolution2d_workload_8hpp_source.html">ClConvolution2dWorkload.hpp</a>.</p> |
| 135 | </div><h2 class="groupheader">Constructor & Destructor Documentation</h2> |
| 136 | <a id="a3896d678476c5f966a32c806a8fda937"></a> |
| 137 | <h2 class="memtitle"><span class="permalink"><a href="#a3896d678476c5f966a32c806a8fda937">◆ </a></span>ClConvolution2dWorkload()</h2> |
| 138 | |
| 139 | <div class="memitem"> |
| 140 | <div class="memproto"> |
| 141 | <table class="memname"> |
| 142 | <tr> |
| 143 | <td class="memname"><a class="el" href="classarmnn_1_1_cl_convolution2d_workload.html">ClConvolution2dWorkload</a> </td> |
| 144 | <td>(</td> |
| 145 | <td class="paramtype">const <a class="el" href="structarmnn_1_1_convolution2d_queue_descriptor.html">Convolution2dQueueDescriptor</a> & </td> |
| 146 | <td class="paramname"><em>descriptor</em>, </td> |
| 147 | </tr> |
| 148 | <tr> |
| 149 | <td class="paramkey"></td> |
| 150 | <td></td> |
| 151 | <td class="paramtype">const <a class="el" href="structarmnn_1_1_workload_info.html">WorkloadInfo</a> & </td> |
| 152 | <td class="paramname"><em>info</em>, </td> |
| 153 | </tr> |
| 154 | <tr> |
| 155 | <td class="paramkey"></td> |
| 156 | <td></td> |
| 157 | <td class="paramtype">std::shared_ptr< arm_compute::MemoryManagerOnDemand > & </td> |
| 158 | <td class="paramname"><em>memoryManager</em> </td> |
| 159 | </tr> |
| 160 | <tr> |
| 161 | <td></td> |
| 162 | <td>)</td> |
| 163 | <td></td><td></td> |
| 164 | </tr> |
| 165 | </table> |
| 166 | </div><div class="memdoc"> |
| 167 | |
| 168 | <p class="definition">Definition at line <a class="el" href="_cl_convolution2d_workload_8cpp_source.html#l00058">58</a> of file <a class="el" href="_cl_convolution2d_workload_8cpp_source.html">ClConvolution2dWorkload.cpp</a>.</p> |
| 169 | |
| 170 | <p class="reference">References <a class="el" href="_cpu_tensor_handle_8hpp_source.html#l00037">ConstCpuTensorHandle::GetTensorInfo()</a>, <a class="el" href="_workload_8hpp_source.html#l00046">BaseWorkload< Convolution2dQueueDescriptor >::m_Data</a>, and <a class="el" href="_workload_data_8hpp_source.html#l00176">Convolution2dQueueDescriptor::m_Weight</a>.</p> |
| 171 | <div class="fragment"><div class="line"><a name="l00060"></a><span class="lineno"> 60</span>  : BaseWorkload<Convolution2dQueueDescriptor>(descriptor, <a class="code" href="namespacearmnn.html#a4dc0adc6737b5944e7671bee71788407acaf9b6b99962bf5c2264824231d7a40c">info</a>)</div><div class="line"><a name="l00061"></a><span class="lineno"> 61</span>  , m_ConvolutionLayer(memoryManager)</div><div class="line"><a name="l00062"></a><span class="lineno"> 62</span> {</div><div class="line"><a name="l00063"></a><span class="lineno"> 63</span>  <span class="comment">// todo: check tensor shapes match.</span></div><div class="line"><a name="l00064"></a><span class="lineno"> 64</span>  <span class="keyword">const</span> TensorInfo& weightInfo = <a class="code" href="classarmnn_1_1_base_workload.html#a0a487c549c63319505095b855ea3c195">m_Data</a>.<a class="code" href="structarmnn_1_1_convolution2d_queue_descriptor.html#a3369b66d9316a773a41711e3f590c041">m_Weight</a>-><a class="code" href="classarmnn_1_1_const_cpu_tensor_handle.html#a66e8f43a5b42b500871ed96e15419567">GetTensorInfo</a>();</div><div class="line"><a name="l00065"></a><span class="lineno"> 65</span> </div><div class="line"><a name="l00066"></a><span class="lineno"> 66</span>  m_KernelTensor = std::make_unique<arm_compute::CLTensor>();</div><div class="line"><a name="l00067"></a><span class="lineno"> 67</span>  BuildArmComputeTensor(*m_KernelTensor, weightInfo, <a class="code" href="classarmnn_1_1_base_workload.html#a0a487c549c63319505095b855ea3c195">m_Data</a>.<a class="code" href="structarmnn_1_1_queue_descriptor_with_parameters.html#aad91b9bbf7aa365d304febe79a3d1333">m_Parameters</a>.<a class="code" href="structarmnn_1_1_convolution2d_descriptor.html#a6089e1ca91914015777ea780a513131a">m_DataLayout</a>);</div><div class="line"><a name="l00068"></a><span class="lineno"> 68</span> </div><div class="line"><a name="l00069"></a><span class="lineno"> 69</span>  <span class="keyword">const</span> arm_compute::Size2D aclDilationInfo = BuildArmComputeSize2D(<a class="code" href="classarmnn_1_1_base_workload.html#a0a487c549c63319505095b855ea3c195">m_Data</a>.<a class="code" href="structarmnn_1_1_queue_descriptor_with_parameters.html#aad91b9bbf7aa365d304febe79a3d1333">m_Parameters</a>.<a class="code" href="structarmnn_1_1_convolution2d_descriptor.html#aa3c6a77a963a98ccb8ea7b8fd008a8c1">m_DilationX</a>,</div><div class="line"><a name="l00070"></a><span class="lineno"> 70</span>  <a class="code" href="classarmnn_1_1_base_workload.html#a0a487c549c63319505095b855ea3c195">m_Data</a>.<a class="code" href="structarmnn_1_1_queue_descriptor_with_parameters.html#aad91b9bbf7aa365d304febe79a3d1333">m_Parameters</a>.<a class="code" href="structarmnn_1_1_convolution2d_descriptor.html#a302b688d88dd73cde0fb1faef6679907">m_DilationY</a>);</div><div class="line"><a name="l00071"></a><span class="lineno"> 71</span> </div><div class="line"><a name="l00072"></a><span class="lineno"> 72</span>  <span class="keywordflow">if</span> (<a class="code" href="classarmnn_1_1_base_workload.html#a0a487c549c63319505095b855ea3c195">m_Data</a>.<a class="code" href="structarmnn_1_1_queue_descriptor_with_parameters.html#aad91b9bbf7aa365d304febe79a3d1333">m_Parameters</a>.<a class="code" href="structarmnn_1_1_convolution2d_descriptor.html#aea202e14d8874cefd9a0f778022b7e25">m_BiasEnabled</a>)</div><div class="line"><a name="l00073"></a><span class="lineno"> 73</span>  {</div><div class="line"><a name="l00074"></a><span class="lineno"> 74</span>  m_BiasTensor = std::make_unique<arm_compute::CLTensor>();</div><div class="line"><a name="l00075"></a><span class="lineno"> 75</span>  BuildArmComputeTensor(*m_BiasTensor, <a class="code" href="classarmnn_1_1_base_workload.html#a0a487c549c63319505095b855ea3c195">m_Data</a>.<a class="code" href="structarmnn_1_1_convolution2d_queue_descriptor.html#ab3437cee6b0687812104fc1b37cbe8b3">m_Bias</a>-><a class="code" href="classarmnn_1_1_const_cpu_tensor_handle.html#a66e8f43a5b42b500871ed96e15419567">GetTensorInfo</a>(), <a class="code" href="classarmnn_1_1_base_workload.html#a0a487c549c63319505095b855ea3c195">m_Data</a>.<a class="code" href="structarmnn_1_1_queue_descriptor_with_parameters.html#aad91b9bbf7aa365d304febe79a3d1333">m_Parameters</a>.<a class="code" href="structarmnn_1_1_convolution2d_descriptor.html#a6089e1ca91914015777ea780a513131a">m_DataLayout</a>);</div><div class="line"><a name="l00076"></a><span class="lineno"> 76</span>  }</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>  <a class="code" href="classarmnn_1_1_base_workload.html#a0a487c549c63319505095b855ea3c195">m_Data</a>.<a class="code" href="structarmnn_1_1_queue_descriptor.html#a765d2cee4ccce5b9467e0c2b6d25b84a">ValidateInputsOutputs</a>(<span class="stringliteral">"ClConvolution2dWorkload"</span>, 1, 1);</div><div class="line"><a name="l00079"></a><span class="lineno"> 79</span> </div><div class="line"><a name="l00080"></a><span class="lineno"> 80</span>  arm_compute::ICLTensor& input = <span class="keyword">static_cast<</span>IClTensorHandle*<span class="keyword">></span>(<a class="code" href="classarmnn_1_1_base_workload.html#a0a487c549c63319505095b855ea3c195">m_Data</a>.<a class="code" href="structarmnn_1_1_queue_descriptor.html#a4b50e46a6810018f3edecfb68b2a76b3">m_Inputs</a>[0])->GetTensor();</div><div class="line"><a name="l00081"></a><span class="lineno"> 81</span>  arm_compute::ICLTensor& output = <span class="keyword">static_cast<</span>IClTensorHandle*<span class="keyword">></span>(<a class="code" href="classarmnn_1_1_base_workload.html#a0a487c549c63319505095b855ea3c195">m_Data</a>.<a class="code" href="structarmnn_1_1_queue_descriptor.html#a6abd491bb99ffe88bd472c1ae5a1ed1a">m_Outputs</a>[0])->GetTensor();</div><div class="line"><a name="l00082"></a><span class="lineno"> 82</span> </div><div class="line"><a name="l00083"></a><span class="lineno"> 83</span>  <a class="code" href="namespacearmnn.html#ad1d5cce2d9e9a5d61c243e5c989112e0">arm_compute::DataLayout</a> aclDataLayout = ConvertDataLayout(<a class="code" href="classarmnn_1_1_base_workload.html#a0a487c549c63319505095b855ea3c195">m_Data</a>.<a class="code" href="structarmnn_1_1_queue_descriptor_with_parameters.html#aad91b9bbf7aa365d304febe79a3d1333">m_Parameters</a>.<a class="code" href="structarmnn_1_1_convolution2d_descriptor.html#a6089e1ca91914015777ea780a513131a">m_DataLayout</a>);</div><div class="line"><a name="l00084"></a><span class="lineno"> 84</span>  input.info()->set_data_layout(aclDataLayout);</div><div class="line"><a name="l00085"></a><span class="lineno"> 85</span>  output.info()->set_data_layout(aclDataLayout);</div><div class="line"><a name="l00086"></a><span class="lineno"> 86</span> </div><div class="line"><a name="l00087"></a><span class="lineno"> 87</span>  arm_compute::PadStrideInfo padStrideInfo = BuildArmComputePadStrideInfo(<a class="code" href="classarmnn_1_1_base_workload.html#a0a487c549c63319505095b855ea3c195">m_Data</a>.<a class="code" href="structarmnn_1_1_queue_descriptor_with_parameters.html#aad91b9bbf7aa365d304febe79a3d1333">m_Parameters</a>);</div><div class="line"><a name="l00088"></a><span class="lineno"> 88</span> </div><div class="line"><a name="l00089"></a><span class="lineno"> 89</span>  m_ConvolutionLayer.configure(&input,</div><div class="line"><a name="l00090"></a><span class="lineno"> 90</span>  m_KernelTensor.get(),</div><div class="line"><a name="l00091"></a><span class="lineno"> 91</span>  m_BiasTensor.get(),</div><div class="line"><a name="l00092"></a><span class="lineno"> 92</span>  &output,</div><div class="line"><a name="l00093"></a><span class="lineno"> 93</span>  padStrideInfo,</div><div class="line"><a name="l00094"></a><span class="lineno"> 94</span>  arm_compute::WeightsInfo(),</div><div class="line"><a name="l00095"></a><span class="lineno"> 95</span>  aclDilationInfo);</div><div class="line"><a name="l00096"></a><span class="lineno"> 96</span> </div><div class="line"><a name="l00097"></a><span class="lineno"> 97</span>  <a class="code" href="namespacearmnn.html#a46747c3d0b99968be0b37d74bc9687dd">InitializeArmComputeClTensorData</a>(*m_KernelTensor, <a class="code" href="classarmnn_1_1_base_workload.html#a0a487c549c63319505095b855ea3c195">m_Data</a>.<a class="code" href="structarmnn_1_1_convolution2d_queue_descriptor.html#a3369b66d9316a773a41711e3f590c041">m_Weight</a>);</div><div class="line"><a name="l00098"></a><span class="lineno"> 98</span> </div><div class="line"><a name="l00099"></a><span class="lineno"> 99</span>  <span class="keywordflow">if</span> (m_BiasTensor)</div><div class="line"><a name="l00100"></a><span class="lineno"> 100</span>  {</div><div class="line"><a name="l00101"></a><span class="lineno"> 101</span>  <a class="code" href="namespacearmnn.html#a46747c3d0b99968be0b37d74bc9687dd">InitializeArmComputeClTensorData</a>(*m_BiasTensor, <a class="code" href="classarmnn_1_1_base_workload.html#a0a487c549c63319505095b855ea3c195">m_Data</a>.<a class="code" href="structarmnn_1_1_convolution2d_queue_descriptor.html#ab3437cee6b0687812104fc1b37cbe8b3">m_Bias</a>);</div><div class="line"><a name="l00102"></a><span class="lineno"> 102</span>  }</div><div class="line"><a name="l00103"></a><span class="lineno"> 103</span> </div><div class="line"><a name="l00104"></a><span class="lineno"> 104</span>  <span class="comment">// Force Compute Library to perform the necessary copying and reshaping, after which</span></div><div class="line"><a name="l00105"></a><span class="lineno"> 105</span>  <span class="comment">// delete all the input tensors that will no longer be needed</span></div><div class="line"><a name="l00106"></a><span class="lineno"> 106</span>  m_ConvolutionLayer.prepare();</div><div class="line"><a name="l00107"></a><span class="lineno"> 107</span>  FreeUnusedTensors();</div><div class="line"><a name="l00108"></a><span class="lineno"> 108</span> }</div><div class="ttc" id="structarmnn_1_1_convolution2d_descriptor_html_a6089e1ca91914015777ea780a513131a"><div class="ttname"><a href="structarmnn_1_1_convolution2d_descriptor.html#a6089e1ca91914015777ea780a513131a">armnn::Convolution2dDescriptor::m_DataLayout</a></div><div class="ttdeci">DataLayout m_DataLayout</div><div class="ttdoc">The data layout to be used (NCHW, NHWC). </div><div class="ttdef"><b>Definition:</b> <a href="_descriptors_8hpp_source.html#l00440">Descriptors.hpp:440</a></div></div> |
| 172 | <div class="ttc" id="classarmnn_1_1_const_cpu_tensor_handle_html_a66e8f43a5b42b500871ed96e15419567"><div class="ttname"><a href="classarmnn_1_1_const_cpu_tensor_handle.html#a66e8f43a5b42b500871ed96e15419567">armnn::ConstCpuTensorHandle::GetTensorInfo</a></div><div class="ttdeci">const TensorInfo & GetTensorInfo() const</div><div class="ttdef"><b>Definition:</b> <a href="_cpu_tensor_handle_8hpp_source.html#l00037">CpuTensorHandle.hpp:37</a></div></div> |
| 173 | <div class="ttc" id="namespacearmnn_html_a4dc0adc6737b5944e7671bee71788407acaf9b6b99962bf5c2264824231d7a40c"><div class="ttname"><a href="namespacearmnn.html#a4dc0adc6737b5944e7671bee71788407acaf9b6b99962bf5c2264824231d7a40c">armnn::BoostLogSeverityMapping::info</a></div></div> |
| 174 | <div class="ttc" id="namespacearmnn_html_a46747c3d0b99968be0b37d74bc9687dd"><div class="ttname"><a href="namespacearmnn.html#a46747c3d0b99968be0b37d74bc9687dd">armnn::InitializeArmComputeClTensorData</a></div><div class="ttdeci">void InitializeArmComputeClTensorData(arm_compute::CLTensor &clTensor, const ConstCpuTensorHandle *handle)</div><div class="ttdef"><b>Definition:</b> <a href="_cl_workload_utils_8hpp_source.html#l00090">ClWorkloadUtils.hpp:90</a></div></div> |
| 175 | <div class="ttc" id="structarmnn_1_1_queue_descriptor_with_parameters_html_aad91b9bbf7aa365d304febe79a3d1333"><div class="ttname"><a href="structarmnn_1_1_queue_descriptor_with_parameters.html#aad91b9bbf7aa365d304febe79a3d1333">armnn::QueueDescriptorWithParameters::m_Parameters</a></div><div class="ttdeci">LayerDescriptor m_Parameters</div><div class="ttdef"><b>Definition:</b> <a href="_workload_data_8hpp_source.html#l00049">WorkloadData.hpp:49</a></div></div> |
| 176 | <div class="ttc" id="structarmnn_1_1_convolution2d_queue_descriptor_html_a3369b66d9316a773a41711e3f590c041"><div class="ttname"><a href="structarmnn_1_1_convolution2d_queue_descriptor.html#a3369b66d9316a773a41711e3f590c041">armnn::Convolution2dQueueDescriptor::m_Weight</a></div><div class="ttdeci">const ConstCpuTensorHandle * m_Weight</div><div class="ttdef"><b>Definition:</b> <a href="_workload_data_8hpp_source.html#l00176">WorkloadData.hpp:176</a></div></div> |
| 177 | <div class="ttc" id="classarmnn_1_1_base_workload_html_a0a487c549c63319505095b855ea3c195"><div class="ttname"><a href="classarmnn_1_1_base_workload.html#a0a487c549c63319505095b855ea3c195">armnn::BaseWorkload< Convolution2dQueueDescriptor >::m_Data</a></div><div class="ttdeci">const Convolution2dQueueDescriptor m_Data</div><div class="ttdef"><b>Definition:</b> <a href="_workload_8hpp_source.html#l00046">Workload.hpp:46</a></div></div> |
| 178 | <div class="ttc" id="structarmnn_1_1_convolution2d_queue_descriptor_html_ab3437cee6b0687812104fc1b37cbe8b3"><div class="ttname"><a href="structarmnn_1_1_convolution2d_queue_descriptor.html#ab3437cee6b0687812104fc1b37cbe8b3">armnn::Convolution2dQueueDescriptor::m_Bias</a></div><div class="ttdeci">const ConstCpuTensorHandle * m_Bias</div><div class="ttdef"><b>Definition:</b> <a href="_workload_data_8hpp_source.html#l00177">WorkloadData.hpp:177</a></div></div> |
| 179 | <div class="ttc" id="structarmnn_1_1_convolution2d_descriptor_html_aea202e14d8874cefd9a0f778022b7e25"><div class="ttname"><a href="structarmnn_1_1_convolution2d_descriptor.html#aea202e14d8874cefd9a0f778022b7e25">armnn::Convolution2dDescriptor::m_BiasEnabled</a></div><div class="ttdeci">bool m_BiasEnabled</div><div class="ttdoc">Enable/disable bias. </div><div class="ttdef"><b>Definition:</b> <a href="_descriptors_8hpp_source.html#l00438">Descriptors.hpp:438</a></div></div> |
| 180 | <div class="ttc" id="structarmnn_1_1_queue_descriptor_html_a765d2cee4ccce5b9467e0c2b6d25b84a"><div class="ttname"><a href="structarmnn_1_1_queue_descriptor.html#a765d2cee4ccce5b9467e0c2b6d25b84a">armnn::QueueDescriptor::ValidateInputsOutputs</a></div><div class="ttdeci">void ValidateInputsOutputs(const std::string &descName, unsigned int numExpectedIn, unsigned int numExpectedOut) const</div><div class="ttdef"><b>Definition:</b> <a href="_workload_data_8cpp_source.html#l00459">WorkloadData.cpp:459</a></div></div> |
| 181 | <div class="ttc" id="namespacearmnn_html_ad1d5cce2d9e9a5d61c243e5c989112e0"><div class="ttname"><a href="namespacearmnn.html#ad1d5cce2d9e9a5d61c243e5c989112e0">armnn::DataLayout</a></div><div class="ttdeci">DataLayout</div><div class="ttdef"><b>Definition:</b> <a href="_types_8hpp_source.html#l00048">Types.hpp:48</a></div></div> |
| 182 | <div class="ttc" id="structarmnn_1_1_convolution2d_descriptor_html_a302b688d88dd73cde0fb1faef6679907"><div class="ttname"><a href="structarmnn_1_1_convolution2d_descriptor.html#a302b688d88dd73cde0fb1faef6679907">armnn::Convolution2dDescriptor::m_DilationY</a></div><div class="ttdeci">uint32_t m_DilationY</div><div class="ttdoc">Dilation along y axis. </div><div class="ttdef"><b>Definition:</b> <a href="_descriptors_8hpp_source.html#l00436">Descriptors.hpp:436</a></div></div> |
| 183 | <div class="ttc" id="structarmnn_1_1_queue_descriptor_html_a6abd491bb99ffe88bd472c1ae5a1ed1a"><div class="ttname"><a href="structarmnn_1_1_queue_descriptor.html#a6abd491bb99ffe88bd472c1ae5a1ed1a">armnn::QueueDescriptor::m_Outputs</a></div><div class="ttdeci">std::vector< ITensorHandle * > m_Outputs</div><div class="ttdef"><b>Definition:</b> <a href="_workload_data_8hpp_source.html#l00031">WorkloadData.hpp:31</a></div></div> |
| 184 | <div class="ttc" id="structarmnn_1_1_queue_descriptor_html_a4b50e46a6810018f3edecfb68b2a76b3"><div class="ttname"><a href="structarmnn_1_1_queue_descriptor.html#a4b50e46a6810018f3edecfb68b2a76b3">armnn::QueueDescriptor::m_Inputs</a></div><div class="ttdeci">std::vector< ITensorHandle * > m_Inputs</div><div class="ttdef"><b>Definition:</b> <a href="_workload_data_8hpp_source.html#l00030">WorkloadData.hpp:30</a></div></div> |
| 185 | <div class="ttc" id="structarmnn_1_1_convolution2d_descriptor_html_aa3c6a77a963a98ccb8ea7b8fd008a8c1"><div class="ttname"><a href="structarmnn_1_1_convolution2d_descriptor.html#aa3c6a77a963a98ccb8ea7b8fd008a8c1">armnn::Convolution2dDescriptor::m_DilationX</a></div><div class="ttdeci">uint32_t m_DilationX</div><div class="ttdoc">Dilation along x axis. </div><div class="ttdef"><b>Definition:</b> <a href="_descriptors_8hpp_source.html#l00434">Descriptors.hpp:434</a></div></div> |
| 186 | </div><!-- fragment --> |
| 187 | </div> |
| 188 | </div> |
| 189 | <h2 class="groupheader">Member Function Documentation</h2> |
| 190 | <a id="ae071e8822437c78baea75c3aef3a263a"></a> |
| 191 | <h2 class="memtitle"><span class="permalink"><a href="#ae071e8822437c78baea75c3aef3a263a">◆ </a></span>Execute()</h2> |
| 192 | |
| 193 | <div class="memitem"> |
| 194 | <div class="memproto"> |
| 195 | <table class="mlabels"> |
| 196 | <tr> |
| 197 | <td class="mlabels-left"> |
| 198 | <table class="memname"> |
| 199 | <tr> |
| 200 | <td class="memname">void Execute </td> |
| 201 | <td>(</td> |
| 202 | <td class="paramname"></td><td>)</td> |
| 203 | <td> const</td> |
| 204 | </tr> |
| 205 | </table> |
| 206 | </td> |
| 207 | <td class="mlabels-right"> |
| 208 | <span class="mlabels"><span class="mlabel">override</span><span class="mlabel">virtual</span></span> </td> |
| 209 | </tr> |
| 210 | </table> |
| 211 | </div><div class="memdoc"> |
| 212 | |
| 213 | <p>Implements <a class="el" href="classarmnn_1_1_i_workload.html#a72ae00e6604850c8798c5e0d825ee7e4">IWorkload</a>.</p> |
| 214 | |
| 215 | <p class="definition">Definition at line <a class="el" href="_cl_convolution2d_workload_8cpp_source.html#l00110">110</a> of file <a class="el" href="_cl_convolution2d_workload_8cpp_source.html">ClConvolution2dWorkload.cpp</a>.</p> |
| 216 | |
| 217 | <p class="reference">References <a class="el" href="_cl_workload_utils_8hpp_source.html#l00020">ARMNN_SCOPED_PROFILING_EVENT_CL</a>, <a class="el" href="_exceptions_8hpp_source.html#l00169">CHECK_LOCATION</a>, and <a class="el" href="_cl_workload_utils_8hpp_source.html#l00131">armnn::RunClFunction()</a>.</p> |
| 218 | <div class="fragment"><div class="line"><a name="l00111"></a><span class="lineno"> 111</span> {</div><div class="line"><a name="l00112"></a><span class="lineno"> 112</span>  <a class="code" href="_cl_workload_utils_8hpp.html#a9166fc90a3ea47a2c9499a810b204daf">ARMNN_SCOPED_PROFILING_EVENT_CL</a>(<span class="stringliteral">"ClConvolution2dWorkload_Execute"</span>);</div><div class="line"><a name="l00113"></a><span class="lineno"> 113</span>  <a class="code" href="namespacearmnn.html#aff5bee79757341daf750c7dd7c123a15">RunClFunction</a>(m_ConvolutionLayer, <a class="code" href="_exceptions_8hpp.html#aa3be76aec4ce713822a5ea1ecbb7bc61">CHECK_LOCATION</a>());</div><div class="line"><a name="l00114"></a><span class="lineno"> 114</span> }</div><div class="ttc" id="namespacearmnn_html_aff5bee79757341daf750c7dd7c123a15"><div class="ttname"><a href="namespacearmnn.html#aff5bee79757341daf750c7dd7c123a15">armnn::RunClFunction</a></div><div class="ttdeci">void RunClFunction(arm_compute::IFunction &function, const CheckLocation &location)</div><div class="ttdef"><b>Definition:</b> <a href="_cl_workload_utils_8hpp_source.html#l00131">ClWorkloadUtils.hpp:131</a></div></div> |
| 219 | <div class="ttc" id="_exceptions_8hpp_html_aa3be76aec4ce713822a5ea1ecbb7bc61"><div class="ttname"><a href="_exceptions_8hpp.html#aa3be76aec4ce713822a5ea1ecbb7bc61">CHECK_LOCATION</a></div><div class="ttdeci">#define CHECK_LOCATION()</div><div class="ttdef"><b>Definition:</b> <a href="_exceptions_8hpp_source.html#l00169">Exceptions.hpp:169</a></div></div> |
| 220 | <div class="ttc" id="_cl_workload_utils_8hpp_html_a9166fc90a3ea47a2c9499a810b204daf"><div class="ttname"><a href="_cl_workload_utils_8hpp.html#a9166fc90a3ea47a2c9499a810b204daf">ARMNN_SCOPED_PROFILING_EVENT_CL</a></div><div class="ttdeci">#define ARMNN_SCOPED_PROFILING_EVENT_CL(name)</div><div class="ttdef"><b>Definition:</b> <a href="_cl_workload_utils_8hpp_source.html#l00020">ClWorkloadUtils.hpp:20</a></div></div> |
| 221 | </div><!-- fragment --> |
| 222 | </div> |
| 223 | </div> |
| 224 | <hr/>The documentation for this class was generated from the following files:<ul> |
| 225 | <li>src/backends/cl/workloads/<a class="el" href="_cl_convolution2d_workload_8hpp_source.html">ClConvolution2dWorkload.hpp</a></li> |
| 226 | <li>src/backends/cl/workloads/<a class="el" href="_cl_convolution2d_workload_8cpp_source.html">ClConvolution2dWorkload.cpp</a></li> |
| 227 | </ul> |
| 228 | </div><!-- contents --> |
| 229 | </div><!-- doc-content --> |
| 230 | <!-- start footer part --> |
| 231 | <div id="nav-path" class="navpath"><!-- id is needed for treeview function! --> |
| 232 | <ul> |
| 233 | <li class="navelem"><a class="el" href="namespacearmnn.html">armnn</a></li><li class="navelem"><a class="el" href="classarmnn_1_1_cl_convolution2d_workload.html">ClConvolution2dWorkload</a></li> |
| 234 | <li class="footer">Generated on Fri Mar 13 2020 16:07:02 for ArmNN by |
| 235 | <a href="http://www.doxygen.org/index.html"> |
| 236 | <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.13 </li> |
| 237 | </ul> |
| 238 | </div> |
| 239 | </body> |
| 240 | </html> |