Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

can not export bge-reranker-base in windows #2924

Open
TatvaJoshi opened this issue Dec 18, 2024 · 0 comments
Open

can not export bge-reranker-base in windows #2924

TatvaJoshi opened this issue Dec 18, 2024 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@TatvaJoshi
Copy link

TatvaJoshi commented Dec 18, 2024

(.venv) PS D:\Projects\model_server\demos\common\export_models> python export_model.py rerank --source_model BAAI/bge-reranker-base --weight-format int8 --config_file_path models/config_all.json
template params: {'task': 'rerank', 'target_device': 'CPU', 'num_streams': '1', 'max_doc_length': 16000}
Exporting rerank model to models\BAAI/bge-reranker-base\rerank\1
config.json: 100%|█████████████████████████████████████████████████████████████████| 799/799 [00:00<00:00, 266kB/s]
d:\projects.venv\lib\site-packages\huggingface_hub\file_download.py:140: UserWarning: huggingface_hub cache-system uses symlinks by default to efficiently store duplicated files but your machine does not support them in C:\Users\tatvajoshi.cache\huggingface\hub\models--BAAI--bge-reranker-base. Caching files will still work but in a degraded version that might require more space on your disk. This warning can be disabled by setting the HF_HUB_DISABLE_SYMLINKS_WARNING environment variable. For more details, see https://huggingface.co/docs/huggingface_hub/how-to-cache#limitations.
To support symlinks on Windows, you either need to activate Developer Mode or to run Python as an administrator. In order to activate developer mode, see this article: https://docs.microsoft.com/en-us/windows/apps/get-started/enable-your-device-for-development
warnings.warn(message)
model.safetensors: 100%|███████████████████████████████████████████████████████| 1.11G/1.11G [00:08<00:00, 133MB/s]
tokenizer_config.json: 100%|███████████████████████████████████████████████████████| 443/443 [00:00<00:00, 111kB/s]
sentencepiece.bpe.model: 100%|████████████████████████████████████████████████| 5.07M/5.07M [00:00<00:00, 98.9MB/s]
tokenizer.json: 100%|█████████████████████████████████████████████████████████| 17.1M/17.1M [00:00<00:00, 97.7MB/s]
special_tokens_map.json: 100%|████████████████████████████████████████████████████| 279/279 [00:00<00:00, 69.7kB/s]
Traceback (most recent call last):
File "C:\Users\tatvajoshi\AppData\Local\Programs\Python\Python39\lib\runpy.py", line 197, in _run_module_as_main
return run_code(code, main_globals, None,
File "C:\Users\tatvajoshi\AppData\Local\Programs\Python\Python39\lib\runpy.py", line 87, in run_code
exec(code, run_globals)
File "D:\Projects.venv\Scripts\optimum-cli.exe_main
.py", line 7, in
File "d:\projects.venv\lib\site-packages\optimum\commands\optimum_cli.py", line 208, in main
service.run()
File "d:\projects.venv\lib\site-packages\optimum\commands\export\openvino.py", line 397, in run
main_export(
File "d:\projects.venv\lib\site-packages\optimum\exporters\openvino_main
.py", line 445, in main_export
submodel = core.read_model(submodel_path)
File "d:\projects.venv\lib\site-packages\openvino\runtime\ie_api.py", line 502, in read_model
return Model(super().read_model(model))
RuntimeError: Exception from src\inference\src\cpp\core.cpp:90:
Exception from src\frontends\ir\src\ir_deserializer.cpp:355:
Incorrect weights in bin file!

Traceback (most recent call last):
File "D:\Projects\model_server\demos\common\export_models\export_model.py", line 376, in
export_rerank_model(args['model_repository_path'], args['source_model'], args['model_name'] ,args['precision'], template_parameters, str(args['version']), args['config_file_path'], args['max_doc_length'])
File "D:\Projects\model_server\demos\common\export_models\export_model.py", line 331, in export_rerank_model
raise ValueError("Failed to export rerank model", source_model)
ValueError: ('Failed to export rerank model', 'BAAI/bge-reranker-base')

@TatvaJoshi TatvaJoshi added the bug Something isn't working label Dec 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants