Skip to content

Commit

Permalink
fix import error
Browse files Browse the repository at this point in the history
  • Loading branch information
davebulaval committed Nov 14, 2023
1 parent 03f4629 commit 217abbc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/training/metrics/model_salience.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import torch
from transformers import AutoTokenizer, AutoModelForMaskedLM

import utils_masking
from utils_masking import NonStopMasker


def unfold(sent_toks, make_tensor=True):
Expand All @@ -27,7 +27,7 @@ def __init__(
if self.tokenizer.eos_token_id is None:
self.eos_token_id = 0

self.masking_model = utils_masking.NonStopMasker()
self.masking_model = NonStopMasker()
self.masking_model.register_tokenizer(self.tokenizer)

self.vocab_size = self.tokenizer.vocab_size
Expand Down

0 comments on commit 217abbc

Please sign in to comment.