changed modeling_fx_utils.py to utils/fx.py for clarity (#12326)

Co-authored-by: Michael Benayoun <michael@huggingface.co>
This commit is contained in:
Michael Benayoun
2021-06-23 18:16:24 +02:00
committed by GitHub
parent 941b4442ba
commit 986ac03e37
2 changed files with 3 additions and 3 deletions

View File

@@ -11,7 +11,7 @@ from torch.fx.node import Argument
from transformers.file_utils import TORCH_FX_REQUIRED_VERSION, importlib_metadata, is_torch_fx_available from transformers.file_utils import TORCH_FX_REQUIRED_VERSION, importlib_metadata, is_torch_fx_available
from . import ( from .. import (
MODEL_FOR_CAUSAL_LM_MAPPING, MODEL_FOR_CAUSAL_LM_MAPPING,
MODEL_FOR_IMAGE_CLASSIFICATION_MAPPING, MODEL_FOR_IMAGE_CLASSIFICATION_MAPPING,
MODEL_FOR_MASKED_LM_MAPPING, MODEL_FOR_MASKED_LM_MAPPING,
@@ -26,7 +26,7 @@ from . import (
PreTrainedModel, PreTrainedModel,
logging, logging,
) )
from .models.auto import get_values from ..models.auto import get_values
logger = logging.get_logger(__name__) logger = logging.get_logger(__name__)

View File

@@ -67,7 +67,7 @@ if is_torch_available():
) )
if is_torch_fx_available(): if is_torch_fx_available():
from transformers.modeling_fx_utils import symbolic_trace from transformers.utils.fx import symbolic_trace
def _config_zero_init(config): def _config_zero_init(config):