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

[BUG] tensorflow-estimator is removed from tensorflow 2.16.1 #2072

Open
SimonYansenZhao opened this issue Mar 19, 2024 · 4 comments
Open

[BUG] tensorflow-estimator is removed from tensorflow 2.16.1 #2072

SimonYansenZhao opened this issue Mar 19, 2024 · 4 comments
Labels
bug Something isn't working

Comments

@SimonYansenZhao
Copy link
Collaborator

Description

As mentioned in TensorFlow's release note for version 2.16.1, the breaking change that removes tensorflow-estimator is complete in TensorFlow 2.16.1. All code using TF estimator in Recommenders needs to change.

In which platform does it happen?

TensorFlow

How do we replicate the issue?

Expected behavior (i.e. solution)

Other Comments

@daviddavo
Copy link
Collaborator

This is needed to update to Python 3.12

I don't know anything about tensorflow and I'm having problems solving this issue. If someone can and wants to help, I did a mini-guide on the problem.

@miguelgfierro
Copy link
Collaborator

@daviddavo it would be good to know exactly what code is affected. Maybe there is a way to change these piece of code to change it. Also, we need to consider that we have some algos that we are going to change by a PyTorch version see #2111

@daviddavo
Copy link
Collaborator

Basically, the entirety of the wide_deep_utils.py file.

I haven't really used tensorflow, so I don't know exactly how it works, but this doesn't seem to be a minor change as it needs a complete refactoring to use tf.keras. For example, tf.estimator.RunConfig doesn't exist anymore and you need to create some callbacks: one for saving checkpoints, one for logging, etc. that may or may not be already available in the library. Each of the three models (wide, deep and wide-deep) would also need to be redone using tf.keras models.

The functions used by wide_deep but defined in tf_utils.py. There are some functions that would need to be created, and others that would be deleted:

Perhaps using keras 3 (backend agnostic) or Pytorch would take a similar effort to migrating to tf.keras.

@miguelgfierro
Copy link
Collaborator

If only wide and deep is affected, would it be easier to replace it with PyTorch? Here's an implementation: https://www.kaggle.com/code/matanivanov/wide-deep-learning-for-recsys-with-pytorch

I think TF W&D was done by @loomlike. What do you suggest?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants