Lines Matching refs:Key

36 template<class Key = std::string, class Hash = std::unordered_map<Key, double> >
46 explicit SparseWeightVector(const SparseWeightVector<Key, Hash> &other) {
49 void operator=(const SparseWeightVector<Key, Hash> &other) {
52 void CopyFrom(const SparseWeightVector<Key, Hash> &other) {
87 bool GetElementMinBound(const Key &fname, double *val) const {
90 bool GetElementMaxBound(const Key &fname, double *val) const {
93 void SetElementMinBound(const Key &fname, const double bound) {
96 void SetElementMaxBound(const Key &fname, const double bound) {
100 double GetElement(const Key &fname) const {
105 void SetElement(const Key &fname, const double val) {
109 void AddUpdateElement(const Key &fname, const double val) {
112 void MultUpdateElement(const Key &fname, const double val) {
116 void LoadWeightVector(const SparseWeightVector<Key, Hash> &vec) {
133 const SparseWeightVector<Key, Hash> &w1,
136 const SparseWeightVector<Key, Hash> &w1,
139 const SparseWeightVector<Key, Hash> &w1,
141 void MultWeightUpdate(const SparseWeightVector<Key, Hash> &w1);
142 double DotProduct(const SparseWeightVector<Key, Hash> &s) const;
150 const SparseWeightVector<Key, Hash> &w1,
152 void MultWeightUpdateBounded(const SparseWeightVector<Key, Hash> &w1);
177 bool GetValue(const Wmap &w1, const Key &fname, double *val) const {
190 template <class Key, class Hash>
192 const SparseWeightVector<Key, Hash> &vector) {
193 typename SparseWeightVector<Key, Hash>::Wmap w_map = vector.GetMap();
195 for (typename SparseWeightVector<Key, Hash>::Witer_const iter = w_map.begin();