Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 13 additions & 3 deletions vec_inf/client/_helper.py
Original file line number Diff line number Diff line change
Expand Up @@ -118,12 +118,22 @@ def _get_model_configuration(self, config_path: str | None = None) -> ModelConfi

model_weights_path = Path(model_weights_parent_dir, self.model_name)

# Only give a warning if weights exist but config missing
if self.kwargs.get("hf_model"):
return ModelConfig(
model_name=self.model_name,
model_family="model_family_placeholder",
model_type="LLM",
gpus_per_node=1,
num_nodes=1,
vocab_size=1000,
model_weights_parent_dir=Path(str(model_weights_parent_dir)),
)

if model_weights_path.exists():
self._warn(
f"Warning: '{self.model_name}' configuration not found in config, please ensure model configuration are properly set in command arguments",
f"Warning: '{self.model_name}' configuration not found in config, "
"please ensure model configuration are properly set in command arguments",
)
# Return a dummy model config object with model name and weights parent dir
return ModelConfig(
model_name=self.model_name,
model_family="model_family_placeholder",
Expand Down