pytorch
bbc6fcd7 - deploy: add dummy metadata for builtin packages (#76211)

Commit
2 years ago
deploy: add dummy metadata for builtin packages (#76211) Summary: This adds dummy metadata for frozen builtin packages when using `torch::deploy`. This is a bit hacky but unblocks allows Huggingface transformers library to be used within `torch::deploy` which depends on `importlib.metadata.version` to detect whether torch is installed or not. https://github.com/huggingface/transformers/blob/main/src/transformers/utils/import_utils.py#L49 Pull Request resolved: https://github.com/pytorch/pytorch/pull/76211 Test Plan: Added `importlib.metadata.version("torch")` unit test Reviewed By: kiukchung, PaliC Differential Revision: D35834831 Pulled By: d4l3k fbshipit-source-id: e58365e1ada69299adea96f0ca1fe211e092dd97 (cherry picked from commit c4b4152a24dcdf359503db2112a10a88633e67b6)
Author
Committer
Parents
Loading