FST
openfst-1.8.3
OpenFst Library
|
#include <sparse-tuple-weight.h>
Public Types | |
using | ReverseWeight = SparseTupleWeight< typename W::ReverseWeight, K > |
using | Iterator = SparseTupleWeightIterator< W, K > |
using | Pair = std::pair< K, W > |
using | Weight = W |
using | Index = K |
Public Member Functions | |
SparseTupleWeight () | |
~SparseTupleWeight () noexcept=default | |
template<class Iterator > | |
SparseTupleWeight (Iterator begin, Iterator end) | |
SparseTupleWeight (const K &key, const W &weight, const W &default_weight) | |
SparseTupleWeight (const W &weight) | |
SparseTupleWeight (const SparseTupleWeight &weight) | |
SparseTupleWeight (SparseTupleWeight &&weight) noexcept | |
std::istream & | Read (std::istream &strm) |
std::ostream & | Write (std::ostream &strm) const |
SparseTupleWeight & | operator= (const SparseTupleWeight &weight) |
SparseTupleWeight & | operator= (SparseTupleWeight &&weight) noexcept |
bool | Member () const |
size_t | Hash () const |
SparseTupleWeight | Quantize (float delta=kDelta) const |
ReverseWeight | Reverse () const |
void | Init (const W &default_value=W::Zero()) |
size_t | Size () const |
void | PushBack (const K &key, const W &weight, bool default_value_check=true) |
void | PushBack (const Pair &pair, bool default_value_check=true) |
const W & | Value (const K &key) const |
void | SetValue (const K &key, const W &w) |
void | SetDefaultValue (const W &value) |
const W & | DefaultValue () const |
Static Public Member Functions | |
static const SparseTupleWeight & | Zero () |
static const SparseTupleWeight & | One () |
static const SparseTupleWeight & | NoWeight () |
Static Public Attributes | |
static constexpr K | kNoKey = -1 |
Friends | |
class | SparseTupleWeightIterator< W, K > |
Definition at line 53 of file sparse-tuple-weight.h.
using fst::SparseTupleWeight< W, K >::Index = K |
Definition at line 60 of file sparse-tuple-weight.h.
using fst::SparseTupleWeight< W, K >::Iterator = SparseTupleWeightIterator<W, K> |
Definition at line 57 of file sparse-tuple-weight.h.
using fst::SparseTupleWeight< W, K >::Pair = std::pair<K, W> |
Definition at line 58 of file sparse-tuple-weight.h.
using fst::SparseTupleWeight< W, K >::ReverseWeight = SparseTupleWeight<typename W::ReverseWeight, K> |
Definition at line 55 of file sparse-tuple-weight.h.
using fst::SparseTupleWeight< W, K >::Weight = W |
Definition at line 59 of file sparse-tuple-weight.h.
|
inline |
Definition at line 64 of file sparse-tuple-weight.h.
|
defaultnoexcept |
|
inline |
Definition at line 69 of file sparse-tuple-weight.h.
|
inline |
Definition at line 77 of file sparse-tuple-weight.h.
|
inlineexplicit |
Definition at line 81 of file sparse-tuple-weight.h.
|
inline |
Definition at line 83 of file sparse-tuple-weight.h.
|
inlinenoexcept |
Definition at line 91 of file sparse-tuple-weight.h.
|
inline |
Definition at line 234 of file sparse-tuple-weight.h.
|
inline |
Definition at line 160 of file sparse-tuple-weight.h.
|
inline |
Definition at line 186 of file sparse-tuple-weight.h.
|
inline |
Definition at line 151 of file sparse-tuple-weight.h.
|
inlinestatic |
Definition at line 112 of file sparse-tuple-weight.h.
|
inlinestatic |
Definition at line 107 of file sparse-tuple-weight.h.
|
inline |
Definition at line 129 of file sparse-tuple-weight.h.
|
inlinenoexcept |
Definition at line 138 of file sparse-tuple-weight.h.
|
inline |
Definition at line 201 of file sparse-tuple-weight.h.
|
inline |
Definition at line 206 of file sparse-tuple-weight.h.
|
inline |
Definition at line 170 of file sparse-tuple-weight.h.
|
inline |
Definition at line 117 of file sparse-tuple-weight.h.
|
inline |
Definition at line 178 of file sparse-tuple-weight.h.
|
inline |
Definition at line 232 of file sparse-tuple-weight.h.
|
inline |
Definition at line 224 of file sparse-tuple-weight.h.
|
inline |
Definition at line 193 of file sparse-tuple-weight.h.
|
inline |
Definition at line 216 of file sparse-tuple-weight.h.
|
inline |
Definition at line 123 of file sparse-tuple-weight.h.
|
inlinestatic |
Definition at line 102 of file sparse-tuple-weight.h.
|
friend |
Definition at line 287 of file sparse-tuple-weight.h.
|
static |
Definition at line 62 of file sparse-tuple-weight.h.