I'm facing an issue trying to read a Dataiku Visual Model into a Python code which is a part of a webapp running in a container. I think the model call from dataiku.Model is making the correct call but it's not able to process the get_predictor() command correctly and I'm seeing a file not found error.
if i am running the webapp using local execution then it seems to work just fine the issue raises only when the webapp runs on a container
Attaching the log of the error for refrence
File "/opt/dataiku/python/dataiku/core/saved_model.py", line 202, in get_predictor
self._predictors[version_id] = build_predictor_for_saved_model(model_folder, self.get_type(), sm.get("conditionalOutputs", ))
File "/opt/dataiku/python/dataiku/core/saved_model.py", line 268, in build_predictor_for_saved_model
core_params = dkujson.load_from_filepath(osp.join(model_folder, "core_params.json"))
File "/opt/dataiku/python/dataiku/core/dkujson.py", line 36, in load_from_filepath
with open(filepath) as fp:
FileNotFoundError: [Errno 2] No such file or directory: '/app/dataiku/DSS_DATA_DIR/saved_models/<PROJECTKEY>/<modelid>/versions/initial/core_params.json'
Thank you for reaching out.
On the attached log, the project key and model ids seem to be missing (look at the `<PROJECTKEY>` and `<modelid>` in the filepath)
The issue must probably lie in the definition of your `filepath`, could you attach the code that performs this operation ?