Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade TensorFlow version to v2.16.1 #2282

Merged
merged 2 commits into from
Apr 2, 2024

Conversation

tenzen-y
Copy link
Member

@tenzen-y tenzen-y commented Mar 10, 2024

What this PR does / why we need it:
I upgraded the TensorFlow version to v2.16.1.
This is a blocker of #2278.

Which issue(s) this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged):
Fixes #

Checklist:

  • Docs included if any changes are user facing

@tenzen-y tenzen-y changed the title Upgrade TensorFlow version to v2.16.1 WIP: Upgrade TensorFlow version to v2.16.1 Mar 10, 2024
@tenzen-y
Copy link
Member Author

I found this isn't a blocker of #2278.

@tenzen-y tenzen-y force-pushed the upgrade-tf-version branch 2 times, most recently from 9261e36 to c939e6f Compare March 12, 2024 23:18
@tenzen-y tenzen-y changed the title WIP: Upgrade TensorFlow version to v2.16.1 Upgrade TensorFlow version to v2.16.1 Mar 12, 2024
@tenzen-y tenzen-y changed the title Upgrade TensorFlow version to v2.16.1 WIP: Upgrade TensorFlow version to v2.16.1 Mar 13, 2024
Signed-off-by: Yuki Iwai <yuki.iwai.tz@gmail.com>
…oach

Signed-off-by: Yuki Iwai <yuki.iwai.tz@gmail.com>
@google-oss-prow google-oss-prow bot added size/S and removed size/XS labels Mar 27, 2024
Comment on lines -79 to +83
augmentation = ImageDataGenerator(
width_shift_range=0.1,
height_shift_range=0.1,
horizontal_flip=True)
augmentation = tf.keras.Sequential([
Rescaling(1./255),
RandomFlip('horizontal'),
RandomTranslation(height_factor=0.1, width_factor=0.1),
])
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a deprecated approach and moved to `tensorflow.keras.preprocessing.image.

Traceback (most recent call last):
  File "/opt/enas-cnn-cifar10/RunTrial.py", line 19, in <module>
    from keras.preprocessing.image import ImageDataGenerator
ImportError: cannot import name 'ImageDataGenerator' from 'keras.preprocessing.image' (/usr/local/lib/python3.11/site-packages/keras/preprocessing/image/__init__.py)

https://www.tensorflow.org/api_docs/python/tf/keras/preprocessing/image/ImageDataGenerator

So, I introduced the recommended approach.

@tenzen-y tenzen-y changed the title WIP: Upgrade TensorFlow version to v2.16.1 Upgrade TensorFlow version to v2.16.1 Mar 27, 2024
@tenzen-y
Copy link
Member Author

/assign @kubeflow/wg-automl-leads

@tenzen-y
Copy link
Member Author

tenzen-y commented Apr 2, 2024

/assign @andreyvelich @johnugeorge

Copy link
Member

@andreyvelich andreyvelich left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the update @tenzen-y!
/lgtm
/approve

@google-oss-prow google-oss-prow bot added the lgtm label Apr 2, 2024
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: andreyvelich, tenzen-y

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:
  • OWNERS [andreyvelich,tenzen-y]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@google-oss-prow google-oss-prow bot merged commit 9680b8c into kubeflow:master Apr 2, 2024
60 checks passed
@tenzen-y tenzen-y deleted the upgrade-tf-version branch April 2, 2024 20:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants