Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions tensorflow/tensorflow_estimator_integration.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
"""

import shutil
import sys
import tempfile
import urllib

Expand Down Expand Up @@ -133,4 +134,11 @@ def main():


if __name__ == "__main__":
if sys.version_info >= (3, 12):
raise RuntimeError(
"Use `optuna_integration.KerasPruningCallback` instead, "
"because TensorFlow recommends migrating from Estimator to Keras APIs. "
"For more details, please check the TensorFlow migration guide: "
"https://www.tensorflow.org/guide/migrate/migrating_estimator"
)
main()
7 changes: 7 additions & 0 deletions tensorflow/tensorflow_estimator_simple.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
"""

import shutil
import sys
import tempfile
import urllib

Expand Down Expand Up @@ -123,4 +124,10 @@ def main():


if __name__ == "__main__":
if sys.version_info >= (3, 12):
raise RuntimeError(
"Use Keras APIs instead of Estimator API in TensorFlow. "
"For more details, please check the TensorFlow migration guide: "
"https://www.tensorflow.org/guide/migrate/migrating_estimator"
)
main()