| 62 | |
| 63 | #if defined(TENSORFLOW_LITE_PROTOS) |
| 64 | Status WriteToFile(const string& filepath, |
| 65 | const ::tensorflow::protobuf::MessageLite& proto) { |
| 66 | string s; |
| 67 | if (!SerializeToStringDeterministic(proto, &s)) { |
| 68 | return errors::Internal("Failed to serialize proto to string."); |
| 69 | } |
| 70 | return WriteStringToFile(Env::Default(), filepath, s); |
| 71 | } |
| 72 | #else |
| 73 | Status WriteToFile(const string& filepath, |
| 74 | const ::tensorflow::protobuf::Message& proto) { |
no test coverage detected