blob: e297f92b6dc127b7a5dde48a6e3cc981b8b90b4b [file] [log] [blame]
<!-- HTML header for doxygen 1.8.15-->
<!-- Remember to use version doxygen 1.8.15 +-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.15"/>
<meta name="robots" content="NOINDEX, NOFOLLOW" /> <!-- Prevent indexing by search engines -->
<title>Compute Library: NumPyAccessor Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(document).ready(initResizable);
/* @license-end */</script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/x-mathjax-config">
MathJax.Hub.Config({
extensions: ["tex2jax.js"],
jax: ["input/TeX","output/HTML-CSS"],
});
</script><script type="text/javascript" async="async" src="http://cdn.mathjax.org/mathjax/latest/MathJax.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="stylesheet.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
<tbody>
<tr style="height: 56px;">
<img alt="Compute Library" src="https://raw.githubusercontent.com/ARM-software/ComputeLibrary/gh-pages/ACL_logo.png" style="max-width: 100%;margin-top: 15px;margin-left: 10px"/>
<td style="padding-left: 0.5em;">
<div id="projectname">
&#160;<span id="projectnumber">20.02.1</span>
</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.15 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
initMenu('',true,false,'search.php','Search');
$(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
<div id="nav-tree">
<div id="nav-tree-contents">
<div id="nav-sync" class="sync"></div>
</div>
</div>
<div id="splitbar" style="-moz-user-select:none;"
class="ui-resizable-handle">
</div>
</div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(document).ready(function(){initNavTree('classarm__compute_1_1graph__utils_1_1_num_py_accessor.xhtml','');});
/* @license-end */
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>
<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0"
name="MSearchResults" id="MSearchResults">
</iframe>
</div>
<div class="header">
<div class="summary">
<a href="#pub-methods">Public Member Functions</a> </div>
<div class="headertitle">
<div class="title">NumPyAccessor Class Reference<span class="mlabels"><span class="mlabel">final</span></span></div> </div>
</div><!--header-->
<div class="contents">
<p>NumPy accessor class.
<a href="classarm__compute_1_1graph__utils_1_1_num_py_accessor.xhtml#details">More...</a></p>
<p><code>#include &lt;<a class="el" href="_graph_utils_8h_source.xhtml">GraphUtils.h</a>&gt;</code></p>
<div class="dynheader">
Collaboration diagram for NumPyAccessor:</div>
<div class="dyncontent">
<div class="center"><iframe scrolling="no" frameborder="0" src="classarm__compute_1_1graph__utils_1_1_num_py_accessor__coll__graph.svg" width="138" height="112"><p><b>This browser is not able to show SVG: try Firefox, Chrome, Safari, or Opera instead.</b></p></iframe>
</div>
<center><span class="legend">[<a target="top" href="graph_legend.xhtml">legend</a>]</span></center></div>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:ad12e8048537cfc3c0d1935aa0e63a1ee"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classarm__compute_1_1graph__utils_1_1_num_py_accessor.xhtml#ad12e8048537cfc3c0d1935aa0e63a1ee">NumPyAccessor</a> (std::string npy_path, <a class="el" href="classarm__compute_1_1_tensor_shape.xhtml">TensorShape</a> shape, <a class="el" href="namespacearm__compute.xhtml#ad8ed01ff3ff33333d8e19db4d2818bb6">DataType</a> data_type, <a class="el" href="namespacearm__compute.xhtml#ad1d5cce2d9e9a5d61c243e5c989112e0">DataLayout</a> data_layout=<a class="el" href="namespacearm__compute.xhtml#ad1d5cce2d9e9a5d61c243e5c989112e0a6b99f356fe3b30a2a850b5ea897c289f">DataLayout::NCHW</a>, std::ostream &amp;output_stream=std::cout)</td></tr>
<tr class="memdesc:ad12e8048537cfc3c0d1935aa0e63a1ee"><td class="mdescLeft">&#160;</td><td class="mdescRight">Constructor. <a href="#ad12e8048537cfc3c0d1935aa0e63a1ee">More...</a><br /></td></tr>
<tr class="separator:ad12e8048537cfc3c0d1935aa0e63a1ee"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:afe75cb833252a242807e17ef560d4fe8"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classarm__compute_1_1graph__utils_1_1_num_py_accessor.xhtml#afe75cb833252a242807e17ef560d4fe8">NumPyAccessor</a> (<a class="el" href="classarm__compute_1_1graph__utils_1_1_num_py_accessor.xhtml">NumPyAccessor</a> &amp;&amp;)=default</td></tr>
<tr class="memdesc:afe75cb833252a242807e17ef560d4fe8"><td class="mdescLeft">&#160;</td><td class="mdescRight">Allow instances of this class to be move constructed. <a href="#afe75cb833252a242807e17ef560d4fe8">More...</a><br /></td></tr>
<tr class="separator:afe75cb833252a242807e17ef560d4fe8"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a8a339f337aa264ea978a648e39df90f2"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classarm__compute_1_1graph__utils_1_1_num_py_accessor.xhtml#a8a339f337aa264ea978a648e39df90f2">NumPyAccessor</a> (const <a class="el" href="classarm__compute_1_1graph__utils_1_1_num_py_accessor.xhtml">NumPyAccessor</a> &amp;)=delete</td></tr>
<tr class="memdesc:a8a339f337aa264ea978a648e39df90f2"><td class="mdescLeft">&#160;</td><td class="mdescRight">Prevent instances of this class from being copied (As this class contains pointers) <a href="#a8a339f337aa264ea978a648e39df90f2">More...</a><br /></td></tr>
<tr class="separator:a8a339f337aa264ea978a648e39df90f2"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aeeb120f5eddd6460ae7681a8d018ce15"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classarm__compute_1_1graph__utils_1_1_num_py_accessor.xhtml">NumPyAccessor</a> &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classarm__compute_1_1graph__utils_1_1_num_py_accessor.xhtml#aeeb120f5eddd6460ae7681a8d018ce15">operator=</a> (const <a class="el" href="classarm__compute_1_1graph__utils_1_1_num_py_accessor.xhtml">NumPyAccessor</a> &amp;)=delete</td></tr>
<tr class="memdesc:aeeb120f5eddd6460ae7681a8d018ce15"><td class="mdescLeft">&#160;</td><td class="mdescRight">Prevent instances of this class from being copied (As this class contains pointers) <a href="#aeeb120f5eddd6460ae7681a8d018ce15">More...</a><br /></td></tr>
<tr class="separator:aeeb120f5eddd6460ae7681a8d018ce15"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab469d593b4bc92e1d1132a03de0aedca"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classarm__compute_1_1graph__utils_1_1_num_py_accessor.xhtml#ab469d593b4bc92e1d1132a03de0aedca">access_tensor</a> (<a class="el" href="classarm__compute_1_1_i_tensor.xhtml">ITensor</a> &amp;tensor) override</td></tr>
<tr class="memdesc:ab469d593b4bc92e1d1132a03de0aedca"><td class="mdescLeft">&#160;</td><td class="mdescRight">Interface to be implemented to access a given tensor. <a href="#ab469d593b4bc92e1d1132a03de0aedca">More...</a><br /></td></tr>
<tr class="separator:ab469d593b4bc92e1d1132a03de0aedca"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="inherit_header pub_methods_classarm__compute_1_1graph_1_1_i_tensor_accessor"><td colspan="2" onclick="javascript:toggleInherit('pub_methods_classarm__compute_1_1graph_1_1_i_tensor_accessor')"><img src="closed.png" alt="-"/>&#160;Public Member Functions inherited from <a class="el" href="classarm__compute_1_1graph_1_1_i_tensor_accessor.xhtml">ITensorAccessor</a></td></tr>
<tr class="memitem:a3c7f21c2eb00ab7ae1c18b1418c0d9c6 inherit pub_methods_classarm__compute_1_1graph_1_1_i_tensor_accessor"><td class="memItemLeft" align="right" valign="top">virtual&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classarm__compute_1_1graph_1_1_i_tensor_accessor.xhtml#a3c7f21c2eb00ab7ae1c18b1418c0d9c6">~ITensorAccessor</a> ()=default</td></tr>
<tr class="memdesc:a3c7f21c2eb00ab7ae1c18b1418c0d9c6 inherit pub_methods_classarm__compute_1_1graph_1_1_i_tensor_accessor"><td class="mdescLeft">&#160;</td><td class="mdescRight">Default virtual destructor. <a href="classarm__compute_1_1graph_1_1_i_tensor_accessor.xhtml#a3c7f21c2eb00ab7ae1c18b1418c0d9c6">More...</a><br /></td></tr>
<tr class="separator:a3c7f21c2eb00ab7ae1c18b1418c0d9c6 inherit pub_methods_classarm__compute_1_1graph_1_1_i_tensor_accessor"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>NumPy accessor class. </p>
<p class="definition">Definition at line <a class="el" href="_graph_utils_8h_source.xhtml#l00146">146</a> of file <a class="el" href="_graph_utils_8h_source.xhtml">GraphUtils.h</a>.</p>
</div><h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
<a id="ad12e8048537cfc3c0d1935aa0e63a1ee"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ad12e8048537cfc3c0d1935aa0e63a1ee">&#9670;&nbsp;</a></span>NumPyAccessor() <span class="overload">[1/3]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classarm__compute_1_1graph__utils_1_1_num_py_accessor.xhtml">NumPyAccessor</a> </td>
<td>(</td>
<td class="paramtype">std::string&#160;</td>
<td class="paramname"><em>npy_path</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="classarm__compute_1_1_tensor_shape.xhtml">TensorShape</a>&#160;</td>
<td class="paramname"><em>shape</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="namespacearm__compute.xhtml#ad8ed01ff3ff33333d8e19db4d2818bb6">DataType</a>&#160;</td>
<td class="paramname"><em>data_type</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="namespacearm__compute.xhtml#ad1d5cce2d9e9a5d61c243e5c989112e0">DataLayout</a>&#160;</td>
<td class="paramname"><em>data_layout</em> = <code><a class="el" href="namespacearm__compute.xhtml#ad1d5cce2d9e9a5d61c243e5c989112e0a6b99f356fe3b30a2a850b5ea897c289f">DataLayout::NCHW</a></code>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">std::ostream &amp;&#160;</td>
<td class="paramname"><em>output_stream</em> = <code>std::cout</code>&#160;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Constructor. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramdir">[in]</td><td class="paramname">npy_path</td><td>Path to npy file. </td></tr>
<tr><td class="paramdir">[in]</td><td class="paramname">shape</td><td>Shape of the numpy tensor data. </td></tr>
<tr><td class="paramdir">[in]</td><td class="paramname">data_type</td><td>DataType of the numpy tensor data. </td></tr>
<tr><td class="paramdir">[in]</td><td class="paramname">data_layout</td><td>(Optional) DataLayout of the numpy tensor data. </td></tr>
<tr><td class="paramdir">[out]</td><td class="paramname">output_stream</td><td>(Optional) Output stream </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="_graph_utils_8cpp_source.xhtml#l00180">180</a> of file <a class="el" href="_graph_utils_8cpp_source.xhtml">GraphUtils.cpp</a>.</p>
<div class="fragment"><div class="line"><a name="l00181"></a><span class="lineno"> 181</span>&#160; : _npy_tensor(), _filename(std::move(npy_path)), _output_stream(output_stream)</div><div class="line"><a name="l00182"></a><span class="lineno"> 182</span>&#160;{</div><div class="line"><a name="l00183"></a><span class="lineno"> 183</span>&#160; <a class="code" href="classarm__compute_1_1graph__utils_1_1_num_py_bin_loader.xhtml">NumPyBinLoader</a> loader(_filename, <a class="code" href="namespacearm__compute_1_1test_1_1validation.xhtml#acf5f12bbab64dd614bd8220c97fe484f">data_layout</a>);</div><div class="line"><a name="l00184"></a><span class="lineno"> 184</span>&#160;</div><div class="line"><a name="l00185"></a><span class="lineno"> 185</span>&#160; TensorInfo <a class="code" href="namespacearm__compute_1_1test_1_1validation.xhtml#a4f4125dba5283887b34f889b1c615c0c">info</a>(<a class="code" href="namespacearm__compute_1_1test_1_1validation.xhtml#a45cde9abb508c62d67c3bb2b9bf566a5">shape</a>, 1, <a class="code" href="namespacearm__compute_1_1test_1_1validation.xhtml#a5f5b6c4337eac9e2e0046ca2304d80dc">data_type</a>);</div><div class="line"><a name="l00186"></a><span class="lineno"> 186</span>&#160; <a class="code" href="namespacearm__compute_1_1test_1_1validation.xhtml#a4f4125dba5283887b34f889b1c615c0c">info</a>.set_data_layout(<a class="code" href="namespacearm__compute_1_1test_1_1validation.xhtml#acf5f12bbab64dd614bd8220c97fe484f">data_layout</a>);</div><div class="line"><a name="l00187"></a><span class="lineno"> 187</span>&#160;</div><div class="line"><a name="l00188"></a><span class="lineno"> 188</span>&#160; _npy_tensor.<a class="code" href="classarm__compute_1_1_tensor.xhtml#adbd0cf83a8e1b335a9bf405a8e5019fa">allocator</a>()-&gt;<a class="code" href="classarm__compute_1_1_tensor_allocator.xhtml#a3fc6adad84b23f10d54d5a7b6928f872">init</a>(<a class="code" href="namespacearm__compute_1_1test_1_1validation.xhtml#a4f4125dba5283887b34f889b1c615c0c">info</a>);</div><div class="line"><a name="l00189"></a><span class="lineno"> 189</span>&#160; _npy_tensor.<a class="code" href="classarm__compute_1_1_tensor.xhtml#adbd0cf83a8e1b335a9bf405a8e5019fa">allocator</a>()-&gt;<a class="code" href="classarm__compute_1_1_tensor_allocator.xhtml#a6e509c2a177b0b29e9e2369535094dee">allocate</a>();</div><div class="line"><a name="l00190"></a><span class="lineno"> 190</span>&#160;</div><div class="line"><a name="l00191"></a><span class="lineno"> 191</span>&#160; loader.access_tensor(_npy_tensor);</div><div class="line"><a name="l00192"></a><span class="lineno"> 192</span>&#160;}</div><div class="ttc" id="namespacearm__compute_1_1test_1_1validation_xhtml_a45cde9abb508c62d67c3bb2b9bf566a5"><div class="ttname"><a href="namespacearm__compute_1_1test_1_1validation.xhtml#a45cde9abb508c62d67c3bb2b9bf566a5">arm_compute::test::validation::shape</a></div><div class="ttdeci">shape</div><div class="ttdef"><b>Definition:</b> <a href="_c_l_2_absolute_difference_8cpp_source.xhtml#l00097">AbsoluteDifference.cpp:97</a></div></div>
<div class="ttc" id="namespacearm__compute_1_1test_1_1validation_xhtml_acf5f12bbab64dd614bd8220c97fe484f"><div class="ttname"><a href="namespacearm__compute_1_1test_1_1validation.xhtml#acf5f12bbab64dd614bd8220c97fe484f">arm_compute::test::validation::data_layout</a></div><div class="ttdeci">const DataLayout data_layout</div><div class="ttdef"><b>Definition:</b> <a href="_n_e_o_n_2_im2_col_8cpp_source.xhtml#l00146">Im2Col.cpp:146</a></div></div>
<div class="ttc" id="classarm__compute_1_1_tensor_allocator_xhtml_a3fc6adad84b23f10d54d5a7b6928f872"><div class="ttname"><a href="classarm__compute_1_1_tensor_allocator.xhtml#a3fc6adad84b23f10d54d5a7b6928f872">arm_compute::TensorAllocator::init</a></div><div class="ttdeci">void init(const TensorAllocator &amp;allocator, const Coordinates &amp;coords, TensorInfo &amp;sub_info)</div><div class="ttdoc">Shares the same backing memory with another tensor allocator, while the tensor info might be differen...</div><div class="ttdef"><b>Definition:</b> <a href="src_2runtime_2_tensor_allocator_8cpp_source.xhtml#l00108">TensorAllocator.cpp:108</a></div></div>
<div class="ttc" id="classarm__compute_1_1_tensor_xhtml_adbd0cf83a8e1b335a9bf405a8e5019fa"><div class="ttname"><a href="classarm__compute_1_1_tensor.xhtml#adbd0cf83a8e1b335a9bf405a8e5019fa">arm_compute::Tensor::allocator</a></div><div class="ttdeci">TensorAllocator * allocator()</div><div class="ttdoc">Return a pointer to the tensor's allocator.</div><div class="ttdef"><b>Definition:</b> <a href="runtime_2_tensor_8cpp_source.xhtml#l00048">Tensor.cpp:48</a></div></div>
<div class="ttc" id="classarm__compute_1_1graph__utils_1_1_num_py_bin_loader_xhtml"><div class="ttname"><a href="classarm__compute_1_1graph__utils_1_1_num_py_bin_loader.xhtml">arm_compute::graph_utils::NumPyBinLoader</a></div><div class="ttdoc">Numpy Binary loader class.</div><div class="ttdef"><b>Definition:</b> <a href="_graph_utils_8h_source.xhtml#l00431">GraphUtils.h:431</a></div></div>
<div class="ttc" id="classarm__compute_1_1_tensor_allocator_xhtml_a6e509c2a177b0b29e9e2369535094dee"><div class="ttname"><a href="classarm__compute_1_1_tensor_allocator.xhtml#a6e509c2a177b0b29e9e2369535094dee">arm_compute::TensorAllocator::allocate</a></div><div class="ttdeci">void allocate() override</div><div class="ttdoc">Allocate size specified by TensorInfo of CPU memory.</div><div class="ttdef"><b>Definition:</b> <a href="src_2runtime_2_tensor_allocator_8cpp_source.xhtml#l00133">TensorAllocator.cpp:133</a></div></div>
<div class="ttc" id="namespacearm__compute_1_1test_1_1validation_xhtml_a5f5b6c4337eac9e2e0046ca2304d80dc"><div class="ttname"><a href="namespacearm__compute_1_1test_1_1validation.xhtml#a5f5b6c4337eac9e2e0046ca2304d80dc">arm_compute::test::validation::data_type</a></div><div class="ttdeci">data_type</div><div class="ttdef"><b>Definition:</b> <a href="_c_l_2_arithmetic_addition_8cpp_source.xhtml#l00138">ArithmeticAddition.cpp:138</a></div></div>
<div class="ttc" id="namespacearm__compute_1_1test_1_1validation_xhtml_a4f4125dba5283887b34f889b1c615c0c"><div class="ttname"><a href="namespacearm__compute_1_1test_1_1validation.xhtml#a4f4125dba5283887b34f889b1c615c0c">arm_compute::test::validation::info</a></div><div class="ttdeci">info</div><div class="ttdef"><b>Definition:</b> <a href="_c_l_2_convolution_layer_8cpp_source.xhtml#l00182">ConvolutionLayer.cpp:182</a></div></div>
</div><!-- fragment -->
<p class="reference">References <a class="el" href="_graph_utils_8cpp_source.xhtml#l00759">NumPyBinLoader::access_tensor()</a>, <a class="el" href="src_2runtime_2_tensor_allocator_8cpp_source.xhtml#l00133">TensorAllocator::allocate()</a>, <a class="el" href="runtime_2_tensor_8cpp_source.xhtml#l00048">Tensor::allocator()</a>, <a class="el" href="_n_e_o_n_2_im2_col_8cpp_source.xhtml#l00146">arm_compute::test::validation::data_layout</a>, <a class="el" href="_c_l_2_arithmetic_addition_8cpp_source.xhtml#l00138">arm_compute::test::validation::data_type</a>, <a class="el" href="_c_l_2_convolution_layer_8cpp_source.xhtml#l00182">arm_compute::test::validation::info</a>, <a class="el" href="src_2runtime_2_tensor_allocator_8cpp_source.xhtml#l00108">TensorAllocator::init()</a>, and <a class="el" href="_c_l_2_absolute_difference_8cpp_source.xhtml#l00097">arm_compute::test::validation::shape</a>.</p>
</div>
</div>
<a id="afe75cb833252a242807e17ef560d4fe8"></a>
<h2 class="memtitle"><span class="permalink"><a href="#afe75cb833252a242807e17ef560d4fe8">&#9670;&nbsp;</a></span>NumPyAccessor() <span class="overload">[2/3]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classarm__compute_1_1graph__utils_1_1_num_py_accessor.xhtml">NumPyAccessor</a> </td>
<td>(</td>
<td class="paramtype"><a class="el" href="classarm__compute_1_1graph__utils_1_1_num_py_accessor.xhtml">NumPyAccessor</a> &amp;&amp;&#160;</td>
<td class="paramname"></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">default</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Allow instances of this class to be move constructed. </p>
</div>
</div>
<a id="a8a339f337aa264ea978a648e39df90f2"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a8a339f337aa264ea978a648e39df90f2">&#9670;&nbsp;</a></span>NumPyAccessor() <span class="overload">[3/3]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classarm__compute_1_1graph__utils_1_1_num_py_accessor.xhtml">NumPyAccessor</a> </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classarm__compute_1_1graph__utils_1_1_num_py_accessor.xhtml">NumPyAccessor</a> &amp;&#160;</td>
<td class="paramname"></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">delete</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Prevent instances of this class from being copied (As this class contains pointers) </p>
</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a id="ab469d593b4bc92e1d1132a03de0aedca"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ab469d593b4bc92e1d1132a03de0aedca">&#9670;&nbsp;</a></span>access_tensor()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">bool access_tensor </td>
<td>(</td>
<td class="paramtype"><a class="el" href="classarm__compute_1_1_i_tensor.xhtml">ITensor</a> &amp;&#160;</td>
<td class="paramname"><em>tensor</em></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">override</span><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Interface to be implemented to access a given tensor. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramdir">[in]</td><td class="paramname">tensor</td><td><a class="el" href="classarm__compute_1_1_tensor.xhtml" title="Basic implementation of the tensor interface.">Tensor</a> to be accessed</td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>True if access is successful else false </dd></dl>
<p>Implements <a class="el" href="classarm__compute_1_1graph_1_1_i_tensor_accessor.xhtml#a497873c25847d7b4f60f37a1a3aa7665">ITensorAccessor</a>.</p>
<p class="definition">Definition at line <a class="el" href="_graph_utils_8cpp_source.xhtml#l00206">206</a> of file <a class="el" href="_graph_utils_8cpp_source.xhtml">GraphUtils.cpp</a>.</p>
<div class="fragment"><div class="line"><a name="l00207"></a><span class="lineno"> 207</span>&#160;{</div><div class="line"><a name="l00208"></a><span class="lineno"> 208</span>&#160; <a class="code" href="_validate_8h.xhtml#aadf5c9cff86327b96d88d04649d9715e">ARM_COMPUTE_ERROR_ON_DATA_TYPE_CHANNEL_NOT_IN</a>(&amp;tensor, 1, <a class="code" href="namespacearm__compute.xhtml#ab4e88c89b3b7ea1735996cc4def22d58a44ad4ef5a76e6aa6fb3e3fa079a54fda">DataType::F32</a>, <a class="code" href="namespacearm__compute.xhtml#ad8ed01ff3ff33333d8e19db4d2818bb6af14462d71aa842202c3e4b272c7ec924">DataType::QASYMM8</a>);</div><div class="line"><a name="l00209"></a><span class="lineno"> 209</span>&#160; <a class="code" href="_error_8h.xhtml#a54a6080c9f4df1f908e57a9bbb46f5da">ARM_COMPUTE_ERROR_ON</a>(_npy_tensor.<a class="code" href="classarm__compute_1_1_tensor.xhtml#a47d74e4e51f9b1a636c4831bd747a97c">info</a>()-&gt;<a class="code" href="classarm__compute_1_1_i_tensor_info.xhtml#a178f0d3d87f959e00a743328d95359d2">dimension</a>(0) != tensor.info()-&gt;dimension(0));</div><div class="line"><a name="l00210"></a><span class="lineno"> 210</span>&#160;</div><div class="line"><a name="l00211"></a><span class="lineno"> 211</span>&#160; <span class="keywordflow">switch</span>(tensor.info()-&gt;data_type())</div><div class="line"><a name="l00212"></a><span class="lineno"> 212</span>&#160; {</div><div class="line"><a name="l00213"></a><span class="lineno"> 213</span>&#160; <span class="keywordflow">case</span> <a class="code" href="namespacearm__compute.xhtml#ad8ed01ff3ff33333d8e19db4d2818bb6af14462d71aa842202c3e4b272c7ec924">DataType::QASYMM8</a>:</div><div class="line"><a name="l00214"></a><span class="lineno"> 214</span>&#160; access_numpy_tensor&lt;qasymm8_t&gt;(tensor, 0);</div><div class="line"><a name="l00215"></a><span class="lineno"> 215</span>&#160; <span class="keywordflow">break</span>;</div><div class="line"><a name="l00216"></a><span class="lineno"> 216</span>&#160; <span class="keywordflow">case</span> <a class="code" href="namespacearm__compute.xhtml#ab4e88c89b3b7ea1735996cc4def22d58a44ad4ef5a76e6aa6fb3e3fa079a54fda">DataType::F32</a>:</div><div class="line"><a name="l00217"></a><span class="lineno"> 217</span>&#160; access_numpy_tensor&lt;float&gt;(tensor, 0.0001f);</div><div class="line"><a name="l00218"></a><span class="lineno"> 218</span>&#160; <span class="keywordflow">break</span>;</div><div class="line"><a name="l00219"></a><span class="lineno"> 219</span>&#160; <span class="keywordflow">default</span>:</div><div class="line"><a name="l00220"></a><span class="lineno"> 220</span>&#160; <a class="code" href="_error_8h.xhtml#a7cf8d8b669b8f7b05680230be30d60f4">ARM_COMPUTE_ERROR</a>(<span class="stringliteral">&quot;NOT SUPPORTED!&quot;</span>);</div><div class="line"><a name="l00221"></a><span class="lineno"> 221</span>&#160; }</div><div class="line"><a name="l00222"></a><span class="lineno"> 222</span>&#160;</div><div class="line"><a name="l00223"></a><span class="lineno"> 223</span>&#160; <span class="keywordflow">return</span> <span class="keyword">false</span>;</div><div class="line"><a name="l00224"></a><span class="lineno"> 224</span>&#160;}</div><div class="ttc" id="classarm__compute_1_1_i_tensor_info_xhtml_a178f0d3d87f959e00a743328d95359d2"><div class="ttname"><a href="classarm__compute_1_1_i_tensor_info.xhtml#a178f0d3d87f959e00a743328d95359d2">arm_compute::ITensorInfo::dimension</a></div><div class="ttdeci">virtual size_t dimension(size_t index) const =0</div><div class="ttdoc">Return the size of the requested dimension.</div></div>
<div class="ttc" id="_error_8h_xhtml_a7cf8d8b669b8f7b05680230be30d60f4"><div class="ttname"><a href="_error_8h.xhtml#a7cf8d8b669b8f7b05680230be30d60f4">ARM_COMPUTE_ERROR</a></div><div class="ttdeci">#define ARM_COMPUTE_ERROR(msg)</div><div class="ttdoc">Print the given message then throw an std::runtime_error.</div><div class="ttdef"><b>Definition:</b> <a href="_error_8h_source.xhtml#l00352">Error.h:352</a></div></div>
<div class="ttc" id="namespacearm__compute_xhtml_ab4e88c89b3b7ea1735996cc4def22d58a44ad4ef5a76e6aa6fb3e3fa079a54fda"><div class="ttname"><a href="namespacearm__compute.xhtml#ab4e88c89b3b7ea1735996cc4def22d58a44ad4ef5a76e6aa6fb3e3fa079a54fda">arm_compute::Format::F32</a></div><div class="ttdoc">1 channel, 1 F32 per channel</div></div>
<div class="ttc" id="_error_8h_xhtml_a54a6080c9f4df1f908e57a9bbb46f5da"><div class="ttname"><a href="_error_8h.xhtml#a54a6080c9f4df1f908e57a9bbb46f5da">ARM_COMPUTE_ERROR_ON</a></div><div class="ttdeci">#define ARM_COMPUTE_ERROR_ON(cond)</div><div class="ttdoc">If the condition is true then an error message is printed and an exception thrown.</div><div class="ttdef"><b>Definition:</b> <a href="_error_8h_source.xhtml#l00466">Error.h:466</a></div></div>
<div class="ttc" id="classarm__compute_1_1_tensor_xhtml_a47d74e4e51f9b1a636c4831bd747a97c"><div class="ttname"><a href="classarm__compute_1_1_tensor.xhtml#a47d74e4e51f9b1a636c4831bd747a97c">arm_compute::Tensor::info</a></div><div class="ttdeci">ITensorInfo * info() const override</div><div class="ttdoc">Interface to be implemented by the child class to return the tensor's metadata.</div><div class="ttdef"><b>Definition:</b> <a href="runtime_2_tensor_8cpp_source.xhtml#l00033">Tensor.cpp:33</a></div></div>
<div class="ttc" id="namespacearm__compute_xhtml_ad8ed01ff3ff33333d8e19db4d2818bb6af14462d71aa842202c3e4b272c7ec924"><div class="ttname"><a href="namespacearm__compute.xhtml#ad8ed01ff3ff33333d8e19db4d2818bb6af14462d71aa842202c3e4b272c7ec924">arm_compute::DataType::QASYMM8</a></div><div class="ttdoc">quantized, asymmetric fixed-point 8-bit number unsigned</div></div>
<div class="ttc" id="_validate_8h_xhtml_aadf5c9cff86327b96d88d04649d9715e"><div class="ttname"><a href="_validate_8h.xhtml#aadf5c9cff86327b96d88d04649d9715e">ARM_COMPUTE_ERROR_ON_DATA_TYPE_CHANNEL_NOT_IN</a></div><div class="ttdeci">#define ARM_COMPUTE_ERROR_ON_DATA_TYPE_CHANNEL_NOT_IN(t, c,...)</div><div class="ttdef"><b>Definition:</b> <a href="_validate_8h_source.xhtml#l00790">Validate.h:790</a></div></div>
</div><!-- fragment -->
<p class="reference">References <a class="el" href="_error_8h_source.xhtml#l00352">ARM_COMPUTE_ERROR</a>, <a class="el" href="_error_8h_source.xhtml#l00466">ARM_COMPUTE_ERROR_ON</a>, <a class="el" href="_validate_8h_source.xhtml#l00790">ARM_COMPUTE_ERROR_ON_DATA_TYPE_CHANNEL_NOT_IN</a>, <a class="el" href="classarm__compute_1_1_i_tensor_info.xhtml#a7cfb31af63202568efef5214acfbf3ba">ITensorInfo::data_type()</a>, <a class="el" href="classarm__compute_1_1_i_tensor_info.xhtml#a178f0d3d87f959e00a743328d95359d2">ITensorInfo::dimension()</a>, <a class="el" href="namespacearm__compute.xhtml#ab4e88c89b3b7ea1735996cc4def22d58a44ad4ef5a76e6aa6fb3e3fa079a54fda">arm_compute::F32</a>, <a class="el" href="classarm__compute_1_1_i_tensor.xhtml#a0e95dc1e53c361348314873b168ae237">ITensor::info()</a>, <a class="el" href="runtime_2_tensor_8cpp_source.xhtml#l00033">Tensor::info()</a>, and <a class="el" href="namespacearm__compute.xhtml#ad8ed01ff3ff33333d8e19db4d2818bb6af14462d71aa842202c3e4b272c7ec924">arm_compute::QASYMM8</a>.</p>
</div>
</div>
<a id="aeeb120f5eddd6460ae7681a8d018ce15"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aeeb120f5eddd6460ae7681a8d018ce15">&#9670;&nbsp;</a></span>operator=()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classarm__compute_1_1graph__utils_1_1_num_py_accessor.xhtml">NumPyAccessor</a>&amp; operator= </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classarm__compute_1_1graph__utils_1_1_num_py_accessor.xhtml">NumPyAccessor</a> &amp;&#160;</td>
<td class="paramname"></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">delete</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Prevent instances of this class from being copied (As this class contains pointers) </p>
</div>
</div>
<hr/>The documentation for this class was generated from the following files:<ul>
<li>utils/<a class="el" href="_graph_utils_8h_source.xhtml">GraphUtils.h</a></li>
<li>utils/<a class="el" href="_graph_utils_8cpp_source.xhtml">GraphUtils.cpp</a></li>
</ul>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
<ul>
<li class="navelem"><a class="el" href="namespacearm__compute.xhtml">arm_compute</a></li><li class="navelem"><a class="el" href="namespacearm__compute_1_1graph__utils.xhtml">graph_utils</a></li><li class="navelem"><a class="el" href="classarm__compute_1_1graph__utils_1_1_num_py_accessor.xhtml">NumPyAccessor</a></li>
<li class="footer">Generated on Thu Mar 5 2020 16:07:18 for Compute Library by
<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.15 </li>
</ul>
</div>
</body>
</html>