• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright 2015 The TensorFlow Authors. All Rights Reserved.
2#
3# Licensed under the Apache License, Version 2.0 (the "License");
4# you may not use this file except in compliance with the License.
5# You may obtain a copy of the License at
6#
7#     http://www.apache.org/licenses/LICENSE-2.0
8#
9# Unless required by applicable law or agreed to in writing, software
10# distributed under the License is distributed on an "AS IS" BASIS,
11# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12# See the License for the specific language governing permissions and
13# limitations under the License.
14# ==============================================================================
15
16"""TensorFlow versions."""
17
18from __future__ import absolute_import
19from __future__ import division
20from __future__ import print_function
21
22from tensorflow.python import pywrap_tensorflow
23from tensorflow.python.util.tf_export import tf_export
24
25__version__ = pywrap_tensorflow.__version__
26__git_version__ = pywrap_tensorflow.__git_version__
27__compiler_version__ = pywrap_tensorflow.__compiler_version__
28__cxx11_abi_flag__ = pywrap_tensorflow.__cxx11_abi_flag__
29__monolithic_build__ = pywrap_tensorflow.__monolithic_build__
30
31VERSION = __version__
32tf_export(
33    "version.VERSION",
34    "__version__",
35    v1=["version.VERSION", "VERSION", "__version__"]).export_constant(
36        __name__, "VERSION")
37GIT_VERSION = __git_version__
38tf_export(
39    "version.GIT_VERSION",
40    "__git_version__",
41    v1=["version.GIT_VERSION", "GIT_VERSION",
42        "__git_version__"]).export_constant(__name__, "GIT_VERSION")
43COMPILER_VERSION = __compiler_version__
44tf_export(
45    "version.COMPILER_VERSION",
46    "__compiler_version__",
47    v1=["version.COMPILER_VERSION", "COMPILER_VERSION",
48        "__compiler_version__"]).export_constant(__name__, "COMPILER_VERSION")
49
50CXX11_ABI_FLAG = __cxx11_abi_flag__
51tf_export(
52    "sysconfig.CXX11_ABI_FLAG",
53    "__cxx11_abi_flag__",
54    v1=["sysconfig.CXX11_ABI_FLAG", "CXX11_ABI_FLAG",
55        "__cxx11_abi_flag__"]).export_constant(__name__, "CXX11_ABI_FLAG")
56MONOLITHIC_BUILD = __monolithic_build__
57tf_export(
58    "sysconfig.MONOLITHIC_BUILD",
59    "__monolithic_build__",
60    v1=[
61        "sysconfig.MONOLITHIC_BUILD", "MONOLITHIC_BUILD", "__monolithic_build__"
62    ]).export_constant(__name__, "MONOLITHIC_BUILD")
63
64GRAPH_DEF_VERSION = pywrap_tensorflow.GRAPH_DEF_VERSION
65tf_export(
66    "version.GRAPH_DEF_VERSION",
67    v1=["version.GRAPH_DEF_VERSION", "GRAPH_DEF_VERSION"]).export_constant(
68        __name__, "GRAPH_DEF_VERSION")
69GRAPH_DEF_VERSION_MIN_CONSUMER = (
70    pywrap_tensorflow.GRAPH_DEF_VERSION_MIN_CONSUMER)
71tf_export(
72    "version.GRAPH_DEF_VERSION_MIN_CONSUMER",
73    v1=[
74        "version.GRAPH_DEF_VERSION_MIN_CONSUMER",
75        "GRAPH_DEF_VERSION_MIN_CONSUMER"
76    ]).export_constant(__name__, "GRAPH_DEF_VERSION_MIN_CONSUMER")
77GRAPH_DEF_VERSION_MIN_PRODUCER = (
78    pywrap_tensorflow.GRAPH_DEF_VERSION_MIN_PRODUCER)
79tf_export(
80    "version.GRAPH_DEF_VERSION_MIN_PRODUCER",
81    v1=[
82        "version.GRAPH_DEF_VERSION_MIN_PRODUCER",
83        "GRAPH_DEF_VERSION_MIN_PRODUCER"
84    ]).export_constant(__name__, "GRAPH_DEF_VERSION_MIN_PRODUCER")
85
86__all__ = [
87    "__version__",
88    "__git_version__",
89    "__compiler_version__",
90    "__cxx11_abi_flag__",
91    "__monolithic_build__",
92    "COMPILER_VERSION",
93    "CXX11_ABI_FLAG",
94    "GIT_VERSION",
95    "GRAPH_DEF_VERSION",
96    "GRAPH_DEF_VERSION_MIN_CONSUMER",
97    "GRAPH_DEF_VERSION_MIN_PRODUCER",
98    "VERSION",
99    "MONOLITHIC_BUILD",
100]
101