Skip to content

Commit

Permalink
Merge pull request #5 from ezesalta/master
Browse files Browse the repository at this point in the history
Replace f-string to make it compatible with python 3.5
  • Loading branch information
charles9n committed Jun 26, 2019
2 parents 97e8846 + 7f3cf96 commit 3ffc072
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions bert_sklearn/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -99,9 +99,9 @@ def __init__(self, tokenizer=None, max_seq_length=64, train_sampler='random',
self.ignore_label_id = np.array(self.ignore_label_id)

def __repr__(self):
attrs = ["%s=%s"%(key, val) for key, val in vars(self).items()]
attrs = ",".join(attrs)
return f'{self.__class__.__name__}({attrs})'
attrs = ['{}={}'.format(key, val) for key, val in vars(self).items()]
attrs = ','.join(attrs)
return '{}({})'.format(self.__class__.__name__, attrs)


def model2config(model):
Expand Down

0 comments on commit 3ffc072

Please sign in to comment.