add alias for fluid.contrib.mixed_precision (#29562)

* add alias for fluid.contrib.mixed_precision
revert-31562-mean
huangxu96 4 years ago committed by GitHub
parent fb6697b424
commit c05170d3d8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -13,9 +13,14 @@
# limitations under the License.
from __future__ import print_function
from . import decorator
from .decorator import *
from .fp16_lists import AutoMixedPrecisionLists
from . import fp16_lists
from .fp16_lists import *
from . import fp16_utils
from .fp16_utils import *
__all__ = decorator.__all__
__all__ += fp16_lists.__all__
__all__ += fp16_utils.__all__

@ -20,6 +20,9 @@ from ... import global_scope
from ...log_helper import get_logger
import logging
import numpy as np
__all__ = ["cast_model_to_fp16", "cast_parameters_to_fp16"]
_logger = get_logger(
__name__, logging.INFO, fmt='%(asctime)s-%(levelname)s: %(message)s')

@ -0,0 +1,18 @@
# Copyright (c) 2020 PaddlePaddle Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
from ...fluid.contrib import mixed_precision
from ...fluid.contrib.mixed_precision import *
__all__ = mixed_precision.__all__
Loading…
Cancel
Save