Skip to content

Commit

Permalink
update CLI due to changes in finetuner class
Browse files Browse the repository at this point in the history
  • Loading branch information
borauyar committed May 1, 2024
1 parent 4233946 commit 02a0906
Showing 1 changed file with 2 additions and 13 deletions.
15 changes: 2 additions & 13 deletions flexynesis/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -230,19 +230,8 @@ class AvailableModels(NamedTuple):

# fine tune on the finetuning dataset; freeze the encoders
finetuner = flexynesis.FineTuner(model,
finetune_dataset,
freeze_encoders=False)

for i in range(finetuner.n_splits):
trainer = pl.Trainer(max_epochs = 10,
devices = 1,
accelerator = device_type,
default_root_dir="./",
logger=False,
enable_checkpointing=False)
finetuner.current_fold = i
print(f"[INFO] Finetuning ... training fold {i+1}")
trainer.fit(finetuner)
finetune_dataset)
finetuner.run_experiments()

# update the model to finetuned model
model = finetuner.model
Expand Down

0 comments on commit 02a0906

Please sign in to comment.