From 769dfa1e69c22d4aea37840a955db7fd2cf3a4d7 Mon Sep 17 00:00:00 2001 From: Michael Denkowski Date: Tue, 17 Sep 2013 12:46:02 -0700 Subject: Save/load weights in stream mira --- utils/weights.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'utils/weights.h') diff --git a/utils/weights.h b/utils/weights.h index 30f71db0..920fdd75 100644 --- a/utils/weights.h +++ b/utils/weights.h @@ -23,6 +23,11 @@ class Weights { static void SanityCheck(const std::vector& w); // write weights with largest magnitude to cerr static void ShowLargestFeatures(const std::vector& w); + static std::string GetString(const std::vector& w, + bool hide_zero_value_features = true); + // Assumes weights are already initialized for now + static void UpdateFromString(std::string& w_string, + std::vector& w); private: Weights(); }; -- cgit v1.2.3