MCPcopy Create free account
hub / github.com/Oneflow-Inc/oneflow / GetChunkId

Function GetChunkId

oneflow/core/embedding/persistent_table.cpp:94–99  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

92}
93
94uint64_t GetChunkId(const std::string& chunk_name) {
95 size_t pos = 0;
96 const uint64_t chunk_id = std::stoull(chunk_name, &pos, 10);
97 CHECK_EQ(pos, kChunkNameSuffixLength);
98 return chunk_id;
99}
100
101uint64_t GetChunkId(const std::string& filename, const std::string& prefix) {
102 CHECK_EQ(filename.compare(0, prefix.size(), prefix), 0);

Callers 4

ListChunkFilesFunction · 0.85
LoadSnapshotImplMethod · 0.85
LoadSnapshotMethod · 0.85
NextMethod · 0.85

Calls 1

sizeMethod · 0.45

Tested by

no test coverage detected