MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / ReadString

Function ReadString

tensorflow/core/lib/wav/wav_io.cc:125–133  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

123}
124
125Status ReadString(const string& data, int expected_length, string* value,
126 int* offset) {
127 int new_offset;
128 TF_RETURN_IF_ERROR(
129 IncrementOffset(*offset, expected_length, data.size(), &new_offset));
130 *value = string(data.begin() + *offset, data.begin() + new_offset);
131 *offset = new_offset;
132 return Status::OK();
133}
134
135Status EncodeAudioAsS16LEWav(const float* audio, size_t sample_rate,
136 size_t num_channels, size_t num_frames,

Callers 9

ReadHeaderMethod · 0.85
ReadRecordMethod · 0.85
ReadNullableStringMethod · 0.85
ReadStringMapMethod · 0.85
OCReadIncreasing<string>Function · 0.85
TESTFunction · 0.85
TESTFunction · 0.85
DecodeTensorNameSliceFunction · 0.85

Calls 3

IncrementOffsetFunction · 0.85
sizeMethod · 0.45
beginMethod · 0.45

Tested by 3

OCReadIncreasing<string>Function · 0.68
TESTFunction · 0.68
TESTFunction · 0.68