|
mxnet
|
Namespaces | |
| cuda | |
| common utils for cuda | |
| helper | |
| Helper functions. | |
| random | |
Classes | |
| struct | csr_idx_check |
| Indices should be non-negative, less than the number of columns and in ascending order per row. More... | |
| struct | csr_indptr_check |
| IndPtr should be non-negative, in non-decreasing order, start with 0 and end with value equal with size of indices. More... | |
| class | LazyAllocArray |
| class | ObjectPool |
| Object pool for fast allocation and deallocation. More... | |
| struct | ObjectPoolAllocatable |
| Helper trait class for easy allocation and deallocation. More... | |
| struct | rsp_idx_check |
| Indices of RSPNDArray should be non-negative, less than the size of first dimension and in ascending order. More... | |
| struct | StaticArray |
| Static array. This code is borrowed from struct Shape<ndim>, except that users can specify the type of the elements of the statically allocated array. The object instance of the struct is copyable between CPU and GPU. More... | |
Typedefs | |
| typedef std::mt19937 | RANDOM_ENGINE |
| Random Engine. More... | |
Functions | |
| bool | SetupDefaultBlobs (const std::vector< NDArray > &src, std::vector< TBlob > *blobs, std::vector< NDArray > *temp_src, std::vector< NDArray > *temp_dst, std::unordered_map< uint32_t, uint32_t > *idx_map=nullptr) |
| void | SetupDefaultBlobsInOut (const std::vector< NDArray > &ndinputs, const std::vector< NDArray > &ndoutputs, std::vector< TBlob > *input_blobs, std::vector< TBlob > *output_blobs, std::vector< NDArray > *pre_temp_src, std::vector< NDArray > *pre_temp_dst, std::vector< NDArray > *post_temp_src, std::vector< NDArray > *post_temp_dst, std::unordered_map< uint32_t, uint32_t > *in_temp_idx_map, const std::vector< uint32_t > &mutate_idx) |
| void | CastNonDefaultStorage (const std::vector< NDArray > &src, const std::vector< NDArray > &dst, const OpContext &ctx, const bool is_gpu) |
| template<typename xpu > | |
| void | CheckFormatWrapper (const RunContext &rctx, const NDArray &input, const TBlob &err_cpu, const bool full_check) |
| template<typename xpu > | |
| void | CheckFormatCSRImpl (const RunContext &rctx, const NDArray &input, const TBlob &err_cpu, const bool full_check) |
| Check the validity of CSRNDArray. More... | |
| template<typename xpu > | |
| void | CheckFormatRSPImpl (const RunContext &rctx, const NDArray &input, const TBlob &err_cpu, const bool full_check) |
| Check the validity of RowSparseNDArray. More... | |
| template<typename xpu > | |
| void | CheckFormatImpl (const RunContext &rctx, const NDArray &input, const TBlob &err_cpu, const bool full_check) |
| template<typename xpu > | |
| void | CastStorageDispatch (const OpContext &ctx, const NDArray &input, const NDArray &output) |
| bool | ContainsOnlyStorage (const StorageTypeVector &vstorage, const NDArrayStorageType stype) |
returns true if all storage types in vstorage are the same as target stype. false is returned for empty inputs. More... | |
| bool | ContainsOnlyStorage (const StorageTypeVector &vstorage, const NDArrayStorageType stype1, const NDArrayStorageType stype2, bool *has_both) |
returns true if all storage types in vstorage are the same as target stype1 or `stype2'. Sets boolean if both found. false is returned for empty inputs. More... | |
| bool | ContainsOnlyStorage (const std::vector< NDArray > &ndarrays, const NDArrayStorageType stype) |
returns true if the storage types of arrays in ndarrays are the same as target stype. false is returned for empty inputs. More... | |
| bool | ContainsOnlyStorage (const std::vector< NDArray > &ndarrays, const NDArrayStorageType stype1, const NDArrayStorageType stype2, bool *has_both) |
returns true if the storage types of arrays in ndarrays are the same as targets stype1 or stype2. false is returned for empty inputs. More... | |
| std::string | dispatch_mode_string (const DispatchMode x) |
| get string representation of dispatch_mode More... | |
| std::string | stype_string (const int x) |
| get string representation of storage_type More... | |
| int | GetNumThreadPerGPU () |
| int | GetExecNumMatchColor () |
| template<typename T , typename V > | |
| V | ParallelAccumulate (const T *a, const int n, V start) |
| template<typename RandomIt , typename Compare > | |
| void | ParallelSortHelper (RandomIt first, size_t len, size_t grainsize, const Compare &comp) |
| Helper function for ParallelSort. DO NOT call this function directly. Use the interface ParallelSort instead. Ref: https://github.com/dmlc/difacto/blob/master/src/common/parallel_sort.h. More... | |
| template<typename RandomIt , typename Compare > | |
| void | ParallelSort (RandomIt first, RandomIt last, size_t num_threads, Compare comp) |
| Sort the elements in the range [first, last) into the ascending order defined by the comparator comp. If the length of the range [first, last) is greater than a certain threshold, the range will be recursively divided into two and assign two threads to sort each half range. Ref: https://github.com/dmlc/difacto/blob/master/src/common/parallel_sort.h. More... | |
| template<typename RandomIt > | |
| void | ParallelSort (RandomIt first, RandomIt last, size_t num_threads) |
| Sort the elements in the range [first, last) into ascending order. The elements are compared using the default < operator. If the length of the range [first, last) is greater than a certain threshold, the range will be recursively divided into two and assign two threads to sort each half range. Ref: https://github.com/dmlc/difacto/blob/master/src/common/parallel_sort.h. More... | |
| template<class T , class... Args> | |
| helper::UniqueIf< T >::SingleObject | MakeUnique (Args &&...args) |
Constructs an object of type T and wraps it in a std::unique_ptr. More... | |
| template<class T > | |
| helper::UniqueIf< T >::UnknownBound | MakeUnique (size_t n) |
Constructs an object of type T and wraps it in a std::unique_ptr. More... | |
| template<class T , class... Args> | |
| helper::UniqueIf< T >::KnownBound | MakeUnique (Args &&...args)=delete |
Constructs an object of type T and wraps it in a std::unique_ptr. More... | |
| template<typename FCompType > | |
| FCompType | GetFCompute (const nnvm::Op *op, const std::string &name, const Context &ctx) |
| typedef std::mt19937 mxnet::common::RANDOM_ENGINE |
Random Engine.
|
inline |
| void mxnet::common::CastStorageDispatch | ( | const OpContext & | ctx, |
| const NDArray & | input, | ||
| const NDArray & | output | ||
| ) |
| void mxnet::common::CheckFormatCSRImpl | ( | const RunContext & | rctx, |
| const NDArray & | input, | ||
| const TBlob & | err_cpu, | ||
| const bool | full_check | ||
| ) |
Check the validity of CSRNDArray.
| rctx | Execution context. |
| input | Input NDArray of CSRStorage. |
| err_cpu | Error number on cpu. |
| full_check | If true, rigorous check, O(N) operations, otherwise basic check, O(1) operations. |
| void mxnet::common::CheckFormatImpl | ( | const RunContext & | rctx, |
| const NDArray & | input, | ||
| const TBlob & | err_cpu, | ||
| const bool | full_check | ||
| ) |
| void mxnet::common::CheckFormatRSPImpl | ( | const RunContext & | rctx, |
| const NDArray & | input, | ||
| const TBlob & | err_cpu, | ||
| const bool | full_check | ||
| ) |
Check the validity of RowSparseNDArray.
| rctx | Execution context. |
| input | Input NDArray of RowSparseStorage. |
| err_cpu | Error number on cpu. |
| full_check | If true, rigorous check, O(N) operations, otherwise basic check, O(1) operations. |
| void mxnet::common::CheckFormatWrapper | ( | const RunContext & | rctx, |
| const NDArray & | input, | ||
| const TBlob & | err_cpu, | ||
| const bool | full_check | ||
| ) |
|
inline |
returns true if all storage types in vstorage are the same as target stype. false is returned for empty inputs.
|
inline |
returns true if all storage types in vstorage are the same as target stype1 or `stype2'. Sets boolean if both found. false is returned for empty inputs.
|
inline |
returns true if the storage types of arrays in ndarrays are the same as target stype. false is returned for empty inputs.
|
inline |
returns true if the storage types of arrays in ndarrays are the same as targets stype1 or stype2. false is returned for empty inputs.
|
inline |
get string representation of dispatch_mode
|
inline |
| FCompType mxnet::common::GetFCompute | ( | const nnvm::Op * | op, |
| const std::string & | name, | ||
| const Context & | ctx | ||
| ) |
|
inline |
|
delete |
Constructs an object of type T and wraps it in a std::unique_ptr.
| args | List of arguments with which an instance of T will be constructed. |
std::unique_ptr of an instance of type T.Constructs a non-array type T. The arguments args are passed to the constructor of T. The function does not participate in the overload resolution if T is an array type.
| helper::UniqueIf<T>::UnknownBound mxnet::common::MakeUnique | ( | size_t | n | ) |
Constructs an object of type T and wraps it in a std::unique_ptr.
| n | The size of the array to construct. |
std::unique_ptr of an instance of type T.Constructs an array of unknown bound T. The function does not participate in the overload resolution unless T is an array of unknown bound.
|
delete |
Constructs an object of type T and wraps it in a std::unique_ptr.
| args | List of arguments with which an instance of T will be constructed. |
Constructs an arrays of known bound is disallowed.
| args | List of arguments with which an instance of T will be constructed. |
std::unique_ptr of an instance of type T.Constructs a non-array type T. The arguments args are passed to the constructor of T. The function does not participate in the overload resolution if T is an array type.
| V mxnet::common::ParallelAccumulate | ( | const T * | a, |
| const int | n, | ||
| V | start | ||
| ) |
| void mxnet::common::ParallelSort | ( | RandomIt | first, |
| RandomIt | last, | ||
| size_t | num_threads, | ||
| Compare | comp | ||
| ) |
Sort the elements in the range [first, last) into the ascending order defined by the comparator comp. If the length of the range [first, last) is greater than a certain threshold, the range will be recursively divided into two and assign two threads to sort each half range. Ref: https://github.com/dmlc/difacto/blob/master/src/common/parallel_sort.h.
| void mxnet::common::ParallelSort | ( | RandomIt | first, |
| RandomIt | last, | ||
| size_t | num_threads | ||
| ) |
Sort the elements in the range [first, last) into ascending order. The elements are compared using the default < operator. If the length of the range [first, last) is greater than a certain threshold, the range will be recursively divided into two and assign two threads to sort each half range. Ref: https://github.com/dmlc/difacto/blob/master/src/common/parallel_sort.h.
| void mxnet::common::ParallelSortHelper | ( | RandomIt | first, |
| size_t | len, | ||
| size_t | grainsize, | ||
| const Compare & | comp | ||
| ) |
Helper function for ParallelSort. DO NOT call this function directly. Use the interface ParallelSort instead. Ref: https://github.com/dmlc/difacto/blob/master/src/common/parallel_sort.h.
|
inline |
|
inline |
|
inline |
get string representation of storage_type
1.8.11