Repository navigation
Description
`
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/workspace/LLaMA-Factory/src/train_bash.py", line 14, in
main()
File "/workspace/LLaMA-Factory/src/train_bash.py", line 5, in main
run_exp()
File "/workspace/LLaMA-Factory/src/llmtuner/train/tuner.py", line 26, in run_exp
run_sft(model_args, data_args, training_args, finetuning_args, generating_args, callbacks)
File "/workspace/LLaMA-Factory/src/llmtuner/train/sft/workflow.py", line 29, in run_sft
model, tokenizer = load_model_and_tokenizer(model_args, finetuning_args, training_args.do_train)
File "/workspace/LLaMA-Factory/src/llmtuner/model/loader.py", line 63, in load_model_and_tokenizer
require_version("unsloth", "Follow the instructions at: https://github.com/unslothai/unsloth")
File "/root/miniconda3/envs/llama_factory/lib/python3.10/site-packages/transformers/utils/versions.py", line 104, in require_version
raise importlib.metadata.PackageNotFoundError(
importlib.metadata.PackageNotFoundError: No package metadata was found for The 'unsloth' distribution was not found and is required by this application.
Follow the instructions at: https://github.com/unslothai/unsloth
Converting format of dataset: 97%|█████████▋| 139000/143000 [00:02<00:00, 55130.54 examples/s]12/31/2023 15:47:40 - INFO - llmtuner.model.patcher - Quantizing model to 4 bit.
Traceback (most recent call last):
File "/root/miniconda3/envs/llama_factory/lib/python3.10/site-packages/transformers/utils/versions.py", line 102, in require_version
got_ver = importlib.metadata.version(pkg)
File "/root/miniconda3/envs/llama_factory/lib/python3.10/importlib/metadata/init.py", line 996, in version
return distribution(distribution_name).version
File "/root/miniconda3/envs/llama_factory/lib/python3.10/importlib/metadata/init.py", line 969, in distribution
return Distribution.from_name(distribution_name)
File "/root/miniconda3/envs/llama_factory/lib/python3.10/importlib/metadata/init.py", line 548, in from_name
raise PackageNotFoundError(name)
importlib.metadata.PackageNotFoundError: No package metadata was found for unsloth
During handling of the above exception, another exception occurred:`
Activity
danielhanchen commentedon Dec 31, 2023
Did you install Unsloth?
danielhanchen commentedon Dec 31, 2023
Oh wait you might have to update pip
xiechengmude commentedon Dec 31, 2023
I installed it with pip .So you mean I should upgrade pip individually again?
But my pip version is the newest verison now.
xiechengmude commentedon Dec 31, 2023
furthermore, whats the info here meaning?
/root/miniconda3/envs/unsloth/lib/python3.10/site-packages/unsloth/__init__.py:23: UserWarning: Unsloth: 'CUDA_VISIBLE_DEVICES' is currently 0,1,2,3,4,5,6,7 but we require 'CUDA_VISIBLE_DEVICES=0' We shall set it ourselves.danielhanchen commentedon Jan 1, 2024
@xiechengmude If you're using the latest pip, then to be honest, I'm not sure why the installation is not working.
Did you follow exactly the instructions as described? If you have Conda / Anaconda, you must follow https://github.com/unslothai/unsloth#installation-instructions---conda or else CUDA will not link properly.
If you used pip, you must have
torch>=2.1.0and ontorch==2.1.1one must use the Pytorch 2.1.1 install path as shown in the pip section https://github.com/unslothai/unsloth#installation-instructions---pipUnsloth only supports single GPUs for now - multi GPU will be for a future release. So, we set
CUDA_VISIBLE_DEVICES=0to not make Unsloth cause CUDA segfaults.danielhanchen commentedon Jan 1, 2024
Wait I just noticed - so Unsloth is in fact working?
When did you get the first error msg?
Studio sd.cpp: pin the prebuilt resynced with upstream master-1056 (u…