QEff library utility to capture environment/runtime/library metadata right after loading a model before any transforms are applied. - #1183
Open
quic-dhirajku wants to merge 2 commits into
Open
Conversation
… flows, and validated that dumps are created once per model even when later stages fail.
This captures environment/runtime/library metadata in a robust, non-intrusive way for CausalLM, VLM, and diffusers CPU paths.
- Add QEfficient/utils/library_dump.py with dump_qeff_library_once(model_architecture, model_name) that writes a JSON manifest under QEFF_HOME/<arch_or_name>/<model_name>/
qeff_library-<run_id>.json
- Capture schema version, creation timestamp, model name/architecture, QEff package info (version/import path/editable flag), runtime (python/platform/pid), QAIC SDK versions
(apps/platform from qaic-version-util), and a full pip-style dependency snapshot
- Ensure the manifest is written only once per model per process via a process-level _written registry
- Add dump_qeff_library_once into QEFFBaseModel.__init__ before any PyTorch transforms so dumps survive transform/export failures and never break model construction
- Add unit tests in tests/unit_test/utils/test_library_dump.py to cover manifest shape, paths, deduplication, QAIC SDK parsing, and basic resilience
- Add tests/unit_test/utils/test_library_dump_api_calls.py to validate CausalLM, VLM (qwen3_vl custom config), Diffusers (Flux pipeline) with this utility.
Signed-off-by: Dhiraj Kumar Sah <dhirajku@qti.qualcomm.com>
quic-dhirajku
force-pushed
the
config_dump
branch
from
July 15, 2026 09:04
7b750c7 to
afbde6c
Compare
…_calls.py to transformers test instead of unit_tests directory as these tests require model weights to test for different stages of API calls. Signed-off-by: Dhiraj Kumar Sah <dhirajku@qti.qualcomm.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Added a QEff library utility, wired it into core model and diffusers flows, and validated that dumps are created once per model even when later stages fail.
This captures environment/runtime/library metadata in a robust, non-intrusive way for CausalLM, VLM, and diffusers CPU paths.