mediapipe icon indicating copy to clipboard operation
mediapipe copied to clipboard

Xcode: Getting Failed to initialize LlmInference session -> Failed to map, error: Cannot allocate memory

Open Pratik-7i opened this issue 1 month ago • 0 comments

Working well in Xcode simulator but getting following error for Device:

Failed to initialize LlmInference session: ; RET_CHECK failure (external/odml/odml/infra/genai/inference/ml_drift/llm/llm_metal_runner.mm:87) llm_runner->model_->Init(llm_config, num_output_heads, std::move(tensor_loader), create_info, sampler_params, &llm_runner->metal_device_) returned INTERNAL: ; RET_CHECK failure (external/odml/odml/infra/genai/inference/utils/llm_utils/memory_mapped_file_posix.cc:86) (data)!=(((void *)-1))Failed to map, error: Cannot allocate memory

Device is having sufficient memory and the model size is 1.35 GB.

Pratik-7i avatar May 13 '24 06:05 Pratik-7i