Inline the trivial _build_model_config wrapper (#25448)
This commit is contained in:
@@ -419,7 +419,7 @@ class ModelRunner(ModelRunnerKVCacheMixin):
|
|||||||
self.dflash_draft_num_layers = None
|
self.dflash_draft_num_layers = None
|
||||||
if self.spec_algorithm.is_eagle3() and not self.is_draft_worker:
|
if self.spec_algorithm.is_eagle3() and not self.is_draft_worker:
|
||||||
# load draft config
|
# load draft config
|
||||||
draft_model_config = self._build_model_config(
|
draft_model_config = ModelConfig.from_server_args(
|
||||||
server_args,
|
server_args,
|
||||||
model_path=(server_args.speculative_draft_model_path),
|
model_path=(server_args.speculative_draft_model_path),
|
||||||
model_revision=server_args.speculative_draft_model_revision,
|
model_revision=server_args.speculative_draft_model_revision,
|
||||||
@@ -448,7 +448,7 @@ class ModelRunner(ModelRunnerKVCacheMixin):
|
|||||||
)
|
)
|
||||||
|
|
||||||
# Select target layers to capture for building DFlash context features.
|
# Select target layers to capture for building DFlash context features.
|
||||||
draft_model_config = self._build_model_config(
|
draft_model_config = ModelConfig.from_server_args(
|
||||||
server_args,
|
server_args,
|
||||||
model_path=(server_args.speculative_draft_model_path),
|
model_path=(server_args.speculative_draft_model_path),
|
||||||
model_revision=server_args.speculative_draft_model_revision,
|
model_revision=server_args.speculative_draft_model_revision,
|
||||||
@@ -568,16 +568,6 @@ class ModelRunner(ModelRunnerKVCacheMixin):
|
|||||||
self._model_update_group = {}
|
self._model_update_group = {}
|
||||||
self._weights_send_group = {}
|
self._weights_send_group = {}
|
||||||
|
|
||||||
def _build_model_config(
|
|
||||||
self, server_args, model_path=None, model_revision=None, is_draft_model=False
|
|
||||||
):
|
|
||||||
return ModelConfig.from_server_args(
|
|
||||||
server_args,
|
|
||||||
model_path=model_path,
|
|
||||||
model_revision=model_revision,
|
|
||||||
is_draft_model=is_draft_model,
|
|
||||||
)
|
|
||||||
|
|
||||||
def init_msprobe(self):
|
def init_msprobe(self):
|
||||||
# Init the msprobe
|
# Init the msprobe
|
||||||
try:
|
try:
|
||||||
|
|||||||
Reference in New Issue
Block a user