tensorflow / tensorflow/recommenders

Various warnings in model from tutorial example.

Open
#188 1 comment 4 reactions 1 assignee View on GitHub

@maciejkula is already working on this.

Since Dec 21, 2020.

question
Dominant language
Python
Stars
2k
Forks
300
PR merge metrics
No merged PRs in 30d

Description

Hi!

First big thanks on this project - seems very nice so far!

Just a quick one, I am seeing 3 warning when following the examples from the tutorials, they do not seem to affect the model in any obvious way, but I think it would be good to get them fixed up:

1. Layers in a Sequential model should only have a single input tensor

WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'url': <tf.Tensor 'IteratorGetNext:2' shape=(None,) dtype=string>, 'text': <tf.Tensor 'IteratorGetNext:1' shape=(None,) dtype=string>}
Consider rewriting this model with the Functional API

2. dtype of the source tensor

WARNING:tensorflow:The dtype of the source tensor must be floating (e.g. tf.float32) when calling GradientTape.gradient, got tf.int32

3. Gradients do not exist for variables

WARNING:tensorflow:Gradients do not exist for variables ['counter:0'] when minimizing the loss.

If I get to the bottom of any of these issues I will be sure to report / PR.

Cheers!

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.