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

Method Init

serving/processor/serving/model_serving.cc:19–35  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

17}
18
19Status Model::Init(const char* model_config) {
20 ModelConfig* config = nullptr;
21 auto status = ModelConfigFactory::Create(model_config, &config);
22 if (!status.ok()) {
23 return status;
24 }
25
26 if (!config->warmup_file_name.empty()) {
27 LOG(INFO) << "User set warmup file: " << config->warmup_file_name;
28 }
29
30 parser_ = ParserFactory::GetInstance(config->serialize_protocol,
31 4);
32 impl_ = ModelImplFactory::Create(config);
33
34 return impl_->Init();
35}
36
37Status Model::Predict(const void* input_data, int input_size,
38 void** output_data, int* output_size) {

Callers

nothing calls this directly

Calls 4

GetInstanceFunction · 0.85
CreateFunction · 0.50
okMethod · 0.45
emptyMethod · 0.45

Tested by

no test coverage detected