Reorganize repo (#8580)
* Put models in subfolders * Styling * Fix imports in tests * More fixes in test imports * Sneaky hidden imports * Fix imports in doc files * More sneaky imports * Finish fixing tests * Fix examples * Fix path for copies * More fixes for examples * Fix dummy files * More fixes for example * More model import fixes * Is this why you're unhappy GitHub? * Fix imports in conver command
This commit is contained in:
@@ -2,18 +2,17 @@ import unittest
|
||||
|
||||
from numpy import ndarray
|
||||
|
||||
from transformers import TensorType, is_flax_available, is_torch_available
|
||||
from transformers import BertTokenizerFast, TensorType, is_flax_available, is_torch_available
|
||||
from transformers.testing_utils import require_flax, require_torch
|
||||
from transformers.tokenization_bert_fast import BertTokenizerFast
|
||||
|
||||
|
||||
if is_flax_available():
|
||||
from transformers.modeling_flax_bert import FlaxBertModel
|
||||
from transformers.models.bert.modeling_flax_bert import FlaxBertModel
|
||||
|
||||
if is_torch_available():
|
||||
import torch
|
||||
|
||||
from transformers.modeling_bert import BertModel
|
||||
from transformers.models.bert.modeling_bert import BertModel
|
||||
|
||||
|
||||
@require_flax
|
||||
|
||||
Reference in New Issue
Block a user