[go: up one dir, main page]

Skip to content

Commit

Permalink
Fix AttributeError when finish training
Browse files Browse the repository at this point in the history
  • Loading branch information
nguyenhoan1988 committed Jul 31, 2024
1 parent 3359b60 commit df16c54
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions gliner/model.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,10 @@ def __init__(self, config: GLiNERConfig,
else:
self.onnx_model = False

# to suppress an AttributeError when training
self._keys_to_ignore_on_save = None


def forward(self, *args, **kwargs):
"""Wrapper function for the model's forward pass."""
output = self.model(*args, **kwargs)
Expand Down

0 comments on commit df16c54

Please sign in to comment.