Skip to content

Commit

Permalink
updated FireWordConfig
Browse files Browse the repository at this point in the history
  • Loading branch information
kduxin committed Dec 7, 2022
1 parent 8e40996 commit ef84a0c
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions firelang/models/_fireword.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,14 +70,15 @@ def detect_device(self) -> torch.device:
return next(iter(self.parameters())).device


class FireWordConfig(dict):
class FireWordConfig:
dim: int
func: str
measure: str

def __init__(self, **kwargs):
dict.__init__(self, **kwargs)
self.__dict__ = self
def __init__(self, dim: int, func: str, measure: str):
self.dim = dim
self.func = func
self.measure = measure


class FireWord(FireEmbedding):
Expand Down

0 comments on commit ef84a0c

Please sign in to comment.