Executing Olive for QNN EP for llama3.2 1B instruct, getting Invalid engine (type=value_error)
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 2.4k
- Forks
- 315
- Avg merge
- 4d 11h
- Merged PRs (30d)
- 16
Description
After executing
olive run --config qnn_config.json
i get
/Olive/olive-ai/lib/python3.10/site-packages/olive/engine/packaging/packaging_generator.py:17: UserWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html. The pkg_resources package is slated for removal as early as 2025-11-30. Refrain from using this package or pin to Setuptools<81./Olive/olive-ai/bin/olive", line 8, in
import pkg_resources
[2025-06-11 02:12:09,619] [WARNING] [config_utils.py:337:validate_config] Keys {'provider_options'} are not part of PythonEnvironmentTargetUserConfig. Ignoring them.
[2025-06-11 02:12:09,619] [WARNING] [config_utils.py:337:validate_config] Keys {'tokenizer'} are not part of DataConfig. Ignoring them.
[2025-06-11 02:12:09,620] [WARNING] [config_utils.py:337:validate_config] Keys {'tokenizer'} are not part of DataConfig. Ignoring them.
Traceback (most recent call last):
File "
sys.exit(main())
File "/Olive/olive-ai/lib/python3.10/site-packages/olive/cli/launcher.py", line 64, in main/Olive/olive-ai/lib/python3.10/site-packages/olive/cli/run.py", line 37, in run
service.run()
File "
olive_run(**var_args)
File "/Olive/olive-ai/lib/python3.10/site-packages/olive/workflows/run/run.py", line 230, in run/Olive/olive-ai/lib/python3.10/site-packages/olive/common/config_utils.py", line 126, in parse_file_or_obj
run_config: RunConfig = RunConfig.parse_file_or_obj(run_config)
File "
return cls.parse_file(file_path)
File "/Olive/olive-ai/lib/python3.10/site-packages/pydantic/v1/main.py", line 575, in parse_file/Olive/olive-ai/lib/python3.10/site-packages/pydantic/v1/main.py", line 532, in parse_obj
return cls.parse_obj(obj)
File "
return cls(**obj)
File "~/Olive/olive-ai/lib/python3.10/site-packages/pydantic/v1/main.py", line 347, in init
raise validation_error
pydantic.v1.error_wrappers.ValidationError: 12 validation errors for RunConfig
engine -> tokenizer
extra fields not permitted (type=value_error.extra)
passes -> q
Invalid engine (type=value_error)
passes -> g
Invalid engine (type=value_error)
passes -> cs
Invalid engine (type=value_error)
passes -> mb
Invalid engine (type=value_error)
passes -> mq
Invalid engine (type=value_error)
passes -> gs
Invalid engine (type=value_error)
passes -> sq
Invalid engine (type=value_error)
passes -> sp
Invalid engine (type=value_error)
passes -> st
Invalid engine (type=value_error)
passes -> cb
Invalid engine (type=value_error)
passes -> cp
Invalid engine (type=value_error)
I have installed QNN EP by creating an ONNX runtime wheel using QNN, i have installed the wheel file and can now see QNN-EP as a listed provider in onnx.
I am trying to do olive optimization for llama3 1b instruct model for 8 gen 3 and am unable to pinpoint the source of this error. Also What kind of GPU memory should i expect to be used for this process? currently i have am using a 12 GB VRAM
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with qnn_config.json and the validation trace in olive/common/config_utils.py and olive/workflows/run/run.py. Check how RunConfig parses engine and passes, then compare the supplied configuration with the accepted schema. Done means the configuration validates without the tokenizer and Invalid engine errors and the QNN workflow can begin.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- machine-learning
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100