Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
norm
vllm
Commits
4f2ad111
Unverified
Commit
4f2ad111
authored
Feb 14, 2024
by
Philipp Moritz
Committed by
GitHub
Feb 14, 2024
Browse files
Fix DeciLM (#2883)
parent
d7afab6d
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
1 deletion
+5
-1
vllm/model_executor/models/decilm.py
vllm/model_executor/models/decilm.py
+5
-1
No files found.
vllm/model_executor/models/decilm.py
View file @
4f2ad111
...
...
@@ -28,6 +28,7 @@ from typing import Optional
import
torch
from
transformers
import
PretrainedConfig
from
vllm.config
import
LoRAConfig
from
vllm.model_executor.layers.linear
import
LinearMethodBase
from
vllm.model_executor.models.llama
import
LlamaForCausalLM
from
vllm.model_executor.weight_utils
import
(
default_weight_loader
,
...
...
@@ -56,10 +57,13 @@ class DeciLMForCausalLM(LlamaForCausalLM):
self
,
config
:
Optional
[
PretrainedConfig
]
=
None
,
linear_method
:
Optional
[
LinearMethodBase
]
=
None
,
lora_config
:
Optional
[
LoRAConfig
]
=
None
,
)
->
None
:
config
.
num_key_value_heads
=
max
(
config
.
num_key_value_heads_per_layer
)
delattr
(
config
,
"num_key_value_heads_per_layer"
)
super
().
__init__
(
config
=
config
,
linear_method
=
linear_method
)
super
().
__init__
(
config
=
config
,
linear_method
=
linear_method
,
lora_config
=
lora_config
)
def
load_weights
(
self
,
model_name_or_path
:
str
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment