Skip to content
Merged
Show file tree
Hide file tree
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
8 changes: 4 additions & 4 deletions examples/custom_models/google_translate_model.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ def __init__(self, config) -> None:
self.model_definition_file_path = config.model_definition_file_path

self.model_info = ModelInfo(
model_name=config.model,
model_name=config.model_name,
model_sha="",
model_dtype=None,
model_size="",
Expand Down Expand Up @@ -132,14 +132,14 @@ def greedy_until(
dataset = GenerativeTaskDataset(requests=requests, num_dataset_splits=self.DATASET_SPLITS)
results = []

for _ in tqdm(
dataset.splits_start_end_iterator(),
for split in tqdm(
dataset.splits_iterator(),
total=dataset.num_dataset_splits,
desc="Splits",
position=0,
disable=False, # self.disable_tqdm,
):
for r in tqdm(dataset, desc="Batch", position=1, disable=False):
for r in tqdm(split, desc="Batch", position=1, disable=False):
# Extract source and target languages from task name
# Format is like "community|sdst-text_level:de-fr|0"
src_lang, tgt_lang = r.task_name.split("|")[1].split(":")[-1].split("-")
Expand Down
2 changes: 1 addition & 1 deletion src/lighteval/main_custom.py
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ def custom(
)

parallelism_manager = ParallelismManager.CUSTOM
model_config = CustomModelConfig(model=model_name, model_definition_file_path=model_definition_file_path)
model_config = CustomModelConfig(model_name=model_name, model_definition_file_path=model_definition_file_path)

pipeline_params = PipelineParameters(
launcher_type=parallelism_manager,
Expand Down
Loading