MCPcopy Create free account
hub / github.com/ARM-software/ComputeLibrary / get_weights_accessor

Function get_weights_accessor

utils/GraphUtils.h:483–494  ·  view source on GitHub ↗

Generates appropriate weights accessor according to the specified path * * @note If path is empty will generate a DummyAccessor else will generate a NumPyBinLoader * * @param[in] path Path to the data files * @param[in] data_file Relative path to the data files from path * @param[in] file_layout (Optional) Layout of file. Defaults to NCHW * * @return An appropriate tensor accessor

Source from the content-addressed store, hash-verified

481 * @return An appropriate tensor accessor
482 */
483inline std::unique_ptr<graph::ITensorAccessor>
484get_weights_accessor(const std::string &path, const std::string &data_file, DataLayout file_layout = DataLayout::NCHW)
485{
486 if (path.empty())
487 {
488 return std::make_unique<DummyAccessor>();
489 }
490 else
491 {
492 return std::make_unique<NumPyBinLoader>(path + data_file, file_layout);
493 }
494}
495
496/** Generates appropriate input accessor according to the specified graph parameters
497 *

Callers 15

do_setupMethod · 0.85
block_mixed_5bMethod · 0.85
block_mixed_6aMethod · 0.85
block_mixed_7aMethod · 0.85
block35_repeatMethod · 0.85
block17_repeatMethod · 0.85
block8_repeatMethod · 0.85
do_setupMethod · 0.85
create_graph_floatMethod · 0.85
create_graph_qasymmMethod · 0.85
get_dwsc_node_floatMethod · 0.85
get_dwsc_node_qasymmMethod · 0.85

Calls 1

emptyMethod · 0.45

Tested by

no test coverage detected