From 3a00674cbf34d22a3ce23a13492f98b30482a13c Mon Sep 17 00:00:00 2001 From: thomwolf Date: Thu, 27 Jun 2019 17:18:46 +0200 Subject: [PATCH] fix imports --- examples/run_bert_classifier.py | 2 +- examples/run_bert_squad.py | 2 +- examples/run_xlnet_classifier.py | 2 +- examples/run_xlnet_squad.py | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/examples/run_bert_classifier.py b/examples/run_bert_classifier.py index 8bb37159d3..d987b35321 100644 --- a/examples/run_bert_classifier.py +++ b/examples/run_bert_classifier.py @@ -34,7 +34,7 @@ from torch.nn import CrossEntropyLoss, MSELoss from tensorboardX import SummaryWriter -from pytorch_pretrained_bert.file_utils import WEIGHTS_NAME, CONFIG_NAME +from pytorch_pretrained_bert import WEIGHTS_NAME, CONFIG_NAME from pytorch_pretrained_bert.modeling import BertForSequenceClassification from pytorch_pretrained_bert.tokenization import BertTokenizer from pytorch_pretrained_bert.optimization import BertAdam, WarmupLinearSchedule diff --git a/examples/run_bert_squad.py b/examples/run_bert_squad.py index 9aaa711c2b..54eceb36f7 100644 --- a/examples/run_bert_squad.py +++ b/examples/run_bert_squad.py @@ -33,7 +33,7 @@ from tqdm import tqdm, trange from tensorboardX import SummaryWriter -from pytorch_pretrained_bert.file_utils import WEIGHTS_NAME, CONFIG_NAME +from pytorch_pretrained_bert import WEIGHTS_NAME, CONFIG_NAME from pytorch_pretrained_bert.modeling import BertForQuestionAnswering from pytorch_pretrained_bert.optimization import BertAdam, WarmupLinearSchedule from pytorch_pretrained_bert.tokenization import BertTokenizer diff --git a/examples/run_xlnet_classifier.py b/examples/run_xlnet_classifier.py index 2309815981..fb5501e370 100644 --- a/examples/run_xlnet_classifier.py +++ b/examples/run_xlnet_classifier.py @@ -34,7 +34,7 @@ from torch.nn import CrossEntropyLoss, MSELoss from tensorboardX import SummaryWriter -from pytorch_pretrained_bert.file_utils import WEIGHTS_NAME, CONFIG_NAME +from pytorch_pretrained_bert import WEIGHTS_NAME, CONFIG_NAME from pytorch_pretrained_bert.modeling_xlnet import XLNetForSequenceClassification from pytorch_pretrained_bert.tokenization_xlnet import XLNetTokenizer from pytorch_pretrained_bert.optimization import BertAdam, WarmupLinearSchedule diff --git a/examples/run_xlnet_squad.py b/examples/run_xlnet_squad.py index 927668c57a..c299358b79 100644 --- a/examples/run_xlnet_squad.py +++ b/examples/run_xlnet_squad.py @@ -33,7 +33,7 @@ from tqdm import tqdm, trange from tensorboardX import SummaryWriter -from pytorch_pretrained_bert.file_utils import WEIGHTS_NAME, CONFIG_NAME +from pytorch_pretrained_bert import WEIGHTS_NAME, CONFIG_NAME from pytorch_pretrained_bert.modeling_xlnet import BertForQuestionAnswering from pytorch_pretrained_bert.tokenization_xlnet import XLNetTokenizer from pytorch_pretrained_bert.optimization import BertAdam, WarmupLinearSchedule