Nikhil Raj | 1dc83fe | 2024-05-16 09:47:51 +0100 | [diff] [blame^] | 1 | <!-- HTML header for doxygen 1.8.17--> |
| 2 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> |
| 3 | <html xmlns="http://www.w3.org/1999/xhtml"> |
| 4 | <head> |
| 5 | <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> |
| 6 | <meta http-equiv="X-UA-Compatible" content="IE=9"/> |
| 7 | <meta name="generator" content="Doxygen 1.8.17"/> |
| 8 | <meta name="viewport" content="width=device-width, initial-scale=1"/> |
| 9 | <title>Arm NN: src/backends/gpuFsa/layers/GpuFsaDepthwiseConvolution2d.cpp Source File</title> |
| 10 | <link href="tabs.css" rel="stylesheet" type="text/css"/> |
| 11 | <script type="text/javascript" src="jquery.js"></script> |
| 12 | <script type="text/javascript" src="dynsections.js"></script> |
| 13 | <link href="navtree.css" rel="stylesheet" type="text/css"/> |
| 14 | <script type="text/javascript" src="resize.js"></script> |
| 15 | <script type="text/javascript" src="navtreedata.js"></script> |
| 16 | <script type="text/javascript" src="navtree.js"></script> |
| 17 | <link href="search/search.css" rel="stylesheet" type="text/css"/> |
| 18 | <script type="text/javascript" src="search/searchdata.js"></script> |
| 19 | <script type="text/javascript" src="search/search.js"></script> |
| 20 | <script type="text/x-mathjax-config"> |
| 21 | MathJax.Hub.Config({ |
| 22 | extensions: ["tex2jax.js"], |
| 23 | jax: ["input/TeX","output/HTML-CSS"], |
| 24 | }); |
| 25 | </script> |
| 26 | <script type="text/javascript" async="async" src="http://cdn.mathjax.org/mathjax/latest/MathJax.js"></script> |
| 27 | <link href="doxygen.css" rel="stylesheet" type="text/css" /> |
| 28 | <link href="customdoxygen.css" rel="stylesheet" type="text/css"/> |
| 29 | </head> |
| 30 | <body> |
| 31 | <div id="top"><!-- do not remove this div, it is closed by doxygen! --> |
| 32 | <div id="titlearea"> |
| 33 | <table cellspacing="0" cellpadding="0"> |
| 34 | <tbody> |
| 35 | <tr style="height: 56px;"> |
| 36 | <img alt="ArmNN" src="Arm_NN_horizontal_blue.png" style="max-width: 15rem; margin-top: .5rem; margin-left 13px"/> |
| 37 | <td id="projectalign" style="padding-left: 0.9em;"> |
| 38 | <div id="projectname"> |
| 39 |  <span id="projectnumber">24.05</span> |
| 40 | </div> |
| 41 | </td> |
| 42 | </tr> |
| 43 | </tbody> |
| 44 | </table> |
| 45 | </div> |
| 46 | <!-- end header part --> |
| 47 | <!-- Generated by Doxygen 1.8.17 --> |
| 48 | <script type="text/javascript"> |
| 49 | /* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */ |
| 50 | var searchBox = new SearchBox("searchBox", "search",false,'Search'); |
| 51 | /* @license-end */ |
| 52 | </script> |
| 53 | <script type="text/javascript" src="menudata.js"></script> |
| 54 | <script type="text/javascript" src="menu.js"></script> |
| 55 | <script type="text/javascript"> |
| 56 | /* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */ |
| 57 | $(function() { |
| 58 | initMenu('',true,false,'search.php','Search'); |
| 59 | $(document).ready(function() { init_search(); }); |
| 60 | }); |
| 61 | /* @license-end */</script> |
| 62 | <div id="main-nav"></div> |
| 63 | </div><!-- top --> |
| 64 | <div id="side-nav" class="ui-resizable side-nav-resizable"> |
| 65 | <div id="nav-tree"> |
| 66 | <div id="nav-tree-contents"> |
| 67 | <div id="nav-sync" class="sync"></div> |
| 68 | </div> |
| 69 | </div> |
| 70 | <div id="splitbar" style="-moz-user-select:none;" |
| 71 | class="ui-resizable-handle"> |
| 72 | </div> |
| 73 | </div> |
| 74 | <script type="text/javascript"> |
| 75 | /* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */ |
| 76 | $(document).ready(function(){initNavTree('_gpu_fsa_depthwise_convolution2d_8cpp_source.html',''); initResizable(); }); |
| 77 | /* @license-end */ |
| 78 | </script> |
| 79 | <div id="doc-content"> |
| 80 | <!-- window showing the filter options --> |
| 81 | <div id="MSearchSelectWindow" |
| 82 | onmouseover="return searchBox.OnSearchSelectShow()" |
| 83 | onmouseout="return searchBox.OnSearchSelectHide()" |
| 84 | onkeydown="return searchBox.OnSearchSelectKey(event)"> |
| 85 | </div> |
| 86 | |
| 87 | <!-- iframe showing the search results (closed by default) --> |
| 88 | <div id="MSearchResultsWindow"> |
| 89 | <iframe src="javascript:void(0)" frameborder="0" |
| 90 | name="MSearchResults" id="MSearchResults"> |
| 91 | </iframe> |
| 92 | </div> |
| 93 | |
| 94 | <div class="header"> |
| 95 | <div class="headertitle"> |
| 96 | <div class="title">GpuFsaDepthwiseConvolution2d.cpp</div> </div> |
| 97 | </div><!--header--> |
| 98 | <div class="contents"> |
| 99 | <a href="_gpu_fsa_depthwise_convolution2d_8cpp.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno"> 1</span> <span class="comment">//</span></div> |
| 100 | <div class="line"><a name="l00002"></a><span class="lineno"> 2</span> <span class="comment">// Copyright © 2024 Arm Ltd and Contributors. All rights reserved.</span></div> |
| 101 | <div class="line"><a name="l00003"></a><span class="lineno"> 3</span> <span class="comment">// SPDX-License-Identifier: MIT</span></div> |
| 102 | <div class="line"><a name="l00004"></a><span class="lineno"> 4</span> <span class="comment">//</span></div> |
| 103 | <div class="line"><a name="l00005"></a><span class="lineno"> 5</span>  </div> |
| 104 | <div class="line"><a name="l00006"></a><span class="lineno"> 6</span> <span class="preprocessor">#include "<a class="code" href="_gpu_fsa_depthwise_convolution2d_8hpp.html">GpuFsaDepthwiseConvolution2d.hpp</a>"</span></div> |
| 105 | <div class="line"><a name="l00007"></a><span class="lineno"> 7</span> <span class="preprocessor">#include "<a class="code" href="_utils_gpu_fsa_8hpp.html">UtilsGpuFsa.hpp</a>"</span></div> |
| 106 | <div class="line"><a name="l00008"></a><span class="lineno"> 8</span>  </div> |
| 107 | <div class="line"><a name="l00009"></a><span class="lineno"> 9</span> <span class="preprocessor">#include <<a class="code" href="_workload_utils_8hpp.html">backendsCommon/WorkloadUtils.hpp</a>></span></div> |
| 108 | <div class="line"><a name="l00010"></a><span class="lineno"> 10</span>  </div> |
| 109 | <div class="line"><a name="l00011"></a><span class="lineno"> 11</span> <span class="preprocessor">#include <<a class="code" href="_arm_compute_tensor_utils_8hpp.html">aclCommon/ArmComputeTensorUtils.hpp</a>></span></div> |
| 110 | <div class="line"><a name="l00012"></a><span class="lineno"> 12</span>  </div> |
| 111 | <div class="line"><a name="l00013"></a><span class="lineno"> 13</span> <span class="preprocessor">#include <arm_compute/dynamic_fusion/sketch/gpu/GpuWorkloadContext.h></span></div> |
| 112 | <div class="line"><a name="l00014"></a><span class="lineno"> 14</span> <span class="preprocessor">#include <arm_compute/dynamic_fusion/sketch/gpu/GpuWorkloadSketch.h></span></div> |
| 113 | <div class="line"><a name="l00015"></a><span class="lineno"> 15</span> <span class="preprocessor">#include <arm_compute/dynamic_fusion/sketch/gpu/operators/GpuDepthwiseConv2d.h></span></div> |
| 114 | <div class="line"><a name="l00016"></a><span class="lineno"> 16</span> <span class="preprocessor">#include <arm_compute/dynamic_fusion/sketch/gpu/operators/GpuOutput.h></span></div> |
| 115 | <div class="line"><a name="l00017"></a><span class="lineno"> 17</span>  </div> |
| 116 | <div class="line"><a name="l00018"></a><span class="lineno"> 18</span> <span class="preprocessor">#include <vector></span></div> |
| 117 | <div class="line"><a name="l00019"></a><span class="lineno"> 19</span>  </div> |
| 118 | <div class="line"><a name="l00020"></a><span class="lineno"> 20</span> <span class="keyword">using namespace </span>arm_compute::experimental::dynamic_fusion;</div> |
| 119 | <div class="line"><a name="l00021"></a><span class="lineno"> 21</span> <span class="keyword">using namespace </span>armnn::armcomputetensorutils;</div> |
| 120 | <div class="line"><a name="l00022"></a><span class="lineno"> 22</span>  </div> |
| 121 | <div class="line"><a name="l00023"></a><span class="lineno"> 23</span> <span class="keyword">namespace </span><a class="code" href="namespacearmnn.html">armnn</a></div> |
| 122 | <div class="line"><a name="l00024"></a><span class="lineno"> 24</span> {</div> |
| 123 | <div class="line"><a name="l00025"></a><span class="lineno"> 25</span>  </div> |
| 124 | <div class="line"><a name="l00026"></a><span class="lineno"><a class="line" href="namespacearmnn.html#af2016aed3575b7302e79c72830c23025"> 26</a></span> <a class="code" href="namespacearmnn.html#a67a0db04d321a74b7e7fcfd3f1a3f70b">arm_compute::Status</a> <a class="code" href="namespacearmnn.html#af2016aed3575b7302e79c72830c23025">GpuFsaDepthwiseConvolution2dValidate</a>(<span class="keyword">const</span> <a class="code" href="classarmnn_1_1_tensor_info.html">TensorInfo</a>& input,</div> |
| 125 | <div class="line"><a name="l00027"></a><span class="lineno"> 27</span>  <span class="keyword">const</span> <a class="code" href="structarmnn_1_1_depthwise_convolution2d_descriptor.html">DepthwiseConvolution2dDescriptor</a>& descriptor,</div> |
| 126 | <div class="line"><a name="l00028"></a><span class="lineno"> 28</span>  <span class="keyword">const</span> <a class="code" href="classarmnn_1_1_tensor_info.html">TensorInfo</a>& weights,</div> |
| 127 | <div class="line"><a name="l00029"></a><span class="lineno"> 29</span>  <span class="keyword">const</span> <a class="code" href="classarmnn_1_1_optional.html">Optional<TensorInfo></a>& biases)</div> |
| 128 | <div class="line"><a name="l00030"></a><span class="lineno"> 30</span> {</div> |
| 129 | <div class="line"><a name="l00031"></a><span class="lineno"> 31</span>  <span class="comment">// Create a new workload sketch, for validation purposes</span></div> |
| 130 | <div class="line"><a name="l00032"></a><span class="lineno"> 32</span>  <span class="keyword">auto</span> compileCtx = arm_compute::CLKernelLibrary::get().get_compile_context();</div> |
| 131 | <div class="line"><a name="l00033"></a><span class="lineno"> 33</span>  <span class="keyword">auto</span> workloadContext = GpuWorkloadContext(&compileCtx);</div> |
| 132 | <div class="line"><a name="l00034"></a><span class="lineno"> 34</span>  GpuWorkloadSketch sketch{ &workloadContext };</div> |
| 133 | <div class="line"><a name="l00035"></a><span class="lineno"> 35</span>  </div> |
| 134 | <div class="line"><a name="l00036"></a><span class="lineno"> 36</span>  <span class="comment">// Build and create tensor infos using the sketch</span></div> |
| 135 | <div class="line"><a name="l00037"></a><span class="lineno"> 37</span>  <span class="keyword">const</span> arm_compute::TensorInfo aclInputInfo = BuildArmComputeTensorInfo(input, descriptor.<a class="code" href="structarmnn_1_1_depthwise_convolution2d_descriptor.html#a6089e1ca91914015777ea780a513131a">m_DataLayout</a>);</div> |
| 136 | <div class="line"><a name="l00038"></a><span class="lineno"> 38</span>  </div> |
| 137 | <div class="line"><a name="l00039"></a><span class="lineno"> 39</span>  <span class="comment">// ArmNN format for weights for depthwise is [1, H, W, C] independently of the input/output layout</span></div> |
| 138 | <div class="line"><a name="l00040"></a><span class="lineno"> 40</span>  <span class="comment">//</span></div> |
| 139 | <div class="line"><a name="l00041"></a><span class="lineno"> 41</span>  <span class="comment">// ACL format for weights for depthwise is:</span></div> |
| 140 | <div class="line"><a name="l00042"></a><span class="lineno"> 42</span>  <span class="comment">// - [1, H, W, C] for [N, H, W, C] input/output layout (matches with ArmNN)</span></div> |
| 141 | <div class="line"><a name="l00043"></a><span class="lineno"> 43</span>  <span class="comment">// - [1, C, H, W] for [N, C, H, W] input/output layout</span></div> |
| 142 | <div class="line"><a name="l00044"></a><span class="lineno"> 44</span>  <span class="comment">//</span></div> |
| 143 | <div class="line"><a name="l00045"></a><span class="lineno"> 45</span>  <span class="comment">// Therefore ArmNN weights have to be permuted when input/output layout is [N, C, H, W] to pass them to ACL.</span></div> |
| 144 | <div class="line"><a name="l00046"></a><span class="lineno"> 46</span>  <span class="comment">// The PermuteDepthwiseConv2dWeights backend optimization takes care of this, but it has not been performed yet,</span></div> |
| 145 | <div class="line"><a name="l00047"></a><span class="lineno"> 47</span>  <span class="comment">// so we do the permute here for the TensorInfo weights.</span></div> |
| 146 | <div class="line"><a name="l00048"></a><span class="lineno"> 48</span>  <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> aclDepthMultiplier;</div> |
| 147 | <div class="line"><a name="l00049"></a><span class="lineno"> 49</span>  <a class="code" href="classarmnn_1_1_tensor_info.html">TensorInfo</a> weightsPermuted;</div> |
| 148 | <div class="line"><a name="l00050"></a><span class="lineno"> 50</span>  std::tie(weightsPermuted, aclDepthMultiplier) = <a class="code" href="namespacearmnn.html#ac4aa9e41515b354234645f115c49de32">Convert1HWOTensorInfoToAcl</a>(weights, input,descriptor.<a class="code" href="structarmnn_1_1_depthwise_convolution2d_descriptor.html#a6089e1ca91914015777ea780a513131a">m_DataLayout</a>);</div> |
| 149 | <div class="line"><a name="l00051"></a><span class="lineno"> 51</span>  <span class="keyword">auto</span> weightsShape = weightsPermuted.<a class="code" href="classarmnn_1_1_tensor_info.html#a8b5d0f8a24e9d9238f412260a552acf8">GetShape</a>();</div> |
| 150 | <div class="line"><a name="l00052"></a><span class="lineno"> 52</span>  weightsPermuted.<a class="code" href="classarmnn_1_1_tensor_info.html#abe8889e8150beef5fd204b2d87b49298">SetShape</a>({weightsShape[1], weightsShape[2], weightsShape[3]});</div> |
| 151 | <div class="line"><a name="l00053"></a><span class="lineno"> 53</span>  </div> |
| 152 | <div class="line"><a name="l00054"></a><span class="lineno"> 54</span>  arm_compute::TensorInfo aclWeightsInfo = BuildArmComputeTensorInfo(weightsPermuted, descriptor.<a class="code" href="structarmnn_1_1_depthwise_convolution2d_descriptor.html#a6089e1ca91914015777ea780a513131a">m_DataLayout</a>);</div> |
| 153 | <div class="line"><a name="l00055"></a><span class="lineno"> 55</span>  aclWeightsInfo.set_are_values_constant(weights.<a class="code" href="classarmnn_1_1_tensor_info.html#a945263e85c27f3216a8323cfc16d8919">IsConstant</a>());</div> |
| 154 | <div class="line"><a name="l00056"></a><span class="lineno"> 56</span>  </div> |
| 155 | <div class="line"><a name="l00057"></a><span class="lineno"> 57</span>  <span class="keyword">auto</span> inputInfo = workloadContext.create_tensor_info(aclInputInfo);</div> |
| 156 | <div class="line"><a name="l00058"></a><span class="lineno"> 58</span>  <span class="keyword">auto</span> weightInfo = workloadContext.create_tensor_info(aclWeightsInfo);</div> |
| 157 | <div class="line"><a name="l00059"></a><span class="lineno"> 59</span>  </div> |
| 158 | <div class="line"><a name="l00060"></a><span class="lineno"> 60</span>  <span class="comment">// Only create the bias tensor info if enabled, otherwise pass nullptr to validate_op</span></div> |
| 159 | <div class="line"><a name="l00061"></a><span class="lineno"> 61</span>  arm_compute::TensorInfo aclBiasInfo;</div> |
| 160 | <div class="line"><a name="l00062"></a><span class="lineno"> 62</span>  arm_compute::ITensorInfo* biasSketchInfoPtr = <span class="keyword">nullptr</span>;</div> |
| 161 | <div class="line"><a name="l00063"></a><span class="lineno"> 63</span>  </div> |
| 162 | <div class="line"><a name="l00064"></a><span class="lineno"> 64</span>  <span class="keywordflow">if</span> (descriptor.<a class="code" href="structarmnn_1_1_depthwise_convolution2d_descriptor.html#aea202e14d8874cefd9a0f778022b7e25">m_BiasEnabled</a>)</div> |
| 163 | <div class="line"><a name="l00065"></a><span class="lineno"> 65</span>  {</div> |
| 164 | <div class="line"><a name="l00066"></a><span class="lineno"> 66</span>  <span class="keywordflow">if</span>(!biases.<a class="code" href="classarmnn_1_1_optional_base.html#a86b749ce2c4bc627fa8a1fcfaf0e314f">has_value</a>())</div> |
| 165 | <div class="line"><a name="l00067"></a><span class="lineno"> 67</span>  {</div> |
| 166 | <div class="line"><a name="l00068"></a><span class="lineno"> 68</span>  <span class="keywordflow">throw</span> <a class="code" href="classarmnn_1_1_invalid_argument_exception.html">InvalidArgumentException</a>(</div> |
| 167 | <div class="line"><a name="l00069"></a><span class="lineno"> 69</span>  <span class="stringliteral">"GpuFsaDepthwiseConvolution2dValidate: No biases set when biases are enabled"</span>);</div> |
| 168 | <div class="line"><a name="l00070"></a><span class="lineno"> 70</span>  }</div> |
| 169 | <div class="line"><a name="l00071"></a><span class="lineno"> 71</span>  aclBiasInfo = BuildArmComputeTensorInfo(biases.<a class="code" href="classarmnn_1_1_optional_reference_switch.html#a77c7d528ac063d870b8c8426ec81c1c3">value</a>(), descriptor.<a class="code" href="structarmnn_1_1_depthwise_convolution2d_descriptor.html#a6089e1ca91914015777ea780a513131a">m_DataLayout</a>);</div> |
| 170 | <div class="line"><a name="l00072"></a><span class="lineno"> 72</span>  aclBiasInfo.set_are_values_constant(biases.<a class="code" href="classarmnn_1_1_optional_reference_switch.html#a77c7d528ac063d870b8c8426ec81c1c3">value</a>().IsConstant());</div> |
| 171 | <div class="line"><a name="l00073"></a><span class="lineno"> 73</span>  </div> |
| 172 | <div class="line"><a name="l00074"></a><span class="lineno"> 74</span>  biasSketchInfoPtr = workloadContext.create_tensor_info(aclBiasInfo);</div> |
| 173 | <div class="line"><a name="l00075"></a><span class="lineno"> 75</span>  }</div> |
| 174 | <div class="line"><a name="l00076"></a><span class="lineno"> 76</span>  </div> |
| 175 | <div class="line"><a name="l00077"></a><span class="lineno"> 77</span>  DepthwiseConv2dAttributes depthwiseConv2dAttributes = <a class="code" href="_utils_gpu_fsa_8cpp.html#a54d1f7200479dad24822853a1e1da500">CreateDWConv2dAttributes</a>(descriptor, aclDepthMultiplier);</div> |
| 176 | <div class="line"><a name="l00078"></a><span class="lineno"> 78</span>  </div> |
| 177 | <div class="line"><a name="l00079"></a><span class="lineno"> 79</span>  <span class="comment">// Validate operator, check status and update reasonIfUnsupported</span></div> |
| 178 | <div class="line"><a name="l00080"></a><span class="lineno"> 80</span>  <a class="code" href="namespacearmnn.html#a67a0db04d321a74b7e7fcfd3f1a3f70b">arm_compute::Status</a> aclStatus = GpuDepthwiseConv2d::validate_op(sketch,</div> |
| 179 | <div class="line"><a name="l00081"></a><span class="lineno"> 81</span>  inputInfo,</div> |
| 180 | <div class="line"><a name="l00082"></a><span class="lineno"> 82</span>  weightInfo,</div> |
| 181 | <div class="line"><a name="l00083"></a><span class="lineno"> 83</span>  biasSketchInfoPtr,</div> |
| 182 | <div class="line"><a name="l00084"></a><span class="lineno"> 84</span>  depthwiseConv2dAttributes);</div> |
| 183 | <div class="line"><a name="l00085"></a><span class="lineno"> 85</span>  </div> |
| 184 | <div class="line"><a name="l00086"></a><span class="lineno"> 86</span>  <span class="keywordflow">return</span> aclStatus;</div> |
| 185 | <div class="line"><a name="l00087"></a><span class="lineno"> 87</span> }</div> |
| 186 | <div class="line"><a name="l00088"></a><span class="lineno"> 88</span>  </div> |
| 187 | <div class="line"><a name="l00089"></a><span class="lineno"><a class="line" href="namespacearmnn.html#a5bdf4240a1fbda27b5fc84baba721781"> 89</a></span> <span class="keywordtype">void</span> <a class="code" href="namespacearmnn.html#a5bdf4240a1fbda27b5fc84baba721781">GpuFsaDepthwiseConvolution2dCreateOp</a>(<a class="code" href="structarmnn_1_1_gpu_fsa_pre_compiled_blob.html">GpuFsaPreCompiledBlob</a>* blob,</div> |
| 188 | <div class="line"><a name="l00090"></a><span class="lineno"> 90</span>  <span class="keyword">const</span> <a class="code" href="classarmnn_1_1_tensor_info.html">TensorInfo</a>& input,</div> |
| 189 | <div class="line"><a name="l00091"></a><span class="lineno"> 91</span>  <span class="keyword">const</span> <a class="code" href="structarmnn_1_1_depthwise_convolution2d_descriptor.html">DepthwiseConvolution2dDescriptor</a>& descriptor,</div> |
| 190 | <div class="line"><a name="l00092"></a><span class="lineno"> 92</span>  <span class="keyword">const</span> <a class="code" href="classarmnn_1_1_tensor_info.html">TensorInfo</a>& weights,</div> |
| 191 | <div class="line"><a name="l00093"></a><span class="lineno"> 93</span>  <span class="keyword">const</span> <a class="code" href="classarmnn_1_1_optional.html">Optional<TensorInfo></a>& biases)</div> |
| 192 | <div class="line"><a name="l00094"></a><span class="lineno"> 94</span> {</div> |
| 193 | <div class="line"><a name="l00095"></a><span class="lineno"> 95</span> <span class="comment">/*</span></div> |
| 194 | <div class="line"><a name="l00096"></a><span class="lineno"> 96</span> <span class="comment">* Creating an Op for the GpuFsa backend requires us to create and maintain quite a bit of data, which is then stored</span></div> |
| 195 | <div class="line"><a name="l00097"></a><span class="lineno"> 97</span> <span class="comment">* in a GpuFsaPreCompiledBlob for execution later. Specifically we need:</span></div> |
| 196 | <div class="line"><a name="l00098"></a><span class="lineno"> 98</span> <span class="comment">* GpuWorkloadContext, this contains the TensorInfos and is unique to the Graph being executed</span></div> |
| 197 | <div class="line"><a name="l00099"></a><span class="lineno"> 99</span> <span class="comment">* Sketch, this is similar to a subgraph and can contain one or more operations. Multiple ops can be "fused" together</span></div> |
| 198 | <div class="line"><a name="l00100"></a><span class="lineno"> 100</span> <span class="comment">* using a single sketch.</span></div> |
| 199 | <div class="line"><a name="l00101"></a><span class="lineno"> 101</span> <span class="comment">* The inputTensorinfos / outputTensorInfos, these are pointers to the TensorInfos used when creating the sketch.</span></div> |
| 200 | <div class="line"><a name="l00102"></a><span class="lineno"> 102</span> <span class="comment">* They refer to the TensorInfos stored within the GpuWorkloadContext and are needed when executing the sketch</span></div> |
| 201 | <div class="line"><a name="l00103"></a><span class="lineno"> 103</span> <span class="comment">* as the TensorInfos used when creating the Tensors must match those used to create the Sketch. Otherwise the runtime</span></div> |
| 202 | <div class="line"><a name="l00104"></a><span class="lineno"> 104</span> <span class="comment">* doesn't know which Tensors to use.</span></div> |
| 203 | <div class="line"><a name="l00105"></a><span class="lineno"> 105</span> <span class="comment">*/</span></div> |
| 204 | <div class="line"><a name="l00106"></a><span class="lineno"> 106</span>  GpuWorkloadSketch* sketch = blob-><a class="code" href="structarmnn_1_1_gpu_fsa_pre_compiled_blob.html#a14f92a9f65e32c3da896e7b1d45abd02">sketch</a>.get();</div> |
| 205 | <div class="line"><a name="l00107"></a><span class="lineno"> 107</span>  GpuWorkloadContext* workloadContext = blob-><a class="code" href="structarmnn_1_1_gpu_fsa_pre_compiled_blob.html#a255c9012137b149ffb46d83c23f2df43">workloadContext</a>.get();</div> |
| 206 | <div class="line"><a name="l00108"></a><span class="lineno"> 108</span>  std::vector<arm_compute::ITensorInfo*> inputTensorInfos = {};</div> |
| 207 | <div class="line"><a name="l00109"></a><span class="lineno"> 109</span>  std::vector<arm_compute::ITensorInfo*> outputTensorInfos = {};</div> |
| 208 | <div class="line"><a name="l00110"></a><span class="lineno"> 110</span>  </div> |
| 209 | <div class="line"><a name="l00111"></a><span class="lineno"> 111</span>  <span class="comment">// Build and create tensor infos using the sketch</span></div> |
| 210 | <div class="line"><a name="l00112"></a><span class="lineno"> 112</span>  <span class="keyword">const</span> arm_compute::TensorInfo aclInputInfo = BuildArmComputeTensorInfo(input, descriptor.<a class="code" href="structarmnn_1_1_depthwise_convolution2d_descriptor.html#a6089e1ca91914015777ea780a513131a">m_DataLayout</a>);</div> |
| 211 | <div class="line"><a name="l00113"></a><span class="lineno"> 113</span>  </div> |
| 212 | <div class="line"><a name="l00114"></a><span class="lineno"> 114</span>  <span class="comment">// ArmNN format for weights for depthwise is [1, H, W, C] independently of the input/output layout</span></div> |
| 213 | <div class="line"><a name="l00115"></a><span class="lineno"> 115</span>  <span class="comment">//</span></div> |
| 214 | <div class="line"><a name="l00116"></a><span class="lineno"> 116</span>  <span class="comment">// ACL format for weights for depthwise is:</span></div> |
| 215 | <div class="line"><a name="l00117"></a><span class="lineno"> 117</span>  <span class="comment">// - [1, H, W, C] for [N, H, W, C] input/output layout (matches with ArmNN)</span></div> |
| 216 | <div class="line"><a name="l00118"></a><span class="lineno"> 118</span>  <span class="comment">// - [1, C, H, W] for [N, C, H, W] input/output layout</span></div> |
| 217 | <div class="line"><a name="l00119"></a><span class="lineno"> 119</span>  <span class="comment">//</span></div> |
| 218 | <div class="line"><a name="l00120"></a><span class="lineno"> 120</span>  <span class="comment">// Therefore ArmNN weights have to be permuted when input/output layout is [N, C, H, W] to pass them to ACL.</span></div> |
| 219 | <div class="line"><a name="l00121"></a><span class="lineno"> 121</span>  <span class="comment">// The PermuteDepthwiseConv2dWeights backend optimization takes care of this, but it has not been performed yet,</span></div> |
| 220 | <div class="line"><a name="l00122"></a><span class="lineno"> 122</span>  <span class="comment">// so we do the permute here for the TensorInfo weights.</span></div> |
| 221 | <div class="line"><a name="l00123"></a><span class="lineno"> 123</span>  <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> aclDepthMultiplier;</div> |
| 222 | <div class="line"><a name="l00124"></a><span class="lineno"> 124</span>  <a class="code" href="classarmnn_1_1_tensor_info.html">TensorInfo</a> weightsPermuted;</div> |
| 223 | <div class="line"><a name="l00125"></a><span class="lineno"> 125</span>  std::tie(weightsPermuted, aclDepthMultiplier) = <a class="code" href="namespacearmnn.html#ac4aa9e41515b354234645f115c49de32">Convert1HWOTensorInfoToAcl</a>(weights, input,descriptor.<a class="code" href="structarmnn_1_1_depthwise_convolution2d_descriptor.html#a6089e1ca91914015777ea780a513131a">m_DataLayout</a>);</div> |
| 224 | <div class="line"><a name="l00126"></a><span class="lineno"> 126</span>  <span class="keyword">auto</span> weightsShape = weightsPermuted.<a class="code" href="classarmnn_1_1_tensor_info.html#a8b5d0f8a24e9d9238f412260a552acf8">GetShape</a>();</div> |
| 225 | <div class="line"><a name="l00127"></a><span class="lineno"> 127</span>  weightsPermuted.<a class="code" href="classarmnn_1_1_tensor_info.html#abe8889e8150beef5fd204b2d87b49298">SetShape</a>({weightsShape[1], weightsShape[2], weightsShape[3]});</div> |
| 226 | <div class="line"><a name="l00128"></a><span class="lineno"> 128</span>  </div> |
| 227 | <div class="line"><a name="l00129"></a><span class="lineno"> 129</span>  arm_compute::TensorInfo aclWeightsInfo = BuildArmComputeTensorInfo(weightsPermuted, descriptor.<a class="code" href="structarmnn_1_1_depthwise_convolution2d_descriptor.html#a6089e1ca91914015777ea780a513131a">m_DataLayout</a>);</div> |
| 228 | <div class="line"><a name="l00130"></a><span class="lineno"> 130</span>  aclWeightsInfo.set_are_values_constant(weights.<a class="code" href="classarmnn_1_1_tensor_info.html#a945263e85c27f3216a8323cfc16d8919">IsConstant</a>());</div> |
| 229 | <div class="line"><a name="l00131"></a><span class="lineno"> 131</span>  </div> |
| 230 | <div class="line"><a name="l00132"></a><span class="lineno"> 132</span>  inputTensorInfos.emplace_back(workloadContext->create_tensor_info(aclInputInfo));</div> |
| 231 | <div class="line"><a name="l00133"></a><span class="lineno"> 133</span>  inputTensorInfos.emplace_back(workloadContext->create_tensor_info(aclWeightsInfo));</div> |
| 232 | <div class="line"><a name="l00134"></a><span class="lineno"> 134</span>  </div> |
| 233 | <div class="line"><a name="l00135"></a><span class="lineno"> 135</span>  <span class="comment">// Only create the bias tensor info if enabled, otherwise pass nullptr to validate_op</span></div> |
| 234 | <div class="line"><a name="l00136"></a><span class="lineno"> 136</span>  arm_compute::TensorInfo aclBiasInfo;</div> |
| 235 | <div class="line"><a name="l00137"></a><span class="lineno"> 137</span>  arm_compute::ITensorInfo* biasSketchInfoPtr = <span class="keyword">nullptr</span>;</div> |
| 236 | <div class="line"><a name="l00138"></a><span class="lineno"> 138</span>  </div> |
| 237 | <div class="line"><a name="l00139"></a><span class="lineno"> 139</span>  <span class="keywordflow">if</span> (descriptor.<a class="code" href="structarmnn_1_1_depthwise_convolution2d_descriptor.html#aea202e14d8874cefd9a0f778022b7e25">m_BiasEnabled</a>)</div> |
| 238 | <div class="line"><a name="l00140"></a><span class="lineno"> 140</span>  {</div> |
| 239 | <div class="line"><a name="l00141"></a><span class="lineno"> 141</span>  <span class="keywordflow">if</span>(!biases.<a class="code" href="classarmnn_1_1_optional_base.html#a86b749ce2c4bc627fa8a1fcfaf0e314f">has_value</a>())</div> |
| 240 | <div class="line"><a name="l00142"></a><span class="lineno"> 142</span>  {</div> |
| 241 | <div class="line"><a name="l00143"></a><span class="lineno"> 143</span>  <span class="keywordflow">throw</span> <a class="code" href="classarmnn_1_1_invalid_argument_exception.html">InvalidArgumentException</a>(<span class="stringliteral">"GpuFsaConvolution2dValidate: No biases set when biases are enabled"</span>);</div> |
| 242 | <div class="line"><a name="l00144"></a><span class="lineno"> 144</span>  }</div> |
| 243 | <div class="line"><a name="l00145"></a><span class="lineno"> 145</span>  aclBiasInfo = BuildArmComputeTensorInfo(biases.<a class="code" href="classarmnn_1_1_optional_reference_switch.html#a77c7d528ac063d870b8c8426ec81c1c3">value</a>(), descriptor.<a class="code" href="structarmnn_1_1_depthwise_convolution2d_descriptor.html#a6089e1ca91914015777ea780a513131a">m_DataLayout</a>);</div> |
| 244 | <div class="line"><a name="l00146"></a><span class="lineno"> 146</span>  aclBiasInfo.set_are_values_constant(biases.<a class="code" href="classarmnn_1_1_optional_reference_switch.html#a77c7d528ac063d870b8c8426ec81c1c3">value</a>().IsConstant());</div> |
| 245 | <div class="line"><a name="l00147"></a><span class="lineno"> 147</span>  </div> |
| 246 | <div class="line"><a name="l00148"></a><span class="lineno"> 148</span>  inputTensorInfos.emplace_back(workloadContext->create_tensor_info(aclBiasInfo));</div> |
| 247 | <div class="line"><a name="l00149"></a><span class="lineno"> 149</span>  biasSketchInfoPtr = inputTensorInfos[2];</div> |
| 248 | <div class="line"><a name="l00150"></a><span class="lineno"> 150</span>  }</div> |
| 249 | <div class="line"><a name="l00151"></a><span class="lineno"> 151</span>  </div> |
| 250 | <div class="line"><a name="l00152"></a><span class="lineno"> 152</span>  DepthwiseConv2dAttributes depthwiseConv2dAttributes = <a class="code" href="_utils_gpu_fsa_8cpp.html#a54d1f7200479dad24822853a1e1da500">CreateDWConv2dAttributes</a>(descriptor, aclDepthMultiplier);</div> |
| 251 | <div class="line"><a name="l00153"></a><span class="lineno"> 153</span>  </div> |
| 252 | <div class="line"><a name="l00154"></a><span class="lineno"> 154</span>  <span class="comment">// Validate operator, check status and update reasonIfUnsupported</span></div> |
| 253 | <div class="line"><a name="l00155"></a><span class="lineno"> 155</span>  <a class="code" href="namespacearmnn.html#a67a0db04d321a74b7e7fcfd3f1a3f70b">arm_compute::Status</a> aclStatus = GpuDepthwiseConv2d::validate_op(*sketch,</div> |
| 254 | <div class="line"><a name="l00156"></a><span class="lineno"> 156</span>  inputTensorInfos[0],</div> |
| 255 | <div class="line"><a name="l00157"></a><span class="lineno"> 157</span>  inputTensorInfos[1],</div> |
| 256 | <div class="line"><a name="l00158"></a><span class="lineno"> 158</span>  biasSketchInfoPtr,</div> |
| 257 | <div class="line"><a name="l00159"></a><span class="lineno"> 159</span>  depthwiseConv2dAttributes);</div> |
| 258 | <div class="line"><a name="l00160"></a><span class="lineno"> 160</span>  </div> |
| 259 | <div class="line"><a name="l00161"></a><span class="lineno"> 161</span>  <span class="keyword">const</span> <span class="keywordtype">bool</span> supported = (aclStatus.error_code() == arm_compute::ErrorCode::OK);</div> |
| 260 | <div class="line"><a name="l00162"></a><span class="lineno"> 162</span>  <span class="keywordflow">if</span> (!supported)</div> |
| 261 | <div class="line"><a name="l00163"></a><span class="lineno"> 163</span>  {</div> |
| 262 | <div class="line"><a name="l00164"></a><span class="lineno"> 164</span>  <span class="keywordflow">throw</span> <a class="code" href="classarmnn_1_1_backend_capability_exception.html">BackendCapabilityException</a>(</div> |
| 263 | <div class="line"><a name="l00165"></a><span class="lineno"> 165</span>  <span class="stringliteral">"\"GpuFsa\" backend failed during DepthwiseConvolution2D operation validation"</span>);</div> |
| 264 | <div class="line"><a name="l00166"></a><span class="lineno"> 166</span>  }</div> |
| 265 | <div class="line"><a name="l00167"></a><span class="lineno"> 167</span>  </div> |
| 266 | <div class="line"><a name="l00168"></a><span class="lineno"> 168</span>  <span class="comment">// Create the Op within the Sketch using the TensorInfos we have stored</span></div> |
| 267 | <div class="line"><a name="l00169"></a><span class="lineno"> 169</span>  arm_compute::ITensorInfo* convOutInfo = GpuDepthwiseConv2d::create_op(*sketch,</div> |
| 268 | <div class="line"><a name="l00170"></a><span class="lineno"> 170</span>  inputTensorInfos[0],</div> |
| 269 | <div class="line"><a name="l00171"></a><span class="lineno"> 171</span>  inputTensorInfos[1],</div> |
| 270 | <div class="line"><a name="l00172"></a><span class="lineno"> 172</span>  biasSketchInfoPtr,</div> |
| 271 | <div class="line"><a name="l00173"></a><span class="lineno"> 173</span>  depthwiseConv2dAttributes);</div> |
| 272 | <div class="line"><a name="l00174"></a><span class="lineno"> 174</span>  </div> |
| 273 | <div class="line"><a name="l00175"></a><span class="lineno"> 175</span>  outputTensorInfos.emplace_back(workloadContext->create_tensor_info());</div> |
| 274 | <div class="line"><a name="l00176"></a><span class="lineno"> 176</span>  GpuOutput::create_op(*sketch, convOutInfo, outputTensorInfos[0]);</div> |
| 275 | <div class="line"><a name="l00177"></a><span class="lineno"> 177</span>  </div> |
| 276 | <div class="line"><a name="l00178"></a><span class="lineno"> 178</span>  <span class="comment">// Store the TensorInfos within the blob as unique_ptrs to be used later</span></div> |
| 277 | <div class="line"><a name="l00179"></a><span class="lineno"> 179</span>  blob-><a class="code" href="structarmnn_1_1_gpu_fsa_pre_compiled_blob.html#a479b90f0b24c427502d94b716117e034">inputTensorInfos</a> = std::make_unique<std::vector<arm_compute::ITensorInfo*>>(inputTensorInfos);</div> |
| 278 | <div class="line"><a name="l00180"></a><span class="lineno"> 180</span>  blob-><a class="code" href="structarmnn_1_1_gpu_fsa_pre_compiled_blob.html#ac49bf679a23aa84f06a6bde3440a4c40">outputTensorInfos</a> = std::make_unique<std::vector<arm_compute::ITensorInfo*>>(outputTensorInfos);</div> |
| 279 | <div class="line"><a name="l00181"></a><span class="lineno"> 181</span> }</div> |
| 280 | <div class="line"><a name="l00182"></a><span class="lineno"> 182</span>  </div> |
| 281 | <div class="line"><a name="l00183"></a><span class="lineno"> 183</span> } <span class="comment">// namespace armnn</span></div> |
| 282 | </div><!-- fragment --></div><!-- contents --> |
| 283 | </div><!-- doc-content --> |
| 284 | <div class="ttc" id="anamespacearmnn_html_ac4aa9e41515b354234645f115c49de32"><div class="ttname"><a href="namespacearmnn.html#ac4aa9e41515b354234645f115c49de32">armnn::Convert1HWOTensorInfoToAcl</a></div><div class="ttdeci">std::tuple< TensorInfo, unsigned int > Convert1HWOTensorInfoToAcl(const TensorInfo &weightInfo, const TensorInfo &inputInfo, const DataLayout dataLayout)</div><div class="ttdoc">Weights for depthwise have a datalayout of [1,H,W,O] = [1,H,W,I*M] This function coverts a TensorInfo...</div><div class="ttdef"><b>Definition:</b> <a href="_workload_utils_8cpp_source.html#l00177">WorkloadUtils.cpp:177</a></div></div> |
| 285 | <div class="ttc" id="aclassarmnn_1_1_optional_html"><div class="ttname"><a href="classarmnn_1_1_optional.html">armnn::Optional</a></div><div class="ttdef"><b>Definition:</b> <a href="_optional_8hpp_source.html#l00270">Optional.hpp:270</a></div></div> |
| 286 | <div class="ttc" id="astructarmnn_1_1_depthwise_convolution2d_descriptor_html_aea202e14d8874cefd9a0f778022b7e25"><div class="ttname"><a href="structarmnn_1_1_depthwise_convolution2d_descriptor.html#aea202e14d8874cefd9a0f778022b7e25">armnn::DepthwiseConvolution2dDescriptor::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#l00708">Descriptors.hpp:708</a></div></div> |
| 287 | <div class="ttc" id="a_workload_utils_8hpp_html"><div class="ttname"><a href="_workload_utils_8hpp.html">WorkloadUtils.hpp</a></div></div> |
| 288 | <div class="ttc" id="astructarmnn_1_1_depthwise_convolution2d_descriptor_html_a6089e1ca91914015777ea780a513131a"><div class="ttname"><a href="structarmnn_1_1_depthwise_convolution2d_descriptor.html#a6089e1ca91914015777ea780a513131a">armnn::DepthwiseConvolution2dDescriptor::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#l00710">Descriptors.hpp:710</a></div></div> |
| 289 | <div class="ttc" id="aclassarmnn_1_1_tensor_info_html"><div class="ttname"><a href="classarmnn_1_1_tensor_info.html">armnn::TensorInfo</a></div><div class="ttdef"><b>Definition:</b> <a href="_tensor_8hpp_source.html#l00152">Tensor.hpp:152</a></div></div> |
| 290 | <div class="ttc" id="aclassarmnn_1_1_tensor_info_html_a945263e85c27f3216a8323cfc16d8919"><div class="ttname"><a href="classarmnn_1_1_tensor_info.html#a945263e85c27f3216a8323cfc16d8919">armnn::TensorInfo::IsConstant</a></div><div class="ttdeci">bool IsConstant() const</div><div class="ttdef"><b>Definition:</b> <a href="_tensor_8cpp_source.html#l00513">Tensor.cpp:513</a></div></div> |
| 291 | <div class="ttc" id="astructarmnn_1_1_gpu_fsa_pre_compiled_blob_html_a479b90f0b24c427502d94b716117e034"><div class="ttname"><a href="structarmnn_1_1_gpu_fsa_pre_compiled_blob.html#a479b90f0b24c427502d94b716117e034">armnn::GpuFsaPreCompiledBlob::inputTensorInfos</a></div><div class="ttdeci">std::unique_ptr< std::vector< arm_compute::ITensorInfo * > > inputTensorInfos</div><div class="ttdef"><b>Definition:</b> <a href="_gpu_fsa_backend_8hpp_source.html#l00037">GpuFsaBackend.hpp:37</a></div></div> |
| 292 | <div class="ttc" id="a_utils_gpu_fsa_8cpp_html_a54d1f7200479dad24822853a1e1da500"><div class="ttname"><a href="_utils_gpu_fsa_8cpp.html#a54d1f7200479dad24822853a1e1da500">CreateDWConv2dAttributes</a></div><div class="ttdeci">arm_compute::experimental::dynamic_fusion::DepthwiseConv2dAttributes CreateDWConv2dAttributes(const DepthwiseConvolution2dDescriptor &descriptor, const unsigned int aclDepthMultiplier)</div><div class="ttdoc">Utility function used to setup an arm_compute::DepthwiseConv2dAttributes object from given descriptor...</div><div class="ttdef"><b>Definition:</b> <a href="_utils_gpu_fsa_8cpp_source.html#l00029">UtilsGpuFsa.cpp:29</a></div></div> |
| 293 | <div class="ttc" id="astructarmnn_1_1_gpu_fsa_pre_compiled_blob_html_a14f92a9f65e32c3da896e7b1d45abd02"><div class="ttname"><a href="structarmnn_1_1_gpu_fsa_pre_compiled_blob.html#a14f92a9f65e32c3da896e7b1d45abd02">armnn::GpuFsaPreCompiledBlob::sketch</a></div><div class="ttdeci">std::unique_ptr< arm_compute::experimental::dynamic_fusion::GpuWorkloadSketch > sketch</div><div class="ttdef"><b>Definition:</b> <a href="_gpu_fsa_backend_8hpp_source.html#l00034">GpuFsaBackend.hpp:34</a></div></div> |
| 294 | <div class="ttc" id="aclassarmnn_1_1_invalid_argument_exception_html"><div class="ttname"><a href="classarmnn_1_1_invalid_argument_exception.html">armnn::InvalidArgumentException</a></div><div class="ttdef"><b>Definition:</b> <a href="_exceptions_8hpp_source.html#l00080">Exceptions.hpp:80</a></div></div> |
| 295 | <div class="ttc" id="anamespacearmnn_html_a5bdf4240a1fbda27b5fc84baba721781"><div class="ttname"><a href="namespacearmnn.html#a5bdf4240a1fbda27b5fc84baba721781">armnn::GpuFsaDepthwiseConvolution2dCreateOp</a></div><div class="ttdeci">void GpuFsaDepthwiseConvolution2dCreateOp(GpuFsaPreCompiledBlob *blob, const TensorInfo &input, const DepthwiseConvolution2dDescriptor &descriptor, const TensorInfo &weights, const Optional< TensorInfo > &biases)</div><div class="ttdef"><b>Definition:</b> <a href="_gpu_fsa_depthwise_convolution2d_8cpp_source.html#l00089">GpuFsaDepthwiseConvolution2d.cpp:89</a></div></div> |
| 296 | <div class="ttc" id="a_gpu_fsa_depthwise_convolution2d_8hpp_html"><div class="ttname"><a href="_gpu_fsa_depthwise_convolution2d_8hpp.html">GpuFsaDepthwiseConvolution2d.hpp</a></div></div> |
| 297 | <div class="ttc" id="anamespacearmnn_html_a67a0db04d321a74b7e7fcfd3f1a3f70b"><div class="ttname"><a href="namespacearmnn.html#a67a0db04d321a74b7e7fcfd3f1a3f70b">armnn::Status</a></div><div class="ttdeci">Status</div><div class="ttdef"><b>Definition:</b> <a href="_types_8hpp_source.html#l00042">Types.hpp:42</a></div></div> |
| 298 | <div class="ttc" id="aclassarmnn_1_1_tensor_info_html_a8b5d0f8a24e9d9238f412260a552acf8"><div class="ttname"><a href="classarmnn_1_1_tensor_info.html#a8b5d0f8a24e9d9238f412260a552acf8">armnn::TensorInfo::GetShape</a></div><div class="ttdeci">const TensorShape & GetShape() const</div><div class="ttdef"><b>Definition:</b> <a href="_tensor_8hpp_source.html#l00193">Tensor.hpp:193</a></div></div> |
| 299 | <div class="ttc" id="aclassarmnn_1_1_backend_capability_exception_html"><div class="ttname"><a href="classarmnn_1_1_backend_capability_exception.html">armnn::BackendCapabilityException</a></div><div class="ttdef"><b>Definition:</b> <a href="_exceptions_8hpp_source.html#l00152">Exceptions.hpp:152</a></div></div> |
| 300 | <div class="ttc" id="aclassarmnn_1_1_tensor_info_html_abe8889e8150beef5fd204b2d87b49298"><div class="ttname"><a href="classarmnn_1_1_tensor_info.html#abe8889e8150beef5fd204b2d87b49298">armnn::TensorInfo::SetShape</a></div><div class="ttdeci">void SetShape(const TensorShape &newShape)</div><div class="ttdef"><b>Definition:</b> <a href="_tensor_8hpp_source.html#l00195">Tensor.hpp:195</a></div></div> |
| 301 | <div class="ttc" id="anamespacearmnn_html"><div class="ttname"><a href="namespacearmnn.html">armnn</a></div><div class="ttdoc">Copyright (c) 2021 ARM Limited and Contributors.</div><div class="ttdef"><b>Definition:</b> <a href="01__00__quick__start_8dox_source.html#l00006">01_00_quick_start.dox:6</a></div></div> |
| 302 | <div class="ttc" id="a_arm_compute_tensor_utils_8hpp_html"><div class="ttname"><a href="_arm_compute_tensor_utils_8hpp.html">ArmComputeTensorUtils.hpp</a></div></div> |
| 303 | <div class="ttc" id="astructarmnn_1_1_gpu_fsa_pre_compiled_blob_html_a255c9012137b149ffb46d83c23f2df43"><div class="ttname"><a href="structarmnn_1_1_gpu_fsa_pre_compiled_blob.html#a255c9012137b149ffb46d83c23f2df43">armnn::GpuFsaPreCompiledBlob::workloadContext</a></div><div class="ttdeci">std::shared_ptr< arm_compute::experimental::dynamic_fusion::GpuWorkloadContext > workloadContext</div><div class="ttdef"><b>Definition:</b> <a href="_gpu_fsa_backend_8hpp_source.html#l00035">GpuFsaBackend.hpp:35</a></div></div> |
| 304 | <div class="ttc" id="astructarmnn_1_1_gpu_fsa_pre_compiled_blob_html"><div class="ttname"><a href="structarmnn_1_1_gpu_fsa_pre_compiled_blob.html">armnn::GpuFsaPreCompiledBlob</a></div><div class="ttdoc">A structure which contains all the elements needed to execute a fused workload in the GpuFsa Backend.</div><div class="ttdef"><b>Definition:</b> <a href="_gpu_fsa_backend_8hpp_source.html#l00032">GpuFsaBackend.hpp:32</a></div></div> |
| 305 | <div class="ttc" id="a_utils_gpu_fsa_8hpp_html"><div class="ttname"><a href="_utils_gpu_fsa_8hpp.html">UtilsGpuFsa.hpp</a></div></div> |
| 306 | <div class="ttc" id="anamespacearmnn_html_af2016aed3575b7302e79c72830c23025"><div class="ttname"><a href="namespacearmnn.html#af2016aed3575b7302e79c72830c23025">armnn::GpuFsaDepthwiseConvolution2dValidate</a></div><div class="ttdeci">arm_compute::Status GpuFsaDepthwiseConvolution2dValidate(const TensorInfo &input, const DepthwiseConvolution2dDescriptor &descriptor, const TensorInfo &weights, const Optional< TensorInfo > &biases)</div><div class="ttdef"><b>Definition:</b> <a href="_gpu_fsa_depthwise_convolution2d_8cpp_source.html#l00026">GpuFsaDepthwiseConvolution2d.cpp:26</a></div></div> |
| 307 | <div class="ttc" id="astructarmnn_1_1_depthwise_convolution2d_descriptor_html"><div class="ttname"><a href="structarmnn_1_1_depthwise_convolution2d_descriptor.html">armnn::DepthwiseConvolution2dDescriptor</a></div><div class="ttdoc">A DepthwiseConvolution2dDescriptor for the DepthwiseConvolution2dLayer.</div><div class="ttdef"><b>Definition:</b> <a href="_descriptors_8hpp_source.html#l00659">Descriptors.hpp:659</a></div></div> |
| 308 | <div class="ttc" id="astructarmnn_1_1_gpu_fsa_pre_compiled_blob_html_ac49bf679a23aa84f06a6bde3440a4c40"><div class="ttname"><a href="structarmnn_1_1_gpu_fsa_pre_compiled_blob.html#ac49bf679a23aa84f06a6bde3440a4c40">armnn::GpuFsaPreCompiledBlob::outputTensorInfos</a></div><div class="ttdeci">std::unique_ptr< std::vector< arm_compute::ITensorInfo * > > outputTensorInfos</div><div class="ttdef"><b>Definition:</b> <a href="_gpu_fsa_backend_8hpp_source.html#l00038">GpuFsaBackend.hpp:38</a></div></div> |
| 309 | <div class="ttc" id="aclassarmnn_1_1_optional_reference_switch_html_a77c7d528ac063d870b8c8426ec81c1c3"><div class="ttname"><a href="classarmnn_1_1_optional_reference_switch.html#a77c7d528ac063d870b8c8426ec81c1c3">armnn::OptionalReferenceSwitch< std::is_reference< T >::value, T >::value</a></div><div class="ttdeci">const T & value() const</div><div class="ttdef"><b>Definition:</b> <a href="_optional_8hpp_source.html#l00146">Optional.hpp:146</a></div></div> |
| 310 | <div class="ttc" id="aclassarmnn_1_1_optional_base_html_a86b749ce2c4bc627fa8a1fcfaf0e314f"><div class="ttname"><a href="classarmnn_1_1_optional_base.html#a86b749ce2c4bc627fa8a1fcfaf0e314f">armnn::OptionalBase::has_value</a></div><div class="ttdeci">bool has_value() const noexcept</div><div class="ttdef"><b>Definition:</b> <a href="_optional_8hpp_source.html#l00053">Optional.hpp:53</a></div></div> |
| 311 | <!-- start footer part --> |
| 312 | <div id="nav-path" class="navpath"><!-- id is needed for treeview function! --> |
| 313 | <ul> |
| 314 | <li class="navelem"><a class="el" href="dir_68267d1309a1af8e8297ef4c3efbcdba.html">src</a></li><li class="navelem"><a class="el" href="dir_0f3cdec46afbc61a1ded8e1687c9c9a0.html">backends</a></li><li class="navelem"><a class="el" href="dir_dd5880bc3520e42c5318e86a9fdc97f6.html">gpuFsa</a></li><li class="navelem"><a class="el" href="dir_6735d107a3ea44e973a098b746f1b3bd.html">layers</a></li><li class="navelem"><a class="el" href="_gpu_fsa_depthwise_convolution2d_8cpp.html">GpuFsaDepthwiseConvolution2d.cpp</a></li> |
| 315 | <li class="footer">Generated on Thu May 16 2024 09:31:47 for Arm NN by |
| 316 | <a href="http://www.doxygen.org/index.html"> |
| 317 | <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.17 </li> |
| 318 | </ul> |
| 319 | </div> |
| 320 | </body> |
| 321 | </html> |