bugs
This commit is contained in:
parent
4285d1b479
commit
42e09d192f
3 changed files with 16 additions and 14 deletions
|
|
@ -178,20 +178,20 @@ from transformers.models.llama.modeling_llama import logger
|
|||
# Get Xformers
|
||||
from xformers import __version__ as xformers_version
|
||||
# Temporarily disable 0.0.27 and higher - inference issues
|
||||
if Version(xformers_version) >= Version("0.0.27"):
|
||||
raise ImportError(
|
||||
"Unsloth: If you are in Colab, we updated the top cell install instructions - please change it to below "\
|
||||
"then press Disconnect Runtime and then Restart it.\n"\
|
||||
"\n"\
|
||||
"%%capture\n"
|
||||
"# Installs Unsloth, Xformers (Flash Attention) and all other packages!\n"
|
||||
'!pip install "unsloth[colab-new] @ git+https://github.com/unslothai/unsloth.git"\n'
|
||||
'!pip install --no-deps "xformers<0.0.27" "trl<0.9.0" peft accelerate bitsandbytes\n'\
|
||||
'\n'\
|
||||
f"Otherwise in local machines, your xformers version of {xformers_version} is too new.\n"\
|
||||
'Please downgrade xformers via `pip install --force-reinstall "xformers<0.0.27"'
|
||||
)
|
||||
pass
|
||||
# if Version(xformers_version) >= Version("0.0.27"):
|
||||
# raise ImportError(
|
||||
# "Unsloth: If you are in Colab, we updated the top cell install instructions - please change it to below "\
|
||||
# "then press Disconnect Runtime and then Restart it.\n"\
|
||||
# "\n"\
|
||||
# "%%capture\n"
|
||||
# "# Installs Unsloth, Xformers (Flash Attention) and all other packages!\n"
|
||||
# '!pip install "unsloth[colab-new] @ git+https://github.com/unslothai/unsloth.git"\n'
|
||||
# '!pip install --no-deps "xformers<0.0.27" "trl<0.9.0" peft accelerate bitsandbytes\n'\
|
||||
# '\n'\
|
||||
# f"Otherwise in local machines, your xformers version of {xformers_version} is too new.\n"\
|
||||
# 'Please downgrade xformers via `pip install --force-reinstall "xformers<0.0.27"'
|
||||
# )
|
||||
# pass
|
||||
|
||||
if Version(torch_version) < Version("2.2.0") and Version(xformers_version) >= Version("0.0.24"):
|
||||
raise ImportError(
|
||||
|
|
|
|||
|
|
@ -42,6 +42,7 @@ def __get_model_name(
|
|||
FLOAT_TO_INT_MAPPER = None,
|
||||
):
|
||||
|
||||
model_name = str(model_name)
|
||||
if not SUPPORTS_FOURBIT and model_name.lower() in INT_TO_FLOAT_MAPPER:
|
||||
model_name = INT_TO_FLOAT_MAPPER[model_name.lower()]
|
||||
logger.warning_once(
|
||||
|
|
|
|||
|
|
@ -67,6 +67,7 @@ __INT_TO_FLOAT_MAPPER = \
|
|||
"codellama/CodeLlama-7b-hf",
|
||||
),
|
||||
"unsloth/codellama-13b-bnb-4bit" : (
|
||||
"unsloth/codellama-13b",
|
||||
"codellama/CodeLlama-13b-hf",
|
||||
),
|
||||
"unsloth/yi-6b-bnb-4bit" : (
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue