from local

This commit is contained in:
dohe0342 2023-05-24 12:43:13 +09:00
parent 7c44951a40
commit 2ddec73e3a
3 changed files with 5 additions and 1 deletions

View File

@ -131,7 +131,11 @@ LRSchedulerType = Union[torch.optim.lr_scheduler._LRScheduler, optim.LRScheduler
class LoRAHook():
def __init__(self, module):
self.hook = module.register_forward_hook(self.hook_fn)
self.lora = LoRAModule(
embedding_dim=768,
rank=4,
lora_alpha=1.0,
)
def hook_fn(self, module, input, output):