MCPcopy Create free account
hub / github.com/appdevforall/CodeOnTheGo / init_fp

Method init_fp

subprojects/llama.cpp/src/llama-mmap.cpp:202–210  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

200#endif
201
202 void init_fp(const char * mode) {
203 fp = ggml_fopen(fname.c_str(), mode);
204 if (fp == NULL) {
205 throw std::runtime_error(format("failed to open %s: %s", fname.c_str(), strerror(errno)));
206 }
207 seek(0, SEEK_END);
208 size = tell();
209 seek(0, SEEK_SET);
210 }
211
212 size_t tell() const {
213 if (fd == -1) {

Callers

nothing calls this directly

Calls 2

ggml_fopenFunction · 0.85
formatFunction · 0.85

Tested by

no test coverage detected