openvinotoolkit / operator

OpenVINO operator for OpenShift and Kubernetes
Apache License 2.0
12 stars 9 forks source link

operator can not read the hostPath mount model #96

Open Huimintai opened 8 months ago

Huimintai commented 8 months ago

Hello, I deployment the ovms chart use the command:

helm install ovms-pipeline ovms --set models_settings.config_configmap_name=ovms-pipeline,models_settings.single_model_mode=false,models_repository.models_host_path=/opt/,models_settings.model_path=/opt/

And I follow the demo steps :https://github.com/openvinotoolkit/operator/blob/main/helm-charts/ovms/README.md#demo---deployment-of-the-model-server-with-a-vehicle-analysis-pipeline The pod can running:

kubectl get pods | grep ovms
ovms-pipeline-b845894db-6qzwc    1/1     Running   0          11m

But it report the errors that it can not find the hostPath model:

[2023-12-22 08:15:54.859][127][modelmanager][error][modelmanager.cpp:1340] Directory does not exist: /opt/vehicle-detection-0202/
[2023-12-22 08:15:55.860][127][modelmanager][error][modelmanager.cpp:1340] Directory does not exist: /opt/vehicle-attributes-recognition-barrier-0042/

I add the config:

models_repository:
  runAsUser: 5000
  runAsGroup: 5000

But it can not work as expect. I can login the pod to see the model files has mounted into pods:

ovms@ovms-pipeline-b845894db-6qzwc:/models$ ls
cni  containerd  img_arrays_for_acc.txt  vehicle-attributes-recognition-barrier-0042  vehicle-detection-0202
whoami
ovms

Can anyone can help with this issue?Thanks a lot.

dtrawins commented 4 months ago

In the config.json file added to the configmap, there should be updated the path to the model. Probably the sed command was not executed. The models are mounted in /models folder but the config.json is expecting them in /opt.