url
stringlengths 63
63
| repository_url
stringclasses 1
value | labels_url
stringlengths 77
77
| comments_url
stringlengths 72
72
| events_url
stringlengths 70
70
| html_url
stringlengths 51
53
| id
int64 1.57B
2.35B
| node_id
stringlengths 18
19
| number
int64 59.5k
69.6k
| title
stringlengths 1
554
| user
dict | labels
listlengths 0
8
| state
stringclasses 2
values | locked
bool 2
classes | assignee
dict | assignees
listlengths 0
8
| milestone
null | comments
listlengths 0
30
| created_at
timestamp[s] | updated_at
timestamp[s] | closed_at
timestamp[s] | author_association
stringclasses 4
values | active_lock_reason
stringclasses 3
values | draft
bool 2
classes | pull_request
dict | body
stringlengths 1
65.4k
⌀ | reactions
dict | timeline_url
stringlengths 72
72
| performed_via_github_app
null | state_reason
stringclasses 3
values | is_pull_request
bool 2
classes |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
https://api.github.com/repos/tensorflow/tensorflow/issues/62890
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62890/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62890/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62890/events
|
https://github.com/tensorflow/tensorflow/pull/62890
| 2,116,615,862 |
PR_kwDOArmXAs5l7B92
| 62,890 |
Fix a typo in tensorflow/tools/pip_package/setup.py
|
{
"login": "timotheeMM",
"id": 143833750,
"node_id": "U_kgDOCJK6lg",
"avatar_url": "https://avatars.githubusercontent.com/u/143833750?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/timotheeMM",
"html_url": "https://github.com/timotheeMM",
"followers_url": "https://api.github.com/users/timotheeMM/followers",
"following_url": "https://api.github.com/users/timotheeMM/following{/other_user}",
"gists_url": "https://api.github.com/users/timotheeMM/gists{/gist_id}",
"starred_url": "https://api.github.com/users/timotheeMM/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/timotheeMM/subscriptions",
"organizations_url": "https://api.github.com/users/timotheeMM/orgs",
"repos_url": "https://api.github.com/users/timotheeMM/repos",
"events_url": "https://api.github.com/users/timotheeMM/events{/privacy}",
"received_events_url": "https://api.github.com/users/timotheeMM/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 1169364259,
"node_id": "MDU6TGFiZWwxMTY5MzY0MjU5",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS",
"name": "size:XS",
"color": "adafea",
"default": false,
"description": "CL Change Size: Extra Small"
}
] |
closed
| false |
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).\n\nView this [failed invocation](https://github.com/tensorflow/tensorflow/pull/62890/checks?check_run_id=21186468501) of the CLA check for more information.\n\nFor the most up to date status, view the checks section at the bottom of the pull request.",
"Hi @timotheeMM, Please submit multiple typo fixes in a single PR as the CPU/GPU hours are wasted on CI. Hence, we do not encourage one liner grammatical changes as it is an expensive process. Thank you for your contribution!\r\n"
] | 2024-02-03T17:50:09 | 2024-02-05T06:04:08 | 2024-02-05T06:04:07 |
NONE
| null | false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62890",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62890",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62890.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62890.patch",
"merged_at": null
}
|
I fixed a typo in the setup.py file:
accomodate -> accommodate
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62890/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62890/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62889
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62889/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62889/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62889/events
|
https://github.com/tensorflow/tensorflow/issues/62889
| 2,116,421,960 |
I_kwDOArmXAs5-JglI
| 62,889 |
Batch Shape inside customized train_step of keras subclassed model is None
|
{
"login": "claCase",
"id": 36463823,
"node_id": "MDQ6VXNlcjM2NDYzODIz",
"avatar_url": "https://avatars.githubusercontent.com/u/36463823?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/claCase",
"html_url": "https://github.com/claCase",
"followers_url": "https://api.github.com/users/claCase/followers",
"following_url": "https://api.github.com/users/claCase/following{/other_user}",
"gists_url": "https://api.github.com/users/claCase/gists{/gist_id}",
"starred_url": "https://api.github.com/users/claCase/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/claCase/subscriptions",
"organizations_url": "https://api.github.com/users/claCase/orgs",
"repos_url": "https://api.github.com/users/claCase/repos",
"events_url": "https://api.github.com/users/claCase/events{/privacy}",
"received_events_url": "https://api.github.com/users/claCase/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 1097546578,
"node_id": "MDU6TGFiZWwxMDk3NTQ2NTc4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:keras",
"name": "comp:keras",
"color": "0052cc",
"default": false,
"description": "Keras related issues"
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
closed
| false |
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi, for me this is not a bug at all here my explanation:\r\n\r\nDuring the training process in TensorFlow, the batch dimension is usually automatically removed before passing the data to the train_step method. In my opinion and this is part of the internal functionality of the TensorFlow facilitate the deployment of custom models, this make models more flexible and can be used with different amounts of data at each training step.\r\n\r\n\r\nI have assumed this behavior from the tensor docu and the following argument:\r\n* dynamic_batch: Whether to set the batch sizes of all the returned tf.TensorSpec to None. (Note that when defining functional or Sequential models with tf.keras.Input([...], batch_size=X), the batch size will always be preserved). Defaults to True.\r\n\r\nIf I'm wrong please make me know since I would also like to learn.",
"Hi @danielreyes9756, you are right, this is the intentional API behaviour. \r\nI've better identified the issue. I'm trying to sample a random vector from a tensorflow_probability distribution. If we follow the example at the docs for a [custom train step](https://github.com/keras-team/keras-io/blob/6623a072e7eef484c3defa44dc16d824eac434cb/guides/custom_train_step_in_tensorflow.py#L377C1-L384C10) tf.shape(inputs)[0] is used to get the batch dimension and sample a random vector from keras.backend.random_normal, and in the example below it outputs the right dimensions (None, dim1). \r\n\r\nHowever if we use a Normal distribution from tensorflow_probability we:\r\n1) Cannot use tf.shape(inputs)[0] as it is a 'tensorflow.python.framework.ops.SymbolicTensor' class, and therfore we must use inputs.shape[0]\r\n2) Cannot sample from a (None, 2) input shape, since we get the following:\r\nValueError: Attempt to convert a value (None) with an unsupported type (<class 'NoneType'>) to a Tensor.\r\n\r\n\r\nI've updated the code example to better show case the issue:\r\n\r\n```python\r\nimport tensorflow as tf \r\nimport tensorflow_probability.python.distributions as tfd \r\n\r\nclass cl(tf.keras.layers.Layer):\r\n def __init__(self):\r\n super().__init__()\r\n\r\n def build(self, input_shape):\r\n super().build(input_shape)\r\n self.normal = tfd.Normal(loc=[1.] * input_shape[-1], scale=[1.] * input_shape[-1])\r\n\r\n def call(self, inputs, *args):\r\n batch_shape = inputs.shape[0]\r\n return self.normal.sample(tf.TensorShape((batch_shape, 2)))\r\n\r\n\r\nclass cm(tf.keras.models.Model):\r\n def __init__(self, **kwargs):\r\n super().__init__(**kwargs)\r\n self.normal = cl()\r\n\r\n def call(self, inputs, *args):\r\n print(f\"tf.shape: {tf.shape(inputs)}, inputs.shape:{inputs.shape}\")\r\n sample = self.normal(inputs)\r\n return sample\r\n\r\n def train_step(self, data):\r\n B = tf.shape(data)[0]\r\n B2 = data.shape[0]\r\n rnd = keras.backend.random_normal(shape=(B, 2))\r\n print(f\"random normal from keras.backend shape: {rnd.shape}\")\r\n ta = tf.TensorArray(dtype=tf.float32, size=100, element_shape=tf.TensorShape((B2, 1)))\r\n sample = self(data) # Error\r\n return {\"loss\":1}\r\n\r\ninputs = tf.random.normal(shape=(100, 10, 2))\r\nc0 = cm()\r\nc0.compile(\"adam\")\r\nc0.fit(tf.constant(inputs),epochs=1)\r\n```\r\n\r\nwhich outputs: \r\n```console\r\nrandom normal from keras.backend shape: (None, 2)\r\ntf.shape: Tensor(\"cm_35/Shape:0\", shape=(3,), dtype=int32), inputs.shape:(None, 10, 2)\r\n\r\nValueError: Cannot convert a partially known TensorShape to a Tensor: (None, 2)\r\n```\r\n\r\nI think this issue may best be opened on the tfp repo. ",
"Hi @claCase, thanks for the answer and for your effort!\r\n\r\nI think it's impressive how you found this!\r\n\r\nbest regards,\r\nReyes",
"Hi @danielreyes9756 , thanks for the kind words.\r\nI think I may have found the culprit in the [Tensorflow Probability Distribution Class](https://github.com/tensorflow/probability/blob/230463ad39a4a089965a9ab1aeb5ac3de7ff398c/tensorflow_probability/python/distributions/distribution.py#L736C1-L739C31). Tensors must be statically defined, and a shape of None type can't be automatically inferred. I don't think there's a solution to this issue, the only solution would be to create a custom fit function... I'm still opening a new issue to get more insights in the tfp repo. ",
"@claCase,\r\nAs mentioned above, this looks like the intended behaviour. The batch dimension is automatically removed before passing the data to the **train_step** method. Also it is mentioned in the tf.keras.Sequential official document. [Reference](https://www.tensorflow.org/api_docs/python/tf/keras/Sequential)\r\n\r\nAlso as you mentioned above, the issue related to tensorflow probabilty will discuss and resolved in this respective [repo](https://github.com/tensorflow/probability/issues).\r\n\r\nThank you!\r\n\r\n\r\n ",
"Hi @tilakrayal \r\nI've opened [the issue](https://github.com/tensorflow/probability/issues/1786) under the tfp repo, this issue can be closed, \r\nThank you",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62889\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62889\">No</a>\n",
"I solved the issue by passing the batch_size parameter to the fit function\r\n```python\r\nc0.fit(tf.constant(inputs),epochs=1, batch_size=10)\r\n```"
] | 2024-02-03T10:50:34 | 2024-02-05T15:39:14 | 2024-02-05T10:54:16 |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
No
### Source
source
### TensorFlow version
tf 2.15
### Custom code
Yes
### OS platform and distribution
Windows WSL
### Mobile device
_No response_
### Python version
3.11
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
I'm trying to get the full input shape inside the train_step function of a subclassed keras model. When using tf.shape(inputs) will output the rank of the tensor, when using inputs.shape will output (None, d1, d2, ...).
This issue is similar to #36991 and #38155 .
### Standalone code to reproduce the issue
```python
import tensorflow as tf
class cm(tf.keras.models.Model):
def __init__(self, **kwargs):
super().__init__(**kwargs)
@tf.function
def call(self, inputs, *args):
print(f"tf.shape: {tf.shape(inputs)}, inputs.shape:{inputs.shape}")
return inputs
@tf.function
def train_step(self, data):
print(tf.shape(data), data.shape)
return {"loss":1}
inputs = tf.random.normal(shape=(100, 10, 1))
c0 = cm()
_ = c0(inputs)
c0.compile("adam")
c0.fit(tf.constant(inputs),epochs=1)
```
### Relevant log output
```shell
Inside call function:
tf.shape: Tensor("Shape:0", shape=(3,), dtype=int32), inputs.shape:(100, 10, 1)
Inside train_step:
Tensor("Shape:0", shape=(3,), dtype=int32) (None, 10, 1)
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62889/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62889/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62888
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62888/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62888/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62888/events
|
https://github.com/tensorflow/tensorflow/issues/62888
| 2,115,489,527 |
I_kwDOArmXAs5-F873
| 62,888 |
PReLU Op Builtin Kernel gives NaN output
|
{
"login": "jamwar01",
"id": 70524219,
"node_id": "MDQ6VXNlcjcwNTI0MjE5",
"avatar_url": "https://avatars.githubusercontent.com/u/70524219?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/jamwar01",
"html_url": "https://github.com/jamwar01",
"followers_url": "https://api.github.com/users/jamwar01/followers",
"following_url": "https://api.github.com/users/jamwar01/following{/other_user}",
"gists_url": "https://api.github.com/users/jamwar01/gists{/gist_id}",
"starred_url": "https://api.github.com/users/jamwar01/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/jamwar01/subscriptions",
"organizations_url": "https://api.github.com/users/jamwar01/orgs",
"repos_url": "https://api.github.com/users/jamwar01/repos",
"events_url": "https://api.github.com/users/jamwar01/events{/privacy}",
"received_events_url": "https://api.github.com/users/jamwar01/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
},
{
"id": 750616506,
"node_id": "MDU6TGFiZWw3NTA2MTY1MDY=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite",
"name": "comp:lite",
"color": "0052cc",
"default": false,
"description": "TF Lite related issues"
},
{
"id": 5922361893,
"node_id": "LA_kwDOArmXAs8AAAABYQASJQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF2.14",
"name": "TF2.14",
"color": "b60205",
"default": false,
"description": "For issues related to Tensorflow 2.14.x"
}
] |
closed
| false |
{
"login": "LakshmiKalaKadali",
"id": 149650845,
"node_id": "U_kgDOCOt9nQ",
"avatar_url": "https://avatars.githubusercontent.com/u/149650845?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/LakshmiKalaKadali",
"html_url": "https://github.com/LakshmiKalaKadali",
"followers_url": "https://api.github.com/users/LakshmiKalaKadali/followers",
"following_url": "https://api.github.com/users/LakshmiKalaKadali/following{/other_user}",
"gists_url": "https://api.github.com/users/LakshmiKalaKadali/gists{/gist_id}",
"starred_url": "https://api.github.com/users/LakshmiKalaKadali/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/LakshmiKalaKadali/subscriptions",
"organizations_url": "https://api.github.com/users/LakshmiKalaKadali/orgs",
"repos_url": "https://api.github.com/users/LakshmiKalaKadali/repos",
"events_url": "https://api.github.com/users/LakshmiKalaKadali/events{/privacy}",
"received_events_url": "https://api.github.com/users/LakshmiKalaKadali/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "LakshmiKalaKadali",
"id": 149650845,
"node_id": "U_kgDOCOt9nQ",
"avatar_url": "https://avatars.githubusercontent.com/u/149650845?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/LakshmiKalaKadali",
"html_url": "https://github.com/LakshmiKalaKadali",
"followers_url": "https://api.github.com/users/LakshmiKalaKadali/followers",
"following_url": "https://api.github.com/users/LakshmiKalaKadali/following{/other_user}",
"gists_url": "https://api.github.com/users/LakshmiKalaKadali/gists{/gist_id}",
"starred_url": "https://api.github.com/users/LakshmiKalaKadali/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/LakshmiKalaKadali/subscriptions",
"organizations_url": "https://api.github.com/users/LakshmiKalaKadali/orgs",
"repos_url": "https://api.github.com/users/LakshmiKalaKadali/repos",
"events_url": "https://api.github.com/users/LakshmiKalaKadali/events{/privacy}",
"received_events_url": "https://api.github.com/users/LakshmiKalaKadali/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"@jamwar01 The simplest solution is to use the BUILTIN_REF kernels instead of the BUILTIN kernels. BUILTIN_REF kernels are reference implementations and often slower, but they shouldn't produce NaN outputs in this case. Here's how to switch:\r\n```\r\nconverter.target_spec.supported_ops = [tf.lite.OpsSet.TFLITE_BUILTIN_REF]\r\n\r\n```\r\nThank you!",
"Thank you for your reply! 😄 \r\nYes, the workaround for now is to use the reference kernels like you say. \r\nMy aim was to just report that the builtin kernels appear to be broken so that this is highlighted to the relevant team. The decrease in performance from using the reference kernels is likely a deterrent in many cases, however, so I believe it would be useful to have this addressed.",
"Hi @jamwar01,\r\n\r\nI have tested the given code with BUILTIN kernels in TF 2.15 version. It is working fine and the output tensor is not giving any Nan values. \r\nHere is the screenshot.\r\n\r\n\r\nand the output tensor values are\r\n```\r\narray([[[[0.18350317, 0.8055407 , 0.08095651, ..., 0.09189863,\r\n 0.64712274, 0.42581546],\r\n [0.06950494, 0.19689496, 0.945694 , ..., 0.96190053,\r\n 0.8043054 , 0.6203221 ],\r\n [0.50733095, 0.00871299, 0.7729663 , ..., 0.3727163 ,\r\n 0.2478801 , 0.4909967 ],\r\n ...,\r\n [0.7556198 , 0.86681217, 0.07057429, ..., 0.4914943 ,\r\n 0.46564332, 0.7217616 ],\r\n [0.4533622 , 0.08109082, 0.6991882 , ..., 0.2784072 ,\r\n 0.73928165, 0.6248881 ],\r\n [0.06713927, 0.37988612, 0.6965632 , ..., 0.66882867,\r\n 0.22982682, 0.7331834 ]],\r\n\r\n [[0.6969852 , 0.3979096 , 0.30966353, ..., 0.8206956 ,\r\n 0.07177956, 0.0412529 ],\r\n [0.87058693, 0.46980223, 0.7791571 , ..., 0.08392384,\r\n 0.44429946, 0.41385922],\r\n [0.12787104, 0.06190566, 0.9563843 , ..., 0.66872364,\r\n 0.5529266 , 0.69724584],\r\n ...,\r\n [0.24671873, 0.8656299 , 0.64001596, ..., 0.5273241 ,\r\n 0.46549922, 0.01413841],\r\n [0.8001449 , 0.303727 , 0.41121402, ..., 0.42395937,\r\n 0.68907714, 0.9973794 ],\r\n [0.5249677 , 0.69011617, 0.32280397, ..., 0.29401043,\r\n 0.8321104 , 0.8224229 ]],\r\n\r\n [[0.46167508, 0.13801032, 0.41837 , ..., 0.76498574,\r\n 0.53632194, 0.6082858 ],\r\n [0.9040914 , 0.9073978 , 0.5598819 , ..., 0.77390254,\r\n 0.5010137 , 0.7959867 ],\r\n [0.9356298 , 0.838803 , 0.2510756 , ..., 0.27377617,\r\n 0.03432407, 0.8112841 ],\r\n ...,\r\n [0.19019738, 0.15415408, 0.15916935, ..., 0.36066476,\r\n 0.02571733, 0.88389844],\r\n [0.05659891, 0.00807601, 0.35056975, ..., 0.99356574,\r\n 0.0229959 , 0.17586842],\r\n [0.16265824, 0.9375197 , 0.04004565, ..., 0.90708274,\r\n 0.4906749 , 0.01150649]],\r\n\r\n ...,\r\n\r\n [[0.9874541 , 0.13711593, 0.03413203, ..., 0.27944687,\r\n 0.5725812 , 0.2872343 ],\r\n [0.93618304, 0.05400326, 0.80379486, ..., 0.6891535 ,\r\n 0.85990685, 0.09732993],\r\n [0.6015796 , 0.6119976 , 0.17900743, ..., 0.64661974,\r\n 0.47710946, 0.5185745 ],\r\n ...,\r\n [0.3314257 , 0.976641 , 0.50370747, ..., 0.18451059,\r\n 0.8898673 , 0.06551789],\r\n [0.7574596 , 0.6803014 , 0.5806643 , ..., 0.02810532,\r\n 0.21359259, 0.13841787],\r\n [0.360362 , 0.8378374 , 0.17994598, ..., 0.52578354,\r\n 0.8449946 , 0.00566057]],\r\n\r\n [[0.90867203, 0.96147287, 0.00522611, ..., 0.49788418,\r\n 0.51192576, 0.87039846],\r\n [0.8130206 , 0.3965184 , 0.5445026 , ..., 0.7833688 ,\r\n 0.3920826 , 0.5033432 ],\r\n [0.58092123, 0.22957331, 0.06166744, ..., 0.04113004,\r\n 0.3806144 , 0.66953444],\r\n ...,\r\n [0.2541557 , 0.7876428 , 0.74799436, ..., 0.8414788 ,\r\n 0.32410142, 0.25649405],\r\n [0.41616407, 0.41103885, 0.3102394 , ..., 0.3179237 ,\r\n 0.41209835, 0.86601245],\r\n [0.13197434, 0.9770973 , 0.576634 , ..., 0.8140475 ,\r\n 0.3756017 , 0.648409 ]],\r\n\r\n [[0.46594724, 0.38555008, 0.9656739 , ..., 0.3989894 ,\r\n 0.73881274, 0.696691 ],\r\n [0.42470434, 0.03731331, 0.5988427 , ..., 0.26365036,\r\n 0.183001 , 0.6578406 ],\r\n [0.4221254 , 0.62892705, 0.8580361 , ..., 0.4409532 ,\r\n 0.55401707, 0.39752722],\r\n ...,\r\n [0.84856015, 0.12720175, 0.12806697, ..., 0.4363036 ,\r\n 0.7615763 , 0.5988579 ],\r\n [0.20318006, 0.40418512, 0.9333598 , ..., 0.17719397,\r\n 0.97456586, 0.42055926],\r\n [0.2521532 , 0.32505414, 0.40645653, ..., 0.863737 ,\r\n 0.8764026 , 0.04436916]]]], dtype=float32)\r\n```\r\n\r\nPlease refer the [gist](https://colab.research.google.com/gist/LakshmiKalaKadali/8306bcb625e56ab887a06c97b161fc14/tflite_62888_prelu-op_nan.ipynb#scrollTo=pD6PjxTkSofS).\r\n\r\nThank You",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"I still have nan output when using my specific numpy input. Could you provide a method whereby I can transfer the faulty_input.npy to you? Its compressed size is 28MB which exceeds the 25MB limit set in this page. Thank you.",
"Hi @jamwar01 ,\r\n\r\nPlease share your `faulty_input.npy` through the google drive link.\r\n\r\nThank You",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62888\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62888\">No</a>\n"
] | 2024-02-02T18:03:25 | 2024-03-09T01:45:25 | 2024-03-09T01:45:23 |
CONTRIBUTOR
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
source
### TensorFlow version
tf 2.14
### Custom code
Yes
### OS platform and distribution
Linux Ubuntu 20.04.6 LTS
### Mobile device
_No response_
### Python version
3.11
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
Some output values in a PReLU output tensor are NaN when using TFLite Interpreter with BUILTIN kernels. No NaNs are seen when using BUILTIN_REF (reference) kernels, so this appears to only be an issue with builtin.
I would expect to see _similar_ values when using both builtin and reference kernels; and not see any NaNs.
### Standalone code to reproduce the issue
```shell
import tensorflow as tf
import numpy as np
def make_prelu_tflite():
model = tf.keras.Sequential(
[
tf.keras.Input((540, 960, 16), dtype=tf.float32),
tf.keras.layers.PReLU(shared_axes=(1,2,3))
]
)
# Imitate effect of training prelu weight
a = np.ndarray(shape=(1,1,1,1))
a[0][0][0][0] = 0.00040957872988656163
model.layers[0].set_weights(a)
# Convert and save the model
converter = tf.lite.TFLiteConverter.from_keras_model(model)
tflite_model = converter.convert()
with open(TFLITE_FILE, 'wb') as f:
f.write(tflite_model)
def run_tflite_inference(tflite_path, input_npy_path, out_npy_path):
# Using AUTO/BUILTIN resolver
interpreter = tf.lite.Interpreter(model_path=tflite_path)
input_details = interpreter.get_input_details()
output_details = interpreter.get_output_details()
interpreter.allocate_tensors()
input_npy = np.load(input_npy_path)
interpreter.set_tensor(input_details[0]['index'], input_npy)
interpreter.invoke()
output = interpreter.get_tensor(output_details[0]['index'])
print(f"Output has nan: {np.any(np.isnan(output))}")
print(f"Writing output to {out_npy_path}")
np.save(f"{out_npy_path}", output)
if __name__ == "__main__":
TFLITE_FILE = "simple_prelu.tflite"
NPY_INPUT_FILE = "faulty_input.npy"
NPY_OUTPUT_FILE = "faulty_output.npy"
make_prelu_tflite()
run_tflite_inference(TFLITE_FILE, NPY_INPUT_FILE, NPY_OUTPUT_FILE)
```
### Relevant log output
```shell
2024-02-02 17:50:30.399478: W tensorflow/compiler/mlir/lite/python/tf_tfl_flatbuffer_helpers.cc:378] Ignored output_format.
2024-02-02 17:50:30.399540: W tensorflow/compiler/mlir/lite/python/tf_tfl_flatbuffer_helpers.cc:381] Ignored drop_control_dependency.
2024-02-02 17:50:30.400359: I tensorflow/cc/saved_model/reader.cc:83] Reading SavedModel from: /tmp/tmp13mra4pw
2024-02-02 17:50:30.400605: I tensorflow/cc/saved_model/reader.cc:51] Reading meta graph with tags { serve }
2024-02-02 17:50:30.400619: I tensorflow/cc/saved_model/reader.cc:146] Reading SavedModel debug info (if present) from: /tmp/tmp13mra4pw
2024-02-02 17:50:30.401264: I tensorflow/compiler/mlir/mlir_graph_optimization_pass.cc:382] MLIR V1 optimization pass is not enabled
2024-02-02 17:50:30.401435: I tensorflow/cc/saved_model/loader.cc:233] Restoring SavedModel bundle.
2024-02-02 17:50:30.419847: I tensorflow/cc/saved_model/loader.cc:217] Running initialization op on SavedModel bundle at path: /tmp/tmp13mra4pw
2024-02-02 17:50:30.422643: I tensorflow/cc/saved_model/loader.cc:316] SavedModel load for tags { serve }; Status: success: OK. Took 22284 microseconds.
2024-02-02 17:50:30.451273: I tensorflow/compiler/mlir/tensorflow/utils/dump_mlir_util.cc:269] disabling MLIR crash reproducer, set env var `MLIR_CRASH_REPRODUCER_DIRECTORY` to enable.
2024-02-02 17:50:30.507802: I tensorflow/compiler/mlir/lite/flatbuffer_export.cc:2245] Estimated count of arithmetic ops: 0 ops, equivalently 0 MACs
INFO: Created TensorFlow Lite XNNPACK delegate for CPU.
Output has nan: True
Writing output to faulty_output.npy
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62888/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62888/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62887
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62887/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62887/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62887/events
|
https://github.com/tensorflow/tensorflow/pull/62887
| 2,115,148,751 |
PR_kwDOArmXAs5l1_NY
| 62,887 |
Multiple func definitions with TFLITE_SINGLE_ROUNDING
|
{
"login": "stwykd",
"id": 5012027,
"node_id": "MDQ6VXNlcjUwMTIwMjc=",
"avatar_url": "https://avatars.githubusercontent.com/u/5012027?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/stwykd",
"html_url": "https://github.com/stwykd",
"followers_url": "https://api.github.com/users/stwykd/followers",
"following_url": "https://api.github.com/users/stwykd/following{/other_user}",
"gists_url": "https://api.github.com/users/stwykd/gists{/gist_id}",
"starred_url": "https://api.github.com/users/stwykd/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/stwykd/subscriptions",
"organizations_url": "https://api.github.com/users/stwykd/orgs",
"repos_url": "https://api.github.com/users/stwykd/repos",
"events_url": "https://api.github.com/users/stwykd/events{/privacy}",
"received_events_url": "https://api.github.com/users/stwykd/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 390482148,
"node_id": "MDU6TGFiZWwzOTA0ODIxNDg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/awaiting%20review",
"name": "awaiting review",
"color": "bc3869",
"default": false,
"description": "Pull request awaiting review"
},
{
"id": 750616506,
"node_id": "MDU6TGFiZWw3NTA2MTY1MDY=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite",
"name": "comp:lite",
"color": "0052cc",
"default": false,
"description": "TF Lite related issues"
},
{
"id": 987666414,
"node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull",
"name": "ready to pull",
"color": "2cd643",
"default": false,
"description": "PR ready for merge process"
},
{
"id": 1169365494,
"node_id": "MDU6TGFiZWwxMTY5MzY1NDk0",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:M",
"name": "size:M",
"color": "adafea",
"default": false,
"description": "CL Change Size: Medium"
}
] |
closed
| false |
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).\n\nView this [failed invocation](https://github.com/tensorflow/tensorflow/pull/62887/checks?check_run_id=21158191124) of the CLA check for more information.\n\nFor the most up to date status, view the checks section at the bottom of the pull request."
] | 2024-02-02T15:09:39 | 2024-02-06T01:42:08 | 2024-02-06T01:42:08 |
CONTRIBUTOR
| null | false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62887",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62887",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62887.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62887.patch",
"merged_at": "2024-02-06T01:42:08"
}
|
When TFLITE_SINGLE_ROUNDING is set, there are multiple function definitions for MultiplyByQuantizedMultiplier.
It's defined in `tensorflow/lite/kernels/internal/common.cc` and `tensorflow/lite/kernels/internal/common.h`. The problem lies in that `common.h` defines MultiplyByQuantizedMultiplier when TFLITE_SINGLE_ROUNDING is set, and `common.cc` defines it without a guard.
Change-Id: I3713ce80a56fe0ac115bde5d3d5eab3d6bc288ac
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62887/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62887/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62886
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62886/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62886/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62886/events
|
https://github.com/tensorflow/tensorflow/issues/62886
| 2,114,891,383 |
I_kwDOArmXAs5-Dq53
| 62,886 |
tfgo Library not loaded: @rpath/libtensorflow.2.dylib in mac M1 (no LC_RPATH's found)
|
{
"login": "juancresc",
"id": 2141907,
"node_id": "MDQ6VXNlcjIxNDE5MDc=",
"avatar_url": "https://avatars.githubusercontent.com/u/2141907?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/juancresc",
"html_url": "https://github.com/juancresc",
"followers_url": "https://api.github.com/users/juancresc/followers",
"following_url": "https://api.github.com/users/juancresc/following{/other_user}",
"gists_url": "https://api.github.com/users/juancresc/gists{/gist_id}",
"starred_url": "https://api.github.com/users/juancresc/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/juancresc/subscriptions",
"organizations_url": "https://api.github.com/users/juancresc/orgs",
"repos_url": "https://api.github.com/users/juancresc/repos",
"events_url": "https://api.github.com/users/juancresc/events{/privacy}",
"received_events_url": "https://api.github.com/users/juancresc/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473173351,
"node_id": "MDU6TGFiZWw0NzMxNzMzNTE=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:build/install",
"name": "type:build/install",
"color": "159b2e",
"default": false,
"description": "Build and install issues"
},
{
"id": 1205765054,
"node_id": "MDU6TGFiZWwxMjA1NzY1MDU0",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/subtype:macOS",
"name": "subtype:macOS",
"color": "b619ea",
"default": false,
"description": "macOS Build/Installation issues"
},
{
"id": 5922361893,
"node_id": "LA_kwDOArmXAs8AAAABYQASJQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF2.14",
"name": "TF2.14",
"color": "b60205",
"default": false,
"description": "For issues related to Tensorflow 2.14.x"
}
] |
closed
| false |
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"adding more details\r\n```\r\n\r\n\r\nexport CGO_LDFLAGS=\"-L/usr/local/lib/ -Wl,-rpath,/usr/local/lib/\"\r\ngo run -ldflags='-X \"xx\" -X \"xxx\"' main.go\r\n\r\n# command-line-arguments\r\nld: warning: duplicate -rpath '/usr/local/lib/' ignored\r\nld: warning: duplicate -rpath '/usr/local/lib/' ignored\r\nld: warning: duplicate -rpath '/usr/local/lib/' ignored\r\ndyld[5000]: Symbol not found: __ZN3xla47_DynamicParameterBindingProto_default_instance_E\r\n Referenced from: <B1880BB8-E3E2-3229-A120-65EFD7CA6548> /usr/local/lib/libtensorflow.so.2\r\n Expected in: <6C0A9BF1-5231-3443-AC09-CE2C58D19879> /usr/local/lib/libtensorflow_framework.2.dylib\r\nsignal: abort trap\r\n\r\n```",
"@juancresc If you are building tfgo from source, make sure you've configured it for the ARM64 architecture (Apple M1) using the `--config=macos_arm64 `flag. If you are using a pre-built binary, please ensure it's specifically for Apple M1.\r\nThank you!",
"I am having the same issue with `tf v2.15.0` on `macos_arm64`. A simple [C code](https://www.tensorflow.org/install/lang_c#build) to display tf version builds and runs fine, however, I get following error when running with Go bindings:\r\n\r\n```\r\ndyld[1089]: Library not loaded: @rpath/libtensorflow.2.dylib\r\n Referenced from: <735FB3A4-830D-31BF-AA59-9D12C6A24D4C> /private/var/folders/jt/nqlsl9n94_d32kp9d544_blc0000gn/T/go-build4047475137/b121/attr.test\r\n Reason: no LC_RPATH's found\r\nsignal: abort trap\r\n```",
"It seems the issue is only when running `go test`. I was able to build an executable using Go bindings to TF and that runs fine on `macos_arm64` for TF v2.15.0",
"This is what I did to make it work. \r\n\r\n```\r\n#build with bazel\r\nbazel build -c opt //tensorflow/tools/lib_package:libtensorflow\r\n#replace .h files\r\nsudo cp -R bazel-bin/tensorflow/tools/lib_package/libtensorflow/include/tensorflow/ /usr/local/include/tensorflow\r\n#install with brew\r\nbrew install tensorflow && brew link tensorflow # just in case\r\n#use this\r\nexport CGO_LDFLAGS=\"-L/opt/homebrew/opt/tensorflow/lib -Wl,-rpath,/opt/homebrew/opt/tensorflow/lib\"\r\n# then you can \r\ngo run main.go\r\n```",
"@juancresc Could you please confirm if the issue has been resolved?\r\nThank you!",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62886\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62886\">No</a>\n"
] | 2024-02-02T13:08:02 | 2024-02-08T15:03:05 | 2024-02-08T15:03:02 |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
source
### TensorFlow version
v2.14.1
### Custom code
Yes
### OS platform and distribution
Apple M1 Pro 14.3
### Mobile device
_No response_
### Python version
3.7
### Bazel version
6.1.0
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
when I run my program that imports tensorflow-go
```
dyld[90744]: Library not loaded: @rpath/libtensorflow.2.dylib
Referenced from: <CDB4E269-8AC1-3314-9A48-AECF62A45D5B> /private/var/folders/7m/mnymf5ss1mz39ygdshyl69n40000gp/T/go-build3544199075/b001/exe/main
Reason: no LC_RPATH's found
signal: abort trap
```
### Standalone code to reproduce the issue
```shell
bazel build --config opt //tensorflow/tools/lib_package:libtensorflow //tensorflow:libtensorflow.so.2 //tensorflow:libtensorflow.so --macos_sdk_version=14.2
sudo cp bazel-bin/tensorflow/libtensorflow*.so /usr/local/lib/
sudo cp -R bazel-bin/tensorflow/tools/lib_package/libtensorflow/include/tensorflow/ /usr/local/include/tensorflow/
sudo tar -C /usr/local/lib -xzf bazel-bin/tensorflow/tools/lib_package/libtensorflow.tar.gz
```
### Relevant log output
_No response_
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62886/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62886/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62885
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62885/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62885/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62885/events
|
https://github.com/tensorflow/tensorflow/pull/62885
| 2,114,279,476 |
PR_kwDOArmXAs5ly_o2
| 62,885 |
Fixing the row_size in matmul_lib.py
|
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 1133285679,
"node_id": "MDU6TGFiZWwxMTMzMjg1Njc5",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:xla",
"name": "comp:xla",
"color": "0052cc",
"default": false,
"description": "XLA"
},
{
"id": 1169364259,
"node_id": "MDU6TGFiZWwxMTY5MzY0MjU5",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS",
"name": "size:XS",
"color": "adafea",
"default": false,
"description": "CL Change Size: Extra Small"
}
] |
closed
| false |
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi @cheshire Can you please review this PR? Thank you!",
"@cheshire,\r\nThank you for the update. I will try to raise the PR for the changes in openxla repo with the test case. "
] | 2024-02-02T07:19:58 | 2024-03-13T09:15:08 | 2024-03-13T09:15:05 |
CONTRIBUTOR
| null | false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62885",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62885",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62885.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62885.patch",
"merged_at": null
}
|
Fixing the row_size in matmul_lib.py
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62885/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62885/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62884
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62884/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62884/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62884/events
|
https://github.com/tensorflow/tensorflow/issues/62884
| 2,114,200,663 |
I_kwDOArmXAs5-BCRX
| 62,884 |
Performance differences from TFLite delegate and Apple CoreML API
|
{
"login": "TimYao18",
"id": 15173100,
"node_id": "MDQ6VXNlcjE1MTczMTAw",
"avatar_url": "https://avatars.githubusercontent.com/u/15173100?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/TimYao18",
"html_url": "https://github.com/TimYao18",
"followers_url": "https://api.github.com/users/TimYao18/followers",
"following_url": "https://api.github.com/users/TimYao18/following{/other_user}",
"gists_url": "https://api.github.com/users/TimYao18/gists{/gist_id}",
"starred_url": "https://api.github.com/users/TimYao18/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/TimYao18/subscriptions",
"organizations_url": "https://api.github.com/users/TimYao18/orgs",
"repos_url": "https://api.github.com/users/TimYao18/repos",
"events_url": "https://api.github.com/users/TimYao18/events{/privacy}",
"received_events_url": "https://api.github.com/users/TimYao18/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 750616506,
"node_id": "MDU6TGFiZWw3NTA2MTY1MDY=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite",
"name": "comp:lite",
"color": "0052cc",
"default": false,
"description": "TF Lite related issues"
},
{
"id": 1463677878,
"node_id": "MDU6TGFiZWwxNDYzNjc3ODc4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:performance",
"name": "type:performance",
"color": "159b2e",
"default": false,
"description": "Performance Issue"
},
{
"id": 1661751498,
"node_id": "MDU6TGFiZWwxNjYxNzUxNDk4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TFLiteConverter",
"name": "TFLiteConverter",
"color": "bfdadc",
"default": false,
"description": "For issues related to TFLite converter"
},
{
"id": 4989164736,
"node_id": "LA_kwDOArmXAs8AAAABKWCcwA",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/iOS",
"name": "iOS",
"color": "5E69E3",
"default": false,
"description": ""
}
] |
open
| false |
{
"login": "yishuangP",
"id": 6421220,
"node_id": "MDQ6VXNlcjY0MjEyMjA=",
"avatar_url": "https://avatars.githubusercontent.com/u/6421220?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/yishuangP",
"html_url": "https://github.com/yishuangP",
"followers_url": "https://api.github.com/users/yishuangP/followers",
"following_url": "https://api.github.com/users/yishuangP/following{/other_user}",
"gists_url": "https://api.github.com/users/yishuangP/gists{/gist_id}",
"starred_url": "https://api.github.com/users/yishuangP/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/yishuangP/subscriptions",
"organizations_url": "https://api.github.com/users/yishuangP/orgs",
"repos_url": "https://api.github.com/users/yishuangP/repos",
"events_url": "https://api.github.com/users/yishuangP/events{/privacy}",
"received_events_url": "https://api.github.com/users/yishuangP/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "yishuangP",
"id": 6421220,
"node_id": "MDQ6VXNlcjY0MjEyMjA=",
"avatar_url": "https://avatars.githubusercontent.com/u/6421220?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/yishuangP",
"html_url": "https://github.com/yishuangP",
"followers_url": "https://api.github.com/users/yishuangP/followers",
"following_url": "https://api.github.com/users/yishuangP/following{/other_user}",
"gists_url": "https://api.github.com/users/yishuangP/gists{/gist_id}",
"starred_url": "https://api.github.com/users/yishuangP/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/yishuangP/subscriptions",
"organizations_url": "https://api.github.com/users/yishuangP/orgs",
"repos_url": "https://api.github.com/users/yishuangP/repos",
"events_url": "https://api.github.com/users/yishuangP/events{/privacy}",
"received_events_url": "https://api.github.com/users/yishuangP/received_events",
"type": "User",
"site_admin": false
},
{
"login": "pkgoogle",
"id": 132095473,
"node_id": "U_kgDOB9-d8Q",
"avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/pkgoogle",
"html_url": "https://github.com/pkgoogle",
"followers_url": "https://api.github.com/users/pkgoogle/followers",
"following_url": "https://api.github.com/users/pkgoogle/following{/other_user}",
"gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}",
"starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions",
"organizations_url": "https://api.github.com/users/pkgoogle/orgs",
"repos_url": "https://api.github.com/users/pkgoogle/repos",
"events_url": "https://api.github.com/users/pkgoogle/events{/privacy}",
"received_events_url": "https://api.github.com/users/pkgoogle/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi @TimYao18, thanks for the data -- it is likely that they are able to optimize better due to internal knowledge of iOS, we would also like to understand this.\r\n\r\n@yishuangP can you please take a look? Thanks.",
"@TimYao18 FYR. \r\n\r\nbased on my previous experiences of using Core ML and Metal delegates on iOS devices (https://github.com/mlcommons/mobile_app_open):\r\n1. Core ML uses relatively old version of Core ML and ops supported by it are quite limited\r\n2. Metal delegate doesn't support all the ops either\r\n\r\nWith that, you are likely to run into ops not supported by them. That is, mostly not the ops are accelerated by either ANE or GPU.",
"Hi @TimYao18,\r\n\r\nI'm wondering what performance you would get with [AI-Edge-Torch](https://github.com/google-ai-edge/ai-edge-torch)?, you can find more information here: [googleblog](https://developers.googleblog.com/en/ai-edge-torch-high-performance-inference-of-pytorch-models-on-mobile-devices/).\r\n\r\nIf you want to, you can actually try visualizing the result in [model-explorer](https://github.com/google-ai-edge/model-explorer) as well.\r\n\r\nPlease try them out and let us know the result. If you still need further help, feel free to open a new issue at a relevant repo."
] | 2024-02-02T06:38:55 | 2024-06-11T21:54:09 | null |
NONE
| null | null | null |
The question is about the performance difference between TensorFlow Lite Delegate and the Apple Core ML API.
I test the same model that convert into TFLite and Core ML mlpackage. If the same model is a Core ML model and using Apple's Core ML API, it can be several times faster than using a TFLite model with TensorFlow Lite Delegate. I'd like to understand the differences and the reasons behind them.

### 1. System information
- iPhone 15 Pro MAX: iOS 17.3
- TensorFlow library: TensorFlowLiteSwift 0.0.1 nightly
### 2. Code
Please use TFLite's iOS benchmark tool
[https://github.com/tensorflow/tensorflow/tree/master/tensorflow/lite/tools/benchmark/ios](https://github.com/tensorflow/tensorflow/tree/master/tensorflow/lite/tools/benchmark/ios)
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62884/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62884/timeline
| null | null | false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62883
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62883/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62883/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62883/events
|
https://github.com/tensorflow/tensorflow/pull/62883
| 2,113,351,084 |
PR_kwDOArmXAs5lvxll
| 62,883 |
[oneDNN] Add oneDNN version of SparseMatrixMatMul
|
{
"login": "matthew-olson-intel",
"id": 87155110,
"node_id": "MDQ6VXNlcjg3MTU1MTEw",
"avatar_url": "https://avatars.githubusercontent.com/u/87155110?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/matthew-olson-intel",
"html_url": "https://github.com/matthew-olson-intel",
"followers_url": "https://api.github.com/users/matthew-olson-intel/followers",
"following_url": "https://api.github.com/users/matthew-olson-intel/following{/other_user}",
"gists_url": "https://api.github.com/users/matthew-olson-intel/gists{/gist_id}",
"starred_url": "https://api.github.com/users/matthew-olson-intel/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/matthew-olson-intel/subscriptions",
"organizations_url": "https://api.github.com/users/matthew-olson-intel/orgs",
"repos_url": "https://api.github.com/users/matthew-olson-intel/repos",
"events_url": "https://api.github.com/users/matthew-olson-intel/events{/privacy}",
"received_events_url": "https://api.github.com/users/matthew-olson-intel/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 987666414,
"node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull",
"name": "ready to pull",
"color": "2cd643",
"default": false,
"description": "PR ready for merge process"
},
{
"id": 1173072136,
"node_id": "MDU6TGFiZWwxMTczMDcyMTM2",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XL",
"name": "size:XL",
"color": "adafea",
"default": false,
"description": "CL Change Size:Extra Large"
},
{
"id": 1478826728,
"node_id": "MDU6TGFiZWwxNDc4ODI2NzI4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:core",
"name": "comp:core",
"color": "024391",
"default": false,
"description": "issues related to core part of tensorflow"
}
] |
closed
| false |
{
"login": "penpornk",
"id": 38085909,
"node_id": "MDQ6VXNlcjM4MDg1OTA5",
"avatar_url": "https://avatars.githubusercontent.com/u/38085909?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/penpornk",
"html_url": "https://github.com/penpornk",
"followers_url": "https://api.github.com/users/penpornk/followers",
"following_url": "https://api.github.com/users/penpornk/following{/other_user}",
"gists_url": "https://api.github.com/users/penpornk/gists{/gist_id}",
"starred_url": "https://api.github.com/users/penpornk/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/penpornk/subscriptions",
"organizations_url": "https://api.github.com/users/penpornk/orgs",
"repos_url": "https://api.github.com/users/penpornk/repos",
"events_url": "https://api.github.com/users/penpornk/events{/privacy}",
"received_events_url": "https://api.github.com/users/penpornk/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "penpornk",
"id": 38085909,
"node_id": "MDQ6VXNlcjM4MDg1OTA5",
"avatar_url": "https://avatars.githubusercontent.com/u/38085909?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/penpornk",
"html_url": "https://github.com/penpornk",
"followers_url": "https://api.github.com/users/penpornk/followers",
"following_url": "https://api.github.com/users/penpornk/following{/other_user}",
"gists_url": "https://api.github.com/users/penpornk/gists{/gist_id}",
"starred_url": "https://api.github.com/users/penpornk/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/penpornk/subscriptions",
"organizations_url": "https://api.github.com/users/penpornk/orgs",
"repos_url": "https://api.github.com/users/penpornk/repos",
"events_url": "https://api.github.com/users/penpornk/events{/privacy}",
"received_events_url": "https://api.github.com/users/penpornk/received_events",
"type": "User",
"site_admin": false
},
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Nice ",
"cool",
"> Could you please help make more changes? There are some more errors.\r\n\r\nSure. Sorry, didn't see those errors in my local tests, and I didn't see which target in the CI threw those errors.",
"I think I've made all of the appropriate changes; @cantonios @penpornk does this look OK to you?",
"@cantonios Made that change, and I think the current \"Presubmit\" test failure is unrelated to this PR.",
"@cantonios I can see that some internal checks failed, but can't see what they are.",
"> @cantonios I can see that some internal checks failed, but can't see what they are.\r\n\r\n```\r\nERROR: tensorflow/core/kernels/mkl/BUILD:104:22: in cc_library rule //tensorflow/core/kernels/mkl:mkl_sparse_matrix_matmul_op: Visibility error:\r\ntarget '//tensorflow/core/kernels/sparse:mat_mul_op.h' is not visible from\r\ntarget '//tensorflow/core/kernels/mkl:mkl_sparse_matrix_matmul_op'\r\n```",
"> > @cantonios I can see that some internal checks failed, but can't see what they are.\r\n> \r\n> ```\r\n> ERROR: tensorflow/core/kernels/mkl/BUILD:104:22: in cc_library rule //tensorflow/core/kernels/mkl:mkl_sparse_matrix_matmul_op: Visibility error:\r\n> target '//tensorflow/core/kernels/sparse:mat_mul_op.h' is not visible from\r\n> target '//tensorflow/core/kernels/mkl:mkl_sparse_matrix_matmul_op'\r\n> ```\r\n\r\nIs it possible to get a commandline reproducer for this error? Can't reproduce locally, so fixing it might be trial-and-error that spams this PR with commits and spams you with emails!",
"> > > @cantonios I can see that some internal checks failed, but can't see what they are.\r\n> > \r\n> > \r\n> > ```\r\n> > ERROR: tensorflow/core/kernels/mkl/BUILD:104:22: in cc_library rule //tensorflow/core/kernels/mkl:mkl_sparse_matrix_matmul_op: Visibility error:\r\n> > target '//tensorflow/core/kernels/sparse:mat_mul_op.h' is not visible from\r\n> > target '//tensorflow/core/kernels/mkl:mkl_sparse_matrix_matmul_op'\r\n> > ```\r\n> \r\n> Is it possible to get a commandline reproducer for this error? Can't reproduce locally, so fixing it might be trial-and-error that spams this PR with commits and spams you with emails!\r\n\r\nI'm not sure... I'm surprised bazel doesn't find the dependency issue. Maybe Google's internal tooling is more strict?",
"> > > > @cantonios I can see that some internal checks failed, but can't see what they are.\r\n> > > \r\n> > > \r\n> > > ```\r\n> > > ERROR: tensorflow/core/kernels/mkl/BUILD:104:22: in cc_library rule //tensorflow/core/kernels/mkl:mkl_sparse_matrix_matmul_op: Visibility error:\r\n> > > target '//tensorflow/core/kernels/sparse:mat_mul_op.h' is not visible from\r\n> > > target '//tensorflow/core/kernels/mkl:mkl_sparse_matrix_matmul_op'\r\n> > > ```\r\n> > \r\n> > \r\n> > Is it possible to get a commandline reproducer for this error? Can't reproduce locally, so fixing it might be trial-and-error that spams this PR with commits and spams you with emails!\r\n> \r\n> I'm not sure... I'm surprised bazel doesn't find the dependency issue. Maybe Google's internal tooling is more strict?\r\n\r\nAll right, trying some things. Thank you for your reviews, by the way!",
"@cantonios Can you get the internal checks running to test the latest version out?",
"> Thank you! Sorry for so many change requests! (It's from our internal checks.)\r\n\r\nHey, I get it -- totally fine! Thanks for bearing with me while I made them.",
"Any update on this? Is the next step in the process for @qqfish to review? Looks like the Copybara checks are passing now.",
"> Any update on this? Is the next step in the process for @qqfish to review? Looks like the Copybara checks are passing now.\r\n\r\nIt's going through the internal battery of tests now.",
"> > Any update on this? Is the next step in the process for @qqfish to review? Looks like the Copybara checks are passing now.\r\n> \r\n> It's going through the internal battery of tests now.\r\n\r\nOh, nice, sounds good.",
"Unfortunately I had to rollback this PR since it broke a oneDNN build on arm64. The error was:\r\n\r\n```\r\nIn file included from tensorflow/core/kernels/mkl/mkl_einsum_op.cc:19:\r\nIn file included from tensorflow/core/kernels/mkl/mkl_batch_matmul_helper.h:25:\r\n./tensorflow/core/kernels/mkl/mkl_matmul_ops_common.h:927:38: error: no member named 'csr' in 'dnnl::memory::desc'\r\n 927 | const auto tmp = memory::desc::csr(\r\n | ~~~~~~~~~~~~~~^\r\n```\r\n\r\n@matthew-olson-intel, can you create a new PR with this issue fixed?\r\n\r\n",
"@reedwm Sure. The new PR is in #63030."
] | 2024-02-01T19:53:00 | 2024-02-22T20:34:50 | 2024-02-21T23:27:26 |
CONTRIBUTOR
| null | false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62883",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62883",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62883.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62883.patch",
"merged_at": "2024-02-21T23:27:26"
}
|
Adds `_MklNativeSparseMatrixMatMul` and its accompanying kernel, which uses oneDNN to multiply a CSR sparse matrix by a dense tensor. The op is enabled with an environment variable (`TF_ENABLE_ONEDNN_SPMM`), so is entirely opt-in. It also includes tests and a benchmark, which we've used below to measure its performance against the existing kernel.
The performance looks promising particularly for larger shapes, and is optimized to use the AVX2 and AVX512 ISAs. These results were collected using the new benchmark in `tensorflow/core/kernels/mkl/mkl_sparse_matrix_matmul_op_benchmark.cc` on an Intel Xeon Platinum 8480 with hyperthreading enabled. To minimize NUMA effects, we bound it to the first socket.
Configuration (NNZ_M_K_N) | Eigen Time (ns) | oneDNN Time (ns) | Ratio
-- | -- | -- | --
128_8_512_1 | 15300 | 18598 | 0.82
128_16_512_1 | 14778 | 18551 | 0.80
128_128_512_1 | 18613 | 19165 | 0.97
128_4096_4096_1 | 151525 | 35904 | 4.22
1024_4096_4096_1 | 161593 | 37041 | 4.36
16384_4096_4096_1 | 163055 | 49355 | 3.30
128_8_1024_16 | 17307 | 18420 | 0.94
128_16_1024_16 | 17765 | 18678 | 0.95
128_128_1024_16 | 19247 | 19200 | 1.00
128_4096_4096_128 | 160341 | 140894 | 1.14
128_4096_4096_1024 | 181590 | 156980 | 1.16
1024_8_1024_16 | 24265 | 19502 | 1.24
1024_16_1024_16 | 24223 | 20448 | 1.18
1024_128_1024_16 | 26013 | 20396 | 1.28
1024_4096_4096_128 | 157612 | 139688 | 1.13
1024_4096_4096_1024 | 177549 | 160973 | 1.10
16384_8_1024_16 | 153005 | 36643 | 4.18
16384_16_1024_16 | 152853 | 36597 | 4.18
16384_128_1024_16 | 153600 | 31928 | 4.81
16384_4096_4096_128 | 166061 | 142494 | 1.17
16384_4096_4096_1024 | 244243 | 194536 | 1.26
16384_4096_4096_4096 | 654950 | 536546 | 1.22
100_1_1000000_100 | 18230 | 19991 | 0.91
200_1_2000000_100 | 20509 | 20818 | 0.99
400_1_4000000_100 | 23023 | 21638 | 1.06
400_4_1000000_100 | 22164 | 21349 | 1.04
800_4_2000000_100 | 26180 | 23374 | 1.12
1600_4_4000000_100 | 40538 | 28622 | 1.42
800_8_1000000_100 | 27015 | 23231 | 1.16
1600_8_2000000_100 | 39953 | 27894 | 1.43
3200_8_4000000_100 | 77708 | 42709 | 1.82
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62883/reactions",
"total_count": 1,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 1,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62883/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62882
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62882/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62882/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62882/events
|
https://github.com/tensorflow/tensorflow/issues/62882
| 2,112,999,448 |
I_kwDOArmXAs598dAY
| 62,882 |
remapper_test fails on AARCH64 with --config=mkl_aarch64_threadpool
|
{
"login": "elfringham",
"id": 10442001,
"node_id": "MDQ6VXNlcjEwNDQyMDAx",
"avatar_url": "https://avatars.githubusercontent.com/u/10442001?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/elfringham",
"html_url": "https://github.com/elfringham",
"followers_url": "https://api.github.com/users/elfringham/followers",
"following_url": "https://api.github.com/users/elfringham/following{/other_user}",
"gists_url": "https://api.github.com/users/elfringham/gists{/gist_id}",
"starred_url": "https://api.github.com/users/elfringham/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/elfringham/subscriptions",
"organizations_url": "https://api.github.com/users/elfringham/orgs",
"repos_url": "https://api.github.com/users/elfringham/repos",
"events_url": "https://api.github.com/users/elfringham/events{/privacy}",
"received_events_url": "https://api.github.com/users/elfringham/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 1104829434,
"node_id": "MDU6TGFiZWwxMTA0ODI5NDM0",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:mkl",
"name": "comp:mkl",
"color": "0052cc",
"default": false,
"description": "MKL related issues"
}
] |
closed
| false |
{
"login": "sachinprasadhs",
"id": 73069040,
"node_id": "MDQ6VXNlcjczMDY5MDQw",
"avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sachinprasadhs",
"html_url": "https://github.com/sachinprasadhs",
"followers_url": "https://api.github.com/users/sachinprasadhs/followers",
"following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}",
"gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions",
"organizations_url": "https://api.github.com/users/sachinprasadhs/orgs",
"repos_url": "https://api.github.com/users/sachinprasadhs/repos",
"events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}",
"received_events_url": "https://api.github.com/users/sachinprasadhs/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "sachinprasadhs",
"id": 73069040,
"node_id": "MDQ6VXNlcjczMDY5MDQw",
"avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sachinprasadhs",
"html_url": "https://github.com/sachinprasadhs",
"followers_url": "https://api.github.com/users/sachinprasadhs/followers",
"following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}",
"gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions",
"organizations_url": "https://api.github.com/users/sachinprasadhs/orgs",
"repos_url": "https://api.github.com/users/sachinprasadhs/repos",
"events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}",
"received_events_url": "https://api.github.com/users/sachinprasadhs/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"@TensorFlow-MKL \r\n@penpornk \r\n@davsva01 ",
"It seems that certain parts of tensorflow/core/grappler/optimizers/remapper.cc are disabled with the presence of DNNL_AARCH64_USE_ACL and this is resulting in the test failures.",
"@milpuz01 Do these features still need to be disabled for the best performance with ACL?",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62882\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62882\">No</a>\n",
"@elfringham, thanks for your fix.\r\n\r\n> @milpuz01 Do these features still need to be disabled for the best performance with ACL?\r\n\r\n\r\nYes, they are still needed. \r\n\r\nUnfortunately, we should have updated the tests initially when the changes were made in this PR: https://github.com/tensorflow/tensorflow/pull/60723, but I think back then the `remapper_test` was disabled and we didn't see it failing.\r\n\r\nProbably the right fix for AArch64 would be to still execute the tests, but check the name of the operators and arguments matches the operators and arguments without the optimisation. In this way we will have testing of `remapper` phase too for occasions when we do not lower to oneDNN on AArch64 and if there are any changes of future we will be able to catch them. We will look into making those changes."
] | 2024-02-01T17:04:48 | 2024-02-12T12:10:36 | 2024-02-07T04:28:29 |
CONTRIBUTOR
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
source
### TensorFlow version
git HEAD
### Custom code
No
### OS platform and distribution
Ubuntu 20.04
### Mobile device
n/a
### Python version
3.9.17
### Bazel version
6.5.0
### GCC/compiler version
17.0.0
### CUDA/cuDNN version
n/a
### GPU model and memory
n/a
### Current behavior?
The tests //tensorflow/core/grappler/optimizers:remapper_test and //tensorflow/core/grappler/optimizers:mkl_remapper_test will fail on AARCH64 when built with --config=mkl_aarch64_threadpool and run with TF_ENABLE_ONEDNN_OPTS=1. But also remapper_test will fail those tests that are not skipped even with TF_ENABLE_ONEDNN_OPTS=0. All tests in mkl_remapper_test are skipped in that case.
### Standalone code to reproduce the issue
```shell
bazel test --config=mkl_aarch64_threadpool --test_timeout=500,900,3000,-1 --copt=-flax-vector-conversions --test_env=TF_ENABLE_ONEDNN_OPTS=1 --test_env=TF2_BEHAVIOR=1 --define=tf_api_version=2 --test_size_filters=small,medium --test_lang_filters=py,cc --test_output=errors --verbose_failures=true --test_keep_going --notest_verbose_timeout_warnings --action_env=PYTHON_BIN_PATH=/usr/local/bin/python3 --test_env=PORTSERVER_ADDRESS=@unittest-portserver --build_tag_filters=-no_oss,-oss_excluded,-oss_serial,-v1only,-benchmark-test,-no_aarch64,-gpu,-tpu,-no_oss_py39,-no_oss_py310 --test_tag_filters=-no_oss,-oss_excluded,-oss_serial,-v1only,-benchmark-test,-no_aarch64,-gpu,-tpu,-no_oss_py39,-no_oss_py310 --jobs=75 --build_tests_only --copt=-Og --copt=-ggdb --strip=never --per_file_copt=external/org_brotli/c/dec/decode.c@-O2 -- //tensorflow/core/grappler/optimizers:remapper_test
```
### Relevant log output
```shell
[ RUN ] RemapperTest.FuseConv2DWithBatchNorm
tensorflow/core/grappler/optimizers/remapper_test.cc:2141: Failure
Expected equality of these values:
node.op()
Which is: "FusedBatchNorm"
"_FusedConv2D"
tensorflow/core/grappler/optimizers/remapper_test.cc:2142: Failure
Expected: (node.input_size()) >= (6), actual: 5 vs 6
[ FAILED ] RemapperTest.FuseConv2DWithBatchNorm (3 ms)
[ RUN ] RemapperTest.FuseConv2DWithBatchNormAndActivation
tensorflow/core/grappler/optimizers/remapper_test.cc:2240: Failure
Expected equality of these values:
node.op()
Which is: "Identity"
"_FusedConv2D"
tensorflow/core/grappler/optimizers/remapper_test.cc:2241: Failure
Expected: (node.input_size()) >= (6), actual: 1 vs 6
[ FAILED ] RemapperTest.FuseConv2DWithBatchNormAndActivation (3 ms)
[ RUN ] RemapperTest.FuseConv3DWithBiasAndAddN
tensorflow/core/grappler/optimizers/remapper_test.cc:2321: Failure
Expected equality of these values:
node.op()
Which is: "AddN"
"_FusedConv3D"
tensorflow/core/grappler/optimizers/remapper_test.cc:2322: Failure
Expected: (node.input_size()) >= (3), actual: 2 vs 3
[ FAILED ] RemapperTest.FuseConv3DWithBiasAndAddN (285 ms)
[ RUN ] RemapperTest.FuseConv3DWithBiasAndAdd
tensorflow/core/grappler/optimizers/remapper_test.cc:2392: Failure
Expected equality of these values:
node.op()
Which is: "Add"
"_FusedConv3D"
tensorflow/core/grappler/optimizers/remapper_test.cc:2393: Failure
Expected: (node.input_size()) >= (3), actual: 2 vs 3
[ FAILED ] RemapperTest.FuseConv3DWithBiasAndAdd (272 ms)
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62882/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62882/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62881
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62881/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62881/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62881/events
|
https://github.com/tensorflow/tensorflow/issues/62881
| 2,112,828,968 |
I_kwDOArmXAs597zYo
| 62,881 |
Unable to build tensorflow lite select ops from source using docker image
|
{
"login": "j-dsouza-19",
"id": 158491014,
"node_id": "U_kgDOCXJhhg",
"avatar_url": "https://avatars.githubusercontent.com/u/158491014?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/j-dsouza-19",
"html_url": "https://github.com/j-dsouza-19",
"followers_url": "https://api.github.com/users/j-dsouza-19/followers",
"following_url": "https://api.github.com/users/j-dsouza-19/following{/other_user}",
"gists_url": "https://api.github.com/users/j-dsouza-19/gists{/gist_id}",
"starred_url": "https://api.github.com/users/j-dsouza-19/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/j-dsouza-19/subscriptions",
"organizations_url": "https://api.github.com/users/j-dsouza-19/orgs",
"repos_url": "https://api.github.com/users/j-dsouza-19/repos",
"events_url": "https://api.github.com/users/j-dsouza-19/events{/privacy}",
"received_events_url": "https://api.github.com/users/j-dsouza-19/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473173351,
"node_id": "MDU6TGFiZWw0NzMxNzMzNTE=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:build/install",
"name": "type:build/install",
"color": "159b2e",
"default": false,
"description": "Build and install issues"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
},
{
"id": 750616506,
"node_id": "MDU6TGFiZWw3NTA2MTY1MDY=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite",
"name": "comp:lite",
"color": "0052cc",
"default": false,
"description": "TF Lite related issues"
},
{
"id": 5922361893,
"node_id": "LA_kwDOArmXAs8AAAABYQASJQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF2.14",
"name": "TF2.14",
"color": "b60205",
"default": false,
"description": "For issues related to Tensorflow 2.14.x"
}
] |
closed
| false |
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"@j-dsouza-19,\r\nLooks like there is incompatible with the Bazel version 6.5.0 and GCC/compiler version 9.4.0 with tensorflow v2.14. The tensorflow version2.14 is compatible with Clang 16.0.0 and Bazel 6.1.0.\r\nhttps://www.tensorflow.org/install/source#linux\r\n\r\nCould you please try to use Bazel 6.1.0 in order to compile the master\r\n\r\n```\r\nbazel build -c opt --cxxopt=--std=c++17 --config=android_arm64 \\\r\n --fat_apk_cpu=x86,x86_64,arm64-v8a,armeabi-v7a \\\r\n --define=android_dexmerger_tool=d8_dexmerger \\\r\n --define=android_incremental_dexing_tool=d8_dexbuilder \\\r\n //tensorflow/lite/java:tensorflow-lite\r\n```\r\nhttps://www.tensorflow.org/install/source#linux\r\n\r\nThank you!",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62881\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62881\">No</a>\n"
] | 2024-02-01T15:44:21 | 2024-02-17T01:46:19 | 2024-02-17T01:46:16 |
NONE
| null | null | null |
### Issue type
Build/Install
### Have you reproduced the bug with TensorFlow Nightly?
No
### Source
source
### TensorFlow version
r2.14
### Custom code
No
### OS platform and distribution
Docker image - tensorflow/build:latest-python3.11
### Mobile device
tensorflow/build:latest-python3.11
### Python version
3.11
### Bazel version
6.5.0
### GCC/compiler version
9.4.0
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
Unable to build tensorflow lite select ops from source using docker image
- facing error due to protobuf mismatch (I think)
### Standalone code to reproduce the issue
```shell
docker run -it -v $PWD:/host_dir tensorflow/build:latest-python3.11 bash
cd /home && git clone https://github.com/tensorflow/tensorflow && git checkout -b r2.14
android update sdk --no-ui -a \
--filter tools,platform-tools,android-{ANDROID_API_LEVEL},build-tools-{ANDROID_BUILD_TOOLS_VERSION}
cd /home/tensorflow && configs=( \
'/usr/bin/python3' \
'/usr/lib/python3/dist-packages' \
'N' 'N' 'Y' \
'/usr/lib/llvm-17/bin/clang' \
'-Wno-sign-compare -Wno-c++20-designator -Wno-gnu-inline-cpp-without-extern' \
'y' \
'/android/sdk' \
) && printf '%s\n' "${configs[@]}" | ./configure
cd /home/tensorflow && tensorflow/lite/tools/build_aar.sh \
--input_models=/host_dir/mymodel.tflite \
--target_archs=arm64-v8a,armeabi-v7a
```
Reference: https://www.tensorflow.org/lite/android/lite_build
```
### Relevant log output
```shell
+++ dirname tensorflow/lite/tools/build_aar.sh
++ cd tensorflow/lite/tools
++ pwd
+ SCRIPT_DIR=/home/tensorflow/tensorflow/lite/tools
++ cd /home/tensorflow/tensorflow/lite/tools/../../../
++ pwd
+ ROOT_DIR=/home/tensorflow
+ TARGET_ARCHS=x86,x86_64,arm64-v8a,armeabi-v7a
+ '[' '!' -z ']'
+ '[' 2 -gt 4 ']'
+ for i in "$@"
+ case $i in
+ FLAG_MODELS=/host_dir/mytflite.tflite
+ shift
+ for i in "$@"
+ case $i in
+ TARGET_ARCHS=arm64-v8a,armeabi-v7a
+ shift
+ cd /home/tensorflow
+ '[' '!' -f /home/tensorflow/.tf_configure.bazelrc ']'
+ grep -q ANDROID_SDK_HOME /home/tensorflow/.tf_configure.bazelrc
+ '[' -z /host_dir/mytflite.tflite ']'
+ TMP_DIR=/home/tensorflow/tmp/
+ rm -rf /home/tensorflow/tmp/
+ mkdir -p /home/tensorflow/tmp/
+ MODEL_NAMES=
++ sed 's/,/ /g'
++ echo /host_dir/mytflite.tflite
+ for model in $(echo ${FLAG_MODELS} | sed "s/,/ /g")
+ cp /host_dir/mytflite.tflite /home/tensorflow/tmp/
++ basename /host_dir/mytflite.tflite
+ MODEL_NAMES=,mytflite.tflite
+ TFLITE_OPS_SRCS=
++ echo
++ sed 's/,/ /g'
+ generate_tflite_aar
+ pushd /home/tensorflow/tmp/
+ message=('load("//tensorflow/lite:build_def.bzl", "tflite_custom_android_library")' 'load("//tenso rflow/lite/java:aar_with_jni.bzl", "aar_with_jni")' '' 'tflite_custom_android_library(' ' name = "custom_tensorflowlite",')
+ message+=(' '$(generate_list_field "models" $MODEL_NAMES))
++ generate_list_field models ,mytflite.tflite
++ local name=models
++ local list_string=,mytflite.tflite
++ list=(${list_string//,/ })
++ local list
++ message=("$name=[")
++ local message
++ for item in "${list[@]}"
++ message+=("\"$item\",")
++ message+=('],')
++ printf %s 'models=[' '"mytflite.tflite",' '],'
+ message+=(' '$(generate_list_field "srcs" $TFLITE_OPS_SRCS))
++ generate_list_field srcs
++ local name=srcs
++ local list_string=
++ list=(${list_string//,/ })
++ local list
++ message=("$name=[")
++ local message
++ message+=('],')
++ printf %s 'srcs=[' '],'
+ message+=(' '$(generate_list_field "deps" $FLAG_TFLITE_OPS_DEPS))
++ generate_list_field deps
++ local name=deps
++ local list_string=
++ list=(${list_string//,/ })
++ local list
++ message=("$name=[")
++ local message
++ message+=('],')
++ printf %s 'deps=[' '],'
+ message+=(')' '' 'aar_with_jni(' ' name = "tensorflow-lite",' ' android_library = ":custom_t ensorflowlite",' ')' '')
+ printf '%s\n' 'load("//tensorflow/lite:build_def.bzl", "tflite_custom_android_library")' 'load("// tensorflow/lite/java:aar_with_jni.bzl", "aar_with_jni")' '' 'tflite_custom_android_library(' ' na me = "custom_tensorflowlite",' ' models=["mytflite.tflite",],' ' srcs=[],' ' deps=[],' ')' '' 'aar_with_jni(' ' name = "tensorflow-lite",' ' android_library = ":custom_t ensorflowlite",' ')' ''
+ popd
+ bazel build -c opt --config=opt --cxxopt=--std=c++17 --fat_apk_cpu=arm64-v8a,armeabi-v7a --define= android_dexmerger_tool=d8_dexmerger --define=android_incremental_dexing_tool=d8_dexbuilder --host_cr osstool_top=@bazel_tools//tools/cpp:toolchain //tmp:tensorflow-lite
INFO: Reading 'startup' options from /home/tensorflow/.bazelrc: --windows_enable_symlinks
INFO: Options provided by the client:
Inherited 'common' options: --isatty=1 --terminal_columns=100
INFO: Reading rc options for 'build' from /home/tensorflow/.bazelrc:
Inherited 'common' options: --experimental_repo_remote_exec
INFO: Reading rc options for 'build' from /etc/bazel.bazelrc:
'build' options: --action_env=DOCKER_CACHEBUSTER=1705796012603651033 --host_action_env=DOCKER_HOST _CACHEBUSTER=1705796012683534545
INFO: Reading rc options for 'build' from /home/tensorflow/.bazelrc:
'build' options: --define framework_shared_object=true --define tsl_protobuf_header_only=true --de fine=use_fast_cpp_protos=true --define=allow_oversize_protos=true --spawn_strategy=standalone -c opt --announce_rc --define=grpc_no_ares=true --noincompatible_remove_legacy_whole_archive --features=-f orce_no_whole_archive --enable_platform_specific_config --define=with_xla_support=true --config=shor t_logs --config=v2 --define=no_aws_support=true --define=no_hdfs_support=true --experimental_cc_shar ed_library --experimental_link_static_libraries_once=false --incompatible_enforce_config_setting_vis ibility
INFO: Reading rc options for 'build' from /home/tensorflow/.tf_configure.bazelrc:
'build' options: --action_env PYTHON_BIN_PATH=/usr/bin/python3 --action_env PYTHON_LIB_PATH=/usr/l ib/python3/dist-packages --python_path=/usr/bin/python3 --action_env CLANG_COMPILER_PATH=/usr/lib/ll vm-17/bin/clang --repo_env=CC=/usr/lib/llvm-17/bin/clang --repo_env=BAZEL_COMPILER=/usr/lib/llvm-17/ bin/clang --copt=-Wno-gnu-offsetof-extensions --action_env ANDROID_NDK_HOME=/android/ndk --action_en v ANDROID_NDK_VERSION=25 --action_env ANDROID_NDK_API_LEVEL=30 --action_env ANDROID_BUILD_TOOLS_VERS ION=31.0.0 --action_env ANDROID_SDK_API_LEVEL=30 --action_env ANDROID_SDK_HOME=/android/sdk
INFO: Found applicable config definition build:short_logs in file /home/tensorflow/.bazelrc: --outpu t_filter=DONT_MATCH_ANYTHING
INFO: Found applicable config definition build:v2 in file /home/tensorflow/.bazelrc: --define=tf_api _version=2 --action_env=TF2_BEHAVIOR=1
INFO: Found applicable config definition build:opt in file /home/tensorflow/.tf_configure.bazelrc: - -copt=-Wno-sign-compare --host_copt=-Wno-sign-compare --copt=-Wno-c++20-designator --host_copt=-Wno- c++20-designator --copt=-Wno-gnu-inline-cpp-without-extern --host_copt=-Wno-gnu-inline-cpp-without-e xtern
INFO: Found applicable config definition build:linux in file /home/tensorflow/.bazelrc: --host_copt= -w --copt=-Wno-all --copt=-Wno-extra --copt=-Wno-deprecated --copt=-Wno-deprecated-declarations --co pt=-Wno-ignored-attributes --copt=-Wno-array-bounds --copt=-Wunused-result --copt=-Werror=unused-res ult --copt=-Wswitch --copt=-Werror=switch --copt=-Wno-error=unused-but-set-variable --define=PREFIX= /usr --define=LIBDIR=$(PREFIX)/lib --define=INCLUDEDIR=$(PREFIX)/include --define=PROTOBUF_INCLUDE_P ATH=$(PREFIX)/include --cxxopt=-std=c++17 --host_cxxopt=-std=c++17 --config=dynamic_kernels --experi mental_guard_against_concurrent_changes
INFO: Found applicable config definition build:dynamic_kernels in file /home/tensorflow/.bazelrc: -- define=dynamic_loaded_kernels=true --copt=-DAUTOLOAD_DYNAMIC_KERNELS
INFO: Analyzed target //tmp:tensorflow-lite (1 packages loaded, 196 targets configured).
INFO: Found 1 target...
Target //tmp:tensorflow-lite up-to-date:
bazel-bin/tmp/tensorflow-lite.aar
INFO: Elapsed time: 10.395s, Critical Path: 7.68s
INFO: 10 processes: 1 internal, 9 local.
INFO: Build completed successfully, 10 total actions
+ OUT_FILES=' bazel-bin/tmp/tensorflow-lite.aar'
+ bazel build -c opt --config=monolithic //tensorflow/lite/tools:list_flex_ops_no_kernel_main
INFO: Reading 'startup' options from /home/tensorflow/.bazelrc: --windows_enable_symlinks
INFO: Options provided by the client:
Inherited 'common' options: --isatty=1 --terminal_columns=100
INFO: Reading rc options for 'build' from /home/tensorflow/.bazelrc:
Inherited 'common' options: --experimental_repo_remote_exec
INFO: Reading rc options for 'build' from /etc/bazel.bazelrc:
'build' options: --action_env=DOCKER_CACHEBUSTER=1705796012603651033 --host_action_env=DOCKER_HOST _CACHEBUSTER=1705796012683534545
INFO: Reading rc options for 'build' from /home/tensorflow/.bazelrc:
'build' options: --define framework_shared_object=true --define tsl_protobuf_header_only=true --de fine=use_fast_cpp_protos=true --define=allow_oversize_protos=true --spawn_strategy=standalone -c opt --announce_rc --define=grpc_no_ares=true --noincompatible_remove_legacy_whole_archive --features=-f orce_no_whole_archive --enable_platform_specific_config --define=with_xla_support=true --config=shor t_logs --config=v2 --define=no_aws_support=true --define=no_hdfs_support=true --experimental_cc_shar ed_library --experimental_link_static_libraries_once=false --incompatible_enforce_config_setting_vis ibility
INFO: Reading rc options for 'build' from /home/tensorflow/.tf_configure.bazelrc:
'build' options: --action_env PYTHON_BIN_PATH=/usr/bin/python3 --action_env PYTHON_LIB_PATH=/usr/l ib/python3/dist-packages --python_path=/usr/bin/python3 --action_env CLANG_COMPILER_PATH=/usr/lib/ll vm-17/bin/clang --repo_env=CC=/usr/lib/llvm-17/bin/clang --repo_env=BAZEL_COMPILER=/usr/lib/llvm-17/ bin/clang --copt=-Wno-gnu-offsetof-extensions --action_env ANDROID_NDK_HOME=/android/ndk --action_en v ANDROID_NDK_VERSION=25 --action_env ANDROID_NDK_API_LEVEL=30 --action_env ANDROID_BUILD_TOOLS_VERS ION=31.0.0 --action_env ANDROID_SDK_API_LEVEL=30 --action_env ANDROID_SDK_HOME=/android/sdk
INFO: Found applicable config definition build:short_logs in file /home/tensorflow/.bazelrc: --outpu t_filter=DONT_MATCH_ANYTHING
INFO: Found applicable config definition build:v2 in file /home/tensorflow/.bazelrc: --define=tf_api _version=2 --action_env=TF2_BEHAVIOR=1
INFO: Found applicable config definition build:monolithic in file /home/tensorflow/.bazelrc: --defin e framework_shared_object=false --define tsl_protobuf_header_only=false --experimental_link_static_l ibraries_once=false
INFO: Found applicable config definition build:linux in file /home/tensorflow/.bazelrc: --host_copt= -w --copt=-Wno-all --copt=-Wno-extra --copt=-Wno-deprecated --copt=-Wno-deprecated-declarations --co pt=-Wno-ignored-attributes --copt=-Wno-array-bounds --copt=-Wunused-result --copt=-Werror=unused-res ult --copt=-Wswitch --copt=-Werror=switch --copt=-Wno-error=unused-but-set-variable --define=PREFIX= /usr --define=LIBDIR=$(PREFIX)/lib --define=INCLUDEDIR=$(PREFIX)/include --define=PROTOBUF_INCLUDE_P ATH=$(PREFIX)/include --cxxopt=-std=c++17 --host_cxxopt=-std=c++17 --config=dynamic_kernels --experi mental_guard_against_concurrent_changes
INFO: Found applicable config definition build:dynamic_kernels in file /home/tensorflow/.bazelrc: -- define=dynamic_loaded_kernels=true --copt=-DAUTOLOAD_DYNAMIC_KERNELS
INFO: Build options --copt, --cxxopt, --define, and 2 more have changed, discarding analysis cache.
INFO: Analyzed target //tensorflow/lite/tools:list_flex_ops_no_kernel_main (0 packages loaded, 1113 targets configured).
INFO: Found 1 target...
Target //tensorflow/lite/tools:list_flex_ops_no_kernel_main up-to-date:
bazel-bin/tensorflow/lite/tools/list_flex_ops_no_kernel_main
INFO: Elapsed time: 35.265s, Critical Path: 32.54s
INFO: 42 processes: 1 internal, 41 local.
INFO: Build completed successfully, 42 total actions
+ bazel-bin/tensorflow/lite/tools/list_flex_ops_no_kernel_main --graphs=/host_dir/modelPoi10kVocabTw o96GRU.tflite
++ cat /home/tensorflow/tmp//ops_list.txt
+ [[ ["TensorListFromTensor","TensorListGetItem","TensorListReserve","TensorListSetItem","TensorList Stack"] != \[\] ]]
+ generate_flex_aar
+ pushd /home/tensorflow/tmp/
/home/tensorflow/tmp /home/tensorflow
+ message=('load("//tensorflow/lite/delegates/flex:build_def.bzl", "tflite_flex_android_library")' ' load("//tensorflow/lite/java:aar_with_jni.bzl", "aar_with_jni")' '' 'tflite_flex_android_library(' ' name = "custom_tensorflowlite_flex",')
+ message+=(' '$(generate_list_field "models" $MODEL_NAMES))
++ generate_list_field models ,mytflite.tflite
++ local name=models
++ local list_string=,mytflite.tflite
++ list=(${list_string//,/ })
++ local list
++ message=("$name=[")
++ local message
++ for item in "${list[@]}"
++ message+=("\"$item\",")
++ message+=('],')
++ printf %s 'models=[' '"mytflite.tflite",' '],'
+ message+=(')' '' 'aar_with_jni(' ' name = "tensorflow-lite-select-tf-ops",' ' android_librar y = ":custom_tensorflowlite_flex",' ')')
+ printf '%s\n' 'load("//tensorflow/lite/delegates/flex:build_def.bzl", "tflite_flex_android_library ")' 'load("//tensorflow/lite/java:aar_with_jni.bzl", "aar_with_jni")' '' 'tflite_flex_android_librar y(' ' name = "custom_tensorflowlite_flex",' ' models=["mytflite.tflite",],' ') ' '' 'aar_with_jni(' ' name = "tensorflow-lite-select-tf-ops",' ' android_library = ":custom_t ensorflowlite_flex",' ')'
+ cp /home/tensorflow/tensorflow/lite/java/AndroidManifest.xml .
+ cp /home/tensorflow/tensorflow/lite/java/proguard.flags .
+ popd
/home/tensorflow
+ bazel build -c opt --config=opt --cxxopt=--std=c++17 --fat_apk_cpu=arm64-v8a,armeabi-v7a --define= android_dexmerger_tool=d8_dexmerger --define=android_incremental_dexing_tool=d8_dexbuilder --host_cr osstool_top=@bazel_tools//tools/cpp:toolchain //tmp:tensorflow-lite-select-tf-ops
INFO: Reading 'startup' options from /home/tensorflow/.bazelrc: --windows_enable_symlinks
INFO: Options provided by the client:
Inherited 'common' options: --isatty=1 --terminal_columns=100
INFO: Reading rc options for 'build' from /home/tensorflow/.bazelrc:
Inherited 'common' options: --experimental_repo_remote_exec
INFO: Reading rc options for 'build' from /etc/bazel.bazelrc:
'build' options: --action_env=DOCKER_CACHEBUSTER=1705796012603651033 --host_action_env=DOCKER_HOST _CACHEBUSTER=1705796012683534545
INFO: Reading rc options for 'build' from /home/tensorflow/.bazelrc:
'build' options: --define framework_shared_object=true --define tsl_protobuf_header_only=true --de fine=use_fast_cpp_protos=true --define=allow_oversize_protos=true --spawn_strategy=standalone -c opt --announce_rc --define=grpc_no_ares=true --noincompatible_remove_legacy_whole_archive --features=-f orce_no_whole_archive --enable_platform_specific_config --define=with_xla_support=true --config=shor t_logs --config=v2 --define=no_aws_support=true --define=no_hdfs_support=true --experimental_cc_shar ed_library --experimental_link_static_libraries_once=false --incompatible_enforce_config_setting_vis ibility
INFO: Reading rc options for 'build' from /home/tensorflow/.tf_configure.bazelrc:
'build' options: --action_env PYTHON_BIN_PATH=/usr/bin/python3 --action_env PYTHON_LIB_PATH=/usr/l ib/python3/dist-packages --python_path=/usr/bin/python3 --action_env CLANG_COMPILER_PATH=/usr/lib/ll vm-17/bin/clang --repo_env=CC=/usr/lib/llvm-17/bin/clang --repo_env=BAZEL_COMPILER=/usr/lib/llvm-17/ bin/clang --copt=-Wno-gnu-offsetof-extensions --action_env ANDROID_NDK_HOME=/android/ndk --action_en v ANDROID_NDK_VERSION=25 --action_env ANDROID_NDK_API_LEVEL=30 --action_env ANDROID_BUILD_TOOLS_VERS ION=31.0.0 --action_env ANDROID_SDK_API_LEVEL=30 --action_env ANDROID_SDK_HOME=/android/sdk
INFO: Found applicable config definition build:short_logs in file /home/tensorflow/.bazelrc: --outpu t_filter=DONT_MATCH_ANYTHING
INFO: Found applicable config definition build:v2 in file /home/tensorflow/.bazelrc: --define=tf_api _version=2 --action_env=TF2_BEHAVIOR=1
INFO: Found applicable config definition build:opt in file /home/tensorflow/.tf_configure.bazelrc: - -copt=-Wno-sign-compare --host_copt=-Wno-sign-compare --copt=-Wno-c++20-designator --host_copt=-Wno- c++20-designator --copt=-Wno-gnu-inline-cpp-without-extern --host_copt=-Wno-gnu-inline-cpp-without-e xtern
INFO: Found applicable config definition build:linux in file /home/tensorflow/.bazelrc: --host_copt= -w --copt=-Wno-all --copt=-Wno-extra --copt=-Wno-deprecated --copt=-Wno-deprecated-declarations --co pt=-Wno-ignored-attributes --copt=-Wno-array-bounds --copt=-Wunused-result --copt=-Werror=unused-res ult --copt=-Wswitch --copt=-Werror=switch --copt=-Wno-error=unused-but-set-variable --define=PREFIX= /usr --define=LIBDIR=$(PREFIX)/lib --define=INCLUDEDIR=$(PREFIX)/include --define=PROTOBUF_INCLUDE_P ATH=$(PREFIX)/include --cxxopt=-std=c++17 --host_cxxopt=-std=c++17 --config=dynamic_kernels --experi mental_guard_against_concurrent_changes
INFO: Found applicable config definition build:dynamic_kernels in file /home/tensorflow/.bazelrc: -- define=dynamic_loaded_kernels=true --copt=-DAUTOLOAD_DYNAMIC_KERNELS
INFO: Build options --copt, --cxxopt, --define, and 2 more have changed, discarding analysis cache.
INFO: Analyzed target //tmp:tensorflow-lite-select-tf-ops (1 packages loaded, 51389 targets configur ed).
INFO: Found 1 target...
ERROR: /home/tensorflow/tmp/BUILD:19:28: Linking tmp/libtensorflowlite_flex_jni.so failed: (Exit 1): clang failed: error executing command (from target //tmp:libtensorflowlite_flex_jni.so) external/an droidndk/toolchains/llvm/prebuilt/linux-x86_64/bin/clang @bazel-out/android-armeabi-v7a-opt/bin/tmp/ libtensorflowlite_flex_jni.so-2.params
ld.lld: error: undefined symbol: google::protobuf::Message::DebugString() const
>>> referenced by function_ops.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/0/function_ops.pic.o:(std::__ndk1::__function::__func<tensorflow::$_0, std::__ ndk1::allocator<tensorflow::$_0>, absl::lts_20230802::Status (tensorflow::shape_inference::Inference Context*)>::operator()(tensorflow::shape_inference::InferenceContext*&&))
>>> referenced by function_ops.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/0/function_ops.pic.o:(std::__ndk1::__function::__func<tensorflow::$_0, std::__ ndk1::allocator<tensorflow::$_0>, absl::lts_20230802::Status (tensorflow::shape_inference::Inference Context*)>::operator()(tensorflow::shape_inference::InferenceContext*&&))
>>> referenced by function_ops.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/0/function_ops.pic.o:(std::__ndk1::__function::__func<tensorflow::$_0, std::__ ndk1::allocator<tensorflow::$_0>, absl::lts_20230802::Status (tensorflow::shape_inference::Inference Context*)>::operator()(tensorflow::shape_inference::InferenceContext*&&))
>>> referenced 35 more times
ld.lld: error: undefined symbol: google::protobuf::internal::kGlobalEmptyTable
>>> referenced by partitioned_function_ops.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/partitioned_function_ops.pic.o:(google::protobuf::Map<std::__ndk1::basic_strin g<char, std::__ndk1::char_traits<char>, std::__ndk1::allocator<char> >, tensorflow::AttrValue>::Map( google::protobuf::Map<std::__ndk1::basic_string<char, std::__ndk1::char_traits<char>, std::__ndk1::a llocator<char> >, tensorflow::AttrValue> const&))
>>> referenced by optimized_function_graph_info.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tensorflow/core/_objs/portable_tensorflow_li b_lite/optimized_function_graph_info.pic.o:(google::protobuf::Map<std::__ndk1::basic_string<char, st d::__ndk1::char_traits<char>, std::__ndk1::allocator<char> >, std::__ndk1::basic_string<char, std::_ _ndk1::char_traits<char>, std::__ndk1::allocator<char> > >::Map<std::__ndk1::__hash_map_const_iterat or<std::__ndk1::__hash_const_iterator<std::__ndk1::__hash_node<std::__ndk1::__hash_value_type<std::_ _ndk1::basic_string<char, std::__ndk1::char_traits<char>, std::__ndk1::allocator<char> >, std::__ndk 1::basic_string<char, std::__ndk1::char_traits<char>, std::__ndk1::allocator<char> > >, void*>*> > > (std::__ndk1::__hash_map_const_iterator<std::__ndk1::__hash_const_iterator<std::__ndk1::__hash_node< std::__ndk1::__hash_value_type<std::__ndk1::basic_string<char, std::__ndk1::char_traits<char>, std:: __ndk1::allocator<char> >, std::__ndk1::basic_string<char, std::__ndk1::char_traits<char>, std::__nd k1::allocator<char> > >, void*>*> > const&, std::__ndk1::__hash_map_const_iterator<std::__ndk1::__ha sh_const_iterator<std::__ndk1::__hash_node<std::__ndk1::__hash_value_type<std::__ndk1::basic_string< char, std::__ndk1::char_traits<char>, std::__ndk1::allocator<char> >, std::__ndk1::basic_string<char , std::__ndk1::char_traits<char>, std::__ndk1::allocator<char> > >, void*>*> > const&))
>>> referenced by optimized_function_graph_info.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tensorflow/core/_objs/portable_tensorflow_li b_lite/optimized_function_graph_info.pic.o:(google::protobuf::Map<std::__ndk1::basic_string<char, st d::__ndk1::char_traits<char>, std::__ndk1::allocator<char> >, std::__ndk1::basic_string<char, std::_ _ndk1::char_traits<char>, std::__ndk1::allocator<char> > >::Map(google::protobuf::Map<std::__ndk1::b asic_string<char, std::__ndk1::char_traits<char>, std::__ndk1::allocator<char> >, std::__ndk1::basic _string<char, std::__ndk1::char_traits<char>, std::__ndk1::allocator<char> > > const&))
>>> referenced 125 more times
ld.lld: error: undefined symbol: google::protobuf::Arena::AllocateAlignedWithHookForArray(unsigned i nt, std::type_info const*)
>>> referenced by partitioned_function_ops.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/partitioned_function_ops.pic.o:(google::protobuf::Arena::AllocateAlignedWithHo okForArray(unsigned int, unsigned int, std::type_info const*))
>>> referenced by partitioned_function_ops.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/partitioned_function_ops.pic.o:(google::protobuf::Arena::AllocateAlignedWithHo okForArray(unsigned int, unsigned int, std::type_info const*))
>>> referenced by kernel.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tensorflow/lite/delegates/flex/_objs/delegat e_only_runtime/kernel.pic.o:(std::__ndk1::pair<google::protobuf::Map<std::__ndk1::basic_string<char, std::__ndk1::char_traits<char>, std::__ndk1::allocator<char> >, tensorflow::AttrValue>::InnerMap::i terator_base<google::protobuf::MapPair<std::__ndk1::basic_string<char, std::__ndk1::char_traits<char >, std::__ndk1::allocator<char> >, tensorflow::AttrValue> >, bool> google::protobuf::Map<std::__ndk1 ::basic_string<char, std::__ndk1::char_traits<char>, std::__ndk1::allocator<char> >, tensorflow::Att rValue>::InnerMap::TryEmplaceInternal<char const (&) [25]>(char const (&) [25]))
ld.lld: error: undefined symbol: google::protobuf::internal::ThreadSafeArena::AddCleanup(void*, void (*)(void*))
>>> referenced by partitioned_function_ops.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/partitioned_function_ops.pic.o:(void google::protobuf::Arena::RegisterDestruct orInternal<std::__ndk1::basic_string<char, std::__ndk1::char_traits<char>, std::__ndk1::allocator<ch ar> > >(std::__ndk1::basic_string<char, std::__ndk1::char_traits<char>, std::__ndk1::allocator<char> >*, google::protobuf::Arena*, std::__ndk1::integral_constant<bool, false>))
>>> referenced by kernel.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tensorflow/lite/delegates/flex/_objs/delegat e_only_runtime/kernel.pic.o:(std::__ndk1::pair<google::protobuf::Map<std::__ndk1::basic_string<char, std::__ndk1::char_traits<char>, std::__ndk1::allocator<char> >, tensorflow::AttrValue>::InnerMap::i terator_base<google::protobuf::MapPair<std::__ndk1::basic_string<char, std::__ndk1::char_traits<char >, std::__ndk1::allocator<char> >, tensorflow::AttrValue> >, bool> google::protobuf::Map<std::__ndk1 ::basic_string<char, std::__ndk1::char_traits<char>, std::__ndk1::allocator<char> >, tensorflow::Att rValue>::InnerMap::TryEmplaceInternal<char const (&) [25]>(char const (&) [25]))
>>> referenced by feature.pb.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tensorflow/core/example/_objs/example_protos _cc_impl/feature.pb.pic.o:(tensorflow::Features::Features(google::protobuf::Arena*, bool))
>>> referenced 71 more times
ld.lld: error: undefined symbol: google::protobuf::Arena::AllocateAlignedWithCleanup(unsigned int, s td::type_info const*)
>>> referenced by partitioned_function_ops.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/partitioned_function_ops.pic.o:(google::protobuf::Map<std::__ndk1::basic_strin g<char, std::__ndk1::char_traits<char>, std::__ndk1::allocator<char> >, tensorflow::AttrValue>::Inne rMap::TreeConvert(unsigned int))
>>> referenced by feature_util.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tensorflow/core/_objs/portable_tensorflow_li b_lite/feature_util.pic.o:(google::protobuf::Map<std::__ndk1::basic_string<char, std::__ndk1::char_t raits<char>, std::__ndk1::allocator<char> >, tensorflow::Feature>::InnerMap::TreeConvert(unsigned in t))
>>> referenced by function.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tensorflow/core/_objs/portable_tensorflow_li b_lite/0/function.pic.o:(google::protobuf::internal::StringTypeHandler::New(google::protobuf::Arena* , std::__ndk1::basic_string<char, std::__ndk1::char_traits<char>, std::__ndk1::allocator<char> >&&))
>>> referenced 59 more times
ld.lld: error: undefined symbol: google::protobuf::internal::RepeatedPtrFieldBase::AddOutOfLineHelpe r(void*)
>>> referenced by save_restore_tensor.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/save_restore_tensor.pic.o:(google::protobuf::RepeatedPtrField<tensorflow::Save dSliceMeta>::TypeHandler::Type* google::protobuf::internal::RepeatedPtrFieldBase::Add<google::protob uf::RepeatedPtrField<tensorflow::SavedSliceMeta>::TypeHandler>(google::protobuf::RepeatedPtrField<te nsorflow::SavedSliceMeta>::TypeHandler::Type const*))
>>> referenced by save_restore_tensor.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/save_restore_tensor.pic.o:(google::protobuf::RepeatedPtrField<tensorflow::Tens orSliceProto>::TypeHandler::Type* google::protobuf::internal::RepeatedPtrFieldBase::Add<google::prot obuf::RepeatedPtrField<tensorflow::TensorSliceProto>::TypeHandler>(google::protobuf::RepeatedPtrFiel d<tensorflow::TensorSliceProto>::TypeHandler::Type const*))
>>> referenced by compression_utils.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/compression_utils.pic.o:(google::protobuf::RepeatedPtrField<tensorflow::data:: CompressedComponentMetadata>::TypeHandler::Type* google::protobuf::internal::RepeatedPtrFieldBase::A dd<google::protobuf::RepeatedPtrField<tensorflow::data::CompressedComponentMetadata>::TypeHandler>(g oogle::protobuf::RepeatedPtrField<tensorflow::data::CompressedComponentMetadata>::TypeHandler::Type const*))
>>> referenced 85 more times
ld.lld: error: undefined symbol: google::protobuf::RepeatedField<unsigned long long>::Reserve(int)
>>> referenced by save_restore_tensor.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/save_restore_tensor.pic.o:(void google::protobuf::RepeatedField<unsigned long long>::Add<unsigned long long const*>(unsigned long long const*, unsigned long long const*))
>>> referenced by save_restore_tensor.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/save_restore_tensor.pic.o:(google::protobuf::RepeatedField<unsigned long long> ::FastAdderImpl<0, true>::Add(unsigned long long))
ld.lld: error: undefined symbol: google::protobuf::RepeatedField<long long>::Reserve(int)
>>> referenced by save_restore_tensor.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/save_restore_tensor.pic.o:(void google::protobuf::RepeatedField<long long>::Ad d<long long const*>(long long const*, long long const*))
>>> referenced by save_restore_tensor.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/save_restore_tensor.pic.o:(google::protobuf::RepeatedField<long long>::FastAdd erImpl<0, true>::Add(long long))
ld.lld: error: undefined symbol: google::protobuf::RepeatedField<unsigned int>::Reserve(int)
>>> referenced by save_restore_tensor.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/save_restore_tensor.pic.o:(void google::protobuf::RepeatedField<unsigned int>: :Add<unsigned int const*>(unsigned int const*, unsigned int const*))
>>> referenced by save_restore_tensor.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/save_restore_tensor.pic.o:(google::protobuf::RepeatedField<unsigned int>::Fast AdderImpl<0, true>::Add(unsigned int))
ld.lld: error: undefined symbol: google::protobuf::RepeatedField<int>::Reserve(int)
>>> referenced by save_restore_tensor.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/save_restore_tensor.pic.o:(void google::protobuf::RepeatedField<int>::Add<unsi gned short const*>(unsigned short const*, unsigned short const*))
>>> referenced by save_restore_tensor.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/save_restore_tensor.pic.o:(google::protobuf::RepeatedField<int>::FastAdderImpl <0, true>::Add(int))
>>> referenced by save_restore_tensor.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/save_restore_tensor.pic.o:(void google::protobuf::RepeatedField<int>::Add<shor t const*>(short const*, short const*))
>>> referenced 8 more times
ld.lld: error: undefined symbol: google::protobuf::RepeatedField<float>::Reserve(int)
>>> referenced by save_restore_tensor.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/save_restore_tensor.pic.o:(void google::protobuf::RepeatedField<float>::Add<fl oat const*>(float const*, float const*))
>>> referenced by save_restore_tensor.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/save_restore_tensor.pic.o:(google::protobuf::RepeatedField<float>::FastAdderIm pl<0, true>::Add(float))
ld.lld: error: undefined symbol: google::protobuf::RepeatedField<double>::Reserve(int)
>>> referenced by save_restore_tensor.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/save_restore_tensor.pic.o:(void google::protobuf::RepeatedField<double>::Add<d ouble const*>(double const*, double const*))
>>> referenced by save_restore_tensor.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/save_restore_tensor.pic.o:(google::protobuf::RepeatedField<double>::FastAdderI mpl<0, true>::Add(double))
ld.lld: error: undefined symbol: google::protobuf::RepeatedField<bool>::Reserve(int)
>>> referenced by save_restore_tensor.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/save_restore_tensor.pic.o:(void google::protobuf::RepeatedField<bool>::Add<boo l const*>(bool const*, bool const*))
>>> referenced by save_restore_tensor.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/save_restore_tensor.pic.o:(google::protobuf::RepeatedField<bool>::FastAdderImp l<0, true>::Add(bool))
ld.lld: error: undefined symbol: google::protobuf::MessageLite::AppendToString(std::__ndk1::basic_st ring<char, std::__ndk1::char_traits<char>, std::__ndk1::allocator<char> >*) const
>>> referenced by tensor_list.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/tensor_list.pic.o:(tensorflow::TensorList::Encode(tensorflow::VariantTensorDat a*) const)
>>> referenced by tensor_coding.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tensorflow/core/_objs/portable_tensorflow_li b_lite/tensor_coding.pic.o:(tensorflow::port::StringListEncoderImpl::Append(google::protobuf::Messag eLite const&))
ld.lld: error: undefined symbol: google::protobuf::MessageLite::ParseFromString(std::__ndk1::basic_s tring<char, std::__ndk1::char_traits<char>, std::__ndk1::allocator<char> > const&)
>>> referenced by tensor_list.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/tensor_list.pic.o:(tensorflow::TensorList::Decode(tensorflow::VariantTensorDat a const&))
>>> referenced by compression_utils.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/compression_utils.pic.o:(tensorflow::data::UncompressElement(tensorflow::data: :CompressedElement const&, std::__ndk1::vector<tensorflow::Tensor, std::__ndk1::allocator<tensorflow ::Tensor> >*))
>>> referenced by compression_utils.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/compression_utils.pic.o:(bool tensorflow::DecodeVariantImpl<tensorflow::data:: CompressedElement>(tensorflow::VariantTensorData, tensorflow::TypeResolver<tensorflow::data::Compres sedElement, false, false, true>, tensorflow::data::CompressedElement*))
>>> referenced 11 more times
ld.lld: error: undefined symbol: google::protobuf::MessageLite::SerializeToArray(void*, int) const
>>> referenced by compression_utils.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/compression_utils.pic.o:(tensorflow::data::CompressElement(std::__ndk1::vector <tensorflow::Tensor, std::__ndk1::allocator<tensorflow::Tensor> > const&, tensorflow::data::Compress edElement*))
ld.lld: error: undefined symbol: google::protobuf::RepeatedField<unsigned long long>::Add(unsigned l ong long const&)
>>> referenced by compression_utils.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/compression_utils.pic.o:(tensorflow::data::CompressedComponentMetadata::_inter nal_add_uncompressed_bytes(unsigned long long))
>>> referenced by tensor.pb_text.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tensorflow/core/_objs/portable_tensorflow_li b_lite/tensor.pb_text.pic.o:(tensorflow::TensorProto::_internal_add_uint64_val(unsigned long long))
>>> referenced by graph_debug_info_builder.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tensorflow/core/_objs/portable_tensorflow_li b_lite/graph_debug_info_builder.pic.o:(tensorflow::GraphDebugInfo_StackTrace::_internal_add_frame_id (unsigned long long))
>>> referenced 1 more times
ld.lld: error: undefined symbol: google::protobuf::internal::ArenaStringPtr::Mutable(google::protobu f::Arena*)
>>> referenced by compression_utils.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/compression_utils.pic.o:(tensorflow::data::CompressedElement::_internal_mutabl e_data())
>>> referenced by dataset_utils.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/dataset_utils.pic.o:(tensorflow::NodeDef::_internal_mutable_device())
>>> referenced by attr_value.pb_text.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tensorflow/core/_objs/portable_tensorflow_li b_lite/attr_value.pb_text.pic.o:(tensorflow::AttrValue::_internal_mutable_s())
>>> referenced 66 more times
ld.lld: error: undefined symbol: google::protobuf::Message::GetTypeName() const
>>> referenced by compression_utils.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/compression_utils.pic.o:(tensorflow::Variant::Value<tensorflow::data::Compress edElement>::TypeName() const)
>>> referenced by compression_utils.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/compression_utils.pic.o:(void tensorflow::EncodeVariant<tensorflow::data::Comp ressedElement>(tensorflow::data::CompressedElement const&, tensorflow::VariantTensorData*))
>>> referenced by compression_utils.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/compression_utils.pic.o:(void tensorflow::EncodeVariant<tensorflow::data::Comp ressedElement>(tensorflow::data::CompressedElement const&, std::__ndk1::basic_string<char, std::__nd k1::char_traits<char>, std::__ndk1::allocator<char> >*))
>>> referenced 290 more times
ld.lld: error: undefined symbol: google::protobuf::MessageLite::SerializeToString(std::__ndk1::basic _string<char, std::__ndk1::char_traits<char>, std::__ndk1::allocator<char> >*) const
>>> referenced by compression_utils.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/compression_utils.pic.o:(void tensorflow::EncodeVariant<tensorflow::data::Comp ressedElement>(tensorflow::data::CompressedElement const&, tensorflow::VariantTensorData*))
>>> referenced by compression_utils.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tmp/_objs/custom_tensorflowlite_flex_flex_de legate_tensorflow_lib/compression_utils.pic.o:(void tensorflow::EncodeVariant<tensorflow::data::Comp ressedElement>(tensorflow::data::CompressedElement const&, std::__ndk1::basic_string<char, std::__nd k1::char_traits<char>, std::__ndk1::allocator<char> >*))
>>> referenced by variant.cc
>>> bazel-out/android-armeabi-v7a-opt/bin/tensorflow/core/_objs/portable_tensorflow_li b_lite/variant.pic.o:(.text._ZN10tensorflow13EncodeVariantINS_22VariantTensorDataProtoEEEvRKT_PNSt6_ _ndk112basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEE+0x0)
>>> referenced 4 more times
ld.lld: error: too many errors emitted, stopping now (use -error-limit=0 to see all errors)
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Target //tmp:tensorflow-lite-select-tf-ops failed to build
Use --verbose_failures to see the command lines of failed build steps.
INFO: Elapsed time: 370.448s, Critical Path: 199.99s
INFO: 800 processes: 40 internal, 760 local.
FAILED: Build did NOT complete successfully
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62881/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62881/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62880
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62880/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62880/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62880/events
|
https://github.com/tensorflow/tensorflow/issues/62880
| 2,112,355,623 |
I_kwDOArmXAs595_0n
| 62,880 |
INVALID_ARGUMENT: Unable to find the relevant tensor remote_handle
|
{
"login": "iCosmos76",
"id": 32038807,
"node_id": "MDQ6VXNlcjMyMDM4ODA3",
"avatar_url": "https://avatars.githubusercontent.com/u/32038807?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/iCosmos76",
"html_url": "https://github.com/iCosmos76",
"followers_url": "https://api.github.com/users/iCosmos76/followers",
"following_url": "https://api.github.com/users/iCosmos76/following{/other_user}",
"gists_url": "https://api.github.com/users/iCosmos76/gists{/gist_id}",
"starred_url": "https://api.github.com/users/iCosmos76/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/iCosmos76/subscriptions",
"organizations_url": "https://api.github.com/users/iCosmos76/orgs",
"repos_url": "https://api.github.com/users/iCosmos76/repos",
"events_url": "https://api.github.com/users/iCosmos76/events{/privacy}",
"received_events_url": "https://api.github.com/users/iCosmos76/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 996845227,
"node_id": "MDU6TGFiZWw5OTY4NDUyMjc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:dist-strat",
"name": "comp:dist-strat",
"color": "0052cc",
"default": false,
"description": "Distribution Strategy related issues"
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
closed
| false |
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"@iCosmos76 Kindly check that all IP addresses and ports specified in your cluster configuration are accurate and accessible across machines. Please ensure you're using the appropriate cluster resolver (e.g., tf.distribute.cluster_resolver.TFConfigClusterResolver) and that it's correctly configured with worker and parameter server addresses. Thank you!",
"@sushreebarsa Thank you very much for your help. Indeed, the machines I was trying to connect to were in the cloud and there is a firewall there that does not allow me to interact correctly with my local cluster members.",
"@iCosmos76 Could you please confirm if the issue has been resolved then?\r\n\r\nThank you!",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62880\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62880\">No</a>\n"
] | 2024-02-01T12:05:41 | 2024-02-05T04:50:21 | 2024-02-05T04:50:18 |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
source
### TensorFlow version
tensorflow 2.15.0.post1
### Custom code
Yes
### OS platform and distribution
Manjaro Linux 23.1.3, Linux Ubuntu 22.04
### Mobile device
_No response_
### Python version
3.11.6
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
Hello. I am using ParameterServerStrategy to train multiple workers who have different ip addresses. When I train the model on the host machine, the training is successful. But when I try to train a distributed model, this error appears: INVALID_ARGUMENT: Unable to find the relevant tensor remote_handle. Please help me.
### Standalone code to reproduce the issue
```shell
import json
import os
import sys
import pathlib
from keras.preprocessing.image import ImageDataGenerator
from tensorflow import keras
from tensorflow.keras import layers
import tensorflow as tf
import splitfolders
from tensorflow.keras.applications import ResNet50
from keras.layers import Dropout, Flatten, Dense
tf.debugging.experimental.enable_dump_debug_info(
"./tfdbg2_logdir",
tensor_debug_mode="FULL_HEALTH",
circular_buffer_size=-1)
os.environ["GRPC_FAIL_FAST"] = "use_caller"
os.environ["CUDA_VISIBLE_DEVICES"] = "-1"
cluster_resolver = tf.distribute.cluster_resolver.TFConfigClusterResolver()
def dataset_fn(input_context):
data_dir = "/home/Kompot/Distributed_calculations/archive/raw-img/"
data_dir = pathlib.Path(data_dir)
train_path='./output/train/'
val_path='./output/val'
test_path='./output/test'
class_names=os.listdir(train_path)
NUM_CLASSES = len(class_names)
BATCH_SIZE = 32
IMG_DIM = 224
train_datagen = ImageDataGenerator(zoom_range=0.15,width_shift_range=0.2,height_shift_range=0.2,shear_range=0.15)
train_generator = train_datagen.flow_from_directory(train_path,target_size=(IMG_DIM, IMG_DIM),batch_size=BATCH_SIZE)
dataset = tf.data.Dataset.from_generator(
lambda: train_generator,
output_signature=(
tf.TensorSpec(shape=[None, IMG_DIM, IMG_DIM, 3], dtype=tf.float32),
tf.TensorSpec(shape=[None, NUM_CLASSES], dtype=tf.float32)
)
)
dataset = dataset.shard(num_shards=input_context.num_input_pipelines, index=input_context.input_pipeline_id)
dataset = dataset.prefetch(tf.data.experimental.AUTOTUNE)
# dataset = dataset.shuffle(10)
return dataset
input_dataset = tf.keras.utils.experimental.DatasetCreator(dataset_fn=dataset_fn)
print("Waiting for workers and pss to connect...")
strategy = tf.distribute.experimental.ParameterServerStrategy(cluster_resolver=cluster_resolver)
with strategy.scope():
modelT = ResNet50(
input_shape=(224, 224, 3),
include_top=False,
weights='imagenet'
)
for layers in modelT.layers:
layers.trainable = False
y = Flatten()(modelT.output)
y = Dropout(0.5)(y)
y = Dense(10, activation="softmax")(y)
modelT = keras.Model(modelT.input, y)
modelT.compile(loss="categorical_crossentropy", optimizer="adam", metrics=["accuracy"], steps_per_execution='auto')
modelT.fit(input_dataset, epochs=10, steps_per_epoch=605)
```
### Relevant log output
```shell
Epoch 1/10
2024-02-01 09:17:23.866528: W ./tensorflow/core/distributed_runtime/eager/destroy_tensor_handle_node.h:59] Ignoring an error encountered when deleting remote tensors handles: INVALID_ARGUMENT: Unable to find the relevant tensor remote_handle: Op ID: 2344, Output num: 1
Additional GRPC error information from remote target /job:worker/replica:0/task:1 while calling /tensorflow.eager.EagerService/Enqueue:
:{"created":"@1706768243.863097783","description":"Error received from peer ipv4:51.250.11.138:8000","file":"external/com_github_grpc_grpc/src/core/lib/surface/call.cc","file_line":1056,"grpc_message":"Unable to find the relevant tensor remote_handle: Op ID: 2344, Output num: 1","grpc_status":3} [type.googleapis.com/tensorflow.core.platform.ErrorSourceProto='\x08\x05']
ERROR:tensorflow:Remote function on worker /job:worker/replica:0/task:1 failed with UnavailableError():failed to connect to all addresses
Additional GRPC error information from remote target /job:ps/replica:0/task:0/device:CPU:0 while calling /tensorflow.eager.EagerService/Enqueue:
:{"created":"@1706768248.511244031","description":"Failed to pick subchannel","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/client_channel.cc","file_line":3941,"referenced_errors":[{"created":"@1706768248.511239749","description":"failed to connect to all addresses","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/lb_policy/pick_first/pick_first.cc","file_line":393,"grpc_status":14}]}
Additional GRPC error information from remote target /job:worker/replica:0/task:1 while calling /tensorflow.eager.EagerService/Enqueue:
:{"created":"@1706768243.823390542","description":"Error received from peer ipv4:51.250.11.138:8000","file":"external/com_github_grpc_grpc/src/core/lib/surface/call.cc","file_line":1056,"grpc_message":"failed to connect to all addresses\nAdditional GRPC error information from remote target /job:ps/replica:0/task:0/device:CPU:0 while calling /tensorflow.eager.EagerService/Enqueue:\n:{"created":"@1706768248.511244031","description":"Failed to pick subchannel","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/client_channel.cc","file_line":3941,"referenced_errors":[{"created":"@1706768248.511239749","description":"failed to connect to all addresses","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/lb_policy/pick_first/pick_first.cc","file_line":393,"grpc_status":14}]}","grpc_status":14} [Op:__inference_train_function_16244]
It is treated as a transient connectivity failure for now.
ERROR:tensorflow:Remote function on worker /job:worker/replica:0/task:1 failed with UnavailableError():failed to connect to all addresses
Additional GRPC error information from remote target /job:ps/replica:0/task:0/device:CPU:0 while calling /tensorflow.eager.EagerService/Enqueue:
:{"created":"@1706768248.511244031","description":"Failed to pick subchannel","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/client_channel.cc","file_line":3941,"referenced_errors":[{"created":"@1706768248.511239749","description":"failed to connect to all addresses","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/lb_policy/pick_first/pick_first.cc","file_line":393,"grpc_status":14}]}
Additional GRPC error information from remote target /job:worker/replica:0/task:1 while calling /tensorflow.eager.EagerService/Enqueue:
:{"created":"@1706768243.823390542","description":"Error received from peer ipv4:51.250.11.138:8000","file":"external/com_github_grpc_grpc/src/core/lib/surface/call.cc","file_line":1056,"grpc_message":"failed to connect to all addresses\nAdditional GRPC error information from remote target /job:ps/replica:0/task:0/device:CPU:0 while calling /tensorflow.eager.EagerService/Enqueue:\n:{"created":"@1706768248.511244031","description":"Failed to pick subchannel","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/client_channel.cc","file_line":3941,"referenced_errors":[{"created":"@1706768248.511239749","description":"failed to connect to all addresses","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/lb_policy/pick_first/pick_first.cc","file_line":393,"grpc_status":14}]}","grpc_status":14} [Op:__inference_train_function_16244]
It is treated as a transient connectivity failure for now.
ERROR:tensorflow:Remote function on worker /job:worker/replica:0/task:1 failed with UnavailableError():failed to connect to all addresses
Additional GRPC error information from remote target /job:ps/replica:0/task:0/device:CPU:0 while calling /tensorflow.eager.EagerService/Enqueue:
:{"created":"@1706768268.511226712","description":"Failed to pick subchannel","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/client_channel.cc","file_line":3941,"referenced_errors":[{"created":"@1706768268.511222584","description":"failed to connect to all addresses","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/lb_policy/pick_first/pick_first.cc","file_line":393,"grpc_status":14}]}
Additional GRPC error information from remote target /job:worker/replica:0/task:1 while calling /tensorflow.eager.EagerService/Enqueue:
:{"created":"@1706768263.943495340","description":"Error received from peer ipv4:51.250.11.138:8000","file":"external/com_github_grpc_grpc/src/core/lib/surface/call.cc","file_line":1056,"grpc_message":"failed to connect to all addresses\nAdditional GRPC error information from remote target /job:ps/replica:0/task:0/device:CPU:0 while calling /tensorflow.eager.EagerService/Enqueue:\n:{"created":"@1706768268.511226712","description":"Failed to pick subchannel","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/client_channel.cc","file_line":3941,"referenced_errors":[{"created":"@1706768268.511222584","description":"failed to connect to all addresses","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/lb_policy/pick_first/pick_first.cc","file_line":393,"grpc_status":14}]}","grpc_status":14} [Op:__inference_train_function_16244]
It is treated as a transient connectivity failure for now.
ERROR:tensorflow:Remote function on worker /job:worker/replica:0/task:1 failed with UnavailableError():failed to connect to all addresses
Additional GRPC error information from remote target /job:ps/replica:0/task:0/device:CPU:0 while calling /tensorflow.eager.EagerService/Enqueue:
:{"created":"@1706768268.511226712","description":"Failed to pick subchannel","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/client_channel.cc","file_line":3941,"referenced_errors":[{"created":"@1706768268.511222584","description":"failed to connect to all addresses","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/lb_policy/pick_first/pick_first.cc","file_line":393,"grpc_status":14}]}
Additional GRPC error information from remote target /job:worker/replica:0/task:1 while calling /tensorflow.eager.EagerService/Enqueue:
:{"created":"@1706768263.943495340","description":"Error received from peer ipv4:51.250.11.138:8000","file":"external/com_github_grpc_grpc/src/core/lib/surface/call.cc","file_line":1056,"grpc_message":"failed to connect to all addresses\nAdditional GRPC error information from remote target /job:ps/replica:0/task:0/device:CPU:0 while calling /tensorflow.eager.EagerService/Enqueue:\n:{"created":"@1706768268.511226712","description":"Failed to pick subchannel","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/client_channel.cc","file_line":3941,"referenced_errors":[{"created":"@1706768268.511222584","description":"failed to connect to all addresses","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/lb_policy/pick_first/pick_first.cc","file_line":393,"grpc_status":14}]}","grpc_status":14} [Op:__inference_train_function_16244]
It is treated as a transient connectivity failure for now.
ERROR:tensorflow: /job:worker/task:1 encountered the following error when processing closure: UnavailableError():failed to connect to all addresses
Additional GRPC error information from remote target /job:ps/replica:0/task:0/device:CPU:0 while calling /tensorflow.eager.EagerService/Enqueue:
:{"created":"@1706768288.511248869","description":"Failed to pick subchannel","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/client_channel.cc","file_line":3941,"referenced_errors":[{"created":"@1706768288.511243624","description":"failed to connect to all addresses","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/lb_policy/pick_first/pick_first.cc","file_line":393,"grpc_status":14}]}
Additional GRPC error information from remote target /job:worker/replica:0/task:1 while calling /tensorflow.eager.EagerService/Enqueue:
:{"created":"@1706768283.943821199","description":"Error received from peer ipv4:51.250.11.138:8000","file":"external/com_github_grpc_grpc/src/core/lib/surface/call.cc","file_line":1056,"grpc_message":"failed to connect to all addresses\nAdditional GRPC error information from remote target /job:ps/replica:0/task:0/device:CPU:0 while calling /tensorflow.eager.EagerService/Enqueue:\n:{"created":"@1706768288.511248869","description":"Failed to pick subchannel","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/client_channel.cc","file_line":3941,"referenced_errors":[{"created":"@1706768288.511243624","description":"failed to connect to all addresses","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/lb_policy/pick_first/pick_first.cc","file_line":393,"grpc_status":14}]}","grpc_status":14} [Op:__inference_train_function_16244]
ERROR:tensorflow: /job:worker/task:1 encountered the following error when processing closure: UnavailableError():failed to connect to all addresses
Additional GRPC error information from remote target /job:ps/replica:0/task:0/device:CPU:0 while calling /tensorflow.eager.EagerService/Enqueue:
:{"created":"@1706768288.511248869","description":"Failed to pick subchannel","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/client_channel.cc","file_line":3941,"referenced_errors":[{"created":"@1706768288.511243624","description":"failed to connect to all addresses","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/lb_policy/pick_first/pick_first.cc","file_line":393,"grpc_status":14}]}
Additional GRPC error information from remote target /job:worker/replica:0/task:1 while calling /tensorflow.eager.EagerService/Enqueue:
:{"created":"@1706768283.943821199","description":"Error received from peer ipv4:51.250.11.138:8000","file":"external/com_github_grpc_grpc/src/core/lib/surface/call.cc","file_line":1056,"grpc_message":"failed to connect to all addresses\nAdditional GRPC error information from remote target /job:ps/replica:0/task:0/device:CPU:0 while calling /tensorflow.eager.EagerService/Enqueue:\n:{"created":"@1706768288.511248869","description":"Failed to pick subchannel","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/client_channel.cc","file_line":3941,"referenced_errors":[{"created":"@1706768288.511243624","description":"failed to connect to all addresses","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/lb_policy/pick_first/pick_first.cc","file_line":393,"grpc_status":14}]}","grpc_status":14} [Op:__inference_train_function_16244]
ERROR:tensorflow:Start cancelling closures due to error UnavailableError(): failed to connect to all addresses
Additional GRPC error information from remote target /job:ps/replica:0/task:0/device:CPU:0 while calling /tensorflow.eager.EagerService/Enqueue:
:{"created":"@1706768288.511248869","description":"Failed to pick subchannel","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/client_channel.cc","file_line":3941,"referenced_errors":[{"created":"@1706768288.511243624","description":"failed to connect to all addresses","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/lb_policy/pick_first/pick_first.cc","file_line":393,"grpc_status":14}]}
Additional GRPC error information from remote target /job:worker/replica:0/task:1 while calling /tensorflow.eager.EagerService/Enqueue:
:{"created":"@1706768283.943821199","description":"Error received from peer ipv4:51.250.11.138:8000","file":"external/com_github_grpc_grpc/src/core/lib/surface/call.cc","file_line":1056,"grpc_message":"failed to connect to all addresses\nAdditional GRPC error information from remote target /job:ps/replica:0/task:0/device:CPU:0 while calling /tensorflow.eager.EagerService/Enqueue:\n:{"created":"@1706768288.511248869","description":"Failed to pick subchannel","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/client_channel.cc","file_line":3941,"referenced_errors":[{"created":"@1706768288.511243624","description":"failed to connect to all addresses","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/lb_policy/pick_first/pick_first.cc","file_line":393,"grpc_status":14}]}","grpc_status":14} [Op:__inference_train_function_16244]
ERROR:tensorflow:Start cancelling closures due to error UnavailableError(): failed to connect to all addresses
Additional GRPC error information from remote target /job:ps/replica:0/task:0/device:CPU:0 while calling /tensorflow.eager.EagerService/Enqueue:
:{"created":"@1706768288.511248869","description":"Failed to pick subchannel","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/client_channel.cc","file_line":3941,"referenced_errors":[{"created":"@1706768288.511243624","description":"failed to connect to all addresses","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/lb_policy/pick_first/pick_first.cc","file_line":393,"grpc_status":14}]}
Additional GRPC error information from remote target /job:worker/replica:0/task:1 while calling /tensorflow.eager.EagerService/Enqueue:
:{"created":"@1706768283.943821199","description":"Error received from peer ipv4:51.250.11.138:8000","file":"external/com_github_grpc_grpc/src/core/lib/surface/call.cc","file_line":1056,"grpc_message":"failed to connect to all addresses\nAdditional GRPC error information from remote target /job:ps/replica:0/task:0/device:CPU:0 while calling /tensorflow.eager.EagerService/Enqueue:\n:{"created":"@1706768288.511248869","description":"Failed to pick subchannel","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/client_channel.cc","file_line":3941,"referenced_errors":[{"created":"@1706768288.511243624","description":"failed to connect to all addresses","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/lb_policy/pick_first/pick_first.cc","file_line":393,"grpc_status":14}]}","grpc_status":14} [Op:__inference_train_function_16244]
ERROR:tensorflow:Remote function on worker /job:worker/replica:0/task:0 failed with CancelledError():Cancelled
Additional GRPC error information from remote target /job:worker/replica:0/task:0 while calling /tensorflow.eager.EagerService/Enqueue:
:{"created":"@1706768284.014644991","description":"Error received from peer ipv4:192.168.83.219:2224","file":"external/com_github_grpc_grpc/src/core/lib/surface/call.cc","file_line":1056,"grpc_message":"Cancelled","grpc_status":1} [Op:__inference_train_function_16244]
This derived error is ignored and not reported to users.
ERROR:tensorflow:Remote function on worker /job:worker/replica:0/task:0 failed with CancelledError():Cancelled
Additional GRPC error information from remote target /job:worker/replica:0/task:0 while calling /tensorflow.eager.EagerService/Enqueue:
:{"created":"@1706768284.014644991","description":"Error received from peer ipv4:192.168.83.219:2224","file":"external/com_github_grpc_grpc/src/core/lib/surface/call.cc","file_line":1056,"grpc_message":"Cancelled","grpc_status":1} [Op:__inference_train_function_16244]
This derived error is ignored and not reported to users.
Traceback (most recent call last):
File "/home/Kompot/Distributed_calculations/./coordinator.py", line 123, in <module>
modelT.fit(input_dataset, epochs=10, steps_per_epoch=605)
File "/home/Kompot/Distributed_calculations/venv/lib/python3.11/site-packages/keras/src/utils/traceback_utils.py", line 70, in error_handler
raise e.with_traceback(filtered_tb) from None
File "/usr/lib/python3.11/contextlib.py", line 144, in __exit__
next(self.gen)
^^^^^^^^^^^^^^^^^^
tensorflow.python.framework.errors_impl.UnavailableError: failed to connect to all addresses
Additional GRPC error information from remote target /job:ps/replica:0/task:0/device:CPU:0 while calling /tensorflow.eager.EagerService/Enqueue:
:{"created":"@1706768288.511248869","description":"Failed to pick subchannel","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/client_channel.cc","file_line":3941,"referenced_errors":[{"created":"@1706768288.511243624","description":"failed to connect to all addresses","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/lb_policy/pick_first/pick_first.cc","file_line":393,"grpc_status":14}]}
Additional GRPC error information from remote target /job:worker/replica:0/task:1 while calling /tensorflow.eager.EagerService/Enqueue:
:{"created":"@1706768283.943821199","description":"Error received from peer ipv4:51.250.11.138:8000","file":"external/com_github_grpc_grpc/src/core/lib/surface/call.cc","file_line":1056,"grpc_message":"failed to connect to all addresses\nAdditional GRPC error information from remote target /job:ps/replica:0/task:0/device:CPU:0 while calling /tensorflow.eager.EagerService/Enqueue:\n:{"created":"@1706768288.511248869","description":"Failed to pick subchannel","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/client_channel.cc","file_line":3941,"referenced_errors":[{"created":"@1706768288.511243624","description":"failed to connect to all addresses","file":"external/com_github_grpc_grpc/src/core/ext/filters/client_channel/lb_policy/pick_first/pick_first.cc","file_line":393,"grpc_status":14}]}","grpc_status":14} [Op:__inference_train_function_16244]
2024-02-01 09:18:06.505567: I tensorflow/core/framework/local_rendezvous.cc:421] Local rendezvous recv item cancelled. Key hash: 14720224220024848622
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62880/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62880/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62879
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62879/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62879/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62879/events
|
https://github.com/tensorflow/tensorflow/pull/62879
| 2,111,127,244 |
PR_kwDOArmXAs5loEa3
| 62,879 |
[oneDNN] Fix macro titles in TF CPU feature guard
|
{
"login": "akhilgoe",
"id": 114951738,
"node_id": "U_kgDOBtoGOg",
"avatar_url": "https://avatars.githubusercontent.com/u/114951738?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/akhilgoe",
"html_url": "https://github.com/akhilgoe",
"followers_url": "https://api.github.com/users/akhilgoe/followers",
"following_url": "https://api.github.com/users/akhilgoe/following{/other_user}",
"gists_url": "https://api.github.com/users/akhilgoe/gists{/gist_id}",
"starred_url": "https://api.github.com/users/akhilgoe/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/akhilgoe/subscriptions",
"organizations_url": "https://api.github.com/users/akhilgoe/orgs",
"repos_url": "https://api.github.com/users/akhilgoe/repos",
"events_url": "https://api.github.com/users/akhilgoe/events{/privacy}",
"received_events_url": "https://api.github.com/users/akhilgoe/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 390482148,
"node_id": "MDU6TGFiZWwzOTA0ODIxNDg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/awaiting%20review",
"name": "awaiting review",
"color": "bc3869",
"default": false,
"description": "Pull request awaiting review"
},
{
"id": 987666414,
"node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull",
"name": "ready to pull",
"color": "2cd643",
"default": false,
"description": "PR ready for merge process"
},
{
"id": 1169364458,
"node_id": "MDU6TGFiZWwxMTY5MzY0NDU4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:S",
"name": "size:S",
"color": "adafea",
"default": false,
"description": "CL Change Size: Small"
},
{
"id": 1478826728,
"node_id": "MDU6TGFiZWwxNDc4ODI2NzI4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:core",
"name": "comp:core",
"color": "024391",
"default": false,
"description": "issues related to core part of tensorflow"
}
] |
closed
| false |
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[] | 2024-01-31T22:57:51 | 2024-02-02T05:00:55 | 2024-02-02T05:00:54 |
CONTRIBUTOR
| null | false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62879",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62879",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62879.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62879.patch",
"merged_at": "2024-02-02T05:00:54"
}
|
This PR fixes the titles of some of the macros used by the TF CPU feature guard and prevents displaying some erroneous messages while importing TensorFlow.
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62879/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62879/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62878
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62878/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62878/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62878/events
|
https://github.com/tensorflow/tensorflow/issues/62878
| 2,110,699,848 |
I_kwDOArmXAs59zrlI
| 62,878 |
Trying to reshape a tensor after applying a boolean_mask with XLA context will result in an error or wrong values
|
{
"login": "MoritzMSP",
"id": 117213406,
"node_id": "U_kgDOBvyI3g",
"avatar_url": "https://avatars.githubusercontent.com/u/117213406?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/MoritzMSP",
"html_url": "https://github.com/MoritzMSP",
"followers_url": "https://api.github.com/users/MoritzMSP/followers",
"following_url": "https://api.github.com/users/MoritzMSP/following{/other_user}",
"gists_url": "https://api.github.com/users/MoritzMSP/gists{/gist_id}",
"starred_url": "https://api.github.com/users/MoritzMSP/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/MoritzMSP/subscriptions",
"organizations_url": "https://api.github.com/users/MoritzMSP/orgs",
"repos_url": "https://api.github.com/users/MoritzMSP/repos",
"events_url": "https://api.github.com/users/MoritzMSP/events{/privacy}",
"received_events_url": "https://api.github.com/users/MoritzMSP/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 1133285679,
"node_id": "MDU6TGFiZWwxMTMzMjg1Njc5",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:xla",
"name": "comp:xla",
"color": "0052cc",
"default": false,
"description": "XLA"
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
closed
| false |
{
"login": "Venkat6871",
"id": 147127861,
"node_id": "U_kgDOCMT-NQ",
"avatar_url": "https://avatars.githubusercontent.com/u/147127861?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/Venkat6871",
"html_url": "https://github.com/Venkat6871",
"followers_url": "https://api.github.com/users/Venkat6871/followers",
"following_url": "https://api.github.com/users/Venkat6871/following{/other_user}",
"gists_url": "https://api.github.com/users/Venkat6871/gists{/gist_id}",
"starred_url": "https://api.github.com/users/Venkat6871/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Venkat6871/subscriptions",
"organizations_url": "https://api.github.com/users/Venkat6871/orgs",
"repos_url": "https://api.github.com/users/Venkat6871/repos",
"events_url": "https://api.github.com/users/Venkat6871/events{/privacy}",
"received_events_url": "https://api.github.com/users/Venkat6871/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "Venkat6871",
"id": 147127861,
"node_id": "U_kgDOCMT-NQ",
"avatar_url": "https://avatars.githubusercontent.com/u/147127861?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/Venkat6871",
"html_url": "https://github.com/Venkat6871",
"followers_url": "https://api.github.com/users/Venkat6871/followers",
"following_url": "https://api.github.com/users/Venkat6871/following{/other_user}",
"gists_url": "https://api.github.com/users/Venkat6871/gists{/gist_id}",
"starred_url": "https://api.github.com/users/Venkat6871/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Venkat6871/subscriptions",
"organizations_url": "https://api.github.com/users/Venkat6871/orgs",
"repos_url": "https://api.github.com/users/Venkat6871/repos",
"events_url": "https://api.github.com/users/Venkat6871/events{/privacy}",
"received_events_url": "https://api.github.com/users/Venkat6871/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi **@MoritzMSP** ,\r\nIt throws an error as it should, given that you're attempting to reshape the tensor to [3, 2], a shape that does not match the number of elements passed through the mask (which should be 6 for your example). This is the correct behavior because XLA cannot validate the shape you're trying to reshape into due to the dynamic nature of the boolean mask operation.\r\nHere I attached [gist](https://colab.sandbox.google.com/gist/Venkat6871/5850f413a403c2ad3bf8c934bfd66030/62878_2-15-v.ipynb) for your reference.\r\n\r\nThank you!\r\n\r\n",
"@Venkat6871 thank you for clarification",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62878\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62878\">No</a>\n"
] | 2024-01-31T18:19:23 | 2024-02-02T09:59:20 | 2024-02-02T09:59:16 |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
No
### Source
source
### TensorFlow version
2.15.post1
### Custom code
Yes
### OS platform and distribution
WSL Ubuntu 22.04
### Mobile device
_No response_
### Python version
3.10.12
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
Trying to reshape a tensor after applying a boolean_mask with XLA context will result in an error. The masked Tensor is not recognized as being smaller and can therefor not be reshaped into the correct size.
In my particular case, working with the flattened tensor after applying the mask is not possible. A reshape into the right dimension is therefor necessary. Also applying the mask outside of the XLA context won't work in my context. I've also tried using tf.ragged.boolean_mask, however the error still persists and my further computations won't work with ragged Tensors.
### Standalone code to reproduce the issue
```shell
# Code is only for demonstration purpose and vastly simplified to show the error
A = tf.reshape(tf.range(1,10), [3,3]) #Creates an 3x3 Matrix with elements from 1-9
mask = tf.broadcast_to(tf.constant([True, False, True]), [3, 3]) #Creates mask with same dimensions as A
# Some functions for exploration of the error
# tf.boolean_mask may be substituted with tf.ragged.boolean_mask
@tf.function(jit_compile=True)
def func1(A, mask):
return tf.boolean_mask(A, mask)
@tf.function(jit_compile=True)
def func2(A, mask):
return tf.reshape(tf.boolean_mask(A, mask), [3,3])
@tf.function(jit_compile=True)
def func3(A, mask):
return tf.reshape(tf.boolean_mask(A, mask), [3,2])
func1(A, mask)
# When using tf.boolean_mask --> Will return the correct values, however in a flatted tensor
# When using tf.ragged.boolean_mask --> Will return the correct values, in the correct shape, however as a ragged tensor
func2(A, mask) # --> An error should be thrown since only 6 elements are in the Tensor after masking
# When using tf.boolean_mask or tf.ragged.boolean_mask --> Will return <tf.Tensor: shape=(3, 3), dtype=int32, numpy=
# array([[1, 3, 4],
# [6, 7, 9],
# [1, 1, 1]], dtype=int32)>
# which are NOT the correct values
func3(A, mask) # Should work
# When using tf.boolean_mask or tf.ragged.boolean_mask --> Will throw an error as provided below
```
### Relevant log output
```shell
W tensorflow/core/framework/op_kernel.cc:1839] OP_REQUIRES failed at xla_ops.cc:574 : INVALID_ARGUMENT: Input to reshape is a tensor with 9 values, but the requested shape has 6
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62878/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62878/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62877
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62877/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62877/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62877/events
|
https://github.com/tensorflow/tensorflow/pull/62877
| 2,110,513,386 |
PR_kwDOArmXAs5ll971
| 62,877 |
Test the oneDNN testing on arm64 builds
|
{
"login": "MichaelHudgins",
"id": 30155094,
"node_id": "MDQ6VXNlcjMwMTU1MDk0",
"avatar_url": "https://avatars.githubusercontent.com/u/30155094?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/MichaelHudgins",
"html_url": "https://github.com/MichaelHudgins",
"followers_url": "https://api.github.com/users/MichaelHudgins/followers",
"following_url": "https://api.github.com/users/MichaelHudgins/following{/other_user}",
"gists_url": "https://api.github.com/users/MichaelHudgins/gists{/gist_id}",
"starred_url": "https://api.github.com/users/MichaelHudgins/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/MichaelHudgins/subscriptions",
"organizations_url": "https://api.github.com/users/MichaelHudgins/orgs",
"repos_url": "https://api.github.com/users/MichaelHudgins/repos",
"events_url": "https://api.github.com/users/MichaelHudgins/events{/privacy}",
"received_events_url": "https://api.github.com/users/MichaelHudgins/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 1169364259,
"node_id": "MDU6TGFiZWwxMTY5MzY0MjU5",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS",
"name": "size:XS",
"color": "adafea",
"default": false,
"description": "CL Change Size: Extra Small"
}
] |
closed
| false |
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[] | 2024-01-31T16:39:05 | 2024-03-12T21:09:23 | 2024-02-12T15:42:04 |
COLLABORATOR
| null | true |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62877",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62877",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62877.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62877.patch",
"merged_at": null
}
| null |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62877/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62877/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62876
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62876/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62876/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62876/events
|
https://github.com/tensorflow/tensorflow/pull/62876
| 2,110,487,600 |
PR_kwDOArmXAs5ll4V-
| 62,876 |
Relax some tolerances for tests running with oneDNN enabled
|
{
"login": "elfringham",
"id": 10442001,
"node_id": "MDQ6VXNlcjEwNDQyMDAx",
"avatar_url": "https://avatars.githubusercontent.com/u/10442001?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/elfringham",
"html_url": "https://github.com/elfringham",
"followers_url": "https://api.github.com/users/elfringham/followers",
"following_url": "https://api.github.com/users/elfringham/following{/other_user}",
"gists_url": "https://api.github.com/users/elfringham/gists{/gist_id}",
"starred_url": "https://api.github.com/users/elfringham/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/elfringham/subscriptions",
"organizations_url": "https://api.github.com/users/elfringham/orgs",
"repos_url": "https://api.github.com/users/elfringham/repos",
"events_url": "https://api.github.com/users/elfringham/events{/privacy}",
"received_events_url": "https://api.github.com/users/elfringham/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 390482148,
"node_id": "MDU6TGFiZWwzOTA0ODIxNDg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/awaiting%20review",
"name": "awaiting review",
"color": "bc3869",
"default": false,
"description": "Pull request awaiting review"
},
{
"id": 987666414,
"node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull",
"name": "ready to pull",
"color": "2cd643",
"default": false,
"description": "PR ready for merge process"
},
{
"id": 1097545273,
"node_id": "MDU6TGFiZWwxMDk3NTQ1Mjcz",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:grappler",
"name": "comp:grappler",
"color": "0052cc",
"default": false,
"description": "Grappler related issues"
},
{
"id": 1169364259,
"node_id": "MDU6TGFiZWwxMTY5MzY0MjU5",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS",
"name": "size:XS",
"color": "adafea",
"default": false,
"description": "CL Change Size: Extra Small"
}
] |
closed
| false |
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "penpornk",
"id": 38085909,
"node_id": "MDQ6VXNlcjM4MDg1OTA5",
"avatar_url": "https://avatars.githubusercontent.com/u/38085909?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/penpornk",
"html_url": "https://github.com/penpornk",
"followers_url": "https://api.github.com/users/penpornk/followers",
"following_url": "https://api.github.com/users/penpornk/following{/other_user}",
"gists_url": "https://api.github.com/users/penpornk/gists{/gist_id}",
"starred_url": "https://api.github.com/users/penpornk/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/penpornk/subscriptions",
"organizations_url": "https://api.github.com/users/penpornk/orgs",
"repos_url": "https://api.github.com/users/penpornk/repos",
"events_url": "https://api.github.com/users/penpornk/events{/privacy}",
"received_events_url": "https://api.github.com/users/penpornk/received_events",
"type": "User",
"site_admin": false
},
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[] | 2024-01-31T16:25:31 | 2024-02-05T08:15:55 | 2024-01-31T20:59:30 |
CONTRIBUTOR
| null | false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62876",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62876",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62876.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62876.patch",
"merged_at": "2024-01-31T20:59:30"
}
|
Slight numerical differences mean that some tolerances need to be relaxed for unit tests to still pass.
Fixes: #62835
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62876/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62876/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62875
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62875/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62875/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62875/events
|
https://github.com/tensorflow/tensorflow/issues/62875
| 2,110,198,581 |
I_kwDOArmXAs59xxM1
| 62,875 |
tf.matMul
|
{
"login": "N1k0l1n",
"id": 97979235,
"node_id": "U_kgDOBdcLYw",
"avatar_url": "https://avatars.githubusercontent.com/u/97979235?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/N1k0l1n",
"html_url": "https://github.com/N1k0l1n",
"followers_url": "https://api.github.com/users/N1k0l1n/followers",
"following_url": "https://api.github.com/users/N1k0l1n/following{/other_user}",
"gists_url": "https://api.github.com/users/N1k0l1n/gists{/gist_id}",
"starred_url": "https://api.github.com/users/N1k0l1n/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/N1k0l1n/subscriptions",
"organizations_url": "https://api.github.com/users/N1k0l1n/orgs",
"repos_url": "https://api.github.com/users/N1k0l1n/repos",
"events_url": "https://api.github.com/users/N1k0l1n/events{/privacy}",
"received_events_url": "https://api.github.com/users/N1k0l1n/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 1097547147,
"node_id": "MDU6TGFiZWwxMDk3NTQ3MTQ3",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:ops",
"name": "comp:ops",
"color": "0052cc",
"default": false,
"description": "OPs related issues"
}
] |
closed
| false |
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"@tilakrayal in the given case the output [[17, 23], [39, 53]] is correct. You're doing a matrix multiplication with the following matricies:\r\n```\r\n|1 2| * |5 7|\r\n|3 4| * |6 8| \r\n```\r\n\r\nso the first element will be \r\n`1*5 + 2*6 =17`\r\nPerhaps you've reversed 6 and 7.",
"Yeah, I switched the possition and i didnt evene noticed. Im terrebly sorry. Thank you for your time",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62875\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62875\">No</a>\n"
] | 2024-01-31T14:17:11 | 2024-02-01T03:47:11 | 2024-01-31T17:54:19 |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
source
### TensorFlow version
3.9.0
### Custom code
Yes
### OS platform and distribution
Windows 10
### Mobile device
_No response_
### Python version
Python 3.12.1
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
Im new to tensorflow js, so please excuse me if the issue is resolved prior. I have a problem iwth tf.matMul, when trying to do this operation with a 2x2 matrix, and the first value is wrong.
### Standalone code to reproduce the issue
```shell
const a = tf.tensor2d([[1, 2], [3, 4]]);
const b = tf.tensor2d([[5, 7], [6, 8]]);
a.matMul(b).print(); // Expected Output: [[19, 23], [39, 53]]
Insted I get : [[17, 23], [39, 53]]
```
### Relevant log output
_No response_
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62875/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62875/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62874
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62874/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62874/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62874/events
|
https://github.com/tensorflow/tensorflow/pull/62874
| 2,108,820,374 |
PR_kwDOArmXAs5lgNJ5
| 62,874 |
Include missing tsl/xla folders on Windows
|
{
"login": "mraunak",
"id": 83710963,
"node_id": "MDQ6VXNlcjgzNzEwOTYz",
"avatar_url": "https://avatars.githubusercontent.com/u/83710963?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/mraunak",
"html_url": "https://github.com/mraunak",
"followers_url": "https://api.github.com/users/mraunak/followers",
"following_url": "https://api.github.com/users/mraunak/following{/other_user}",
"gists_url": "https://api.github.com/users/mraunak/gists{/gist_id}",
"starred_url": "https://api.github.com/users/mraunak/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/mraunak/subscriptions",
"organizations_url": "https://api.github.com/users/mraunak/orgs",
"repos_url": "https://api.github.com/users/mraunak/repos",
"events_url": "https://api.github.com/users/mraunak/events{/privacy}",
"received_events_url": "https://api.github.com/users/mraunak/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 987666414,
"node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull",
"name": "ready to pull",
"color": "2cd643",
"default": false,
"description": "PR ready for merge process"
},
{
"id": 1169364259,
"node_id": "MDU6TGFiZWwxMTY5MzY0MjU5",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS",
"name": "size:XS",
"color": "adafea",
"default": false,
"description": "CL Change Size: Extra Small"
}
] |
closed
| false |
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"@mraunak , about #62579 , it looks like the nightly build still have the problem, even after merging this PR. What is missing is not folder in this case but symbols exported by the C library:\r\n```\r\njnitensorflow.obj : error LNK2001: unresolved external symbol TSL_DeleteStatus\r\njnitensorflow.obj : error LNK2001: unresolved external symbol TSL_SetStatus\r\njnitensorflow.obj : error LNK2001: unresolved external symbol TSL_SetStatusFromIOError\r\njnitensorflow.obj : error LNK2001: unresolved external symbol \"struct TFE_TensorHandle * __cdecl TFE_NewTensorHandle(class tensorflow::Tensor const &,struct TSL_Status *)\" (?TFE_NewTensorHandle@@YAPEAUTFE_TensorHandle@@AEBVTensor@tensorflow@@PEAUTSL_Status@@@Z)\r\n Hint on symbols that are defined and could potentially match:\r\n TFE_NewTensorHandle\r\njnitensorflow.obj : error LNK2001: unresolved external symbol TSL_Message\r\njnitensorflow.obj : error LNK2001: unresolved external symbol TSL_ForEachPayload\r\njnitensorflow.obj : error LNK2001: unresolved external symbol TSL_NewStatus\r\njnitensorflow.obj : error LNK2001: unresolved external symbol TSL_GetCode\r\njnitensorflow.obj : error LNK2001: unresolved external symbol TSL_SetPayload\r\n```"
] | 2024-01-30T21:32:19 | 2024-02-05T00:18:41 | 2024-01-31T04:22:18 |
CONTRIBUTOR
| null | false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62874",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62874",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62874.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62874.patch",
"merged_at": "2024-01-31T04:22:18"
}
|
This PR aims to resolve the issue of the missing TSL and XLA folders within the 'include' directory in the TF release and nightly wheels specifically for the Windows platform. The folders are present for the Linux platform
It addresses the Github issues mentioned below:
https://github.com/tensorflow/tensorflow/issues/62579
https://github.com/tensorflow/tensorflow/issues/61830
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62874/reactions",
"total_count": 1,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 1
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62874/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62873
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62873/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62873/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62873/events
|
https://github.com/tensorflow/tensorflow/pull/62873
| 2,108,612,078 |
PR_kwDOArmXAs5lffBn
| 62,873 |
[oneDNN] Upgrade oneDNN version to v3.3.4
|
{
"login": "ashiqimranintel",
"id": 65728957,
"node_id": "MDQ6VXNlcjY1NzI4OTU3",
"avatar_url": "https://avatars.githubusercontent.com/u/65728957?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/ashiqimranintel",
"html_url": "https://github.com/ashiqimranintel",
"followers_url": "https://api.github.com/users/ashiqimranintel/followers",
"following_url": "https://api.github.com/users/ashiqimranintel/following{/other_user}",
"gists_url": "https://api.github.com/users/ashiqimranintel/gists{/gist_id}",
"starred_url": "https://api.github.com/users/ashiqimranintel/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/ashiqimranintel/subscriptions",
"organizations_url": "https://api.github.com/users/ashiqimranintel/orgs",
"repos_url": "https://api.github.com/users/ashiqimranintel/repos",
"events_url": "https://api.github.com/users/ashiqimranintel/events{/privacy}",
"received_events_url": "https://api.github.com/users/ashiqimranintel/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 390482148,
"node_id": "MDU6TGFiZWwzOTA0ODIxNDg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/awaiting%20review",
"name": "awaiting review",
"color": "bc3869",
"default": false,
"description": "Pull request awaiting review"
},
{
"id": 987666414,
"node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull",
"name": "ready to pull",
"color": "2cd643",
"default": false,
"description": "PR ready for merge process"
},
{
"id": 1104829434,
"node_id": "MDU6TGFiZWwxMTA0ODI5NDM0",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:mkl",
"name": "comp:mkl",
"color": "0052cc",
"default": false,
"description": "MKL related issues"
},
{
"id": 1169364259,
"node_id": "MDU6TGFiZWwxMTY5MzY0MjU5",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS",
"name": "size:XS",
"color": "adafea",
"default": false,
"description": "CL Change Size: Extra Small"
}
] |
closed
| false |
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "penpornk",
"id": 38085909,
"node_id": "MDQ6VXNlcjM4MDg1OTA5",
"avatar_url": "https://avatars.githubusercontent.com/u/38085909?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/penpornk",
"html_url": "https://github.com/penpornk",
"followers_url": "https://api.github.com/users/penpornk/followers",
"following_url": "https://api.github.com/users/penpornk/following{/other_user}",
"gists_url": "https://api.github.com/users/penpornk/gists{/gist_id}",
"starred_url": "https://api.github.com/users/penpornk/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/penpornk/subscriptions",
"organizations_url": "https://api.github.com/users/penpornk/orgs",
"repos_url": "https://api.github.com/users/penpornk/repos",
"events_url": "https://api.github.com/users/penpornk/events{/privacy}",
"received_events_url": "https://api.github.com/users/penpornk/received_events",
"type": "User",
"site_admin": false
},
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[] | 2024-01-30T19:34:52 | 2024-02-06T15:50:29 | 2024-02-06T15:50:29 |
CONTRIBUTOR
| null | false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62873",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62873",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62873.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62873.patch",
"merged_at": "2024-02-06T15:50:29"
}
|
This PR upgrades oneDNN version from v3.3 to v3.3.4, this PR has been tested on several models across different platforms including cascade-lake, sapphire-rapids, and granite-rapids
Several bug fixes have been resolved in this version. Details can be found here https://github.com/oneapi-src/oneDNN/releases
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62873/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62873/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62872
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62872/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62872/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62872/events
|
https://github.com/tensorflow/tensorflow/issues/62872
| 2,108,471,751 |
I_kwDOArmXAs59rLnH
| 62,872 |
Details of the calculation when referencing a quantized TFLite CNN model
|
{
"login": "Truongdhvnu",
"id": 122275694,
"node_id": "U_kgDOB0nHbg",
"avatar_url": "https://avatars.githubusercontent.com/u/122275694?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/Truongdhvnu",
"html_url": "https://github.com/Truongdhvnu",
"followers_url": "https://api.github.com/users/Truongdhvnu/followers",
"following_url": "https://api.github.com/users/Truongdhvnu/following{/other_user}",
"gists_url": "https://api.github.com/users/Truongdhvnu/gists{/gist_id}",
"starred_url": "https://api.github.com/users/Truongdhvnu/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Truongdhvnu/subscriptions",
"organizations_url": "https://api.github.com/users/Truongdhvnu/orgs",
"repos_url": "https://api.github.com/users/Truongdhvnu/repos",
"events_url": "https://api.github.com/users/Truongdhvnu/events{/privacy}",
"received_events_url": "https://api.github.com/users/Truongdhvnu/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473184161,
"node_id": "MDU6TGFiZWw0NzMxODQxNjE=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:support",
"name": "type:support",
"color": "159b2e",
"default": false,
"description": "Support issues"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
},
{
"id": 750616506,
"node_id": "MDU6TGFiZWw3NTA2MTY1MDY=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite",
"name": "comp:lite",
"color": "0052cc",
"default": false,
"description": "TF Lite related issues"
},
{
"id": 5922361893,
"node_id": "LA_kwDOArmXAs8AAAABYQASJQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF2.14",
"name": "TF2.14",
"color": "b60205",
"default": false,
"description": "For issues related to Tensorflow 2.14.x"
}
] |
closed
| false |
{
"login": "LakshmiKalaKadali",
"id": 149650845,
"node_id": "U_kgDOCOt9nQ",
"avatar_url": "https://avatars.githubusercontent.com/u/149650845?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/LakshmiKalaKadali",
"html_url": "https://github.com/LakshmiKalaKadali",
"followers_url": "https://api.github.com/users/LakshmiKalaKadali/followers",
"following_url": "https://api.github.com/users/LakshmiKalaKadali/following{/other_user}",
"gists_url": "https://api.github.com/users/LakshmiKalaKadali/gists{/gist_id}",
"starred_url": "https://api.github.com/users/LakshmiKalaKadali/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/LakshmiKalaKadali/subscriptions",
"organizations_url": "https://api.github.com/users/LakshmiKalaKadali/orgs",
"repos_url": "https://api.github.com/users/LakshmiKalaKadali/repos",
"events_url": "https://api.github.com/users/LakshmiKalaKadali/events{/privacy}",
"received_events_url": "https://api.github.com/users/LakshmiKalaKadali/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "LakshmiKalaKadali",
"id": 149650845,
"node_id": "U_kgDOCOt9nQ",
"avatar_url": "https://avatars.githubusercontent.com/u/149650845?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/LakshmiKalaKadali",
"html_url": "https://github.com/LakshmiKalaKadali",
"followers_url": "https://api.github.com/users/LakshmiKalaKadali/followers",
"following_url": "https://api.github.com/users/LakshmiKalaKadali/following{/other_user}",
"gists_url": "https://api.github.com/users/LakshmiKalaKadali/gists{/gist_id}",
"starred_url": "https://api.github.com/users/LakshmiKalaKadali/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/LakshmiKalaKadali/subscriptions",
"organizations_url": "https://api.github.com/users/LakshmiKalaKadali/orgs",
"repos_url": "https://api.github.com/users/LakshmiKalaKadali/repos",
"events_url": "https://api.github.com/users/LakshmiKalaKadali/events{/privacy}",
"received_events_url": "https://api.github.com/users/LakshmiKalaKadali/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi @Truongdhvnu,\r\n\r\nIt's appreciable for your research interest on TFLite quantization. \r\n\r\n>How my data calculate thought these tensors with specific input value. And why is the last tensor look so strange (no name and all paramers are equal 0)\r\n\r\nIn the TFLite quantization process, the input values, weights and bias data types(float) at each layer are converted to either to int8/int16/float16/... during conversion depending on target device. The quantization might be symmetric(-127to +128) or affine(Unsymmetric 0-255) . To know how tensors are quantized, please refer [ link1](https://towardsdatascience.com/tensor-quantization-the-untold-story-d798c30e7646).\r\n\r\nThe last unnamed tensor might be an unused tensor created during the conversion process. \r\n\r\n>I tried to quantization with all parameters is uint8, but i can't find supported parameter to configure for converter\r\n\r\nFor more clear interpretation about tensors and their quantized values add the following command for tflite file.```tf.lite.experimental.Analyzer.analyze(model_content=tflite_quant_model) ``` and use [link2](https://netron.app/) for better visualization of the quantized model .\r\n\r\n```\r\ninterpreter = tf.lite.Interpreter(model_content=tflite_quant_model, experimental_preserve_all_tensors=True)\r\ninterpreter.allocate_tensors()\r\ntensor_details = interpreter.get_tensor_details()\r\ntf.lite.experimental.Analyzer.analyze(model_content=tflite_quant_model) \r\n```\r\n\r\nThank You\r\n\r\n\r\n\r\n",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62872\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62872\">No</a>\n"
] | 2024-01-30T18:12:54 | 2024-02-21T01:47:06 | 2024-02-21T01:47:02 |
NONE
| null | null | null |
### Issue type
Documentation Feature Request
### Have you reproduced the bug with TensorFlow Nightly?
No
### Source
source
### TensorFlow version
2.14.0
### Custom code
Yes
### OS platform and distribution
Window10
### Mobile device
_No response_
### Python version
_No response_
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
for the purpose of research and learning, I am trying to understand the series of mathematical operations needed to operate when using a CNN quantized model. I started with quantized conv2D layers.
I studied a [paper](https://arxiv.org/pdf/1712.05877.pdf) about the quantization method and inference method. As I understand, when operating conv2D, an affine function is applied to input data and kernels; then, we add bias to the result. Finally, we quantize the result to uint8 (also using an affine function), so the uint8 quantized result can be used for the next layer.
I created a very simple model that contains only one conv2D layer, with 1 input channel and 1 output channel. So, the only operation this layer performs is the convolution between the input and the simple kernel that I created.
```
input = np.array([[[[1] for _ in range(4)] for _ in range(4)]])
custom_matrix = np.array([[1,1,1], [0.5, 0.5, 0.5], [1, 1, 1]]).astype(np.float32)
custom_initializer = Constant(value=custom_matrix)
def creat_model():
model = Sequential(
[
Conv2D(1, (3,3), padding="same", input_shape = (4,4,1), kernel_initializer=custom_initializer),
]
)
return model
model = creat_model()
```
Then, i quantized the simple model
```
random_matrices = np.random.randint(0, 256, size=(50, 4, 4, 1))
print(random_matrices[0].shape)
x_train = random_matrices / 255.0
x_train = np.asarray(x_train).astype(np.float32)
x_train = np.asarray(x_train).astype(np.float32)
def representative_data_gen():
for input_value in tf.data.Dataset.from_tensor_slices(x_train).batch(1).take(40):
yield [input_value]
converter = tf.lite.TFLiteConverter.from_keras_model(model)
converter.optimizations = [tf.lite.Optimize.DEFAULT]
converter.representative_dataset = representative_data_gen
converter.target_spec.supported_ops = [tf.lite.OpsSet.TFLITE_BUILTINS_INT8]
converter.inference_input_type = tf.uint8
converter.inference_output_type = tf.uint8
tflite_quant_model = converter.convert()
```
I succesfully infer using this quantized model (the result of the origin model & of quantized model are quite the same).
But when i print details about the quantized model using
```
interpreter = tf.lite.Interpreter(model_content=tflite_quant_model, experimental_preserve_all_tensors=True)
interpreter.allocate_tensors()
tensor_details = interpreter.get_tensor_details()
for tensor_detail in tensor_details:
print(tensor_detail['index'], " Name: ", tensor_detail["name"])
print(" Quant_parameters:", tensor_detail["quantization"])
print(" Type:", tensor_detail["dtype"])
```
The result is
```
0 Name: serving_default_conv2d_4_input:0
Quant_parameters: (0.003921568859368563, 0)
Type: <class 'numpy.uint8'>
1 Name: sequential_4/conv2d_4/BiasAdd/ReadVariableOp
Quant_parameters: (3.0878494726493955e-05, 0)
Type: <class 'numpy.int32'>
2 Name: sequential_4/conv2d_4/Conv2D
Quant_parameters: (0.007874015718698502, 0)
Type: <class 'numpy.int8'>
3 Name: tfl.quantize
Quant_parameters: (0.003921568859368563, -128)
Type: <class 'numpy.int8'>
4 Name: StatefulPartitionedCall:01
Quant_parameters: (0.023214150220155716, -128)
Type: <class 'numpy.int8'>
5 Name: StatefulPartitionedCall:0
Quant_parameters: (0.023214150220155716, 0)
Type: <class 'numpy.uint8'>
6 Name:
Quant_parameters: (0.0, 0)
Type: <class 'numpy.int8'>
```
I tried to find documetation about these tensors for many days but i can't. I think that the first tensor is used to convert input value range from \[0,1\] to \[0,255\]. The second tensor for operating with bias parameters. The third tensor for convolution operation. But i don know how last tensors operate with their quantization parameters to get final result.
My questions is:
1. How my data calculate thought these tensors with specific input value. And why is the last tensor look so strange (no name and all paramers are equal 0)
2. I tried to quantization with all parameters is uint8, but i can't find supported parameter to configure for converter
I really need and will appreciate any help or suggestions I may receive. Thank you so much.
### Standalone code to reproduce the issue
```shell
(code above)
```
### Relevant log output
_No response_
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62872/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62872/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62871
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62871/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62871/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62871/events
|
https://github.com/tensorflow/tensorflow/issues/62871
| 2,108,170,411 |
I_kwDOArmXAs59qCCr
| 62,871 |
Building stuck at "Linking tensorflow/libtensorflow_cc.so.2.16.0" with "--compilation_mode=dbg"
|
{
"login": "Doomski99",
"id": 45564681,
"node_id": "MDQ6VXNlcjQ1NTY0Njgx",
"avatar_url": "https://avatars.githubusercontent.com/u/45564681?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/Doomski99",
"html_url": "https://github.com/Doomski99",
"followers_url": "https://api.github.com/users/Doomski99/followers",
"following_url": "https://api.github.com/users/Doomski99/following{/other_user}",
"gists_url": "https://api.github.com/users/Doomski99/gists{/gist_id}",
"starred_url": "https://api.github.com/users/Doomski99/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Doomski99/subscriptions",
"organizations_url": "https://api.github.com/users/Doomski99/orgs",
"repos_url": "https://api.github.com/users/Doomski99/repos",
"events_url": "https://api.github.com/users/Doomski99/events{/privacy}",
"received_events_url": "https://api.github.com/users/Doomski99/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 473173351,
"node_id": "MDU6TGFiZWw0NzMxNzMzNTE=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:build/install",
"name": "type:build/install",
"color": "159b2e",
"default": false,
"description": "Build and install issues"
}
] |
closed
| false |
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Build stopped with an error after several hours:\r\n\r\n```\r\nbazel build -c opt tensorflow/lite/python:tflite_convert --compilation_mode=dbg --verbose_failures\r\nINFO: Reading 'startup' options from /private/tensorflow/.bazelrc: --windows_enable_symlinks\r\nINFO: Options provided by the client:\r\n Inherited 'common' options: --isatty=1 --terminal_columns=203\r\nINFO: Reading rc options for 'build' from /private/tensorflow/.bazelrc:\r\n Inherited 'common' options: --experimental_repo_remote_exec\r\nINFO: Reading rc options for 'build' from /private/tensorflow/.bazelrc:\r\n 'build' options: --define framework_shared_object=true --define tsl_protobuf_header_only=true --define=use_fast_cpp_protos=true --define=allow_oversize_protos=true --spawn_strategy=standalone -c opt --announce_rc --define=grpc_no_ares=true --noincompatible_remove_legacy_whole_archive --features=-force_no_whole_archive --enable_platform_specific_config --define=with_xla_support=true --config=short_logs --config=v2 --define=no_aws_support=true --define=no_hdfs_support=true --experimental_cc_shared_library --experimental_link_static_libraries_once=false --incompatible_enforce_config_setting_visibility\r\nINFO: Found applicable config definition build:short_logs in file /private/tensorflow/.bazelrc: --output_filter=DONT_MATCH_ANYTHING\r\nINFO: Found applicable config definition build:v2 in file /private/tensorflow/.bazelrc: --define=tf_api_version=2 --action_env=TF2_BEHAVIOR=1\r\nINFO: Found applicable config definition build:linux in file /private/tensorflow/.bazelrc: --host_copt=-w --copt=-Wno-all --copt=-Wno-extra --copt=-Wno-deprecated --copt=-Wno-deprecated-declarations --copt=-Wno-ignored-attributes --copt=-Wno-array-bounds --copt=-Wunused-result --copt=-Werror=unused-result --copt=-Wswitch --copt=-Werror=switch --copt=-Wno-error=unused-but-set-variable --define=PREFIX=/usr --define=LIBDIR=$(PREFIX)/lib --define=INCLUDEDIR=$(PREFIX)/include --define=PROTOBUF_INCLUDE_PATH=$(PREFIX)/include --cxxopt=-std=c++17 --host_cxxopt=-std=c++17 --config=dynamic_kernels --experimental_guard_against_concurrent_changes\r\nINFO: Found applicable config definition build:dynamic_kernels in file /private/tensorflow/.bazelrc: --define=dynamic_loaded_kernels=true --copt=-DAUTOLOAD_DYNAMIC_KERNELS\r\nINFO: Analyzed target //tensorflow/lite/python:tflite_convert (0 packages loaded, 0 targets configured).\r\nINFO: Found 1 target...\r\nERROR: /private/tensorflow/tensorflow/BUILD:1314:21: Linking tensorflow/libtensorflow_cc.so.2.16.0 failed: (Exit 1): gcc failed: error executing command (from target //tensorflow:libtensorflow_cc.so.2.16.0) \r\n (cd /home/rd/.cache/bazel/_bazel_rd/7dd12a92052954e911919783cd6ca021/execroot/org_tensorflow && \\\r\n exec env - \\\r\n PATH=/home/rd/anaconda3/bin:/home/rd/anaconda3/condabin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/snap/bin \\\r\n PWD=/proc/self/cwd \\\r\n TF2_BEHAVIOR=1 \\\r\n /usr/bin/gcc @bazel-out/k8-dbg/bin/tensorflow/libtensorflow_cc.so.2.16.0-2.params)\r\n# Configuration: 922fc4df46810e014c35c27c9665581d34e181306206844730af5a180c2c4048\r\n# Execution platform: @local_execution_config_platform//:platform\r\nstderr (/home/rd/.cache/bazel/_bazel_rd/7dd12a92052954e911919783cd6ca021/execroot/org_tensorflow/bazel-out/_tmp/actions/stderr-2) 608971967 exceeds maximum size of --experimental_ui_max_stdouterr_bytes=1048576 bytes; skipping\r\nTarget //tensorflow/lite/python:tflite_convert failed to build\r\nINFO: Elapsed time: 16653.336s, Critical Path: 16652.51s\r\nINFO: 2 processes: 2 internal.\r\nFAILED: Build did NOT complete successfully\r\n```\r\n\r\nThe file stderr-2 is very large (at 600MB+) and contains lines such as:\r\n\r\n```\r\nbazel-out/k8-dbg/bin/external/com_google_absl/absl/random/internal/_objs/platform/randen_round_keys.pic.o(.debug_aranges+0x6): error: relocation overflow: reference to local symbol 3 in bazel-out/k8-dbg/bin/external/com_google_absl/absl/random/internal/_objs/platform/randen_round_keys.pic.o\r\n\r\nbazel-out/k8-dbg/bin/external/com_google_absl/absl/log/internal/_objs/nullguard/nullguard.pic.o(.debug_info+0x4cd): error: relocation overflow: reference to local symbol 5 in bazel-out/k8-dbg/bin/external/com_google_absl/absl/log/internal/_objs/nullguard/nullguard.pic.o\r\n\r\nbazel-out/k8-dbg/bin/tensorflow/core/kernels/_objs/cwise_op/cwise_op_maximum.pic.o(.debug_info+0x2f83ac): error: relocation overflow: reference to local symbol 15443 in bazel-out/k8-dbg/bin/tensorflow/core/kernels/_objs/cwise_op/cwise_op_maximum.pic.o\r\n\r\nbazel-out/k8-dbg/bin/tensorflow/core/kernels/_objs/cwise_op/cwise_op_less_equal.pic.o(.debug_info+0x42a89c): error: relocation overflow: reference to local symbol 15191 in bazel-out/k8-dbg/bin/tensorflow/core/kernels/_objs/cwise_op/cwise_op_less_equal.pic.o\r\n```",
"I'm not sure if changing --compilation_mode to --config fixed it or it was the --per_file_copt, nonetheless I ran this command and it worked:\r\n`bazel build --config=dbg --verbose_failures --jobs=16 --per_file_copt=+tensorflow/compiler/mlir/lite/*@-g //tensorflow/lite/python:tflite_convert`.\r\nThis helped: https://github.com/tensorflow/tensorflow/blob/master/CONTRIBUTING.md",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62871\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62871\">No</a>\n"
] | 2024-01-30T15:40:11 | 2024-01-31T15:12:24 | 2024-01-31T15:11:54 |
NONE
| null | null | null |
### Issue type
Build/Install
### Have you reproduced the bug with TensorFlow Nightly?
No
### Source
source
### TensorFlow version
2.16
### Custom code
No
### OS platform and distribution
Linux Ubuntu 22.04.1 LTS
### Mobile device
_No response_
### Python version
3.11
### Bazel version
6.5.0
### GCC/compiler version
11.4.0
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
I'm trying to build tensorflow/lite/python:tflite_convert with compilation_mode=dbg to debug it later with gdb. I've tried with two very different systems: one with an intel cpu on WSL2 win11 and one with a ryzen cpu on native ubuntu. Both are getting stuck with linking "tensorflow/libtensorflow_cc.so.2.16.0". Is it supposed to take many hours? I've built the tflite_convert many times without that compilation mode and it always builds successfully.
Full output (after restarting the command):
```
bazel build -c opt tensorflow/lite/python:tflite_convert --compilation_mode=dbg --verbose_failures
INFO: Reading 'startup' options from /private/tensorflow/.bazelrc: --windows_enable_symlinks
INFO: Options provided by the client:
Inherited 'common' options: --isatty=1 --terminal_columns=203
INFO: Reading rc options for 'build' from /private/tensorflow/.bazelrc:
Inherited 'common' options: --experimental_repo_remote_exec
INFO: Reading rc options for 'build' from /private/tensorflow/.bazelrc:
'build' options: --define framework_shared_object=true --define tsl_protobuf_header_only=true --define=use_fast_cpp_protos=true --define=allow_oversize_protos=true --spawn_strategy=standalone -c opt --announce_rc --define=grpc_no_ares=true --noincompatible_remove_legacy_whole_archive --features=-force_no_whole_archive --enable_platform_specific_config --define=with_xla_support=true --config=short_logs --config=v2 --define=no_aws_support=true --define=no_hdfs_support=true --experimental_cc_shared_library --experimental_link_static_libraries_once=false --incompatible_enforce_config_setting_visibility
INFO: Found applicable config definition build:short_logs in file /private/tensorflow/.bazelrc: --output_filter=DONT_MATCH_ANYTHING
INFO: Found applicable config definition build:v2 in file /private/tensorflow/.bazelrc: --define=tf_api_version=2 --action_env=TF2_BEHAVIOR=1
INFO: Found applicable config definition build:linux in file /private/tensorflow/.bazelrc: --host_copt=-w --copt=-Wno-all --copt=-Wno-extra --copt=-Wno-deprecated --copt=-Wno-deprecated-declarations --copt=-Wno-ignored-attributes --copt=-Wno-array-bounds --copt=-Wunused-result --copt=-Werror=unused-result --copt=-Wswitch --copt=-Werror=switch --copt=-Wno-error=unused-but-set-variable --define=PREFIX=/usr --define=LIBDIR=$(PREFIX)/lib --define=INCLUDEDIR=$(PREFIX)/include --define=PROTOBUF_INCLUDE_PATH=$(PREFIX)/include --cxxopt=-std=c++17 --host_cxxopt=-std=c++17 --config=dynamic_kernels --experimental_guard_against_concurrent_changes
INFO: Found applicable config definition build:dynamic_kernels in file /private/tensorflow/.bazelrc: --define=dynamic_loaded_kernels=true --copt=-DAUTOLOAD_DYNAMIC_KERNELS
INFO: Analyzed target //tensorflow/lite/python:tflite_convert (0 packages loaded, 0 targets configured).
INFO: Found 1 target...
[1 / 63] Linking tensorflow/libtensorflow_cc.so.2.16.0; 1220s local
```
### Standalone code to reproduce the issue
```shell
git clone latest tensorflow repo then run:
bazel build -c opt tensorflow/lite/python:tflite_convert --compilation_mode=dbg --verbose_failures
```
### Relevant log output
_No response_
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62871/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62871/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62870
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62870/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62870/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62870/events
|
https://github.com/tensorflow/tensorflow/pull/62870
| 2,108,166,933 |
PR_kwDOArmXAs5ld-h6
| 62,870 |
Correct tag to exclude on AARCH64 to be no_aarch64
|
{
"login": "elfringham",
"id": 10442001,
"node_id": "MDQ6VXNlcjEwNDQyMDAx",
"avatar_url": "https://avatars.githubusercontent.com/u/10442001?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/elfringham",
"html_url": "https://github.com/elfringham",
"followers_url": "https://api.github.com/users/elfringham/followers",
"following_url": "https://api.github.com/users/elfringham/following{/other_user}",
"gists_url": "https://api.github.com/users/elfringham/gists{/gist_id}",
"starred_url": "https://api.github.com/users/elfringham/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/elfringham/subscriptions",
"organizations_url": "https://api.github.com/users/elfringham/orgs",
"repos_url": "https://api.github.com/users/elfringham/repos",
"events_url": "https://api.github.com/users/elfringham/events{/privacy}",
"received_events_url": "https://api.github.com/users/elfringham/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 390482148,
"node_id": "MDU6TGFiZWwzOTA0ODIxNDg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/awaiting%20review",
"name": "awaiting review",
"color": "bc3869",
"default": false,
"description": "Pull request awaiting review"
},
{
"id": 987666414,
"node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull",
"name": "ready to pull",
"color": "2cd643",
"default": false,
"description": "PR ready for merge process"
},
{
"id": 1169364259,
"node_id": "MDU6TGFiZWwxMTY5MzY0MjU5",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS",
"name": "size:XS",
"color": "adafea",
"default": false,
"description": "CL Change Size: Extra Small"
},
{
"id": 1478826728,
"node_id": "MDU6TGFiZWwxNDc4ODI2NzI4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:core",
"name": "comp:core",
"color": "024391",
"default": false,
"description": "issues related to core part of tensorflow"
}
] |
closed
| false |
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[] | 2024-01-30T15:38:46 | 2024-02-01T18:01:03 | 2024-02-01T18:01:03 |
CONTRIBUTOR
| null | false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62870",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62870",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62870.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62870.patch",
"merged_at": "2024-02-01T18:01:03"
}
|
Correct this sole use of no_arm64 to be no_aarch64 to be consistent with pre-existing tag and usage.
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62870/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62870/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62869
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62869/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62869/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62869/events
|
https://github.com/tensorflow/tensorflow/issues/62869
| 2,107,004,526 |
I_kwDOArmXAs59llZu
| 62,869 |
Inconsistency of `LeftShift` between eager mode and JIT=true
|
{
"login": "zoux1a",
"id": 100054206,
"node_id": "U_kgDOBfa0vg",
"avatar_url": "https://avatars.githubusercontent.com/u/100054206?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/zoux1a",
"html_url": "https://github.com/zoux1a",
"followers_url": "https://api.github.com/users/zoux1a/followers",
"following_url": "https://api.github.com/users/zoux1a/following{/other_user}",
"gists_url": "https://api.github.com/users/zoux1a/gists{/gist_id}",
"starred_url": "https://api.github.com/users/zoux1a/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/zoux1a/subscriptions",
"organizations_url": "https://api.github.com/users/zoux1a/orgs",
"repos_url": "https://api.github.com/users/zoux1a/repos",
"events_url": "https://api.github.com/users/zoux1a/events{/privacy}",
"received_events_url": "https://api.github.com/users/zoux1a/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
},
{
"id": 1097547147,
"node_id": "MDU6TGFiZWwxMDk3NTQ3MTQ3",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:ops",
"name": "comp:ops",
"color": "0052cc",
"default": false,
"description": "OPs related issues"
},
{
"id": 5922361893,
"node_id": "LA_kwDOArmXAs8AAAABYQASJQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF2.14",
"name": "TF2.14",
"color": "b60205",
"default": false,
"description": "For issues related to Tensorflow 2.14.x"
}
] |
closed
| false |
{
"login": "Venkat6871",
"id": 147127861,
"node_id": "U_kgDOCMT-NQ",
"avatar_url": "https://avatars.githubusercontent.com/u/147127861?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/Venkat6871",
"html_url": "https://github.com/Venkat6871",
"followers_url": "https://api.github.com/users/Venkat6871/followers",
"following_url": "https://api.github.com/users/Venkat6871/following{/other_user}",
"gists_url": "https://api.github.com/users/Venkat6871/gists{/gist_id}",
"starred_url": "https://api.github.com/users/Venkat6871/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Venkat6871/subscriptions",
"organizations_url": "https://api.github.com/users/Venkat6871/orgs",
"repos_url": "https://api.github.com/users/Venkat6871/repos",
"events_url": "https://api.github.com/users/Venkat6871/events{/privacy}",
"received_events_url": "https://api.github.com/users/Venkat6871/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "Venkat6871",
"id": 147127861,
"node_id": "U_kgDOCMT-NQ",
"avatar_url": "https://avatars.githubusercontent.com/u/147127861?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/Venkat6871",
"html_url": "https://github.com/Venkat6871",
"followers_url": "https://api.github.com/users/Venkat6871/followers",
"following_url": "https://api.github.com/users/Venkat6871/following{/other_user}",
"gists_url": "https://api.github.com/users/Venkat6871/gists{/gist_id}",
"starred_url": "https://api.github.com/users/Venkat6871/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Venkat6871/subscriptions",
"organizations_url": "https://api.github.com/users/Venkat6871/orgs",
"repos_url": "https://api.github.com/users/Venkat6871/repos",
"events_url": "https://api.github.com/users/Venkat6871/events{/privacy}",
"received_events_url": "https://api.github.com/users/Venkat6871/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi **@zoux1a** ,\r\n\r\nI was able to reproduce the issue on colab using TF v2.15, and TF-nightly. Please find the [gist](https://colab.sandbox.google.com/gist/Venkat6871/30f067f2c0c10cbc396fb8032b6e0b07/62869_2-15-nightly-v.ipynb) here for reference.\r\n\r\nThank you!",
"Hi **@zoux1a** ,\r\n\r\n- Ensure that the input tensors tensor_x and tensor_y have the correct shapes and data types. The LeftShift operation requires that the first tensor (x) be an integer tensor, and the second tensor (y) can be either an integer or a boolean tensor.\r\n- The raw_ops.LeftShift operation is used to perform bitwise left shift operations on tensors. However, this operation is only available for integer tensors. If you need to perform a bitwise left shift on a boolean tensor, you should use the bitwise.left_shift operation instead.\r\n- Here i used bitwise.left_shift, it works fine. i am providing [gist](https://colab.sandbox.google.com/gist/Venkat6871/e2e891a2ee396422b1da55014f63e20d/62869_2-16-1-v.ipynb) for your reference.\r\n\r\nThank you!\r\n\r\n",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62869\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62869\">No</a>\n"
] | 2024-01-30T05:48:48 | 2024-05-10T01:49:27 | 2024-05-10T01:49:24 |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
source
### TensorFlow version
2.14.1
### Custom code
Yes
### OS platform and distribution
Ubuntu 22.04.3 LTS (x86_64)
### Mobile device
_No response_
### Python version
_No response_
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
Different outputs of `tf.raw_ops.LeftShift` between eagermode and op mode are observed.
### Standalone code to reproduce the issue
```shell
import tensorflow as tf
class Network(tf.Module):
def __init__(self):
super().__init__()
@tf.function(jit_compile=True)
def __call__(self, x, y):
x = tf.raw_ops.LeftShift(y=x, x=y)
return x
m = Network()
tensor_x = tf.random.uniform([],minval=0,maxval=255,dtype=tf.int32)
tensor_y = tf.random.uniform([9],minval=0,maxval=255,dtype=tf.int32)
inp = {
"x": tensor_x,
"y": tensor_y
}
with tf.device('/CPU:0'):
tf.config.run_functions_eagerly(True)
no_op_res = m(**inp)
tf.config.run_functions_eagerly(False)
with tf.device('/CPU:0'):
op_res = m(**inp)
tf.debugging.assert_near(tf.cast(no_op_res, tf.float64), tf.cast(op_res, tf.float64), atol=0.001, rtol=0.001)
```
### Relevant log output
```shell
raise errors.InvalidArgumentError(
tensorflow.python.framework.errors_impl.InvalidArgumentError: Expected 'tf.Tensor(False, shape=(), dtype=bool)' to be true. Summarized data: b''
b'x and y not equal to tolerance rtol = tf.Tensor(0.001, shape=(), dtype=float64), atol = tf.Tensor(0.001, shape=(), dtype=float64)'
b'x (shape=(9,) dtype=float64) = '
-2147483648.0, 0.0, 0.0, ...
b'y (shape=(9,) dtype=float64) = '
0.0, 0.0, 0.0, ...
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62869/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62869/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62868
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62868/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62868/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62868/events
|
https://github.com/tensorflow/tensorflow/issues/62868
| 2,106,844,397 |
I_kwDOArmXAs59k-Tt
| 62,868 |
error: ‘tensorflow::error’ has not been declared Status(tensorflow::error::Code code, tensorflow::StringPiece msg);
|
{
"login": "Frinklin-Wang",
"id": 102162481,
"node_id": "U_kgDOBhbgMQ",
"avatar_url": "https://avatars.githubusercontent.com/u/102162481?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/Frinklin-Wang",
"html_url": "https://github.com/Frinklin-Wang",
"followers_url": "https://api.github.com/users/Frinklin-Wang/followers",
"following_url": "https://api.github.com/users/Frinklin-Wang/following{/other_user}",
"gists_url": "https://api.github.com/users/Frinklin-Wang/gists{/gist_id}",
"starred_url": "https://api.github.com/users/Frinklin-Wang/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Frinklin-Wang/subscriptions",
"organizations_url": "https://api.github.com/users/Frinklin-Wang/orgs",
"repos_url": "https://api.github.com/users/Frinklin-Wang/repos",
"events_url": "https://api.github.com/users/Frinklin-Wang/events{/privacy}",
"received_events_url": "https://api.github.com/users/Frinklin-Wang/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 473184161,
"node_id": "MDU6TGFiZWw0NzMxODQxNjE=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:support",
"name": "type:support",
"color": "159b2e",
"default": false,
"description": "Support issues"
},
{
"id": 1478826728,
"node_id": "MDU6TGFiZWwxNDc4ODI2NzI4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:core",
"name": "comp:core",
"color": "024391",
"default": false,
"description": "issues related to core part of tensorflow"
},
{
"id": 1548890241,
"node_id": "MDU6TGFiZWwxNTQ4ODkwMjQx",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%201.15",
"name": "TF 1.15",
"color": "e99695",
"default": false,
"description": "for issues seen on TF 1.15"
}
] |
closed
| false |
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"@Frinklin-Wang,\r\nTensorFlow 1.x is not actively supported. Could you please update TensorFlow to the latest stable version v2.15 and check if you are facing the same issue.\r\n\r\nAlso I suspect you have missed to submit the CMakeLists Info:\r\n```python\r\ncmake_minimum_required\r\nproject(tensorflow_cc_test)\r\nset(CMAKE_CXX_STANDARD 11)\r\nset(TENSORFLOW_DIR )\r\ninclude_directories(${TENSORFLOW_DIR})\r\ninclude_directories(${TENSORFLOW_DIR}/tensorflow/contrib/makefile/downloads/absl)\r\ninclude_directories(${TENSORFLOW_DIR}/tensorflow/contrib/makefile/downloads/protobuf/src)\r\ninclude_directories(${TENSORFLOW_DIR}/tensorflow/contrib/makefile/gen/proto)\r\ninclude_directories(${TENSORFLOW_DIR}/tensorflow/contrib/makefile/gen/protobuf-host/include)\r\ninclude_directories(${TENSORFLOW_DIR}/tensorflow/contrib/makefile/downloads)\r\ninclude_directories(${TENSORFLOW_DIR}/tensorflow/contrib/makefile/downloads/eigen)\r\ninclude_directories(${TENSORFLOW_DIR}/tensorflow/contrib/makefile/downloads/nsync/public)\r\n\r\nlink_directories(${TENSORFLOW_DIR}/tensorflow/contrib/makefile/gen/lib)\r\nlink_directories(${TENSORFLOW_DIR}/tensorflow/contrib/makefile/gen/protobuf-host/lib)\r\nlink_directories(${TENSORFLOW_DIR}/tensorflow/contrib/makefile/downloads/nsync/builds/default.linux.c++11)\r\nlink_directories(${TENSORFLOW_DIR}/bazel-bin/tensorflow)\r\n\r\nadd_executable(tensorflow_cc_test hello.cpp)\r\ntarget_link_libraries(tensorflow_cc_test tensorflow_cc tensorflow_framework)\r\n```\r\nand try to add a declare `class tensorflow::error::Code`\r\n\r\nThank you!",
"@tilakrayal ,\r\nI add a declare `class tensorflow::error::Code` in `.../core/lib/core/status.h`. But it doesn't work.\r\nAnd I don't know how to compile the tensorflow2.x c++ static library. I only try tensorflow1.x c++ static library.\r\n\r\nI add `#include<error_codes.pb.h>` in `tensorflow/core/lib/core/status.h `, it does work. But, there are some other errors:\r\n```\r\n/usr/bin/ld: CMakeFiles/tensorflow_cc_test.dir/test.cpp.o: in function `main':\r\ntest.cpp:(.text+0x82): undefined reference to `tensorflow::SessionOptions::SessionOptions()'\r\n/usr/bin/ld: test.cpp:(.text+0xa2): undefined reference to `tensorflow::NewSession(tensorflow::SessionOptions const&, tensorflow::Session**)'\r\n/usr/bin/ld: test.cpp:(.text+0xe0): undefined reference to `tensorflow::Status::ToString[abi:cxx11]() const'\r\n/usr/bin/ld: CMakeFiles/tensorflow_cc_test.dir/test.cpp.o: in function `tensorflow::core::RefCounted::~RefCounted()':\r\ntest.cpp:(.text._ZN10tensorflow4core10RefCountedD2Ev[_ZN10tensorflow4core10RefCountedD5Ev]+0xf8): undefined reference to `tensorflow::internal::LogMessageFatal::LogMessageFatal(char const*, int)'\r\n/usr/bin/ld: test.cpp:(.text._ZN10tensorflow4core10RefCountedD2Ev[_ZN10tensorflow4core10RefCountedD5Ev]+0x120): undefined reference to `tensorflow::internal::LogMessageFatal::~LogMessageFatal()'\r\n/usr/bin/ld: CMakeFiles/tensorflow_cc_test.dir/test.cpp.o: in function `tensorflow::SessionOptions::~SessionOptions()':\r\ntest.cpp:(.text._ZN10tensorflow14SessionOptionsD2Ev[_ZN10tensorflow14SessionOptionsD5Ev]+0x1c): undefined reference to `tensorflow::ConfigProto::~ConfigProto()'\r\n/usr/bin/ld: CMakeFiles/tensorflow_cc_test.dir/test.cpp.o: in function `std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >* tensorflow::internal::MakeCheckOpString<long, int>(long const&, int const&, char const*)':\r\ntest.cpp:(.text._ZN10tensorflow8internal17MakeCheckOpStringIliEEPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKT_RKT0_PKc[_ZN10tensorflow8internal17MakeCheckOpStringIliEEPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKT_RKT0_PKc]+0x37): undefined reference to `tensorflow::internal::CheckOpMessageBuilder::CheckOpMessageBuilder(char const*)'\r\n/usr/bin/ld: test.cpp:(.text._ZN10tensorflow8internal17MakeCheckOpStringIliEEPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKT_RKT0_PKc[_ZN10tensorflow8internal17MakeCheckOpStringIliEEPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKT_RKT0_PKc]+0x61): undefined reference to `tensorflow::internal::CheckOpMessageBuilder::ForVar2()'\r\n/usr/bin/ld: test.cpp:(.text._ZN10tensorflow8internal17MakeCheckOpStringIliEEPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKT_RKT0_PKc[_ZN10tensorflow8internal17MakeCheckOpStringIliEEPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKT_RKT0_PKc]+0x7f): undefined reference to `tensorflow::internal::CheckOpMessageBuilder::NewString[abi:cxx11]()'\r\n/usr/bin/ld: test.cpp:(.text._ZN10tensorflow8internal17MakeCheckOpStringIliEEPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKT_RKT0_PKc[_ZN10tensorflow8internal17MakeCheckOpStringIliEEPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKT_RKT0_PKc]+0x8f): undefined reference to `tensorflow::internal::CheckOpMessageBuilder::~CheckOpMessageBuilder()'\r\n/usr/bin/ld: test.cpp:(.text._ZN10tensorflow8internal17MakeCheckOpStringIliEEPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKT_RKT0_PKc[_ZN10tensorflow8internal17MakeCheckOpStringIliEEPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKT_RKT0_PKc]+0xb6): undefined reference to `tensorflow::internal::CheckOpMessageBuilder::~CheckOpMessageBuilder()'\r\ncollect2: error: ld returned 1 exit status\r\nmake[2]: *** [CMakeFiles/tensorflow_cc_test.dir/build.make:97: tensorflow_cc_test] Error 1\r\nmake[1]: *** [CMakeFiles/Makefile2:83: CMakeFiles/tensorflow_cc_test.dir/all] Error 2\r\nmake: *** [Makefile:91: all] Error 2\r\n```\r\nMy test.cpp is :\r\n```\r\n#include \"tensorflow/core/platform/env.h\"\r\n#include \"tensorflow/core/public/session.h\"\r\n#include <iostream>\r\nusing namespace std;\r\nusing namespace tensorflow;\r\nint main()\r\n{\r\n Session* session;\r\n Status status = NewSession(SessionOptions(), &session);\r\n if (!status.ok()) {\r\n cout << status.ToString() << \"\\n\";\r\n return 1;\r\n }\r\n cout << \"Session successfully created.\\n\";\r\n}\r\n```\r\nHow to solve the problems?",
"I solved these errors when I modified the contents of CMakeLists.txt.\r\n```\r\nCMAKE_MINIMUM_REQUIRED(VERSION 2.8)\r\nproject(load_model)\r\nset(TENSORFLOW /home/wmc/tensorflow1.x/tensorflow-r1.15/)\r\nSET(TENSORFLOW_CORE_PATH ${CMAKE_SOURCE_DIR}/tensorflow/core)\r\nMESSAGE(STATUS \"TENSORFLOW_CORE_PATH ${TENSORFLOW_CORE_PATH}\")\r\nSET(TENSORFLOW_LIBARY ${CMAKE_SOURCE_DIR}/tensorflow/lib/libtensorflow-core.a)\r\nMESSAGE(STATUS \"TENSORFLOW_LIBARY ${TENSORFLOW_LIBARY}\")\r\nSET(TENSORFLOW_PROTOBUF_INCLUDE_PATH ${CMAKE_SOURCE_DIR}/tensorflow/protobuf/include)\r\nSET(TENSORFLOW_PROTOBUF_LIBRARY_PATH ${CMAKE_SOURCE_DIR}/tensorflow/protobuf/lib)\r\nMESSAGE(STATUS \"TENSORFLOW_PROTOBUF_INCLUDE_PATH ${TENSORFLOW_PROTOBUF_INCLUDE_PATH}\")\r\nMESSAGE(STATUS \"TENSORFLOW_PROTOBUF_LIBRARY_PATH ${TENSORFLOW_PROTOBUF_LIBRARY_PATH}\")\r\nSET(TENSORFLOW_PROTOBUF_LIBRARY ${TENSORFLOW_PROTOBUF_LIBRARY_PATH}/libprotobuf.a)\r\nSET(TENSORFLOW_PROTOC_LIBRARY ${TENSORFLOW_PROTOBUF_LIBRARY_PATH}/libprotoc.a)\r\nMESSAGE(STATUS \"TENSORFLOW_NSYNC_INCLUDE_PATH ${TENSORFLOW_PROTOBUF_LIBRARY}\")\r\nMESSAGE(STATUS \"TENSORFLOW_NSYNC_LIBRARY_PATH ${TENSORFLOW_PROTOC_LIBRARY}\")\r\nSET(TENSORFLOW_NSYNC_INCLUDE_PATH ${CMAKE_SOURCE_DIR}/tensorflow/nsyc/include)\r\nSET(TENSORFLOW_NSYNC_LIBRARY_PATH ${CMAKE_SOURCE_DIR}/tensorflow/nsyc/lib)\r\nMESSAGE(STATUS \"TENSORFLOW_NSYNC_INCLUDE_PATH ${TENSORFLOW_NSYNC_INCLUDE_PATH}\")\r\nMESSAGE(STATUS \"TENSORFLOW_NSYNC_LIBRARY_PATH ${TENSORFLOW_NSYNC_LIBRARY_PATH}\")\r\nSET(TENSORFLOW_NSYNC_LIBRARY ${TENSORFLOW_NSYNC_LIBRARY_PATH}/libnsync.a)\r\nMESSAGE(STATUS \"TENSORFLOW_NSYNC_LIBRARY ${TENSORFLOW_NSYNC_LIBRARY}\")\r\nSET(TENSORFLOW_PROTO_INCLUDE_PATH ${CMAKE_SOURCE_DIR}/tensorflow/proto)\r\nSET(TENSORFLOW_PROTO_TEXT_INCLUDE_PATH ${CMAKE_SOURCE_DIR}/tensorflow/proto_text)\r\nSET(TENSORFLOW_HOST_OBJ_INCLUDE_PATH ${CMAKE_SOURCE_DIR}/tensorflow/host_obj/)\r\nSET(TENSORFLOW_EIGEN_INCLUDE_PATH ${CMAKE_SOURCE_DIR}/tensorflow/eigen3)\r\nSET(TENSORFLOW_ABSL_INCLUDE_PATH ${CMAKE_SOURCE_DIR}/tensorflow/absl)\r\nSET(TENSORFLOW_THIRD_PARTY_INCLUDE_PATH ${CMAKE_SOURCE_DIR}/tensorflow/tensorflow_third_party)\r\nMESSAGE(STATUS \"TENSORFLOW_PROTO_INCLUDE_PATH ${TENSORFLOW_PROTO_INCLUDE_PATH}\")\r\nMESSAGE(STATUS \"TENSORFLOW_PROTO_TEXT_INCLUDE_PATH ${TENSORFLOW_PROTO_TEXT_INCLUDE_PATH}\")\r\nMESSAGE(STATUS \"TENSORFLOW_HOST_OBJ_INCLUDE_PATH ${TENSORFLOW_HOST_OBJ_INCLUDE_PATH}\")\r\nMESSAGE(STATUS \"TENSORFLOW_EIGEN_INCLUDE_PATH ${TENSORFLOW_EIGEN_INCLUDE_PATH}\")\r\nMESSAGE(STATUS \"TENSORFLOW_ABSL_INCLUDE_PATH ${TENSORFLOW_ABSL_INCLUDE_PATH}\")\r\nMESSAGE(STATUS \"TENSORFLOW_THIRD_PARTY_INCLUDE_PATH ${TENSORFLOW_THIRD_PARTY_INCLUDE_PATH}\")\r\nINCLUDE_DIRECTORIES(${TENSORFLOW_CORE_PATH})\r\nINCLUDE_DIRECTORIES(${TENSORFLOW_PROTOBUF_INCLUDE_PATH})\r\nINCLUDE_DIRECTORIES(${TENSORFLOW_PROTO_INCLUDE_PATH})\r\nINCLUDE_DIRECTORIES(${TENSORFLOW_PROTO_TEXT_INCLUDE_PATH})\r\nINCLUDE_DIRECTORIES(${TENSORFLOW_HOST_OBJ_INCLUDE_PATH})\r\nINCLUDE_DIRECTORIES(${TENSORFLOW_EIGEN_INCLUDE_PATH})\r\nINCLUDE_DIRECTORIES(${TENSORFLOW_ABSL_INCLUDE_PATH}) \r\nINCLUDE_DIRECTORIES(${TENSORFLOW_THIRD_PARTY_INCLUDE_PATH})\r\nINCLUDE_DIRECTORIES(${TENSORFLOW_NSYNC_INCLUDE_PATH})\r\nINCLUDE_DIRECTORIES(${TENSORFLOW_NSYNC_LIBRARY_PATH})\r\nADD_EXECUTABLE(load_model test.cpp)\r\nSET(LOAD_MODEL_LIBRARIES\r\n ${TENSORFLOW_NSYNC_LIBRARY}\r\n ${TENSORFLOW_PROTOC_LIBRARY}\r\n ${TENSORFLOW_PROTOBUF_LIBRARY}\r\n )\r\nSET(LDFLAGS \"-std=c++11 -msse4.1 -fPIC -O3 -march=native -Wall -finline-functions -undefined\")\r\nSET(CMAKE_CXX_FLAGS \"${CMAKE_CXX_FLAGS}${LDFLAGS}\")\r\nadd_compile_options(-Wl,--whole-archive -lpthread -ldl)\r\nTARGET_LINK_LIBRARIES(load_model -Wl,--whole-archive ${TENSORFLOW_LIBARY} -Wl,--no-whole-archive ${LOAD_MODEL_LIBRARIES} ${CMAKE_CXX_FLAGS})\r\n```\r\n\r\n",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62868\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62868\">No</a>\n"
] | 2024-01-30T02:50:20 | 2024-02-02T06:51:10 | 2024-02-02T06:51:07 |
NONE
| null | null | null |
**System information**
```
Have I written custom code (as opposed to using a stock example script provided in TensorFlow):
OS Platform and Distribution : Linux Ubuntu 22.04
TensorFlow installed from : source
TensorFlow version : 1.15
Python version: 3.10
Bazel version (if compiling from source): 0.24.1
GCC/Compiler version : 11.4.0
```
I am a newer to c++. I finish tensorflow compiling and generate the `libtensorflow-core.a` file. Now I want to test using cmake 2.8+.
I create a `CMakeLists.txt` such as:
```
CMAKE_MINIMUM_REQUIRED(VERSION 2.8)
SET(TENSORFLOW_CORE_PATH ${CMAKE_SOURCE_DIR}/tensorflow/core)
MESSAGE(STATUS "TENSORFLOW_CORE_PATH ${TENSORFLOW_CORE_PATH}")
SET(TENSORFLOW_LIBARY ${CMAKE_SOURCE_DIR}/tensorflow/lib/libtensorflow-core.a)
MESSAGE(STATUS "TENSORFLOW_LIBARY ${TENSORFLOW_LIBARY}")
SET(TENSORFLOW_PROTOBUF_INCLUDE_PATH ${CMAKE_SOURCE_DIR}/tensorflow/protobuf/include)
SET(TENSORFLOW_PROTOBUF_LIBRARY_PATH ${CMAKE_SOURCE_DIR}/tensorflow/protobuf/lib)
SET(TENSORFLOW_PROTOBUF_LIBRARY ${TENSORFLOW_PROTOBUF_LIBRARY_PATH}/libprotobuf.a)
#SET(TENSORFLOW_PROTOBUF_LITE_LIBRARY ${TENSORFLOW_PROTOBUF_LIBRARY_PATH}/libprotobuf-lite.a)
SET(TENSORFLOW_PROTOC_LIBRARY ${TENSORFLOW_PROTOBUF_LIBRARY_PATH}/libprotoc.a)
MESSAGE(STATUS "TENSORFLOW_PROTOBUF_INCLUDE_PATH ${TENSORFLOW_PROTOBUF_INCLUDE_PATH}")
MESSAGE(STATUS "TENSORFLOW_PROTOBUF_LIBRARY_PATH ${TENSORFLOW_PROTOBUF_LIBRARY_PATH}")
SET(TENSORFLOW_NSYNC_INCLUDE_PATH ${CMAKE_SOURCE_DIR}/tensorflow/nsyc/include)
SET(TENSORFLOW_NSYNC_LIBRARY_PATH ${CMAKE_SOURCE_DIR}/tensorflow/nsyc/lib)
MESSAGE(STATUS "TENSORFLOW_NSYNC_INCLUDE_PATH ${TENSORFLOW_NSYNC_INCLUDE_PATH}")
MESSAGE(STATUS "TENSORFLOW_NSYNC_LIBRARY_PATH ${TENSORFLOW_NSYNC_LIBRARY_PATH}")
SET(TENSORFLOW_NSYNC_LIBRARY ${TENSORFLOW_NSYNC_LIBRARY_PATH}/libnsync.a)
MESSAGE(STATUS "TENSORFLOW_NSYNC_LIBRARY ${TENSORFLOW_NSYNC_LIBRARY}")
SET(TENSORFLOW_PROTO_INCLUDE_PATH ${CMAKE_SOURCE_DIR}/tensorflow/proto)
SET(TENSORFLOW_PROTO_TEXT_INCLUDE_PATH ${CMAKE_SOURCE_DIR}/tensorflow/proto_text)
SET(TENSORFLOW_HOST_OBJ_INCLUDE_PATH ${CMAKE_SOURCE_DIR}/tensorflow/host_obj/)
SET(TENSORFLOW_EIGEN_INCLUDE_PATH ${CMAKE_SOURCE_DIR}/tensorflow/eigen3)
SET(TENSORFLOW_ABSL_INCLUDE_PATH ${CMAKE_SOURCE_DIR}/tensorflow/absl)
SET(TENSORFLOW_THIRD_PARTY_INCLUDE_PATH ${CMAKE_SOURCE_DIR}/tensorflow/tensorflow_third_party)
MESSAGE(STATUS "TENSORFLOW_PROTO_INCLUDE_PATH ${TENSORFLOW_PROTO_INCLUDE_PATH}")
MESSAGE(STATUS "TENSORFLOW_PROTO_TEXT_INCLUDE_PATH ${TENSORFLOW_PROTO_TEXT_INCLUDE_PATH}")
MESSAGE(STATUS "TENSORFLOW_HOST_OBJ_INCLUDE_PATH ${TENSORFLOW_HOST_OBJ_INCLUDE_PATH}")
MESSAGE(STATUS "TENSORFLOW_EIGEN_INCLUDE_PATH ${TENSORFLOW_EIGEN_INCLUDE_PATH}")
MESSAGE(STATUS "TENSORFLOW_ABSL_INCLUDE_PATH ${TENSORFLOW_ABSL_INCLUDE_PATH}")
MESSAGE(STATUS "TENSORFLOW_THIRD_PARTY_INCLUDE_PATH ${TENSORFLOW_THIRD_PARTY_INCLUDE_PATH}")
INCLUDE_DIRECTORIES(${TENSORFLOW_CORE_PATH})
INCLUDE_DIRECTORIES(${TENSORFLOW_PROTOBUF_INCLUDE_PATH})
#INCLUDE_DIRECTORIES(${TENSORFLOW_PROTOBUF_LITE_LIBRARY})
INCLUDE_DIRECTORIES(${TENSORFLOW_PROTO_INCLUDE_PATH})
INCLUDE_DIRECTORIES(${TENSORFLOW_PROTO_TEXT_INCLUDE_PATH})
INCLUDE_DIRECTORIES(${TENSORFLOW_HOST_OBJ_INCLUDE_PATH})
INCLUDE_DIRECTORIES(${TENSORFLOW_EIGEN_INCLUDE_PATH})
INCLUDE_DIRECTORIES(${TENSORFLOW_ABSL_INCLUDE_PATH})
INCLUDE_DIRECTORIES(${TENSORFLOW_NSYNC_INCLUDE_PATH})
INCLUDE_DIRECTORIES(${TENSORFLOW_THIRD_PARTY_INCLUDE_PATH})
ADD_EXECUTABLE(load_model load_model.cpp)
SET(LOAD_MODEL_LIBRARIES
${TENSORFLOW_LIBARY}
${TENSORFLOW_PROTOBUF_LIBRARY}
${TENSORFLOW_PROTOC_LIBRARY}
${TENSORFLOW_NSYNC_LIBRARY}
)
SET(LDFLAGS "-std=c++11 -msse4.1 -fPIC -O3 -march=native -Wall -finline-functions -undefined dynamic_lookup load")
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS}${LDFLAGS}")
MESSAGE(STATUS "CMAKE_CXX_COMPILER: ${CMAKE_CXX_COMPILER}")
MESSAGE(STATUS "CMAKE_CXX_FLAGS: ${CMAKE_CXX_FLAGS}")
#TARGET_LINK_LIBRARIES(load_model ${LOAD_MODEL_LIBRARIES} ${CMAKE_CXX_FLAGS})
TARGET_LINK_LIBRARIES(load_model -Wl , --whole-archive ${TENSORFLOW_LIBARY} , --no-whole-archive ${LOAD_MODEL_LIBRARIES} -Wl ${CMAKE_CXX_FLAGS})
```
The ` load_model.cpp` such as:
```
#include "tensorflow/core/platform/env.h"
#include "tensorflow/core/public/session.h"
#include <iostream>
#include <string>
const static std::string kModelPath = "test_model.pb";
int main()
{
using namespace tensorflow;
auto session = NewSession(SessionOptions());
if (session == nullptr)
{
std::cerr << "Tensorflow session create failded.\n";
return -1;
}
else
{
std::cout << "Tensorflow session create success.\n";
}
Status status;
// Read in the protobuf graph we exported
GraphDef graph_def;
status = ReadBinaryProto(Env::Default(), kModelPath, &graph_def);
if (!status.ok())
{
std::cerr << "Error reading graph definition from " << kModelPath
<< ": " << status.ToString();
return -1;
}
else
{
std::cout << "Read graph def success.\n";
}
// Add the graph to the session
status = session->Create(graph_def);
if (!status.ok())
{
std::cerr << "Error creating graph: " << status.ToString();
return -1;
}
else
{
std::cout << "Create graph success.\n";
}
// Set model input
Tensor hello(DT_STRING, TensorShape());
hello.scalar<string>()() = "hello";
Tensor tensorflow(DT_STRING, TensorShape());
tensorflow.scalar<string>()() = " tensorflow";
// Apply the loaded model
std::vector<std::pair<string, tensorflow::Tensor>> inputs =
{
{ "a", hello },
{ "b", tensorflow },
}; // input
std::vector<tensorflow::Tensor> outputs; // output
status = session->Run(inputs, {"result"}, {}, &outputs);
if (!status.ok())
{
std::cerr << status.ToString() << std::endl;
return -1;
}
else
{
std::cout << "Run session successfully" << std::endl;
}
// Output the result
const auto result = outputs[0].scalar<string>()();
std::cout << "Result value: " << result << std::endl;
status = session->Close();
if (!status.ok())
{
std::cerr << "Session closed success";
return -1;
}
return 0;
}
```
The `test_model.pb` such as:
```
import tensorflow as tf
a = tf.Variable("hello ", name = "a")
b = tf.Variable("tensorflow", name = "b")
result = tf.add(a, b, name = "result")
with tf.Session() as sess:
sess.run(tf.global_variables_initializer())
tf.train.write_graph(sess.graph_def, '.', 'test_model.pb', as_text = False)
print result.eval()
```
`mkdir build` and `cd build`
I run
`cmake ..`
`make`
The error logs are:
```
In file included from /home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:22,
from /home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/platform/env.h:24,
from /home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/load_model.cpp:3:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/status.h:49:22: error: ‘tensorflow::error’ has not been declared
49 | Status(tensorflow::error::Code code, tensorflow::StringPiece msg);
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/status.h:49:33: error: expected ‘)’ before ‘code’
49 | Status(tensorflow::error::Code code, tensorflow::StringPiece msg);
| ~ ^~~~~
| )
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/status.h:60:15: error: ‘error’ in namespace ‘tensorflow’ does not name a type
60 | tensorflow::error::Code code() const {
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/status.h:94:17: error: ‘error’ in namespace ‘tensorflow’ does not name a type
94 | tensorflow::error::Code code;
| ^~~~~
In file included from /home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/platform/env.h:24,
from /home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/load_model.cpp:3:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:31:23: error: ‘error’ in namespace ‘tensorflow’ does not name a type; did you mean ‘errors’?
31 | typedef ::tensorflow::error::Code Code;
| ^~~~~
| errors
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘void tensorflow::errors::AppendToMessage(tensorflow::Status*, Args ...)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:66:15: error: ‘class tensorflow::Status’ has no member named ‘code’
66 | status->code(),
| ^~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘tensorflow::Status tensorflow::errors::Cancelled(Args ...)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:96:23: error: ‘error’ is not a member of ‘tensorflow’; did you mean ‘errors’?
96 | ::tensorflow::error::CONST, \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:104:1: note: in expansion of macro ‘DECLARE_ERROR’
104 | DECLARE_ERROR(Cancelled, CANCELLED)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘bool tensorflow::errors::IsCancelled(const tensorflow::Status&)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:19: error: ‘const class tensorflow::Status’ has no member named ‘code’
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:104:1: note: in expansion of macro ‘DECLARE_ERROR’
104 | DECLARE_ERROR(Cancelled, CANCELLED)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:43: error: ‘tensorflow::error’ has not been declared
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:104:1: note: in expansion of macro ‘DECLARE_ERROR’
104 | DECLARE_ERROR(Cancelled, CANCELLED)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘tensorflow::Status tensorflow::errors::InvalidArgument(Args ...)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:96:23: error: ‘error’ is not a member of ‘tensorflow’; did you mean ‘errors’?
96 | ::tensorflow::error::CONST, \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:105:1: note: in expansion of macro ‘DECLARE_ERROR’
105 | DECLARE_ERROR(InvalidArgument, INVALID_ARGUMENT)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘bool tensorflow::errors::IsInvalidArgument(const tensorflow::Status&)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:19: error: ‘const class tensorflow::Status’ has no member named ‘code’
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:105:1: note: in expansion of macro ‘DECLARE_ERROR’
105 | DECLARE_ERROR(InvalidArgument, INVALID_ARGUMENT)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:43: error: ‘tensorflow::error’ has not been declared
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:105:1: note: in expansion of macro ‘DECLARE_ERROR’
105 | DECLARE_ERROR(InvalidArgument, INVALID_ARGUMENT)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘tensorflow::Status tensorflow::errors::NotFound(Args ...)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:96:23: error: ‘error’ is not a member of ‘tensorflow’; did you mean ‘errors’?
96 | ::tensorflow::error::CONST, \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:106:1: note: in expansion of macro ‘DECLARE_ERROR’
106 | DECLARE_ERROR(NotFound, NOT_FOUND)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘bool tensorflow::errors::IsNotFound(const tensorflow::Status&)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:19: error: ‘const class tensorflow::Status’ has no member named ‘code’
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:106:1: note: in expansion of macro ‘DECLARE_ERROR’
106 | DECLARE_ERROR(NotFound, NOT_FOUND)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:43: error: ‘tensorflow::error’ has not been declared
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:106:1: note: in expansion of macro ‘DECLARE_ERROR’
106 | DECLARE_ERROR(NotFound, NOT_FOUND)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘tensorflow::Status tensorflow::errors::AlreadyExists(Args ...)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:96:23: error: ‘error’ is not a member of ‘tensorflow’; did you mean ‘errors’?
96 | ::tensorflow::error::CONST, \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:107:1: note: in expansion of macro ‘DECLARE_ERROR’
107 | DECLARE_ERROR(AlreadyExists, ALREADY_EXISTS)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘bool tensorflow::errors::IsAlreadyExists(const tensorflow::Status&)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:19: error: ‘const class tensorflow::Status’ has no member named ‘code’
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:107:1: note: in expansion of macro ‘DECLARE_ERROR’
107 | DECLARE_ERROR(AlreadyExists, ALREADY_EXISTS)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:43: error: ‘tensorflow::error’ has not been declared
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:107:1: note: in expansion of macro ‘DECLARE_ERROR’
107 | DECLARE_ERROR(AlreadyExists, ALREADY_EXISTS)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘tensorflow::Status tensorflow::errors::ResourceExhausted(Args ...)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:96:23: error: ‘error’ is not a member of ‘tensorflow’; did you mean ‘errors’?
96 | ::tensorflow::error::CONST, \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:108:1: note: in expansion of macro ‘DECLARE_ERROR’
108 | DECLARE_ERROR(ResourceExhausted, RESOURCE_EXHAUSTED)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘bool tensorflow::errors::IsResourceExhausted(const tensorflow::Status&)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:19: error: ‘const class tensorflow::Status’ has no member named ‘code’
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:108:1: note: in expansion of macro ‘DECLARE_ERROR’
108 | DECLARE_ERROR(ResourceExhausted, RESOURCE_EXHAUSTED)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:43: error: ‘tensorflow::error’ has not been declared
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:108:1: note: in expansion of macro ‘DECLARE_ERROR’
108 | DECLARE_ERROR(ResourceExhausted, RESOURCE_EXHAUSTED)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘tensorflow::Status tensorflow::errors::Unavailable(Args ...)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:96:23: error: ‘error’ is not a member of ‘tensorflow’; did you mean ‘errors’?
96 | ::tensorflow::error::CONST, \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:109:1: note: in expansion of macro ‘DECLARE_ERROR’
109 | DECLARE_ERROR(Unavailable, UNAVAILABLE)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘bool tensorflow::errors::IsUnavailable(const tensorflow::Status&)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:19: error: ‘const class tensorflow::Status’ has no member named ‘code’
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:109:1: note: in expansion of macro ‘DECLARE_ERROR’
109 | DECLARE_ERROR(Unavailable, UNAVAILABLE)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:43: error: ‘tensorflow::error’ has not been declared
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:109:1: note: in expansion of macro ‘DECLARE_ERROR’
109 | DECLARE_ERROR(Unavailable, UNAVAILABLE)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘tensorflow::Status tensorflow::errors::FailedPrecondition(Args ...)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:96:23: error: ‘error’ is not a member of ‘tensorflow’; did you mean ‘errors’?
96 | ::tensorflow::error::CONST, \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:110:1: note: in expansion of macro ‘DECLARE_ERROR’
110 | DECLARE_ERROR(FailedPrecondition, FAILED_PRECONDITION)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘bool tensorflow::errors::IsFailedPrecondition(const tensorflow::Status&)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:19: error: ‘const class tensorflow::Status’ has no member named ‘code’
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:110:1: note: in expansion of macro ‘DECLARE_ERROR’
110 | DECLARE_ERROR(FailedPrecondition, FAILED_PRECONDITION)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:43: error: ‘tensorflow::error’ has not been declared
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:110:1: note: in expansion of macro ‘DECLARE_ERROR’
110 | DECLARE_ERROR(FailedPrecondition, FAILED_PRECONDITION)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘tensorflow::Status tensorflow::errors::OutOfRange(Args ...)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:96:23: error: ‘error’ is not a member of ‘tensorflow’; did you mean ‘errors’?
96 | ::tensorflow::error::CONST, \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:111:1: note: in expansion of macro ‘DECLARE_ERROR’
111 | DECLARE_ERROR(OutOfRange, OUT_OF_RANGE)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘bool tensorflow::errors::IsOutOfRange(const tensorflow::Status&)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:19: error: ‘const class tensorflow::Status’ has no member named ‘code’
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:111:1: note: in expansion of macro ‘DECLARE_ERROR’
111 | DECLARE_ERROR(OutOfRange, OUT_OF_RANGE)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:43: error: ‘tensorflow::error’ has not been declared
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:111:1: note: in expansion of macro ‘DECLARE_ERROR’
111 | DECLARE_ERROR(OutOfRange, OUT_OF_RANGE)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘tensorflow::Status tensorflow::errors::Unimplemented(Args ...)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:96:23: error: ‘error’ is not a member of ‘tensorflow’; did you mean ‘errors’?
96 | ::tensorflow::error::CONST, \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:112:1: note: in expansion of macro ‘DECLARE_ERROR’
112 | DECLARE_ERROR(Unimplemented, UNIMPLEMENTED)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘bool tensorflow::errors::IsUnimplemented(const tensorflow::Status&)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:19: error: ‘const class tensorflow::Status’ has no member named ‘code’
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:112:1: note: in expansion of macro ‘DECLARE_ERROR’
112 | DECLARE_ERROR(Unimplemented, UNIMPLEMENTED)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:43: error: ‘tensorflow::error’ has not been declared
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:112:1: note: in expansion of macro ‘DECLARE_ERROR’
112 | DECLARE_ERROR(Unimplemented, UNIMPLEMENTED)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘tensorflow::Status tensorflow::errors::Internal(Args ...)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:96:23: error: ‘error’ is not a member of ‘tensorflow’; did you mean ‘errors’?
96 | ::tensorflow::error::CONST, \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:113:1: note: in expansion of macro ‘DECLARE_ERROR’
113 | DECLARE_ERROR(Internal, INTERNAL)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘bool tensorflow::errors::IsInternal(const tensorflow::Status&)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:19: error: ‘const class tensorflow::Status’ has no member named ‘code’
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:113:1: note: in expansion of macro ‘DECLARE_ERROR’
113 | DECLARE_ERROR(Internal, INTERNAL)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:43: error: ‘tensorflow::error’ has not been declared
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:113:1: note: in expansion of macro ‘DECLARE_ERROR’
113 | DECLARE_ERROR(Internal, INTERNAL)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘tensorflow::Status tensorflow::errors::Aborted(Args ...)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:96:23: error: ‘error’ is not a member of ‘tensorflow’; did you mean ‘errors’?
96 | ::tensorflow::error::CONST, \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:114:1: note: in expansion of macro ‘DECLARE_ERROR’
114 | DECLARE_ERROR(Aborted, ABORTED)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘bool tensorflow::errors::IsAborted(const tensorflow::Status&)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:19: error: ‘const class tensorflow::Status’ has no member named ‘code’
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:114:1: note: in expansion of macro ‘DECLARE_ERROR’
114 | DECLARE_ERROR(Aborted, ABORTED)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:43: error: ‘tensorflow::error’ has not been declared
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:114:1: note: in expansion of macro ‘DECLARE_ERROR’
114 | DECLARE_ERROR(Aborted, ABORTED)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘tensorflow::Status tensorflow::errors::DeadlineExceeded(Args ...)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:96:23: error: ‘error’ is not a member of ‘tensorflow’; did you mean ‘errors’?
96 | ::tensorflow::error::CONST, \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:115:1: note: in expansion of macro ‘DECLARE_ERROR’
115 | DECLARE_ERROR(DeadlineExceeded, DEADLINE_EXCEEDED)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘bool tensorflow::errors::IsDeadlineExceeded(const tensorflow::Status&)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:19: error: ‘const class tensorflow::Status’ has no member named ‘code’
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:115:1: note: in expansion of macro ‘DECLARE_ERROR’
115 | DECLARE_ERROR(DeadlineExceeded, DEADLINE_EXCEEDED)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:43: error: ‘tensorflow::error’ has not been declared
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:115:1: note: in expansion of macro ‘DECLARE_ERROR’
115 | DECLARE_ERROR(DeadlineExceeded, DEADLINE_EXCEEDED)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘tensorflow::Status tensorflow::errors::DataLoss(Args ...)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:96:23: error: ‘error’ is not a member of ‘tensorflow’; did you mean ‘errors’?
96 | ::tensorflow::error::CONST, \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:116:1: note: in expansion of macro ‘DECLARE_ERROR’
116 | DECLARE_ERROR(DataLoss, DATA_LOSS)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘bool tensorflow::errors::IsDataLoss(const tensorflow::Status&)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:19: error: ‘const class tensorflow::Status’ has no member named ‘code’
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:116:1: note: in expansion of macro ‘DECLARE_ERROR’
116 | DECLARE_ERROR(DataLoss, DATA_LOSS)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:43: error: ‘tensorflow::error’ has not been declared
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:116:1: note: in expansion of macro ‘DECLARE_ERROR’
116 | DECLARE_ERROR(DataLoss, DATA_LOSS)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘tensorflow::Status tensorflow::errors::Unknown(Args ...)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:96:23: error: ‘error’ is not a member of ‘tensorflow’; did you mean ‘errors’?
96 | ::tensorflow::error::CONST, \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:117:1: note: in expansion of macro ‘DECLARE_ERROR’
117 | DECLARE_ERROR(Unknown, UNKNOWN)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘bool tensorflow::errors::IsUnknown(const tensorflow::Status&)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:19: error: ‘const class tensorflow::Status’ has no member named ‘code’
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:117:1: note: in expansion of macro ‘DECLARE_ERROR’
117 | DECLARE_ERROR(Unknown, UNKNOWN)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:43: error: ‘tensorflow::error’ has not been declared
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:117:1: note: in expansion of macro ‘DECLARE_ERROR’
117 | DECLARE_ERROR(Unknown, UNKNOWN)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘tensorflow::Status tensorflow::errors::PermissionDenied(Args ...)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:96:23: error: ‘error’ is not a member of ‘tensorflow’; did you mean ‘errors’?
96 | ::tensorflow::error::CONST, \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:118:1: note: in expansion of macro ‘DECLARE_ERROR’
118 | DECLARE_ERROR(PermissionDenied, PERMISSION_DENIED)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘bool tensorflow::errors::IsPermissionDenied(const tensorflow::Status&)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:19: error: ‘const class tensorflow::Status’ has no member named ‘code’
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:118:1: note: in expansion of macro ‘DECLARE_ERROR’
118 | DECLARE_ERROR(PermissionDenied, PERMISSION_DENIED)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:43: error: ‘tensorflow::error’ has not been declared
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:118:1: note: in expansion of macro ‘DECLARE_ERROR’
118 | DECLARE_ERROR(PermissionDenied, PERMISSION_DENIED)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘tensorflow::Status tensorflow::errors::Unauthenticated(Args ...)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:96:23: error: ‘error’ is not a member of ‘tensorflow’; did you mean ‘errors’?
96 | ::tensorflow::error::CONST, \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:119:1: note: in expansion of macro ‘DECLARE_ERROR’
119 | DECLARE_ERROR(Unauthenticated, UNAUTHENTICATED)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: In function ‘bool tensorflow::errors::IsUnauthenticated(const tensorflow::Status&)’:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:19: error: ‘const class tensorflow::Status’ has no member named ‘code’
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:119:1: note: in expansion of macro ‘DECLARE_ERROR’
119 | DECLARE_ERROR(Unauthenticated, UNAUTHENTICATED)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:101:43: error: ‘tensorflow::error’ has not been declared
101 | return status.code() == ::tensorflow::error::CONST; \
| ^~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:119:1: note: in expansion of macro ‘DECLARE_ERROR’
119 | DECLARE_ERROR(Unauthenticated, UNAUTHENTICATED)
| ^~~~~~~~~~~~~
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h: At global scope:
/home/wmc/tensorflow1.x/tensorflowr1.15_static_lib/test_static_lib-x86/tensorflow/core/lib/core/errors.h:156:21: error: ‘tensorflow::error’ has not been declared
156 | using ::tensorflow::error::OK;
| ^~~~~
make[2]: *** [CMakeFiles/load_model.dir/build.make:76: CMakeFiles/load_model.dir/load_model.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:83: CMakeFiles/load_model.dir/all] Error 2
make: *** [Makefile:91: all] Error 2
```
Can anyone give me some help? Thank you very much!
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62868/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62868/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62867
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62867/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62867/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62867/events
|
https://github.com/tensorflow/tensorflow/issues/62867
| 2,106,816,428 |
I_kwDOArmXAs59k3es
| 62,867 |
TFLITE: Execution on GPU delegate gives runtime error with no CPU fallback
|
{
"login": "suyash-narain",
"id": 78979784,
"node_id": "MDQ6VXNlcjc4OTc5Nzg0",
"avatar_url": "https://avatars.githubusercontent.com/u/78979784?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/suyash-narain",
"html_url": "https://github.com/suyash-narain",
"followers_url": "https://api.github.com/users/suyash-narain/followers",
"following_url": "https://api.github.com/users/suyash-narain/following{/other_user}",
"gists_url": "https://api.github.com/users/suyash-narain/gists{/gist_id}",
"starred_url": "https://api.github.com/users/suyash-narain/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/suyash-narain/subscriptions",
"organizations_url": "https://api.github.com/users/suyash-narain/orgs",
"repos_url": "https://api.github.com/users/suyash-narain/repos",
"events_url": "https://api.github.com/users/suyash-narain/events{/privacy}",
"received_events_url": "https://api.github.com/users/suyash-narain/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 404586594,
"node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower",
"name": "stat:awaiting tensorflower",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from tensorflower"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 750616506,
"node_id": "MDU6TGFiZWw3NTA2MTY1MDY=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite",
"name": "comp:lite",
"color": "0052cc",
"default": false,
"description": "TF Lite related issues"
},
{
"id": 2671339633,
"node_id": "MDU6TGFiZWwyNjcxMzM5NjMz",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TFLiteGpuDelegate",
"name": "TFLiteGpuDelegate",
"color": "F71F04",
"default": false,
"description": "TFLite Gpu delegate issue"
},
{
"id": 5922361893,
"node_id": "LA_kwDOArmXAs8AAAABYQASJQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF2.14",
"name": "TF2.14",
"color": "b60205",
"default": false,
"description": "For issues related to Tensorflow 2.14.x"
}
] |
open
| false |
{
"login": "impjdi",
"id": 9742927,
"node_id": "MDQ6VXNlcjk3NDI5Mjc=",
"avatar_url": "https://avatars.githubusercontent.com/u/9742927?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/impjdi",
"html_url": "https://github.com/impjdi",
"followers_url": "https://api.github.com/users/impjdi/followers",
"following_url": "https://api.github.com/users/impjdi/following{/other_user}",
"gists_url": "https://api.github.com/users/impjdi/gists{/gist_id}",
"starred_url": "https://api.github.com/users/impjdi/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/impjdi/subscriptions",
"organizations_url": "https://api.github.com/users/impjdi/orgs",
"repos_url": "https://api.github.com/users/impjdi/repos",
"events_url": "https://api.github.com/users/impjdi/events{/privacy}",
"received_events_url": "https://api.github.com/users/impjdi/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "impjdi",
"id": 9742927,
"node_id": "MDQ6VXNlcjk3NDI5Mjc=",
"avatar_url": "https://avatars.githubusercontent.com/u/9742927?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/impjdi",
"html_url": "https://github.com/impjdi",
"followers_url": "https://api.github.com/users/impjdi/followers",
"following_url": "https://api.github.com/users/impjdi/following{/other_user}",
"gists_url": "https://api.github.com/users/impjdi/gists{/gist_id}",
"starred_url": "https://api.github.com/users/impjdi/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/impjdi/subscriptions",
"organizations_url": "https://api.github.com/users/impjdi/orgs",
"repos_url": "https://api.github.com/users/impjdi/repos",
"events_url": "https://api.github.com/users/impjdi/events{/privacy}",
"received_events_url": "https://api.github.com/users/impjdi/received_events",
"type": "User",
"site_admin": false
},
{
"login": "pkgoogle",
"id": 132095473,
"node_id": "U_kgDOB9-d8Q",
"avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/pkgoogle",
"html_url": "https://github.com/pkgoogle",
"followers_url": "https://api.github.com/users/pkgoogle/followers",
"following_url": "https://api.github.com/users/pkgoogle/following{/other_user}",
"gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}",
"starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions",
"organizations_url": "https://api.github.com/users/pkgoogle/orgs",
"repos_url": "https://api.github.com/users/pkgoogle/repos",
"events_url": "https://api.github.com/users/pkgoogle/events{/privacy}",
"received_events_url": "https://api.github.com/users/pkgoogle/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"I don't have a VM which matches this architecture with GPU closely enough,\r\n\r\nHi @impjdi, can you please take a look? Thanks.",
"Hi @pkgoogle @impjdi,\r\n\r\nI get the same error when i use any whisper based tflite models. On digging a bit deeper I found out that the delegate is giving runtime errors because the model contains an op which has dynamic sized tensors whereas the delegate can support only static sized tensors. \r\nMy question now is, why are these ops not falling back onto CPU instead and giving a runtime error on GPU?\r\nIs there a way i can convert dynamic tensors to static while converting the model?\r\n\r\n\r\nI use the below script to generate my whisper tflite model\r\n\r\n```\r\nimport tensorflow as tf\r\nimport transformers\r\n\r\n\r\nfrom datasets import load_dataset\r\nfrom transformers import WhisperProcessor, WhisperFeatureExtractor, TFWhisperForConditionalGeneration, WhisperTokenizer\r\n\r\ntarget = \"openai/whisper-tiny.en\"\r\n\r\nfeature_extractor = WhisperFeatureExtractor.from_pretrained(target)\r\ntokenizer = WhisperTokenizer.from_pretrained(target, predict_timestamps=True)\r\nprocessor = WhisperProcessor(feature_extractor, tokenizer)\r\nmodel = TFWhisperForConditionalGeneration.from_pretrained(target)\r\n# Loading dataset\r\nds = load_dataset(\"hf-internal-testing/librispeech_asr_dummy\", \"clean\", split=\"validation\")\r\n\r\ninputs = feature_extractor(\r\n ds[0][\"audio\"][\"array\"], sampling_rate=ds[0][\"audio\"][\"sampling_rate\"], return_tensors=\"tf\"\r\n)\r\ninput_features = inputs.input_features\r\n\r\n# Generating Transcription\r\ngenerated_ids = model.generate(input_features=input_features)\r\nprint(generated_ids)\r\ntranscription = processor.tokenizer.decode(generated_ids[0])\r\nprint(transcription)\r\n\r\n# Save the model\r\nmodel.save('./content/tf_whisper_saved')\r\n\r\nclass GenerateModel(tf.Module):\r\n def __init__(self, model):\r\n super(GenerateModel, self).__init__()\r\n self.model = model\r\n\r\n @tf.function(\r\n input_signature=[\r\n tf.TensorSpec((1, 80, 3000), tf.float32, name=\"input_features\"),\r\n ],\r\n )\r\n def serving(self, input_features):\r\n outputs = self.model.generate(\r\n input_features,\r\n max_new_tokens=100,\r\n return_dict_in_generate=True,\r\n )\r\n return {\"sequences\": outputs[\"sequences\"]}\r\n\r\nsaved_model_dir = './content/tf_whisper_saved'\r\ntflite_model_path = 'whisper_tiny.tflite'\r\n\r\ngenerate_model = GenerateModel(model=model)\r\ntf.saved_model.save(generate_model, saved_model_dir, signatures={\"serving_default\": generate_model.serving})\r\n\r\n# Convert the model\r\nconverter = tf.lite.TFLiteConverter.from_saved_model(saved_model_dir)\r\nconverter.target_spec.supported_ops = [tf.lite.OpsSet.TFLITE_BUILTINS,\r\ntf.lite.OpsSet.EXPERIMENTAL_TFLITE_BUILTINS_ACTIVATIONS_INT16_WEIGHTS_INT8,\r\ntf.lite.OpsSet.SELECT_TF_OPS] # enable TensorFlow Lite ops.\r\n # enable TensorFlow ops.\r\nconverter.optimizations = [tf.lite.Optimize.DEFAULT]\r\n\r\n# Float16 quantization reduces the size to 50%\r\nconverter.target_spec.supported_types = [tf.float16]\r\ntflite_model = converter.convert()\r\n\r\n# Save the model\r\nwith open(tflite_model_path, 'wb') as f:.\r\n f.write(tflite_model)\r\n```\r\n\r\nthe generated model has an OP named 'WHILE' which is INT32, and is the second last op, having multiple inputs. How can i give it static inputs instead or ensure this op fallsback onto CPU instead of the delegate?\r\n\r\nthanks"
] | 2024-01-30T02:18:21 | 2024-02-09T02:17:14 | null |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
source
### TensorFlow version
tf 2.14
### Custom code
Yes
### OS platform and distribution
aarch64 linux
### Mobile device
_No response_
### Python version
python 3.10.9
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
I am using an aarch64 device similar to raspberry pi running tf 2.14.
I installed the latest version of tflite_runtime using pip3 install tflite_runtime which installed v2.14
I have a tflite model sourced from here: https://github.com/usefulsensors/openai-whisper/blob/main/models/whisper.tflite
which works well on CPU but when I try to execute it on GPU or NNAPI tflite delegate, I get runtime error and no other error log accompanying it.
The error snippet is below:
```
INFO: Created TensorFlow Lite delegate for GPU.
Traceback (most recent call last):
File "/home/root/whisper_interpreter1.py", line 19, in <module>
interpreter = tflite.Interpreter(args.model, experimental_delegates=[tflite.load_delegate('gpu_external_delegate.so')], num_threads=args.threads)
File "/usr/lib/python3.10/site-packages/tflite_runtime/interpreter.py", line 513, in __init__
self._interpreter.ModifyGraphWithDelegate(
RuntimeError
```
the code I am using is similar to the one mentioned in this comment: https://github.com/tensorflow/tensorflow/issues/59273#issuecomment-1397704596
I checked the model support using model Analyzer
```
import tensorflow as tf
tf.lite.experimental.Analyzer.analyze(model_path='whisper.tflite',
gpu_compatibility=True)
```
and i get the output:
```
GPU COMPATIBILITY WARNING: Not supported op WHILE
GPU COMPATIBILITY WARNING: Subgraph#0 has GPU delegate compatibility issues at nodes 357, 358, 359, 360, 361, 362, 694 on TFLite runtime version 2.15.0
```
the entire log is attached:
[model_analyzer_log.txt](https://github.com/tensorflow/tensorflow/files/14091984/model_analyzer_log.txt)
Not all ops in this model are supported in GPU but other ops are supported. My understanding is that model ops which are not supported on the delegate should fallback onto CPU. But instead of falling back, I end up getting RUNTIME ERROR. Why are unsupported ops not falling back onto CPU instead?
Are unsupported ops not falling back onto CPU by default in TFLite?
### Standalone code to reproduce the issue
```shell
import os
from timeit import default_timer as timer
import wave
import argparse
import tflite_runtime.interpreter as tflite
import numpy as np
import whisper
import re
parser = argparse.ArgumentParser(description="Running Whisper TFlite test inference.")
parser.add_argument("-f", "--folder", default="./test_wavs/", help="Folder with WAV input files")
parser.add_argument("-m", "--model", default="models/whisper.tflite", help="Path to model")
parser.add_argument("-t", "--threads", type=int, default=2, help="Threads used")
args = parser.parse_args()
interpreter = tflite.Interpreter(args.model, experimental_delegates=[tflite.load_delegate('gpu_external_delegate.so')], num_threads=args.threads)
interpreter.allocate_tensors()
input_tensor = interpreter.get_input_details()[0]['index']
output_tensor = interpreter.get_output_details()[0]['index']
wtokenizer = whisper.tokenizer.get_tokenizer(False, language="en")
def transcribe(audio_file):
wf = wave.open(audio_file, "rb")
if (wf.getnchannels() != 1 or wf.getsampwidth() != 2 or wf.getcomptype() != "NONE" or wf.getframerate() != 16000):
print("Audio file must be WAV format mono PCM.")
exit (1)
wf.close()
mel_from_file = whisper.audio.log_mel_spectrogram(audio_file)
input_data = whisper.audio.pad_or_trim(mel_from_file, whisper.audio.N_FRAMES)
input_data = np.expand_dims(input_data, 0)
interpreter.set_tensor(input_tensor, input_data)
interpreter.invoke()
output_data = interpreter.get_tensor(output_tensor)
for token in output_data:
token[token == -100] = wtokenizer.eot
text = wtokenizer.decode([t for t in token if t not in wtokenizer.special_tokens])
_re_special = re.compile(r"\<\|.+?\|\>")
def strip_special_tokens(string):
return re.sub(_re_special, "", string)
print(strip_special_tokens(text))
test_files = os.listdir(args.folder)
for file in test_files:
if file.endswith(".wav"):
print(file)
inference_start = timer()
transcribe(args.folder + file)
print("\nInference took {:.3}s".format(timer() - inference_start))
```
### Relevant log output
_No response_
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62867/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62867/timeline
| null | null | false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62866
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62866/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62866/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62866/events
|
https://github.com/tensorflow/tensorflow/issues/62866
| 2,106,603,061 |
I_kwDOArmXAs59kDY1
| 62,866 |
ml_dtypes.h:19:10: fatal error: 'ml_dtypes/include/float8.h' file not found
|
{
"login": "plopresti",
"id": 8864861,
"node_id": "MDQ6VXNlcjg4NjQ4NjE=",
"avatar_url": "https://avatars.githubusercontent.com/u/8864861?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/plopresti",
"html_url": "https://github.com/plopresti",
"followers_url": "https://api.github.com/users/plopresti/followers",
"following_url": "https://api.github.com/users/plopresti/following{/other_user}",
"gists_url": "https://api.github.com/users/plopresti/gists{/gist_id}",
"starred_url": "https://api.github.com/users/plopresti/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/plopresti/subscriptions",
"organizations_url": "https://api.github.com/users/plopresti/orgs",
"repos_url": "https://api.github.com/users/plopresti/repos",
"events_url": "https://api.github.com/users/plopresti/events{/privacy}",
"received_events_url": "https://api.github.com/users/plopresti/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 1478826728,
"node_id": "MDU6TGFiZWwxNDc4ODI2NzI4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:core",
"name": "comp:core",
"color": "024391",
"default": false,
"description": "issues related to core part of tensorflow"
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
closed
| false |
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
" @plopresti Please use compiler flags like -I/path/to/ml_dtypes/include or adjust project settings accordingly. Sometimes, build system caches can cause issues, please clean & rebuild your project, and let us know?\r\nThank you!",
"@sushreebarsa\r\n\r\nI normally use `-I/path/to/bazel-bin/tensorflow/include`. This has worked fine for years.\r\n\r\nStarting with r2.15, I have to use `-I/path/to/bazel-bin/tensorflow/include -I/path/to/bazel-bin/tensorflow/include/_virtual_includes/float8/ml_dtypes/include -I/path/to/bazel-bin/tensorflow/include/_virtual_includes/int4/ml_dtypes/include`\r\n\r\n...which is a bug introduced by https://github.com/tensorflow/tensorflow/commit/ef1ea4f5c5c36209b6bd56a99fdd71e5052f6d63.",
"@cantonios Any chance you might take a look at this? The ml_dtypes change appears to have broken the `//tensorflow:install_headers` Bazel target.",
"Hmm... I see, it's an an issue with the genrule, since TF's targets use an `include_prefix`.\r\n\r\nSeems like an easy fix, we need to add the one line:\r\n```\r\n d=\"$${d#_virtual_includes/*/}\"\r\n```\r\nin the genrule to remove that prefix.",
"@plopresti Could you please refer to the above comment and let us know the update?\r\nThank you!",
"I have an internal change to fix the issue. Should hopefully propagate before the end of the week and make it into the next release.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62866\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62866\">No</a>\n",
"d=\"$${d#_virtual_includes/*/}\"",
"Will this be going into a 2.15.1 release at some point soon?",
"> Will this be going into a 2.15.1 release at some point soon?\r\n\r\nNo, it's not a security fix, so will not be backported. It will go into 2.16.\r\n\r\nThe header is somewhere in the folder structure, so there is currently a work-around.",
"> No, it's not a security fix, so will not be backported.\r\n\r\nAh, didn't realize it was only security. Thought it would be for bugfix too.\r\n\r\n-----\r\n\r\nDo you know the rough timeline for 2.16?",
"Looks like it made it into the 2.16 branch: https://github.com/tensorflow/tensorflow/commits/r2.16/?author=cantonios\r\n\r\ntimeline for that release is early march. Releases come out about once a quarter."
] | 2024-01-29T23:10:36 | 2024-02-23T21:00:38 | 2024-02-01T19:47:51 |
CONTRIBUTOR
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
source
### TensorFlow version
r2.15
### Custom code
Yes
### OS platform and distribution
Linux RedHat 9.3
### Mobile device
_No response_
### Python version
3.11
### Bazel version
6.4.0
### GCC/compiler version
12.1.1
### CUDA/cuDNN version
N/A
### GPU model and memory
N/A
### Current behavior?
Note: This is related to, but different from, https://github.com/tensorflow/tensorflow/issues/61121.
Steps to reproduce:
1. Build the `//tensorflow:install_headers` Bazel target.
2. Add `bazel-bin/tensorflow/include` (or a copy thereof) to your compiler's header search path (`-I/path/to/tensorflow/include`).
3. Try to compile any file that includes `tsl/platform/ml_dtypes.h` directly or indirectly.
4. Observe a compilation failure as there is no `ml_dtypes/include/float8.h`.
```
In file included from ./mysource.hh:37:
In file included from .../include/tensorflow/core/public/session.h:26:
In file included from .../include/tensorflow/core/framework/tensor.h:26:
In file included from .../include/tensorflow/core/framework/allocator.h:26:
In file included from .../include/tensorflow/core/framework/numeric_types.h:24:
In file included from .../include/tsl/framework/numeric_types.h:22:
In file included from .../include/tsl/platform/types.h:22:
.../include/tsl/platform/ml_dtypes.h:19:10: fatal error: 'ml_dtypes/include/float8.h' file not found
19 | #include "ml_dtypes/include/float8.h" // from @ml_dtypes
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.
```
Note that there is a `ml_dtypes/include/float8.h` under `_virtual_includes/float8`. So one work-around is to add that directory (and the neighboring `int4` directory) to the header search path. But this is clumsy and has never been necessary prior to r2.15. The `//tensorflow/install_headers` target has always created a usable stand-alone include tree.
The Python package's include tree has this fixed up somehow. But the `//tensorflow/install_headers` target needs an update.
### Standalone code to reproduce the issue
```shell
#include "tensorflow/core/public/session.h"
```
### Relevant log output
_No response_
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62866/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62866/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62865
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62865/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62865/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62865/events
|
https://github.com/tensorflow/tensorflow/pull/62865
| 2,106,313,790 |
PR_kwDOArmXAs5lXrhK
| 62,865 |
Upgrade Clang version on Windows Platform
|
{
"login": "mraunak",
"id": 83710963,
"node_id": "MDQ6VXNlcjgzNzEwOTYz",
"avatar_url": "https://avatars.githubusercontent.com/u/83710963?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/mraunak",
"html_url": "https://github.com/mraunak",
"followers_url": "https://api.github.com/users/mraunak/followers",
"following_url": "https://api.github.com/users/mraunak/following{/other_user}",
"gists_url": "https://api.github.com/users/mraunak/gists{/gist_id}",
"starred_url": "https://api.github.com/users/mraunak/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/mraunak/subscriptions",
"organizations_url": "https://api.github.com/users/mraunak/orgs",
"repos_url": "https://api.github.com/users/mraunak/repos",
"events_url": "https://api.github.com/users/mraunak/events{/privacy}",
"received_events_url": "https://api.github.com/users/mraunak/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 750616506,
"node_id": "MDU6TGFiZWw3NTA2MTY1MDY=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite",
"name": "comp:lite",
"color": "0052cc",
"default": false,
"description": "TF Lite related issues"
},
{
"id": 987666414,
"node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull",
"name": "ready to pull",
"color": "2cd643",
"default": false,
"description": "PR ready for merge process"
},
{
"id": 1169364458,
"node_id": "MDU6TGFiZWwxMTY5MzY0NDU4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:S",
"name": "size:S",
"color": "adafea",
"default": false,
"description": "CL Change Size: Small"
}
] |
closed
| false |
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[] | 2024-01-29T20:02:30 | 2024-01-30T18:22:16 | 2024-01-30T18:22:15 |
CONTRIBUTOR
| null | false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62865",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62865",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62865.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62865.patch",
"merged_at": "2024-01-30T18:22:15"
}
|
This PR aims to upgrade the Clang version from 15.0.7 to 17.0.6 on the Windows platform and bring TensorFlow builds on Windows and Linux on the same compiler version to facilitate convenient debugging for the issues related to the compiler
The following changes have been made:
1. Updated https://github.com/tensorflow/tensorflow/blob/master/tensorflow/lite/experimental/microfrontend/lib/bits.h
to pick the correct inbuilt function __builtin_clzll supported on the Clang compiler on the Windows platform
2. Removed the hack "/D_USING_V110_SDK71_" https://github.com/tensorflow/tensorflow/blob/master/third_party/curl.BUILD#L21
that was blocking the intended Windows configuration defined in the header sdkddkver.h, if WINVER is undefined, WINVER is set equal to _WIN32_WINNT.
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62865/reactions",
"total_count": 1,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 1
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62865/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62864
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62864/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62864/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62864/events
|
https://github.com/tensorflow/tensorflow/issues/62864
| 2,105,844,741 |
I_kwDOArmXAs59hKQF
| 62,864 |
Cannot disable XLA and/or JIT
|
{
"login": "wudisheng",
"id": 8771316,
"node_id": "MDQ6VXNlcjg3NzEzMTY=",
"avatar_url": "https://avatars.githubusercontent.com/u/8771316?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/wudisheng",
"html_url": "https://github.com/wudisheng",
"followers_url": "https://api.github.com/users/wudisheng/followers",
"following_url": "https://api.github.com/users/wudisheng/following{/other_user}",
"gists_url": "https://api.github.com/users/wudisheng/gists{/gist_id}",
"starred_url": "https://api.github.com/users/wudisheng/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/wudisheng/subscriptions",
"organizations_url": "https://api.github.com/users/wudisheng/orgs",
"repos_url": "https://api.github.com/users/wudisheng/repos",
"events_url": "https://api.github.com/users/wudisheng/events{/privacy}",
"received_events_url": "https://api.github.com/users/wudisheng/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 404586594,
"node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower",
"name": "stat:awaiting tensorflower",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from tensorflower"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 1133285679,
"node_id": "MDU6TGFiZWwxMTMzMjg1Njc5",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:xla",
"name": "comp:xla",
"color": "0052cc",
"default": false,
"description": "XLA"
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
open
| false |
{
"login": "cheshire",
"id": 348959,
"node_id": "MDQ6VXNlcjM0ODk1OQ==",
"avatar_url": "https://avatars.githubusercontent.com/u/348959?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/cheshire",
"html_url": "https://github.com/cheshire",
"followers_url": "https://api.github.com/users/cheshire/followers",
"following_url": "https://api.github.com/users/cheshire/following{/other_user}",
"gists_url": "https://api.github.com/users/cheshire/gists{/gist_id}",
"starred_url": "https://api.github.com/users/cheshire/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/cheshire/subscriptions",
"organizations_url": "https://api.github.com/users/cheshire/orgs",
"repos_url": "https://api.github.com/users/cheshire/repos",
"events_url": "https://api.github.com/users/cheshire/events{/privacy}",
"received_events_url": "https://api.github.com/users/cheshire/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "cheshire",
"id": 348959,
"node_id": "MDQ6VXNlcjM0ODk1OQ==",
"avatar_url": "https://avatars.githubusercontent.com/u/348959?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/cheshire",
"html_url": "https://github.com/cheshire",
"followers_url": "https://api.github.com/users/cheshire/followers",
"following_url": "https://api.github.com/users/cheshire/following{/other_user}",
"gists_url": "https://api.github.com/users/cheshire/gists{/gist_id}",
"starred_url": "https://api.github.com/users/cheshire/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/cheshire/subscriptions",
"organizations_url": "https://api.github.com/users/cheshire/orgs",
"repos_url": "https://api.github.com/users/cheshire/repos",
"events_url": "https://api.github.com/users/cheshire/events{/privacy}",
"received_events_url": "https://api.github.com/users/cheshire/received_events",
"type": "User",
"site_admin": false
},
{
"login": "sachinprasadhs",
"id": 73069040,
"node_id": "MDQ6VXNlcjczMDY5MDQw",
"avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sachinprasadhs",
"html_url": "https://github.com/sachinprasadhs",
"followers_url": "https://api.github.com/users/sachinprasadhs/followers",
"following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}",
"gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions",
"organizations_url": "https://api.github.com/users/sachinprasadhs/orgs",
"repos_url": "https://api.github.com/users/sachinprasadhs/repos",
"events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}",
"received_events_url": "https://api.github.com/users/sachinprasadhs/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi **@wudisheng** ,\r\n\r\nCould you try this once\r\n```\r\nSet XLA_FLAGS=--xla_disabled_backends=cpu,gpu to disable XLA for both CPU and GPU.\r\n```\r\nNote: \r\nDisabling XLA and JIT might impact performance, so consider testing and benchmarking before deploying.\r\n\r\nIf problem is not resolved then please share a simple standalone code to reproduce the issue.\r\n\r\nThank you!\r\n",
"> --xla_disabled_backends=cpu,gpu\r\n\r\nIt is not a valid `XLA_FLAGS` in `2.15.0`, I got\r\n\r\n```\r\n2024-01-30 18:49:17.343195: F external/local_xla/xla/parse_flags_from_env.cc:210] Unknown flags in XLA_FLAGS: --xla_disabled_backends=cpu,gpu \r\n```\r\n\r\nBTW: I also tried `--xla_gpu_disable_gpuasm_optimizations=true`, `--xla_backend_optimization_level=0` and `--xla_gpu_autotune_level=0`, but it still looks for `ptxas` and compile a bunch of \"entry function 'main_kernel' ...\"",
"OOC, why do you want to disable XLA? This is not generally supported, a lot of features an some layers are XLA-only these days.",
"Generally we don't trust JIT --- we don't want our graph to be optimized or fused in any way beyond our SWE's knowledge. Performance is the last thing to concern about.\r\n\r\nActually we have been seeing a bunch more errors after a try of 2.15.0, including CUDA_ERROR_ILLEGAL_ADDRESS, etc. (when doing exactly the same thing as 2.12.1), so we are planning to stick with 2.12.1 for some time, if we can resolve some other issues when using 2.12.1 with CUDA 12.1/12.2. ",
"Overall this is not supported: if a TF function is annotated with `@tf.function(jit_compile=True)`, there's no way to avoid JITing.\r\n\r\nYou can use the \"fully eager mode\" fallback, which would disable `tf.function` itself, that should be sufficient.\r\n\r\nThe statement\r\n\r\n> we don't want our graph to be optimized or fused in any way beyond our SWE's knowledge\r\n\r\nalready does not hold without XLA: Grappler pass runs a number of fusion/etc optimizations on TF graph even without XLA.",
"We don't use Python. What's the equivalent way of doing your suggestion in C++?"
] | 2024-01-29T16:09:44 | 2024-02-08T21:09:30 | null |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
No
### Source
source
### TensorFlow version
2.15.0
### Custom code
Yes
### OS platform and distribution
Linux Ubuntu 22.04.3
### Mobile device
_No response_
### Python version
3.10.12 (Unrelated)
### Bazel version
6.3.2
### GCC/compiler version
Clang 18
### CUDA/cuDNN version
12.2
### GPU model and memory
A100 and A10
### Current behavior?
After upgrading from `2.12.1` to `2.15.0` we observed a lot **new** logs when starting a **C++** service using Tensorflow, that it calls `ptxas` to compile some generated PTX, a snippet is attached below.
We tried a bunch of options in TF_XLA_FLAGS such as `--tf_xla_auto_jit=-1`, `--tf_mlir_enable_mlir_bridge=0`, `--tf_xla_cpu_global_jit=0`, `--tf_xla_clustering_fuel=0`, etc. but it still compiles those ops in the pass of `CreateGpuKernelToBlobPass` anyway.
I wonder if anything related to XLA / JIT changed between `2.12.1` and `2.15.0`? And is there a way to simply disable all XLA and JIT?
BTW: Both Tensorflow versions were built with XLA and CUDA supports, with `TF_CUDA_COMPUTE_CAPABILITIES="7.0,7.5,8.0,8.6,9.0"`.
### Standalone code to reproduce the issue
```shell
It is a C++ service which loads model and do inference, we do not currently have a minimal example at this time. However, we can try providing detailed context as much as possible if we can narrow the scenario down to a considerable small portion of the service.
```
### Relevant log output
```shell
2024-01-29 15:14:43.203921: I external/local_xla/xla/service/gpu/llvm_gpu_backend/gpu_backend_lib.cc:565] Compile module main_kernel_0 time: 7.33 ms (cumulative: 82.4 ms, max: 9.23 ms, #called: 15)2024-01-29 15:14:43.204021: I external/local_xla/xla/service/gpu/llvm_gpu_backend/gpu_backend_lib.cc:565] Compile module main_kernel time: 7.43 ms (cumulative: 89.9 ms, max: 9.23 ms, #called: 16)2024-01-29 15:14:43.204084: I external/local_xla/xla/stream_executor/gpu/asm_compiler.cc:263] ptx written to: /tmp/tempfile-jscs02-ai-deep-dev-4a10-01-d460ae06-1673-61010665dbba92024-01-29 15:14:43.204112: I external/local_xla/xla/stream_executor/gpu/asm_compiler.cc:295] /usr/local/cuda-12.2/bin/ptxas /tmp/tempfile-jscs02-ai-deep-dev-4a10-01-d460ae06-1673-61010665dbba9 -o /tmp/tempfile-jscs02-ai-deep-dev-4a10-01-d460ae06-1673-61010665dbc05 -arch=sm_86 --warn-on-spills -v 2024-01-29 15:14:43.204182: I external/local_xla/xla/stream_executor/gpu/asm_compiler.cc:263] ptx written to: /tmp/tempfile-jscs02-ai-deep-dev-4a10-01-b79066f7-1673-61010665dbc0d2024-01-29 15:14:43.204209: I external/local_xla/xla/stream_executor/gpu/asm_compiler.cc:295] /usr/local/cuda-12.2/bin/ptxas /tmp/tempfile-jscs02-ai-deep-dev-4a10-01-b79066f7-1673-61010665dbc0d -o /tmp/tempfile-jscs02-ai-deep-dev-4a10-01-b79066f7-1673-61010665dbc66 -arch=sm_86 --warn-on-spills -v2024-01-29 15:14:43.204334: I external/local_xla/xla/service/gpu/llvm_gpu_backend/gpu_backend_lib.cc:565] Compile module main_kernel_1 time: 7.71 ms (cumulative: 97.6 ms, max: 9.23 ms, #called: 17)2024-01-29 15:14:43.204499: I external/local_xla/xla/stream_executor/gpu/asm_compiler.cc:263] ptx written to: /tmp/tempfile-jscs02-ai-deep-dev-4a10-01-7941e65c-1673-61010665dbd48
2024-01-29 15:14:43.204528: I external/local_xla/xla/stream_executor/gpu/asm_compiler.cc:295] /usr/local/cuda-12.2/bin/ptxas /tmp/tempfile-jscs02-ai-deep-dev-4a10-01-7941e65c-1673-61010665dbd48 -o /tmp/tempfile-jscs02-ai-deep-dev-4a10-01-7941e65c-1673-61010665dbda4 -arch=sm_86 --warn-on-spills -v2024-01-29 15:14:43.236003: I external/local_xla/xla/stream_executor/gpu/asm_compiler.cc:333] ptxas info : 0 bytes gmem
ptxas info : Compiling entry function 'main_kernel' for 'sm_86'ptxas info : Function properties for main_kernel 0 bytes stack frame, 0 bytes spill stores, 0 bytes spill loadsptxas info : Used 12 registers, 452 bytes cmem[0]
2024-01-29 15:14:43.236589: I external/local_xla/xla/stream_executor/gpu/asm_compiler.cc:333] ptxas info : 0 bytes gmem
ptxas info : Compiling entry function 'main_kernel' for 'sm_86'ptxas info : Function properties for main_kernel 0 bytes stack frame, 0 bytes spill stores, 0 bytes spill loads
ptxas info : Used 14 registers, 476 bytes cmem[0]
2024-01-29 15:14:43.237263: I external/local_xla/xla/stream_executor/gpu/asm_compiler.cc:333] ptxas info : 0 bytes gmem
ptxas info : Compiling entry function 'main_kernel' for 'sm_86'
ptxas info : Function properties for main_kernel
0 bytes stack frame, 0 bytes spill stores, 0 bytes spill loads
ptxas info : Used 14 registers, 508 bytes cmem[0]
2024-01-29 15:14:43.238685: I external/local_xla/xla/stream_executor/gpu/asm_compiler.cc:333] ptxas info : 0 bytes gmem
ptxas info : Compiling entry function 'main_kernel' for 'sm_86'
ptxas info : Function properties for main_kernel
0 bytes stack frame, 0 bytes spill stores, 0 bytes spill loads
ptxas info : Used 14 registers, 532 bytes cmem[0]
2024-01-29 15:14:43.240855: I external/local_xla/xla/stream_executor/gpu/asm_compiler.cc:333] ptxas info : 0 bytes gmem
ptxas info : Compiling entry function 'main_kernel' for 'sm_86'
ptxas info : Function properties for main_kernel
0 bytes stack frame, 0 bytes spill stores, 0 bytes spill loads
ptxas info : Used 15 registers, 564 bytes cmem[0]
2024-01-29 15:14:43.241720: I external/local_xla/xla/stream_executor/gpu/asm_compiler.cc:333] ptxas info : 0 bytes gmem
ptxas info : Compiling entry function 'main_kernel' for 'sm_86'
ptxas info : Function properties for main_kernel
0 bytes stack frame, 0 bytes spill stores, 0 bytes spill loads
ptxas info : Used 18 registers, 444 bytes cmem[0]
2024-01-29 15:14:43.241731: I external/local_xla/xla/stream_executor/gpu/asm_compiler.cc:333] ptxas info : 0 bytes gmem
ptxas info : Compiling entry function 'main_kernel' for 'sm_86'
ptxas info : Function properties for main_kernel
0 bytes stack frame, 0 bytes spill stores, 0 bytes spill loads
ptxas info : Used 16 registers, 444 bytes cmem[0]
2024-01-29 15:14:43.242423: I external/local_xla/xla/stream_executor/gpu/asm_compiler.cc:333] ptxas info : 0 bytes gmem
ptxas info : Compiling entry function 'main_kernel' for 'sm_86'
ptxas info : Function properties for main_kernel
0 bytes stack frame, 0 bytes spill stores, 0 bytes spill loads
ptxas info : Used 18 registers, 452 bytes cmem[0]
libunwind: __unw_add_dynamic_fde: bad fde: FDE is really a CIE
2024-01-29 15:14:43.416923: I tensorflow/core/common_runtime/gpu/gpu_device.cc:812] GpuDevice::ComputeHelper scheduled dense/clip_by_value_65 op Maximum on GPU 0 stream[0]
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62864/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62864/timeline
| null | null | false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62863
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62863/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62863/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62863/events
|
https://github.com/tensorflow/tensorflow/issues/62863
| 2,105,278,578 |
I_kwDOArmXAs59fABy
| 62,863 |
Custom-built TFLite with WASM – best practices
|
{
"login": "AlexanderLutsenko",
"id": 2457934,
"node_id": "MDQ6VXNlcjI0NTc5MzQ=",
"avatar_url": "https://avatars.githubusercontent.com/u/2457934?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/AlexanderLutsenko",
"html_url": "https://github.com/AlexanderLutsenko",
"followers_url": "https://api.github.com/users/AlexanderLutsenko/followers",
"following_url": "https://api.github.com/users/AlexanderLutsenko/following{/other_user}",
"gists_url": "https://api.github.com/users/AlexanderLutsenko/gists{/gist_id}",
"starred_url": "https://api.github.com/users/AlexanderLutsenko/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/AlexanderLutsenko/subscriptions",
"organizations_url": "https://api.github.com/users/AlexanderLutsenko/orgs",
"repos_url": "https://api.github.com/users/AlexanderLutsenko/repos",
"events_url": "https://api.github.com/users/AlexanderLutsenko/events{/privacy}",
"received_events_url": "https://api.github.com/users/AlexanderLutsenko/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473173351,
"node_id": "MDU6TGFiZWw0NzMxNzMzNTE=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:build/install",
"name": "type:build/install",
"color": "159b2e",
"default": false,
"description": "Build and install issues"
},
{
"id": 473184161,
"node_id": "MDU6TGFiZWw0NzMxODQxNjE=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:support",
"name": "type:support",
"color": "159b2e",
"default": false,
"description": "Support issues"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
},
{
"id": 750616506,
"node_id": "MDU6TGFiZWw3NTA2MTY1MDY=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite",
"name": "comp:lite",
"color": "0052cc",
"default": false,
"description": "TF Lite related issues"
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
closed
| false |
{
"login": "LakshmiKalaKadali",
"id": 149650845,
"node_id": "U_kgDOCOt9nQ",
"avatar_url": "https://avatars.githubusercontent.com/u/149650845?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/LakshmiKalaKadali",
"html_url": "https://github.com/LakshmiKalaKadali",
"followers_url": "https://api.github.com/users/LakshmiKalaKadali/followers",
"following_url": "https://api.github.com/users/LakshmiKalaKadali/following{/other_user}",
"gists_url": "https://api.github.com/users/LakshmiKalaKadali/gists{/gist_id}",
"starred_url": "https://api.github.com/users/LakshmiKalaKadali/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/LakshmiKalaKadali/subscriptions",
"organizations_url": "https://api.github.com/users/LakshmiKalaKadali/orgs",
"repos_url": "https://api.github.com/users/LakshmiKalaKadali/repos",
"events_url": "https://api.github.com/users/LakshmiKalaKadali/events{/privacy}",
"received_events_url": "https://api.github.com/users/LakshmiKalaKadali/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "LakshmiKalaKadali",
"id": 149650845,
"node_id": "U_kgDOCOt9nQ",
"avatar_url": "https://avatars.githubusercontent.com/u/149650845?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/LakshmiKalaKadali",
"html_url": "https://github.com/LakshmiKalaKadali",
"followers_url": "https://api.github.com/users/LakshmiKalaKadali/followers",
"following_url": "https://api.github.com/users/LakshmiKalaKadali/following{/other_user}",
"gists_url": "https://api.github.com/users/LakshmiKalaKadali/gists{/gist_id}",
"starred_url": "https://api.github.com/users/LakshmiKalaKadali/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/LakshmiKalaKadali/subscriptions",
"organizations_url": "https://api.github.com/users/LakshmiKalaKadali/orgs",
"repos_url": "https://api.github.com/users/LakshmiKalaKadali/repos",
"events_url": "https://api.github.com/users/LakshmiKalaKadali/events{/privacy}",
"received_events_url": "https://api.github.com/users/LakshmiKalaKadali/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi @AlexanderLutsenko ,\r\n\r\nYes, TFJS supports WASM when executing TensorFlow Lite models in the browser. You can move with the [link](https://github.com/tensorflow/tfjs/tree/master/tfjs-tflite#tflite-support-for-tensorflowjs) as you menmtioned and can build the `tfjs-tflite` using `yarn build` which inturn uses `bazel` with wasm backend.\r\n\r\n- Navigate to `tfjs-tflite repo`\r\n- Check for `yarn` installation\r\n- Run `yarn build`\r\n- \r\nI tried with Bazel 6.1.0 but build was not successsful but tested with Bazel 5.3.0, the yarn build is successful. Please check this [gist](https://colab.research.google.com/gist/LakshmiKalaKadali/42c828b624b00a4b28615dc0d7865d83/tflite_62863.ipynb) provided with the tfjs-tflite build.\r\n Please refer other useful links [link1](https://github.com/emscripten-core/emsdk/tree/master/bazel#bazel-emscripten-toolchain), [link2](https://github.com/tensorflow/tensorflow/issues/46359#issuecomment-1215595828).\r\n\r\nThank You",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62863\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62863\">No</a>\n"
] | 2024-01-29T11:29:11 | 2024-02-17T01:46:23 | 2024-02-17T01:46:18 |
NONE
| null | null | null |
### Issue type
Build/Install
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
source
### TensorFlow version
2.15
### Custom code
Yes
### OS platform and distribution
Linux Ubuntu 20.04
### Mobile device
_No response_
### Python version
_No response_
### Bazel version
6.5.0
### GCC/compiler version
13.1.0
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
Hello, folks! I want to make a custom build of TFLite for the web, but not sure how to approach it.
Specifically, there are two things I'd like to add
1. The ability to write model inputs directly to memory and read outputs from memory. This improves performance quite substantially.
```python
EMSCRIPTEN_KEEPALIVE
float* getInputMemoryOffset(int i) {
return interpreter->typed_input_tensor<float>(i);
}
EMSCRIPTEN_KEEPALIVE
float* getOutputMemoryOffset(int i) {
return interpreter->typed_output_tensor<float>(i);
}
```
2. Support for custom ops (e.g. from Mediapipe) which are not present in the standard build
```python
tflite::ops::builtin::BuiltinOpResolver resolver;
resolver.AddCustom("Convolution2DTransposeBias", mediapipe::tflite_operations::RegisterConvolution2DTransposeBias());
tflite::InterpreterBuilder builder(*model, resolver);
```
[Here](https://github.com/tensorflow/tensorflow/issues/61200) is one approach that used to work some time ago (I believe around v2.3), bit it does not anymore.
Then I read [this](https://github.com/tensorflow/tfjs/tree/master/tfjs-tflite#tflite-support-for-tensorflowjs), and it says in TFJS, WASM is supported out of the box. Should I perhaps go that way? If so, how?
To summarize:
Should I use bazel or cmake? Plain TFLite or TFJS? Is it necessary to write a custom emscripten build recipe or the standard ones will do?
### Standalone code to reproduce the issue
```shell
N/A
```
### Relevant log output
_No response_
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62863/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62863/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62862
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62862/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62862/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62862/events
|
https://github.com/tensorflow/tensorflow/issues/62862
| 2,105,175,035 |
I_kwDOArmXAs59emv7
| 62,862 |
1
|
{
"login": "iCosmos76",
"id": 32038807,
"node_id": "MDQ6VXNlcjMyMDM4ODA3",
"avatar_url": "https://avatars.githubusercontent.com/u/32038807?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/iCosmos76",
"html_url": "https://github.com/iCosmos76",
"followers_url": "https://api.github.com/users/iCosmos76/followers",
"following_url": "https://api.github.com/users/iCosmos76/following{/other_user}",
"gists_url": "https://api.github.com/users/iCosmos76/gists{/gist_id}",
"starred_url": "https://api.github.com/users/iCosmos76/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/iCosmos76/subscriptions",
"organizations_url": "https://api.github.com/users/iCosmos76/orgs",
"repos_url": "https://api.github.com/users/iCosmos76/repos",
"events_url": "https://api.github.com/users/iCosmos76/events{/privacy}",
"received_events_url": "https://api.github.com/users/iCosmos76/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
}
] |
closed
| true |
{
"login": "SuryanarayanaY",
"id": 116063290,
"node_id": "U_kgDOBur8Og",
"avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/SuryanarayanaY",
"html_url": "https://github.com/SuryanarayanaY",
"followers_url": "https://api.github.com/users/SuryanarayanaY/followers",
"following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}",
"gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}",
"starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions",
"organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs",
"repos_url": "https://api.github.com/users/SuryanarayanaY/repos",
"events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}",
"received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "SuryanarayanaY",
"id": 116063290,
"node_id": "U_kgDOBur8Og",
"avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/SuryanarayanaY",
"html_url": "https://github.com/SuryanarayanaY",
"followers_url": "https://api.github.com/users/SuryanarayanaY/followers",
"following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}",
"gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}",
"starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions",
"organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs",
"repos_url": "https://api.github.com/users/SuryanarayanaY/repos",
"events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}",
"received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events",
"type": "User",
"site_admin": false
}
] | null |
[] | 2024-01-29T10:33:44 | 2024-01-30T04:51:22 | 2024-01-30T04:51:22 |
NONE
|
spam
| null | null | null |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62862/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62862/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62861
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62861/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62861/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62861/events
|
https://github.com/tensorflow/tensorflow/issues/62861
| 2,105,026,993 |
I_kwDOArmXAs59eCmx
| 62,861 |
tf.concat (and tf.transpose) inside a for loop with tf.range in the context of a GradientTape while using XLA dosn't work
|
{
"login": "MoritzMSP",
"id": 117213406,
"node_id": "U_kgDOBvyI3g",
"avatar_url": "https://avatars.githubusercontent.com/u/117213406?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/MoritzMSP",
"html_url": "https://github.com/MoritzMSP",
"followers_url": "https://api.github.com/users/MoritzMSP/followers",
"following_url": "https://api.github.com/users/MoritzMSP/following{/other_user}",
"gists_url": "https://api.github.com/users/MoritzMSP/gists{/gist_id}",
"starred_url": "https://api.github.com/users/MoritzMSP/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/MoritzMSP/subscriptions",
"organizations_url": "https://api.github.com/users/MoritzMSP/orgs",
"repos_url": "https://api.github.com/users/MoritzMSP/repos",
"events_url": "https://api.github.com/users/MoritzMSP/events{/privacy}",
"received_events_url": "https://api.github.com/users/MoritzMSP/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 404586594,
"node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower",
"name": "stat:awaiting tensorflower",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from tensorflower"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 1133285679,
"node_id": "MDU6TGFiZWwxMTMzMjg1Njc5",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:xla",
"name": "comp:xla",
"color": "0052cc",
"default": false,
"description": "XLA"
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
open
| false |
{
"login": "cheshire",
"id": 348959,
"node_id": "MDQ6VXNlcjM0ODk1OQ==",
"avatar_url": "https://avatars.githubusercontent.com/u/348959?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/cheshire",
"html_url": "https://github.com/cheshire",
"followers_url": "https://api.github.com/users/cheshire/followers",
"following_url": "https://api.github.com/users/cheshire/following{/other_user}",
"gists_url": "https://api.github.com/users/cheshire/gists{/gist_id}",
"starred_url": "https://api.github.com/users/cheshire/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/cheshire/subscriptions",
"organizations_url": "https://api.github.com/users/cheshire/orgs",
"repos_url": "https://api.github.com/users/cheshire/repos",
"events_url": "https://api.github.com/users/cheshire/events{/privacy}",
"received_events_url": "https://api.github.com/users/cheshire/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "cheshire",
"id": 348959,
"node_id": "MDQ6VXNlcjM0ODk1OQ==",
"avatar_url": "https://avatars.githubusercontent.com/u/348959?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/cheshire",
"html_url": "https://github.com/cheshire",
"followers_url": "https://api.github.com/users/cheshire/followers",
"following_url": "https://api.github.com/users/cheshire/following{/other_user}",
"gists_url": "https://api.github.com/users/cheshire/gists{/gist_id}",
"starred_url": "https://api.github.com/users/cheshire/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/cheshire/subscriptions",
"organizations_url": "https://api.github.com/users/cheshire/orgs",
"repos_url": "https://api.github.com/users/cheshire/repos",
"events_url": "https://api.github.com/users/cheshire/events{/privacy}",
"received_events_url": "https://api.github.com/users/cheshire/received_events",
"type": "User",
"site_admin": false
},
{
"login": "ishark",
"id": 723624,
"node_id": "MDQ6VXNlcjcyMzYyNA==",
"avatar_url": "https://avatars.githubusercontent.com/u/723624?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/ishark",
"html_url": "https://github.com/ishark",
"followers_url": "https://api.github.com/users/ishark/followers",
"following_url": "https://api.github.com/users/ishark/following{/other_user}",
"gists_url": "https://api.github.com/users/ishark/gists{/gist_id}",
"starred_url": "https://api.github.com/users/ishark/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/ishark/subscriptions",
"organizations_url": "https://api.github.com/users/ishark/orgs",
"repos_url": "https://api.github.com/users/ishark/repos",
"events_url": "https://api.github.com/users/ishark/events{/privacy}",
"received_events_url": "https://api.github.com/users/ishark/received_events",
"type": "User",
"site_admin": false
},
{
"login": "changm",
"id": 1015726,
"node_id": "MDQ6VXNlcjEwMTU3MjY=",
"avatar_url": "https://avatars.githubusercontent.com/u/1015726?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/changm",
"html_url": "https://github.com/changm",
"followers_url": "https://api.github.com/users/changm/followers",
"following_url": "https://api.github.com/users/changm/following{/other_user}",
"gists_url": "https://api.github.com/users/changm/gists{/gist_id}",
"starred_url": "https://api.github.com/users/changm/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/changm/subscriptions",
"organizations_url": "https://api.github.com/users/changm/orgs",
"repos_url": "https://api.github.com/users/changm/repos",
"events_url": "https://api.github.com/users/changm/events{/privacy}",
"received_events_url": "https://api.github.com/users/changm/received_events",
"type": "User",
"site_admin": false
},
{
"login": "wangpengmit",
"id": 7817365,
"node_id": "MDQ6VXNlcjc4MTczNjU=",
"avatar_url": "https://avatars.githubusercontent.com/u/7817365?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/wangpengmit",
"html_url": "https://github.com/wangpengmit",
"followers_url": "https://api.github.com/users/wangpengmit/followers",
"following_url": "https://api.github.com/users/wangpengmit/following{/other_user}",
"gists_url": "https://api.github.com/users/wangpengmit/gists{/gist_id}",
"starred_url": "https://api.github.com/users/wangpengmit/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/wangpengmit/subscriptions",
"organizations_url": "https://api.github.com/users/wangpengmit/orgs",
"repos_url": "https://api.github.com/users/wangpengmit/repos",
"events_url": "https://api.github.com/users/wangpengmit/events{/privacy}",
"received_events_url": "https://api.github.com/users/wangpengmit/received_events",
"type": "User",
"site_admin": false
},
{
"login": "swachhandl",
"id": 11137436,
"node_id": "MDQ6VXNlcjExMTM3NDM2",
"avatar_url": "https://avatars.githubusercontent.com/u/11137436?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/swachhandl",
"html_url": "https://github.com/swachhandl",
"followers_url": "https://api.github.com/users/swachhandl/followers",
"following_url": "https://api.github.com/users/swachhandl/following{/other_user}",
"gists_url": "https://api.github.com/users/swachhandl/gists{/gist_id}",
"starred_url": "https://api.github.com/users/swachhandl/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/swachhandl/subscriptions",
"organizations_url": "https://api.github.com/users/swachhandl/orgs",
"repos_url": "https://api.github.com/users/swachhandl/repos",
"events_url": "https://api.github.com/users/swachhandl/events{/privacy}",
"received_events_url": "https://api.github.com/users/swachhandl/received_events",
"type": "User",
"site_admin": false
},
{
"login": "sachinprasadhs",
"id": 73069040,
"node_id": "MDQ6VXNlcjczMDY5MDQw",
"avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sachinprasadhs",
"html_url": "https://github.com/sachinprasadhs",
"followers_url": "https://api.github.com/users/sachinprasadhs/followers",
"following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}",
"gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions",
"organizations_url": "https://api.github.com/users/sachinprasadhs/orgs",
"repos_url": "https://api.github.com/users/sachinprasadhs/repos",
"events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}",
"received_events_url": "https://api.github.com/users/sachinprasadhs/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"@MoritzMSP Could you consider to calculate shapes and perform tf.concat and tf.transpose outside the loop. Pre-compute Shapes and Operations could help in this case. Thank you!",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62861\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62861\">No</a>\n",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62861\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62861\">No</a>\n",
"@sushreebarsa This could indeed work in the given simplified example, however in other models I'm developing this is not possible since the values which are concatenated are dependent on the value of yi which is in turn dependent on the prior iteration of the loop.\r\n\r\ne.g. Part of the compute function from another model:\r\n```\r\[email protected](input_signature=[tf.TensorSpec(shape=(None, 12, 1), dtype=tf.float32)],\r\n jit_compile=False)\r\ndef compute(self, yi):\r\n eta_LR = yi[:, 0:3, :]\r\n rp0_R = yi[:, 3:6, :]\r\n drp0_R = yi[:, 6:9, :] \r\n omegaLR_L = yi[:, 9:12, :]\r\n\r\n A_LR = Modeling.calcA_LR(eta_LR)\r\n A_RL = tf.transpose(A_LR, perm=[0, 2, 1])\r\n\r\n PhiUpper = tf.concat([tf.eye(3,batch_shape=[self.batchsize]), [email protected](self.rgp_L)], axis=2)\r\n PhiLower = tf.concat([tf.zeros([self.batchsize, 2, 3]), Modeling.skewSym(A_LR[:, :, 2:3])[:, 0:2, :]], axis=2)\r\n Phi = tf.concat([PhiUpper, PhiLower], axis=1)\r\n\r\n #Code continues here \r\n # --> LHS and RHS will be constructed (Phi is a part of LHS)\r\n # d_eta will be calculated\r\n\r\n sol = tf.linalg.solve(LHS, RHS)\r\n dd_rp0_R = sol[:, 0:3, :]\r\n d_omegaLR_L = sol[:, 3:6, :]\r\n\r\n return tf.concat([d_eta, drp0_R, dd_rp0_R, d_omegaLR_L], axis=1)\r\n```\r\n(The Modeling.skewSym(X) function just rearranges the elements in X with the shape [None, 3, 1] into a Matrix with a shape of [None, 3, 3])\r\n\r\n--> In the tf,concat / tf.transpose Function A_LR and A_RL are used, which are depended on eta_LR and eta_LR is part of yi. Thats the reason why it can't be Pre-computed outside of the loop.\r\n",
"@MoritzMSP Thank you for the update!\r\n@sachinprasadhs Please find the replicated [gist](https://colab.research.google.com/gist/sushreebarsa/094dc8a7cf598f338c1ca7693e2a706d/62861.ipynb) of the error reported. Thank you!",
"I am not familiar with tf.function, assigning to @cheshire who is familiar with this and might know who can help.",
"I'm not sure this is expected behavior or not. I was able to simplify the program a bit:\r\n\r\n```\r\nclass Model():\r\n def __init__(self, batchsize):\r\n self.batchsize = batchsize\r\n self.g = tf.Variable(initial_value=tf.ones([self.batchsize,1,1]), trainable=True, name=\"g\")\r\n self.y0 = tf.ones([self.batchsize, 2, 1])\r\n\r\n\r\n @tf.function(input_signature=[tf.TensorSpec(shape=(None, 2, 1), dtype=tf.float32)],\r\n jit_compile=False)\r\n def compute(self, yi):\r\n B = tf.concat([tf.zeros_like(self.g), self.g], 1)\r\n return B\r\n\r\nclass Estimator():\r\n def __init__(self, model):\r\n self.model = model\r\n self.dt = tf.constant(0.001)\r\n\r\n @tf.function(jit_compile=True, reduce_retracing=False)\r\n def estimate(self):\r\n with tf.GradientTape() as tape:\r\n yi = self.model.y0\r\n for i in tf.range(10):\r\n yi = self.model.compute(yi)\r\n grads = tape.gradient(yi, [self.model.g])\r\n return grads\r\n\r\ndevice = \"CPU:0\"\r\n\r\nwith tf.device(device):\r\n batchsize = 5\r\n model = Model(batchsize)\r\n estimator = Estimator(model)\r\n grads = estimator.estimate()\r\n```\r\n\r\nFails due to `ConcatOffset` not having constant time inputs. The error message is a weird red herring since the shapes are known but the actual arguments to `ConcatOffset` need to be constant. Also the Model.compute(..) has jit_compile=False but since it's called by Estimator.estimate(...) all the callees also have to be compiled. \r\n\r\n> If you remove either\r\n> the GradientTape context\r\n> or the for loop with tf.range\r\n> or the XLA compilation\r\n> the code will work as expected.\r\n\r\nRemoving these makes this totally skip compilation and so that's why the error doesn't show up. I'm not sure this is expected behavior. Looping in swachhandl@ who might know more.\r\n\r\n\r\n================ EXTRA DEBUG DUMP===============\r\nFailed MLIR dump from simple version:\r\n\r\n```\r\nmodule attributes {tf.versions = {bad_consumers = [], min_consumer = 0 : i32, producer = 1739 : i32}} {\r\n func.func @main(%arg0: tensor<5x2x1xf32>, %arg1: tensor<5x1x1xf32> {tf._user_specified_name = \"input_5\"}) -> tensor<5x1x1xf32> attributes {allow_soft_placement = false, tf.entry_function = {control_outputs = \"while,gradient_tape/while/VariableShape\", inputs = \"unknown,while_input_5\", outputs = \"identity_RetVal\"}} {\r\n %cst = \"tf.Const\"() <{value = dense<> : tensor<0xi32>}> : () -> tensor<0xi32>\r\n %cst_0 = \"tf.Const\"() <{value = dense<3> : tensor<i32>}> : () -> tensor<i32>\r\n %cst_1 = \"tf.Const\"() <{value = dense<[5, 1, 1]> : tensor<3xi32>}> : () -> tensor<3xi32>\r\n %cst_2 = \"tf.Const\"() <{value = dense<0.000000e+00> : tensor<5x2x1xf32>}> : () -> tensor<5x2x1xf32>\r\n %cst_3 = \"tf.Const\"() <{value = dense<1> : tensor<i32>}> : () -> tensor<i32>\r\n %cst_4 = \"tf.Const\"() <{value = dense<1> : tensor<1xi32>}> : () -> tensor<1xi32>\r\n %cst_5 = \"tf.Const\"() <{value = dense<10> : tensor<i32>}> : () -> tensor<i32>\r\n %cst_6 = \"tf.Const\"() <{value = dense<0> : tensor<1xi32>}> : () -> tensor<1xi32>\r\n %cst_7 = \"tf.Const\"() <{value = dense<0.000000e+00> : tensor<5x1x1xf32>}> : () -> tensor<5x1x1xf32>\r\n %cst_8 = \"tf.Const\"() <{value = dense<1.000000e+00> : tensor<5x2x1xf32>}> : () -> tensor<5x2x1xf32>\r\n %cst_9 = \"tf.Const\"() <{value = dense<0> : tensor<i32>}> : () -> tensor<i32>\r\n %cst_10 = \"tf.Const\"() <{value = dense<0> : tensor<10xi32>}> : () -> tensor<10xi32>\r\n %0:4 = \"tf.WhileRegion\"(%cst_9, %cst_9, %cst_10, %cst_6) <{is_stateless = false, parallel_iterations = 10 : i64}> ({\r\n ^bb0(%arg2: tensor<i32>, %arg3: tensor<i32>, %arg4: tensor<10xi32>, %arg5: tensor<1xi32>):\r\n %2 = \"tf.Less\"(%arg3, %cst_5) {device = \"\"} : (tensor<i32>, tensor<i32>) -> tensor<i1>\r\n %3 = \"tf.Less\"(%arg2, %cst_5) {device = \"\"} : (tensor<i32>, tensor<i32>) -> tensor<i1>\r\n %4 = \"tf.LogicalAnd\"(%3, %2) {device = \"\"} : (tensor<i1>, tensor<i1>) -> tensor<i1>\r\n \"tf.Yield\"(%4) : (tensor<i1>) -> ()\r\n }, {\r\n ^bb0(%arg2: tensor<i32>, %arg3: tensor<i32>, %arg4: tensor<10xi32>, %arg5: tensor<1xi32>):\r\n %2 = \"tf.AddV2\"(%arg3, %cst_3) {device = \"\"} : (tensor<i32>, tensor<i32>) -> tensor<i32>\r\n %3 = \"tf.XlaDynamicUpdateSlice\"(%arg4, %cst_4, %arg5) : (tensor<10xi32>, tensor<1xi32>, tensor<1xi32>) -> tensor<10xi32>\r\n %4 = \"tf.AddV2\"(%arg5, %cst_4) : (tensor<1xi32>, tensor<1xi32>) -> tensor<1xi32>\r\n %5 = \"tf.AddV2\"(%arg2, %cst_3) {device = \"\"} : (tensor<i32>, tensor<i32>) -> tensor<i32>\r\n \"tf.Yield\"(%5, %2, %3, %4) : (tensor<i32>, tensor<i32>, tensor<10xi32>, tensor<1xi32>) -> ()\r\n }) {_num_original_outputs = 8 : i64, _read_only_resource_inputs = [5], _xla_propagate_compile_time_consts = true, device = \"\"} : (tensor<i32>, tensor<i32>, tensor<10xi32>, tensor<1xi32>) -> (tensor<i32>, tensor<i32>, tensor<10xi32>, tensor<1xi32>)\r\n %1:4 = \"tf.WhileRegion\"(%cst_9, %cst_8, %cst_7, %0#3) <{is_stateless = true, parallel_iterations = 10 : i64}> ({\r\n ^bb0(%arg2: tensor<i32>, %arg3: tensor<5x2x1xf32>, %arg4: tensor<5x1x1xf32>, %arg5: tensor<1xi32>):\r\n %2 = \"tf.Less\"(%arg2, %0#0) {device = \"\"} : (tensor<i32>, tensor<i32>) -> tensor<i1>\r\n \"tf.Yield\"(%2) : (tensor<i1>) -> ()\r\n }, {\r\n ^bb0(%arg2: tensor<i32>, %arg3: tensor<5x2x1xf32>, %arg4: tensor<5x1x1xf32>, %arg5: tensor<1xi32>):\r\n %2 = \"tf.Sub\"(%arg5, %cst_4) : (tensor<1xi32>, tensor<1xi32>) -> tensor<1xi32>\r\n %3 = \"tf.Slice\"(%0#2, %2, %cst_4) : (tensor<10xi32>, tensor<1xi32>, tensor<1xi32>) -> tensor<1xi32>\r\n %4 = \"tf.Reshape\"(%3, %cst) : (tensor<1xi32>, tensor<0xi32>) -> tensor<i32>\r\n %5 = \"tf.AddV2\"(%arg2, %cst_3) {device = \"\"} : (tensor<i32>, tensor<i32>) -> tensor<i32>\r\n %6 = \"tf.FloorMod\"(%4, %cst_0) {device = \"\"} : (tensor<i32>, tensor<i32>) -> tensor<i32>\r\n %7:2 = \"tf.ConcatOffset\"(%6, %cst_1, %cst_1) {device = \"\"} : (tensor<i32>, tensor<3xi32>, tensor<3xi32>) -> (tensor<3xi32>, tensor<3xi32>)\r\n %8 = \"tf.Slice\"(%arg3, %7#1, %cst_1) {device = \"\"} : (tensor<5x2x1xf32>, tensor<3xi32>, tensor<3xi32>) -> tensor<5x1x1xf32>\r\n %9 = \"tf.AddN\"(%arg4, %8) {_class = [\"loc:@gradient_tape/while/gradients/grad_ys_1\"], device = \"\"} : (tensor<5x1x1xf32>, tensor<5x1x1xf32>) -> tensor<5x1x1xf32>\r\n \"tf.Yield\"(%5, %cst_2, %9, %2) : (tensor<i32>, tensor<5x2x1xf32>, tensor<5x1x1xf32>, tensor<1xi32>) -> ()\r\n }) {_num_original_outputs = 6 : i64, _read_only_resource_inputs = [], _xla_propagate_compile_time_consts = true, device = \"\"} : (tensor<i32>, tensor<5x2x1xf32>, tensor<5x1x1xf32>, tensor<1xi32>) -> (tensor<i32>, tensor<5x2x1xf32>, tensor<5x1x1xf32>, tensor<1xi32>)\r\n return %1#2 : tensor<5x1x1xf32>\r\n }\r\n}\r\n```\r\n\r\nI'm not sure why `tf.ConcatOffset` is being created here upstream, but the op definition says the input for the dimension should be constant. Here it's the output of `tf.FLoorMod` and not const and hence the error. \r\n\r\n",
"Unfortunately I'm not very familiar with the behavior here. The documentation for ConcatOffset seems to mention that it is used for gradient computations: https://www.tensorflow.org/mlir/tf_ops#tfconcatoffset_tfconcatoffsetop \r\n\r\nTagging @ishark and @wangpengmit to see if they know more about the gradient computation / concat op. "
] | 2024-01-29T09:22:38 | 2024-02-08T19:15:53 | null |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
No
### Source
binary
### TensorFlow version
2.15.0.post1, 2.15.0
### Custom code
Yes
### OS platform and distribution
WSL Ubuntu 22.04
### Mobile device
_No response_
### Python version
3.10.12
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
12.2
### GPU model and memory
RTX 3080 Ti
### Current behavior?
### Current behavior
Even tho the shapes of the elements which are concatenated are well defined to compile time, when running the code provided, the execution fails with the error log provided. This is also the case, if you enforce the shapes with using tf.reshape().
If you remove either
- the GradientTape context
- or the for loop with tf.range
- or the XLA compilation
the code will work as expected.
Unrolling the for loop with range() is not desired since the number of iterations will be >50000 in the final project. Also converting the for loop in a tf.while loop with maximum_iterations specified will result in the same error. Specifying the batchsize to a constant value (also in the input_signature) won't resolve the issue either. Also changing the tf.device between GPU / CPU won't resolve the issue.
The same error arises if you try to use tf.transpose()
### Expected behavior
The arrays with well defined shapes at compile time will be concatenated / transposed when using a for loop with tf.range in the context of a GradientTape while using XLA (jit_compile=True)
### Standalone code to reproduce the issue
```shell
class Model():
def __init__(self, batchsize):
self.batchsize = batchsize
self.g = tf.Variable(initial_value=tf.ones([self.batchsize,1,1]), trainable=True, name="g")
self.m = tf.Variable(initial_value=tf.ones([self.batchsize,1,1]), trainable=True, name="m")
self.d = tf.Variable(initial_value=tf.ones([self.batchsize,1,1]), trainable=True, name="d")
self.k = tf.Variable(initial_value=tf.ones([self.batchsize,1,1]), trainable=True, name="k")
self.y0 = tf.ones([self.batchsize, 2, 1])
@tf.function(input_signature=[tf.TensorSpec(shape=(None, 2, 1), dtype=tf.float32)],
jit_compile=False)
def compute(self, yi):
A1 = tf.concat([tf.zeros_like(self.m), tf.ones_like(self.m)], 2)
A2 = tf.concat([-self.k/self.m, -self.d/self.m], 2)
A = tf.concat([A1, A2], 1)
#A = tf.transpose(A, perm=[0, 2, 1])
B = tf.concat([tf.zeros_like(self.g), self.g], 1)
dy = tf.linalg.matmul(A, yi) + B
return dy
class Estimator():
def __init__(self, model):
self.model = model
self.dt = tf.constant(0.001)
@tf.function(jit_compile=True, reduce_retracing=False)
def estimate(self):
with tf.GradientTape() as tape:
yi = self.model.y0
for i in tf.range(10):
dyi = self.model.compute(yi)
yi = yi + dyi*self.dt
grads = tape.gradient(yi, [self.model.g, self.model.m, self.model.d, self.model.k])
return grads
device = "CPU:0"
#device = "GPU:0"
with tf.device(device):
batchsize = 5
model = Model(batchsize)
estimator = Estimator(model)
grads = estimator.estimate()
```
### Relevant log output
```shell
OP_REQUIRES failed at concat_op.cc:168 : INVALID_ARGUMENT: Input 0 to node `gradient_tape/while/gradients/while/StatefulPartitionedCall_grad/PartitionedCall/gradients/concat_3_grad/ConcatOffset` with op ConcatOffset must be a compile-time constant.
XLA compilation requires that operator arguments that represent shapes or dimensions be evaluated to concrete values at compile time. This error means that a shape or dimension argument could not be evaluated at compile time, usually because the value of the argument depends on a parameter to the computation, on a variable, or on a stateful operation such as a random number generator.
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62861/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62861/timeline
| null |
reopened
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62860
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62860/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62860/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62860/events
|
https://github.com/tensorflow/tensorflow/issues/62860
| 2,104,552,438 |
I_kwDOArmXAs59cOv2
| 62,860 |
tensorflow 2.15 "Illegal instruction: 4" Mac M1 processor
|
{
"login": "skwyddie",
"id": 1452376,
"node_id": "MDQ6VXNlcjE0NTIzNzY=",
"avatar_url": "https://avatars.githubusercontent.com/u/1452376?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/skwyddie",
"html_url": "https://github.com/skwyddie",
"followers_url": "https://api.github.com/users/skwyddie/followers",
"following_url": "https://api.github.com/users/skwyddie/following{/other_user}",
"gists_url": "https://api.github.com/users/skwyddie/gists{/gist_id}",
"starred_url": "https://api.github.com/users/skwyddie/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/skwyddie/subscriptions",
"organizations_url": "https://api.github.com/users/skwyddie/orgs",
"repos_url": "https://api.github.com/users/skwyddie/repos",
"events_url": "https://api.github.com/users/skwyddie/events{/privacy}",
"received_events_url": "https://api.github.com/users/skwyddie/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473173351,
"node_id": "MDU6TGFiZWw0NzMxNzMzNTE=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:build/install",
"name": "type:build/install",
"color": "159b2e",
"default": false,
"description": "Build and install issues"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
},
{
"id": 1205765054,
"node_id": "MDU6TGFiZWwxMjA1NzY1MDU0",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/subtype:macOS",
"name": "subtype:macOS",
"color": "b619ea",
"default": false,
"description": "macOS Build/Installation issues"
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
closed
| false |
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"@skwyddie ensorFlow 2.15 is not natively compatible with M1 so you need to switch to a version built for Apple Silicon. TensorFlow 2.10.0-rc0 is the latest release with official M1 support and TensorFlow 2.9.1 is a more stable option, also offering M1 compatibility. Please refer to the TensorFlow M1 installation guide for detailed instructions: https://developer.apple.com/metal/tensorflow-plugin/\r\n\r\nThank you!",
"Same problem happens with TensorFlow 2.10.0-rc0 and 2.9.1 on Mac M1 Pro",
"I can't find any version of tf that works on M1. I've tried everything down to 2.9.1.",
"@skwyddie You're right, there isn't an official TensorFlow version compiled specifically for Apple M1 yet. However, there are workarounds and alternative options you can explore. Here's the guide to install TensorFlow Metal: https://github.com/apple/tensorflow_macos\r\nHowever, note that it's still under development and might have limitations or compatibility issues.\r\nThank you!",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62860\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62860\">No</a>\n",
"This issue should be reopened, I am still facing the same issue, even with 2.16"
] | 2024-01-29T03:13:57 | 2024-05-30T12:34:55 | 2024-02-23T01:46:46 |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
source
### TensorFlow version
2.15.0
### Custom code
No
### OS platform and distribution
Darwin MacBook-Pro-2.localdomain 23.3.0 Darwin Kernel Version 23.3.0; root:xnu-10002.81.5~7/RELEASE_ARM64_T6000 arm64 (Sonoma 14.3 Apple M1 Max)
### Mobile device
_No response_
### Python version
3.11.7
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
$ python3
Python 3.11.7 (main, Dec 4 2023, 18:10:11) [Clang 15.0.0 (clang-1500.1.0.2.5)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import tensorflow
Illegal instruction: 4
$
I expected to be able to import the module after it is installed. I suspect the newer processor is an issue.
### Standalone code to reproduce the issue
```shell
$ python3
Python 3.11.7 (main, Dec 4 2023, 18:10:11) [Clang 15.0.0 (clang-1500.1.0.2.5)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import tensorflow
Illegal instruction: 4
$
```
### Relevant log output
_No response_
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62860/reactions",
"total_count": 4,
"+1": 4,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62860/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62859
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62859/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62859/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62859/events
|
https://github.com/tensorflow/tensorflow/issues/62859
| 2,104,394,053 |
I_kwDOArmXAs59boFF
| 62,859 |
Tensorflow distributes training throws exception on mac m2
|
{
"login": "SVyatoslavG",
"id": 21696037,
"node_id": "MDQ6VXNlcjIxNjk2MDM3",
"avatar_url": "https://avatars.githubusercontent.com/u/21696037?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/SVyatoslavG",
"html_url": "https://github.com/SVyatoslavG",
"followers_url": "https://api.github.com/users/SVyatoslavG/followers",
"following_url": "https://api.github.com/users/SVyatoslavG/following{/other_user}",
"gists_url": "https://api.github.com/users/SVyatoslavG/gists{/gist_id}",
"starred_url": "https://api.github.com/users/SVyatoslavG/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/SVyatoslavG/subscriptions",
"organizations_url": "https://api.github.com/users/SVyatoslavG/orgs",
"repos_url": "https://api.github.com/users/SVyatoslavG/repos",
"events_url": "https://api.github.com/users/SVyatoslavG/events{/privacy}",
"received_events_url": "https://api.github.com/users/SVyatoslavG/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 404586594,
"node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower",
"name": "stat:awaiting tensorflower",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from tensorflower"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 996845227,
"node_id": "MDU6TGFiZWw5OTY4NDUyMjc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:dist-strat",
"name": "comp:dist-strat",
"color": "0052cc",
"default": false,
"description": "Distribution Strategy related issues"
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
open
| false |
{
"login": "sachinprasadhs",
"id": 73069040,
"node_id": "MDQ6VXNlcjczMDY5MDQw",
"avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sachinprasadhs",
"html_url": "https://github.com/sachinprasadhs",
"followers_url": "https://api.github.com/users/sachinprasadhs/followers",
"following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}",
"gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions",
"organizations_url": "https://api.github.com/users/sachinprasadhs/orgs",
"repos_url": "https://api.github.com/users/sachinprasadhs/repos",
"events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}",
"received_events_url": "https://api.github.com/users/sachinprasadhs/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "sachinprasadhs",
"id": 73069040,
"node_id": "MDQ6VXNlcjczMDY5MDQw",
"avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sachinprasadhs",
"html_url": "https://github.com/sachinprasadhs",
"followers_url": "https://api.github.com/users/sachinprasadhs/followers",
"following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}",
"gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions",
"organizations_url": "https://api.github.com/users/sachinprasadhs/orgs",
"repos_url": "https://api.github.com/users/sachinprasadhs/repos",
"events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}",
"received_events_url": "https://api.github.com/users/sachinprasadhs/received_events",
"type": "User",
"site_admin": false
}
] | null |
[] | 2024-01-28T23:20:51 | 2024-01-29T17:50:16 | null |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
source
### TensorFlow version
2.15
### Custom code
Yes
### OS platform and distribution
Mac OS 14.2.1
### Mobile device
_No response_
### Python version
3.11.6
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
I am trying to run distributed training using `tf.distribute.experimental.MultiWorkerMirroredStrategy()` on two Mac M2 machines. However, training does not start on the GPU, and the code throws the attached exception.
The distributed training works fine if I use CPU only.
I have installed the latest `tensorflow-metal 1.1.0`.
Is `MultiWorkerMirroredStrategy` supported on Mac M2?
### Standalone code to reproduce the issue
```shell
from pandas import read_csv
from sklearn.model_selection import train_test_split
from sklearn.preprocessing import LabelEncoder
from tensorflow.keras import Sequential
import tensorflow as tf
from tensorflow.keras.layers import Dense
import datetime
import os
import keras
import json
import glob
print("Tensforflow version: ", tf.__version__)
print("Availabe devices: ", devices)
if len(devices) == 0:
print("No devices for mac found")
exit(1)
directory = os.environ['TF_FOLDER']
checkpoint_dir = os.path.join(directory, "ckpt")
if not os.path.exists(checkpoint_dir):
os.makedirs(checkpoint_dir)
path = 'https://raw.githubusercontent.com/jbrownlee/Datasets/master/ionosphere.csv'
df = read_csv(path, header=None)
X, y = df.values[:, :-1], df.values[:, -1]
X = X.astype('float32')
y = LabelEncoder().fit_transform(y)
X_train, X_test, y_train, y_test = train_test_split(X, y, test_size=0.33)
print(X_train.shape, X_test.shape, y_train.shape, y_test.shape)
n_features = X_train.shape[1]
def get_compiled_model():
model = tf.keras.Sequential([
tf.keras.layers.Flatten(input_shape=(n_features,)),
tf.keras.layers.Dense(128, activation='relu'),
tf.keras.layers.Dense(10)
])
model.summary()
model.compile(optimizer=tf.keras.optimizers.legacy.Adam(learning_rate=0.0001), loss='binary_crossentropy', metrics=['accuracy'])
return model
strategy = tf.distribute.experimental.MultiWorkerMirroredStrategy()
print("Number of devices: {}".format(strategy.num_replicas_in_sync))
with strategy.scope():
model = get_compiled_model()
log_dir = os.path.join(directory, "logs/fit/") + datetime.datetime.now().strftime("%Y%m%d-%H%M%S")
tensorboard_callback = tf.keras.callbacks.TensorBoard(log_dir=log_dir, histogram_freq=1)
class CustomModelCheckpoint(keras.callbacks.ModelCheckpoint):
def __init__(self, filepath, max_to_keep=100, **kwargs):
super().__init__(filepath, **kwargs)
self.filepath = filepath
self.max_to_keep = max_to_keep
def on_epoch_end(self, epoch, logs=None):
super().on_epoch_end(epoch, logs)
files = sorted(glob.glob(self.filepath.format(epoch='*')))
if len(files) > self.max_to_keep:
for f in files[:-self.max_to_keep]:
os.remove(f)
callbacks = [
CustomModelCheckpoint(
filepath=checkpoint_dir + "/ckpt-{epoch}", save_freq="epoch", max_to_keep=10, save_weights_only=True
),
keras.callbacks.TensorBoard('tensorboard_logs')
]
latest = tf.train.latest_checkpoint(checkpoint_dir)
if latest:
print("Loading model checkpoint {} ...\n".format(latest))
model.load_weights(latest)
model.fit(X_train, y_train, epochs=100, batch_size=32, verbose=1,callbacks=callbacks)
loss, acc = model.evaluate(X_test, y_test, verbose=0)
print(f'Test Accuracy: {acc:.3f}')
```
### Relevant log output
```shell
2024-01-28 14:46:40.395499: I tensorflow/core/grappler/optimizers/custom_graph_optimizer_registry.cc:117] Plugin optimizer for device_type GPU is enabled.
Epoch 1/100
2024-01-28 14:46:40.778281: W tensorflow/core/framework/op_kernel.cc:1803] INTERNAL: Failed to build OpKernel for Add : No registered 'Add' OpKernel for 'GPU' devices compatible with node {{node Add}}
(OpKernel was found, but attributes didn't match) Requested Attributes: T=DT_INT64, _device="/job:worker/replica:0/task:0/device:GPU:0"
. Registered: device='XLA_CPU_JIT'; T in [DT_FLOAT, DT_DOUBLE, DT_INT32, DT_UINT8, DT_INT16, DT_INT8, DT_COMPLEX64, DT_INT64, DT_BFLOAT16, DT_COMPLEX128, DT_HALF]
device='GPU'; T in [DT_FLOAT]
device='GPU'; T in [DT_HALF]
device='GPU'; T in [DT_BFLOAT16]
device='DEFAULT'; T in [DT_INT32]
device='CPU'; T in [DT_FLOAT]
device='CPU'; T in [DT_HALF]
device='CPU'; T in [DT_DOUBLE]
device='CPU'; T in [DT_INT32]
device='CPU'; T in [DT_INT64]
device='CPU'; T in [DT_BFLOAT16]
device='CPU'; T in [DT_INT8]
device='CPU'; T in [DT_INT16]
device='CPU'; T in [DT_COMPLEX64]
device='CPU'; T in [DT_UINT8]
device='CPU'; T in [DT_COMPLEX128]
device='CPU'; T in [DT_STRING]
Traceback (most recent call last):
File "/Users/inet11/git/tensorflow/model.py", line 129, in <module>
model.fit(X_train, y_train, epochs=100, batch_size=32, verbose=1,callbacks=callbacks)
File "/Users/inet11/git/tensorflow/email/tf/lib/python3.11/site-packages/keras/src/utils/traceback_utils.py", line 70, in error_handler
raise e.with_traceback(filtered_tb) from None
File "/Users/inet11/git/tensorflow/email/tf/lib/python3.11/site-packages/tensorflow/python/eager/execute.py", line 53, in quick_execute
tensors = pywrap_tfe.TFE_Py_Execute(ctx._handle, device_name, op_name,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
tensorflow.python.framework.errors_impl.InternalError: Graph execution error:
Detected at node Add defined at (most recent call last):
<stack traces unavailable>
2 root error(s) found.
(0) INTERNAL: Failed to build OpKernel for Add : No registered 'Add' OpKernel for 'GPU' devices compatible with node {{node Add}}
(OpKernel was found, but attributes didn't match) Requested Attributes: T=DT_INT64, _device="/job:worker/replica:0/task:0/device:GPU:0"
. Registered: device='XLA_CPU_JIT'; T in [DT_FLOAT, DT_DOUBLE, DT_INT32, DT_UINT8, DT_INT16, DT_INT8, DT_COMPLEX64, DT_INT64, DT_BFLOAT16, DT_COMPLEX128, DT_HALF]
device='GPU'; T in [DT_FLOAT]
device='GPU'; T in [DT_HALF]
device='GPU'; T in [DT_BFLOAT16]
device='DEFAULT'; T in [DT_INT32]
device='CPU'; T in [DT_FLOAT]
device='CPU'; T in [DT_HALF]
device='CPU'; T in [DT_DOUBLE]
device='CPU'; T in [DT_INT32]
device='CPU'; T in [DT_INT64]
device='CPU'; T in [DT_BFLOAT16]
device='CPU'; T in [DT_INT8]
device='CPU'; T in [DT_INT16]
device='CPU'; T in [DT_COMPLEX64]
device='CPU'; T in [DT_UINT8]
device='CPU'; T in [DT_COMPLEX128]
device='CPU'; T in [DT_STRING]
[[CollectiveReduceV2]]
(1) CANCELLED: Function was cancelled before it was started
0 successful operations.
0 derived errors ignored. [Op:__inference_train_function_1260]
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62859/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62859/timeline
| null | null | false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62858
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62858/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62858/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62858/events
|
https://github.com/tensorflow/tensorflow/pull/62858
| 2,104,345,598 |
PR_kwDOArmXAs5lQ83y
| 62,858 |
[DONOTMERGE]test1
|
{
"login": "haozheng-cobalt",
"id": 131711973,
"node_id": "U_kgDOB9nD5Q",
"avatar_url": "https://avatars.githubusercontent.com/u/131711973?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/haozheng-cobalt",
"html_url": "https://github.com/haozheng-cobalt",
"followers_url": "https://api.github.com/users/haozheng-cobalt/followers",
"following_url": "https://api.github.com/users/haozheng-cobalt/following{/other_user}",
"gists_url": "https://api.github.com/users/haozheng-cobalt/gists{/gist_id}",
"starred_url": "https://api.github.com/users/haozheng-cobalt/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/haozheng-cobalt/subscriptions",
"organizations_url": "https://api.github.com/users/haozheng-cobalt/orgs",
"repos_url": "https://api.github.com/users/haozheng-cobalt/repos",
"events_url": "https://api.github.com/users/haozheng-cobalt/events{/privacy}",
"received_events_url": "https://api.github.com/users/haozheng-cobalt/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 1169364259,
"node_id": "MDU6TGFiZWwxMTY5MzY0MjU5",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS",
"name": "size:XS",
"color": "adafea",
"default": false,
"description": "CL Change Size: Extra Small"
}
] |
closed
| false |
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[] | 2024-01-28T20:59:21 | 2024-01-28T23:26:59 | 2024-01-28T23:26:59 |
NONE
| null | false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62858",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62858",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62858.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62858.patch",
"merged_at": null
}
| null |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62858/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62858/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62857
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62857/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62857/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62857/events
|
https://github.com/tensorflow/tensorflow/pull/62857
| 2,104,201,003 |
PR_kwDOArmXAs5lQf9G
| 62,857 |
sh-runner-poc.yml
|
{
"login": "Shoubi007",
"id": 77432795,
"node_id": "MDQ6VXNlcjc3NDMyNzk1",
"avatar_url": "https://avatars.githubusercontent.com/u/77432795?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/Shoubi007",
"html_url": "https://github.com/Shoubi007",
"followers_url": "https://api.github.com/users/Shoubi007/followers",
"following_url": "https://api.github.com/users/Shoubi007/following{/other_user}",
"gists_url": "https://api.github.com/users/Shoubi007/gists{/gist_id}",
"starred_url": "https://api.github.com/users/Shoubi007/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Shoubi007/subscriptions",
"organizations_url": "https://api.github.com/users/Shoubi007/orgs",
"repos_url": "https://api.github.com/users/Shoubi007/repos",
"events_url": "https://api.github.com/users/Shoubi007/events{/privacy}",
"received_events_url": "https://api.github.com/users/Shoubi007/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 1169364458,
"node_id": "MDU6TGFiZWwxMTY5MzY0NDU4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:S",
"name": "size:S",
"color": "adafea",
"default": false,
"description": "CL Change Size: Small"
}
] |
closed
| false |
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).\n\nView this [failed invocation](https://github.com/tensorflow/tensorflow/pull/62857/checks?check_run_id=20945491518) of the CLA check for more information.\n\nFor the most up to date status, view the checks section at the bottom of the pull request.",
"Hi @Shoubi007 Can you please sign CLA and describe about the proposed changes in description? Thank you!"
] | 2024-01-28T14:54:34 | 2024-02-21T09:16:43 | 2024-02-21T09:16:38 |
NONE
| null | false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62857",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62857",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62857.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62857.patch",
"merged_at": null
}
| null |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62857/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62857/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62856
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62856/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62856/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62856/events
|
https://github.com/tensorflow/tensorflow/issues/62856
| 2,104,176,485 |
I_kwDOArmXAs59ay9l
| 62,856 |
No File Named ci_sanity.sh
|
{
"login": "mahrukhS",
"id": 66876079,
"node_id": "MDQ6VXNlcjY2ODc2MDc5",
"avatar_url": "https://avatars.githubusercontent.com/u/66876079?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/mahrukhS",
"html_url": "https://github.com/mahrukhS",
"followers_url": "https://api.github.com/users/mahrukhS/followers",
"following_url": "https://api.github.com/users/mahrukhS/following{/other_user}",
"gists_url": "https://api.github.com/users/mahrukhS/gists{/gist_id}",
"starred_url": "https://api.github.com/users/mahrukhS/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/mahrukhS/subscriptions",
"organizations_url": "https://api.github.com/users/mahrukhS/orgs",
"repos_url": "https://api.github.com/users/mahrukhS/repos",
"events_url": "https://api.github.com/users/mahrukhS/events{/privacy}",
"received_events_url": "https://api.github.com/users/mahrukhS/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 473173351,
"node_id": "MDU6TGFiZWw0NzMxNzMzNTE=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:build/install",
"name": "type:build/install",
"color": "159b2e",
"default": false,
"description": "Build and install issues"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
closed
| false |
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"@mahrukhS,\r\nTensorFlow's CI Sanity scripts have been replaced with the \"Code Check\" bats files inside of the SIG Build docker images. Could you please have a look at the bottom of\r\n[https://github.com/tensorflow/build/blob/master/tf_sig_build_dockerfiles/](https://www.google.com/url?sa=D&q=https%3A%2F%2Fgithub.com%2Ftensorflow%2Fbuild%2Fblob%2Fmaster%2Ftf_sig_build_dockerfiles%2F) \r\n\r\n\r\n\r\nThank you!",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62856\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62856\">No</a>\n"
] | 2024-01-28T13:57:07 | 2024-02-13T01:47:03 | 2024-02-13T01:47:00 |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
No
### Source
binary
### TensorFlow version
2.15.0
### Custom code
No
### OS platform and distribution
Windows 11 Pro (Host), Docker container based on ubuntu:16.04
### Mobile device
_No response_
### Python version
3.11.6
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
I am struggling to perform sanity check as mentioned in #62841. However, I have noticed another issue in [CONTRIBUTING.md](https://github.com/tensorflow/tensorflow/blob/master/CONTRIBUTING.md).
The issue is with the [SanityCheck](https://github.com/tensorflow/tensorflow/blob/master/CONTRIBUTING.md#running-sanity-check) section's command which is as follows:
`tensorflow/tools/ci_build/ci_build.sh CPU tensorflow/tools/ci_build/ci_sanity.sh`
There is no file named `ci_sanity.sh` within **ci_build** directory. Also I cannot find this file in any other directory. I need help with correct command and correct file name for the second part of the above sanity check command
### Standalone code to reproduce the issue
```shell
Running the following sanity check command from tensorflow root will result in error:
tensorflow/tools/ci_build/ci_build.sh CPU tensorflow/tools/ci_build/ci_sanity.sh
```
### Relevant log output
```shell
$ tensorflow/tools/ci_build/ci_build.sh CPU tensorflow/tools/ci_build/install/tensorflow/tools/ci_build/install/build_and_install_python.sh
WORKSPACE: /c/Users/Username/tensorflow
CI_DOCKER_BUILD_EXTRA_PARAMS:
CI_DOCKER_EXTRA_PARAMS:
COMMAND: tensorflow/tools/ci_build/install/tensorflow/tools/ci_build/install/build_and_install_python.sh
CI_COMMAND_PREFIX: ./tensorflow/tools/ci_build/builds/with_the_same_user ./tensorflow/tools/ci_build/builds/configured cpu
CONTAINER_TYPE: cpu
BUILD_TAG: tf_ci
(docker container name will be tf_ci.cpu)
Building container (tf_ci.cpu)...
[+] Building 7.3s (17/17) FINISHED docker:default
=> [internal] load build definition from Dockerfile.cpu 0.1s
=> => transferring dockerfile: 705B 0.0s
=> [internal] load .dockerignore 0.1s
=> => transferring context: 2B 0.0s
=> [internal] load metadata for docker.io/library/ubuntu:16.04 6.9s
=> [ 1/12] FROM docker.io/library/ubuntu:16.04@sha256:1f1a2d56de1d604801a9671f301190704c25d604a416f 0.0s
=> [internal] load build context 0.1s
=> => transferring context: 5.00kB 0.0s
=> CACHED [ 2/12] COPY install/*.sh /install/ 0.0s
=> CACHED [ 3/12] RUN /install/install_bootstrap_deb_packages.sh 0.0s
=> CACHED [ 4/12] RUN add-apt-repository -y ppa:openjdk-r/ppa && add-apt-repository -y ppa:geor 0.0s
=> CACHED [ 5/12] RUN /install/install_deb_packages.sh 0.0s
=> CACHED [ 6/12] RUN /install/install_bazel.sh 0.0s
=> CACHED [ 7/12] RUN /install/install_pip_packages.sh 0.0s
=> CACHED [ 8/12] RUN /install/install_proto3.sh 0.0s
=> CACHED [ 9/12] RUN /install/install_buildifier.sh 0.0s
=> CACHED [10/12] RUN /install/install_auditwheel.sh 0.0s
=> CACHED [11/12] RUN /install/install_golang.sh 0.0s
=> CACHED [12/12] COPY install/.bazelrc /etc/bazel.bazelrc 0.0s
=> exporting to image 0.0s
=> => exporting layers 0.0s
=> => writing image sha256:bdba01e977e82446718c8f606444de0098c89149578a6180591f53d225820d86 0.0s
=> => naming to docker.io/library/tf_ci.cpu 0.0s
View build details: docker-desktop://dashboard/build/default/default/j7ijehblr2xubkq1x5utbjpki
What's Next?
View a summary of image vulnerabilities and recommendations → docker scout quickview
Running 'tensorflow/tools/ci_build/install/tensorflow/tools/ci_build/install/build_and_install_python.sh' inside tf_ci.cpu...
id: cannot find name for group ID 197121
docker: Error response from daemon: the working directory 'C:/Program Files/Git/workspace' is invalid, it needs to be an absolute path.
See 'docker run --help'.
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62856/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62856/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62855
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62855/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62855/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62855/events
|
https://github.com/tensorflow/tensorflow/issues/62855
| 2,104,117,169 |
I_kwDOArmXAs59akex
| 62,855 |
Having non-converted operations, even for simplest models
|
{
"login": "Black3rror",
"id": 33788464,
"node_id": "MDQ6VXNlcjMzNzg4NDY0",
"avatar_url": "https://avatars.githubusercontent.com/u/33788464?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/Black3rror",
"html_url": "https://github.com/Black3rror",
"followers_url": "https://api.github.com/users/Black3rror/followers",
"following_url": "https://api.github.com/users/Black3rror/following{/other_user}",
"gists_url": "https://api.github.com/users/Black3rror/gists{/gist_id}",
"starred_url": "https://api.github.com/users/Black3rror/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Black3rror/subscriptions",
"organizations_url": "https://api.github.com/users/Black3rror/orgs",
"repos_url": "https://api.github.com/users/Black3rror/repos",
"events_url": "https://api.github.com/users/Black3rror/events{/privacy}",
"received_events_url": "https://api.github.com/users/Black3rror/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 750616506,
"node_id": "MDU6TGFiZWw3NTA2MTY1MDY=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite",
"name": "comp:lite",
"color": "0052cc",
"default": false,
"description": "TF Lite related issues"
},
{
"id": 1661751498,
"node_id": "MDU6TGFiZWwxNjYxNzUxNDk4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TFLiteConverter",
"name": "TFLiteConverter",
"color": "bfdadc",
"default": false,
"description": "For issues related to TFLite converter"
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
open
| false |
{
"login": "zichuan-wei",
"id": 10928342,
"node_id": "MDQ6VXNlcjEwOTI4MzQy",
"avatar_url": "https://avatars.githubusercontent.com/u/10928342?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/zichuan-wei",
"html_url": "https://github.com/zichuan-wei",
"followers_url": "https://api.github.com/users/zichuan-wei/followers",
"following_url": "https://api.github.com/users/zichuan-wei/following{/other_user}",
"gists_url": "https://api.github.com/users/zichuan-wei/gists{/gist_id}",
"starred_url": "https://api.github.com/users/zichuan-wei/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/zichuan-wei/subscriptions",
"organizations_url": "https://api.github.com/users/zichuan-wei/orgs",
"repos_url": "https://api.github.com/users/zichuan-wei/repos",
"events_url": "https://api.github.com/users/zichuan-wei/events{/privacy}",
"received_events_url": "https://api.github.com/users/zichuan-wei/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "zichuan-wei",
"id": 10928342,
"node_id": "MDQ6VXNlcjEwOTI4MzQy",
"avatar_url": "https://avatars.githubusercontent.com/u/10928342?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/zichuan-wei",
"html_url": "https://github.com/zichuan-wei",
"followers_url": "https://api.github.com/users/zichuan-wei/followers",
"following_url": "https://api.github.com/users/zichuan-wei/following{/other_user}",
"gists_url": "https://api.github.com/users/zichuan-wei/gists{/gist_id}",
"starred_url": "https://api.github.com/users/zichuan-wei/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/zichuan-wei/subscriptions",
"organizations_url": "https://api.github.com/users/zichuan-wei/orgs",
"repos_url": "https://api.github.com/users/zichuan-wei/repos",
"events_url": "https://api.github.com/users/zichuan-wei/events{/privacy}",
"received_events_url": "https://api.github.com/users/zichuan-wei/received_events",
"type": "User",
"site_admin": false
},
{
"login": "pkgoogle",
"id": 132095473,
"node_id": "U_kgDOB9-d8Q",
"avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/pkgoogle",
"html_url": "https://github.com/pkgoogle",
"followers_url": "https://api.github.com/users/pkgoogle/followers",
"following_url": "https://api.github.com/users/pkgoogle/following{/other_user}",
"gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}",
"starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions",
"organizations_url": "https://api.github.com/users/pkgoogle/orgs",
"repos_url": "https://api.github.com/users/pkgoogle/repos",
"events_url": "https://api.github.com/users/pkgoogle/events{/privacy}",
"received_events_url": "https://api.github.com/users/pkgoogle/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"perhaps \"TF-TRT Warning: Could not find TensorRT\" ?",
"I have just got the same issue for TensorFlow 2.15.0 on my M3 Pro MacBook. It seems that TF Lite somehow failed to support 20 `arith.constant` operations in my model.",
"Hi @Black3rror,\r\n\r\nGood observation. Exactly, when running ```!python test.py``` , on colab, the Non-converted ops are being shown but the model is converted to tflite successfully and runs fine. So, could you please try on TFLM and let us know if you encounter any blockers. Regarding performance point of view, I tested with another sample code, the accuracy was maintained the same even after converting to TFLite. Please refer to the following sample code: ```sample_train.py```.\r\n```\r\nimport tensorflow as tf\r\nfrom tensorflow import keras\r\nimport numpy as np\r\nimport pathlib\r\n\r\n# Load MNIST dataset\r\nmnist = keras.datasets.mnist\r\n(train_images, train_labels), (test_images, test_labels) = mnist.load_data()\r\n\r\n# Normalize the input image so that each pixel value is between 0 to 1.\r\ntrain_images = train_images / 255.0\r\ntest_images = test_images / 255.0\r\n\r\n# Define the model architecture\r\nmodel = keras.Sequential([\r\n keras.layers.InputLayer(input_shape=(28, 28)),\r\n keras.layers.Reshape(target_shape=(28, 28, 1)),\r\n keras.layers.Conv2D(filters=12, kernel_size=(3, 3), activation=tf.nn.relu),\r\n keras.layers.MaxPooling2D(pool_size=(2, 2)),\r\n keras.layers.Flatten(),\r\n keras.layers.Dense(10)\r\n])\r\n\r\n# Train the digit classification model\r\nmodel.compile(optimizer='adam',\r\n loss=keras.losses.SparseCategoricalCrossentropy(from_logits=True),\r\n metrics=['accuracy'])\r\nmodel.fit(\r\n train_images,\r\n train_labels,\r\n epochs=1,\r\n validation_data=(test_images, test_labels)\r\n)\r\nmodel.save('tf_model')\r\ntf_accuracy = model.evaluate(test_images, test_labels, verbose=0)\r\n#results.append(['TF', '', '{:.2f}%'.format(tf_accuracy * 100)]\r\nprint(tf_accuracy)\r\n\r\nconverter = tf.lite.TFLiteConverter.from_keras_model(model)\r\ntflite_model = converter.convert()\r\n# Save the model.\r\nwith open('model.tflite', 'wb') as f:\r\n f.write(tflite_model)\r\n\r\nconverter.optimizations = [tf.lite.Optimize.DEFAULT]\r\ntflite_quant_model = converter.convert()\r\nwith open('model_quant.tflite', 'wb') as f:\r\n f.write(tflite_model) \r\n``` \r\n \r\nthen run the [code](https://colab.research.google.com/gist/LakshmiKalaKadali/94fcd0557e7cb8d2a78408b12831029c/sample_inference.ipynb) for accuracy checking. \r\n\r\nThank You\r\n\r\n",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"@zhuochenKIDD Are you suggesting that I fix the TensorRT warning and the problem with *Non-Converted Ops* will get resolved automatically?\r\n\r\n@LakshmiKalaKadali Hi, and thanks for the response.\r\nI've converted the models to TFLM and executed them on a microcontroller. It was successful in giving output. So, if it gets converted successfully and runs on microcontrollers without any problem, should we just ignore the non-converted ops message? (Hope to see this message removed in the next fix, if it's supposed to be ignored)",
"Hi @Black3rror, you can still run non-converted ops successfully and because they have higher precision the performance in terms of accuracy is actually usually better, however you lose the benefits of efficiency and latency performance. Not all ops are convertable but I can't imagine that arith.constant is one of them.\r\n\r\n@zichuan-wei, can you please take a look? Thanks.",
"@pkgoogle\r\nThanks for the response. I'm a bit confused: What was supposed to happen in the course of the conversion? The conversion is basic, i.e., no quantization and just having tflite from tf model. So, since you said \"they have higher precision\", should I expect any loss of precision in this process?!\r\n\r\nAlso, it might worth mentioning that I've tested different networks with different quantization techniques (including full_int, full_int_only (input and outputs are in int as well), 16x8, ...), and they all worked. I mean, I'm still getting similar non-converted messages to those I asked in the first place, but looking at `interpreter.get_tensor_details()[...][dtype]`, it seems everything is getting converted successfully (unless I'm wrong :)) and putting these models on a microcontroller using TFLM goes well.\r\n\r\nCan you please clarify your answer?\r\n\r\nYes, I also believe something is wrong since I'm not able to convert a minimum network without getting such a message, and as you said, at least `arith.constant` shouldn't be the problem.",
"Hi @Black3rror, if that is the configuration of your conversion then, you are correct, you should not expect any loss of precision, however with any quantization techniques included -- then of course there is a potential loss. Non-converted ops are by definition not going to go through any quantization, so they will maintain precision and still \"work\" in the sense that you can still run inference through the model. Hope that clarifies my answer?",
"@pkgoogle Yes, now things make more sense to me. Still, it leaves me wondering why I'm getting the \"non-converted operations\" message even in this situation where I'm not using any quantization (based on your reply, this message should be related to quantization conversion).\r\nStill, this question is subsidiary, and the main question remains: If the message is valid and some operations are actually not getting converted, why is TFLite not able to convert them in such a simple model?\r\nLooking forward to its answer.",
"I have the same issue of having non converted operations, and my model is quite simple as well. It is just a multi perceptron model with fully connected layers, relu activation and softmax activation functions. I wonder how I can suppress the log message of 'having non-converted operations ......' in the converter.convert() method.\r\n\r\n```\r\nSummary on the non-converted ops:\r\n---------------------------------\r\n * Accepted dialects: tfl, builtin, func\r\n * Non-Converted Ops: 10, Total Ops 19, % non-converted = 52.63 %\r\n * 10 ARITH ops\r\n\r\n- arith.constant: 10 occurrences (f32: 10)\r\n\r\n\r\n\r\n (f32: 5)\r\n (f32: 1)\r\n```",
"seems like a tensorflow version problem. I just change the version from tf2.15 to tf2.10. The non-converted ops are gone...",
"I am having the same issue, the model runs fine though. The inference results are as expected.",
"Running the same code with TensorFlow version 2.16.1 outputs:\r\n```\r\n2024-05-10 08:16:11.827293: W tensorflow/compiler/tf2tensorrt/utils/py_utils.cc:38] TF-TRT Warning: Could not find TensorRT\r\n2.16.1\r\nWARNING: All log messages before absl::InitializeLog() is called are written to STDERR\r\nW0000 00:00:1715328974.281010 3144 tf_tfl_flatbuffer_helpers.cc:390] Ignored output_format.\r\nW0000 00:00:1715328974.281077 3144 tf_tfl_flatbuffer_helpers.cc:393] Ignored drop_control_dependency.\r\nloc(fused[\"ReadVariableOp:\", callsite(\"sequential_1/dense_1/Add/ReadVariableOp@__inference_serving_default_29\"(\"/content/test.py\":11:1) at callsite(\"/usr/local/lib/python3.10/dist-packages/tensorflow/lite/python/lite.py\":1175:1 at callsite(\"/usr/local/lib/python3.10/dist-packages/tensorflow/lite/python/lite.py\":1129:1 at callsite(\"/usr/local/lib/python3.10/dist-packages/tensorflow/lite/python/lite.py\":1636:1 at callsite(\"/usr/local/lib/python3.10/dist-packages/tensorflow/lite/python/lite.py\":1614:1 at callsite(\"/usr/local/lib/python3.10/dist-packages/tensorflow/lite/python/convert_phase.py\":205:1 at callsite(\"/usr/local/lib/python3.10/dist-packages/tensorflow/lite/python/lite.py\":1537:1 at callsite(\"/usr/local/lib/python3.10/dist-packages/keras/src/backend/tensorflow/layer.py\":58:1 at callsite(\"/usr/local/lib/python3.10/dist-packages/keras/src/backend/tensorflow/layer.py\":120:1 at callsite(\"/usr/local/lib/python3.10/dist-packages/keras/src/utils/traceback_utils.py\":117:1 at callsite(\"/usr/local/lib/python3.10/dist-packages/keras/src/layers/layer.py\":846:1 at callsite(\"/usr/local/lib/python3.10/dist-packages/keras/src/utils/traceback_utils.py\":117:1 at callsite(\"/usr/local/lib/python3.10/dist-packages/keras/src/ops/operation.py\":48:1 at callsite(\"/usr/local/lib/python3.10/dist-packages/keras/src/utils/traceback_utils.py\":156:1 at callsite(\"/usr/local/lib/python3.10/dist-packages/keras/src/models/sequential.py\":209:1 at callsite(\"/usr/local/lib/python3.10/dist-packages/keras/src/models/functional.py\":202:1 at callsite(\"/usr/local/lib/python3.10/dist-packages/keras/src/ops/function.py\":155:1 at callsite(\"/usr/local/lib/python3.10/dist-packages/keras/src/models/functional.py\":592:1 at callsite(\"/usr/local/lib/python3.10/dist-packages/keras/src/utils/traceback_utils.py\":117:1 at callsite(\"/usr/local/lib/python3.10/dist-packages/keras/src/layers/layer.py\":846:1 at callsite(\"/usr/local/lib/python3.10/dist-packages/keras/src/utils/traceback_utils.py\":117:1 at callsite(\"/usr/local/lib/python3.10/dist-packages/keras/src/ops/operation.py\":48:1 at callsite(\"/usr/local/lib/python3.10/dist-packages/keras/src/utils/traceback_utils.py\":156:1 at callsite(\"/usr/local/lib/python3.10/dist-packages/keras/src/layers/core/dense.py\":152:1 at callsite(\"/usr/local/lib/python3.10/dist-packages/keras/src/ops/numpy.py\":168:1 at callsite(\"/usr/local/lib/python3.10/dist-packages/keras/src/backend/tensorflow/sparse.py\":493:1 at callsite(\"/usr/local/lib/python3.10/dist-packages/keras/src/backend/tensorflow/numpy.py\":36:1 at \"/usr/local/lib/python3.10/dist-packages/keras/src/backend/tensorflow/core.py\":65:1)))))))))))))))))))))))))))]): error: missing attribute 'value'\r\nLLVM ERROR: Failed to infer result type(s).\r\n```\r\n\r\nThis is an error, and no *tflite* file will be generated anymore.",
"Hi @Black3rror, If I use [AI-Edge-Torch](https://github.com/google-ai-edge/ai-edge-torch), it appears to work well:\r\n\r\nconvert.py\r\n```py\r\nimport torch\r\nimport torch.nn as nn\r\nimport ai_edge_torch\r\n\r\n\r\nclass LinearRegression(nn.Module):\r\n def __init__(self):\r\n super().__init__()\r\n self.dense = nn.Linear(1, 1)\r\n\r\n def forward(self, x):\r\n return self.dense(x)\r\n\r\n\r\nmodel = LinearRegression()\r\nsample_inputs = (torch.randn(1),)\r\n\r\nedge_model = ai_edge_torch.convert(model.eval(), sample_inputs)\r\nedge_model.export(\"lr.tflite\")\r\n```\r\n\r\nmy output:\r\n```sh\r\npython convert.py\r\n2024-06-11 21:49:20.614022: I external/local_xla/xla/tsl/cuda/cudart_stub.cc:32] Could not find cuda drivers on your machine, GPU will not be used.\r\n2024-06-11 21:49:20.617583: I external/local_xla/xla/tsl/cuda/cudart_stub.cc:32] Could not find cuda drivers on your machine, GPU will not be used.\r\n2024-06-11 21:49:20.656618: I tensorflow/core/platform/cpu_feature_guard.cc:210] This TensorFlow binary is optimized to use available CPU instructions in performance-critical operations.\r\nTo enable the following instructions: AVX2 FMA, in other operations, rebuild TensorFlow with the appropriate compiler flags.\r\n2024-06-11 21:49:21.702560: W tensorflow/compiler/tf2tensorrt/utils/py_utils.cc:38] TF-TRT Warning: Could not find TensorRT\r\nWARNING:root:PJRT is now the default runtime. For more information, see https://github.com/pytorch/xla/blob/master/docs/pjrt.md\r\nWARNING:root:Defaulting to PJRT_DEVICE=CPU\r\nWARNING: All log messages before absl::InitializeLog() is called are written to STDERR\r\nI0000 00:00:1718142563.953505 816506 cpu_client.cc:424] TfrtCpuClient created.\r\nWARNING: All log messages before absl::InitializeLog() is called are written to STDERR\r\nW0000 00:00:1718142565.742263 816506 tf_tfl_flatbuffer_helpers.cc:392] Ignored output_format.\r\nW0000 00:00:1718142565.742290 816506 tf_tfl_flatbuffer_helpers.cc:395] Ignored drop_control_dependency.\r\n2024-06-11 21:49:25.743230: I tensorflow/cc/saved_model/reader.cc:83] Reading SavedModel from: /tmp/tmp1n3s0fho\r\n2024-06-11 21:49:25.743512: I tensorflow/cc/saved_model/reader.cc:52] Reading meta graph with tags { serve }\r\n2024-06-11 21:49:25.743532: I tensorflow/cc/saved_model/reader.cc:147] Reading SavedModel debug info (if present) from: /tmp/tmp1n3s0fho\r\n2024-06-11 21:49:25.748880: I tensorflow/compiler/mlir/mlir_graph_optimization_pass.cc:388] MLIR V1 optimization pass is not enabled\r\n2024-06-11 21:49:25.749202: I tensorflow/cc/saved_model/loader.cc:236] Restoring SavedModel bundle.\r\n2024-06-11 21:49:25.760743: I tensorflow/cc/saved_model/loader.cc:220] Running initialization op on SavedModel bundle at path: /tmp/tmp1n3s0fho\r\n2024-06-11 21:49:25.764008: I tensorflow/cc/saved_model/loader.cc:462] SavedModel load for tags { serve }; Status: success: OK. Took 20779 microseconds.\r\n2024-06-11 21:49:25.770494: I tensorflow/compiler/mlir/tensorflow/utils/dump_mlir_util.cc:268] disabling MLIR crash reproducer, set env var `MLIR_CRASH_REPRODUCER_DIRECTORY` to enable.\r\n2024-06-11 21:49:25.803013: I tensorflow/compiler/mlir/lite/flatbuffer_export.cc:3531] Estimated count of arithmetic ops: 3 ops, equivalently 1 MACs\r\nI0000 00:00:1718142566.683158 816506 cpu_client.cc:427] TfrtCpuClient destroyed.\r\n```\r\n\r\nDoes this resolve your issue?"
] | 2024-01-28T11:36:51 | 2024-06-11T21:57:44 | null |
NONE
| null | null | null |
### System information
- Platform: Tried on Google Colab
- TensorFlow version: 2.15.0
### Steps to reproduce
- Creating a Python file with the following content in Google Colab (let's call it test.py):
```Python
import tensorflow as tf
model = tf.keras.models.Sequential([
tf.keras.layers.InputLayer(input_shape=(1,)),
tf.keras.layers.Dense(1)
])
converter = tf.lite.TFLiteConverter.from_keras_model(model)
tflite_model = converter.convert()
with open('model.tflite', 'wb') as f:
f.write(tflite_model)
```
- Calling it in Jupyter Notebook by `!python test.py`
- The output will be:
```Python
2024-01-28 11:17:11.939381: E external/local_xla/xla/stream_executor/cuda/cuda_dnn.cc:9261] Unable to register cuDNN factory: Attempting to register factory for plugin cuDNN when one has already been registered
2024-01-28 11:17:11.939450: E external/local_xla/xla/stream_executor/cuda/cuda_fft.cc:607] Unable to register cuFFT factory: Attempting to register factory for plugin cuFFT when one has already been registered
2024-01-28 11:17:11.941203: E external/local_xla/xla/stream_executor/cuda/cuda_blas.cc:1515] Unable to register cuBLAS factory: Attempting to register factory for plugin cuBLAS when one has already been registered
2024-01-28 11:17:13.646897: W tensorflow/compiler/tf2tensorrt/utils/py_utils.cc:38] TF-TRT Warning: Could not find TensorRT
2024-01-28 11:17:16.713671: W tensorflow/compiler/mlir/lite/python/tf_tfl_flatbuffer_helpers.cc:378] Ignored output_format.
2024-01-28 11:17:16.713736: W tensorflow/compiler/mlir/lite/python/tf_tfl_flatbuffer_helpers.cc:381] Ignored drop_control_dependency.
Summary on the non-converted ops:
---------------------------------
* Accepted dialects: tfl, builtin, func
* Non-Converted Ops: 1, Total Ops 6, % non-converted = 16.67 %
* 1 ARITH ops
- arith.constant: 1 occurrences (f32: 1)
(f32: 1)
```
Note: running the code directly in Jupyter Notebook won't print anything
### Problem
- Why can it not convert all the operations in such a simple model?
- Was it supposed to be like that?
- Does having non-converted operations affect the performance of the model when deployed on a microcontroller using TFLM?
- Is there a way to solve it?
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62855/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62855/timeline
| null | null | false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62854
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62854/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62854/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62854/events
|
https://github.com/tensorflow/tensorflow/issues/62854
| 2,103,231,008 |
I_kwDOArmXAs59XMIg
| 62,854 |
RAM memory leak with tf.function when training multiple models in a loop
|
{
"login": "chrisyeh96",
"id": 7686641,
"node_id": "MDQ6VXNlcjc2ODY2NDE=",
"avatar_url": "https://avatars.githubusercontent.com/u/7686641?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/chrisyeh96",
"html_url": "https://github.com/chrisyeh96",
"followers_url": "https://api.github.com/users/chrisyeh96/followers",
"following_url": "https://api.github.com/users/chrisyeh96/following{/other_user}",
"gists_url": "https://api.github.com/users/chrisyeh96/gists{/gist_id}",
"starred_url": "https://api.github.com/users/chrisyeh96/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/chrisyeh96/subscriptions",
"organizations_url": "https://api.github.com/users/chrisyeh96/orgs",
"repos_url": "https://api.github.com/users/chrisyeh96/repos",
"events_url": "https://api.github.com/users/chrisyeh96/events{/privacy}",
"received_events_url": "https://api.github.com/users/chrisyeh96/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 404586594,
"node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower",
"name": "stat:awaiting tensorflower",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from tensorflower"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 2691123225,
"node_id": "MDU6TGFiZWwyNjkxMTIzMjI1",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:tf.function",
"name": "comp:tf.function",
"color": "0052cc",
"default": false,
"description": "tf.function related issues"
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
open
| false |
{
"login": "sachinprasadhs",
"id": 73069040,
"node_id": "MDQ6VXNlcjczMDY5MDQw",
"avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sachinprasadhs",
"html_url": "https://github.com/sachinprasadhs",
"followers_url": "https://api.github.com/users/sachinprasadhs/followers",
"following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}",
"gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions",
"organizations_url": "https://api.github.com/users/sachinprasadhs/orgs",
"repos_url": "https://api.github.com/users/sachinprasadhs/repos",
"events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}",
"received_events_url": "https://api.github.com/users/sachinprasadhs/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "sachinprasadhs",
"id": 73069040,
"node_id": "MDQ6VXNlcjczMDY5MDQw",
"avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sachinprasadhs",
"html_url": "https://github.com/sachinprasadhs",
"followers_url": "https://api.github.com/users/sachinprasadhs/followers",
"following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}",
"gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions",
"organizations_url": "https://api.github.com/users/sachinprasadhs/orgs",
"repos_url": "https://api.github.com/users/sachinprasadhs/repos",
"events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}",
"received_events_url": "https://api.github.com/users/sachinprasadhs/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"@sachinprasadhs I was able to replicate the issue on colab. Please find the [gist](https://colab.research.google.com/gist/sushreebarsa/af609c8a065feeb7c2d4491ea0fac09c/62854.ipynb#scrollTo=hnC0ZaIEKabZ) here for reference.\r\nThank you!"
] | 2024-01-27T05:06:09 | 2024-01-30T19:10:34 | null |
CONTRIBUTOR
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
No
### Source
binary
### TensorFlow version
tf 2.15
### Custom code
Yes
### OS platform and distribution
Ubuntu 22.04.3 LTS
### Mobile device
_No response_
### Python version
3.10
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
n/a
### GPU model and memory
n/a
### Current behavior?
When I train multiple models in a loop, if I decorate the `train()` function with `@tf.function`, then the memory usage keeps on increasing after each loop iteration, even when I delete the model at the end of each loop and clear the TensorFlow graph/session.
The memory leak does not occur when `@tf.function` is removed. However, model training performance is significantly slower.
Colab notebook to reproduce issue:
https://colab.research.google.com/drive/1sJsGmcFeZVx6ImNbqnBsgF_LzIyPxXPW?usp=sharing
### Standalone code to reproduce the issue
```python
import gc
import os
import psutil
import tensorflow as tf
class MyModel:
def __init__(self):
self.dnn = tf.keras.Sequential([
tf.keras.layers.Dense(256),
tf.keras.layers.Dense(256),
tf.keras.layers.Dense(256),
tf.keras.layers.Dense(1),
])
self.optimizer = tf.optimizers.Adam()
@tf.function # if we remove this @tf.function decorator, then there is no memory leak
def train(self, X):
with tf.GradientTape() as tape:
loss = tf.reduce_sum(self.dnn(X))
grads = tape.gradient(loss, self.dnn.trainable_variables)
self.optimizer.apply_gradients(zip(grads, self.dnn.trainable_variables))
process = psutil.Process(os.getpid())
rss = int(process.memory_info().rss / 1024 / 1024) # in MB
print(f'rss: {rss} MB')
X = tf.ones((50, 80))
for i in range(50):
model = MyModel()
for _ in range(20):
model.train(X)
del model
tf.keras.backend.clear_session()
tf.compat.v1.reset_default_graph()
gc.collect()
new_rss = int(process.memory_info().rss / 1024 / 1024)
if new_rss > rss:
rss_increase = new_rss - rss
rss = new_rss
print(f'Iter {i:05d}, rss increase: {rss_increase} MB, rss: {rss} MB')
```
### Relevant log output
```shell
rss: 593 MB
Iter 00000, rss increase: 31 MB, rss: 624 MB
Iter 00001, rss increase: 6 MB, rss: 630 MB
Iter 00002, rss increase: 5 MB, rss: 635 MB
Iter 00003, rss increase: 5 MB, rss: 640 MB
Iter 00004, rss increase: 5 MB, rss: 645 MB
Iter 00005, rss increase: 5 MB, rss: 650 MB
Iter 00006, rss increase: 5 MB, rss: 655 MB
Iter 00007, rss increase: 5 MB, rss: 660 MB
Iter 00008, rss increase: 5 MB, rss: 665 MB
Iter 00009, rss increase: 5 MB, rss: 670 MB
Iter 00010, rss increase: 4 MB, rss: 674 MB
--- <omitting some rows for brevity> ---
Iter 00040, rss increase: 5 MB, rss: 822 MB
Iter 00041, rss increase: 5 MB, rss: 827 MB
Iter 00042, rss increase: 5 MB, rss: 832 MB
Iter 00043, rss increase: 5 MB, rss: 837 MB
Iter 00044, rss increase: 5 MB, rss: 842 MB
Iter 00045, rss increase: 5 MB, rss: 847 MB
Iter 00046, rss increase: 5 MB, rss: 852 MB
Iter 00047, rss increase: 5 MB, rss: 857 MB
Iter 00048, rss increase: 5 MB, rss: 862 MB
Iter 00049, rss increase: 5 MB, rss: 867 MB
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62854/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62854/timeline
| null | null | false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62853
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62853/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62853/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62853/events
|
https://github.com/tensorflow/tensorflow/issues/62853
| 2,102,984,424 |
I_kwDOArmXAs59WP7o
| 62,853 |
TfLite: undefined symbol TfLiteGpuDelegateV2Create in android
|
{
"login": "suyash-narain",
"id": 78979784,
"node_id": "MDQ6VXNlcjc4OTc5Nzg0",
"avatar_url": "https://avatars.githubusercontent.com/u/78979784?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/suyash-narain",
"html_url": "https://github.com/suyash-narain",
"followers_url": "https://api.github.com/users/suyash-narain/followers",
"following_url": "https://api.github.com/users/suyash-narain/following{/other_user}",
"gists_url": "https://api.github.com/users/suyash-narain/gists{/gist_id}",
"starred_url": "https://api.github.com/users/suyash-narain/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/suyash-narain/subscriptions",
"organizations_url": "https://api.github.com/users/suyash-narain/orgs",
"repos_url": "https://api.github.com/users/suyash-narain/repos",
"events_url": "https://api.github.com/users/suyash-narain/events{/privacy}",
"received_events_url": "https://api.github.com/users/suyash-narain/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 404586594,
"node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower",
"name": "stat:awaiting tensorflower",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from tensorflower"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 750616506,
"node_id": "MDU6TGFiZWw3NTA2MTY1MDY=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite",
"name": "comp:lite",
"color": "0052cc",
"default": false,
"description": "TF Lite related issues"
},
{
"id": 2671339633,
"node_id": "MDU6TGFiZWwyNjcxMzM5NjMz",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TFLiteGpuDelegate",
"name": "TFLiteGpuDelegate",
"color": "F71F04",
"default": false,
"description": "TFLite Gpu delegate issue"
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
open
| false |
{
"login": "impjdi",
"id": 9742927,
"node_id": "MDQ6VXNlcjk3NDI5Mjc=",
"avatar_url": "https://avatars.githubusercontent.com/u/9742927?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/impjdi",
"html_url": "https://github.com/impjdi",
"followers_url": "https://api.github.com/users/impjdi/followers",
"following_url": "https://api.github.com/users/impjdi/following{/other_user}",
"gists_url": "https://api.github.com/users/impjdi/gists{/gist_id}",
"starred_url": "https://api.github.com/users/impjdi/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/impjdi/subscriptions",
"organizations_url": "https://api.github.com/users/impjdi/orgs",
"repos_url": "https://api.github.com/users/impjdi/repos",
"events_url": "https://api.github.com/users/impjdi/events{/privacy}",
"received_events_url": "https://api.github.com/users/impjdi/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "impjdi",
"id": 9742927,
"node_id": "MDQ6VXNlcjk3NDI5Mjc=",
"avatar_url": "https://avatars.githubusercontent.com/u/9742927?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/impjdi",
"html_url": "https://github.com/impjdi",
"followers_url": "https://api.github.com/users/impjdi/followers",
"following_url": "https://api.github.com/users/impjdi/following{/other_user}",
"gists_url": "https://api.github.com/users/impjdi/gists{/gist_id}",
"starred_url": "https://api.github.com/users/impjdi/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/impjdi/subscriptions",
"organizations_url": "https://api.github.com/users/impjdi/orgs",
"repos_url": "https://api.github.com/users/impjdi/repos",
"events_url": "https://api.github.com/users/impjdi/events{/privacy}",
"received_events_url": "https://api.github.com/users/impjdi/received_events",
"type": "User",
"site_admin": false
},
{
"login": "pkgoogle",
"id": 132095473,
"node_id": "U_kgDOB9-d8Q",
"avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/pkgoogle",
"html_url": "https://github.com/pkgoogle",
"followers_url": "https://api.github.com/users/pkgoogle/followers",
"following_url": "https://api.github.com/users/pkgoogle/following{/other_user}",
"gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}",
"starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions",
"organizations_url": "https://api.github.com/users/pkgoogle/orgs",
"repos_url": "https://api.github.com/users/pkgoogle/repos",
"events_url": "https://api.github.com/users/pkgoogle/events{/privacy}",
"received_events_url": "https://api.github.com/users/pkgoogle/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi @suyash-narain, I'm trying to understand how you integrated TFLite into your application. Did you build a shared library from source and included in your project? If so do you happen to have the build command you used? I'm assuming you're using JNI. Alternatively if you can export your project, I believe that will answer my questions as well. Thanks for your help.",
"Hi @pkgoogle, how can i export my project onto github issues? or should i point you to the github link from where the project is sourced?\r\nits sourced from https://github.com/nyadla-sys/whisper.tflite/tree/main/whisper_android",
"Hi @suyash-narain, you should be able to export it in Android Studio, then upload the zip file: \r\n\r\nIf not you can upload it to an external source such as gdrive and ensure I can download it (i.e make it public).",
"i think i figured out the reason behind the error. the model is not compatible with the delegate and hence it fails to even create the same on android studio.\r\nthe thing i cannot understand is, if a model is CPU compatible but not compatible with the delegate, why can't the model be simply fallback on CPU instead of giving 'error invoking delegate' error?",
"@suyash-narain https://www.tensorflow.org/lite/performance/gpu#troubleshooting_gpu_support seems to state that it should just fallback to running parts of the model on CPU (despite it being slower). So this should be a bug... do you mind uploading your project so that we may reproduce? (Often times people change more than they think, that affects our current understanding of the issue.)",
"https://drive.google.com/file/d/1EQ4_ieaV_7SFZBLR9aM9yDvBY_pUXN_3/view?usp=sharing\r\nhere is the zip file for the project",
"I tried updating the tflite versions to see if that helped, it did not, I was able to reproduce with the uploaded zip file:\r\n\r\n```\r\n implementation 'org.tensorflow:tensorflow-lite:+'\r\n implementation 'org.tensorflow:tensorflow-lite-support:+'\r\n```\r\n\r\nHi, @impjdi, can you please take a look? Thanks.",
"@suyash-narain \r\n\r\nI did resolve this error by linking tflite for gpu in cmake file.\r\n\r\nYou can download this from https://github.com/ValYouW/tflite-dist/releases\r\n//tensorflow/lite:libtensorflowlite.so //this is already available in your tree\r\ntensorflow/lite/delegates/gpu:libtensorflowlite_gpu_gl.so // this needs to be pushed at cpp/tf-lite-api/generated-libs/armeabi-v7a\r\n\r\n\r\nUpodate the whisper_android/app/src/main/cpp/CMakeLists.txt as below\r\n\r\nif (ANDROID)\r\n add_library(audioEngine SHARED TFLiteEngine.cpp TFLiteEngineJNI.cpp)\r\n target_include_directories(audioEngine PRIVATE ${INCLUDE_DIRS})\r\n # Add 'tflite' library (imported)\r\n message(\"new\")\r\n add_library(tflite SHARED IMPORTED)\r\n set_target_properties(tflite PROPERTIES IMPORTED_LOCATION\r\n ${CMAKE_CURRENT_LIST_DIR}/tf-lite-api/generated-libs/${ANDROID_ABI}/libtensorflowlite.so)\r\n **add_library(tflite_gpu_delegate SHARED IMPORTED)\r\n set_target_properties(tflite_gpu_delegate PROPERTIES IMPORTED_LOCATION\r\n ${CMAKE_CURRENT_LIST_DIR}/tf-lite-api/generated-libs/${ANDROID_ABI}/libtensorflowlite_gpu_delegate.so)\r\n target_link_libraries(audioEngine tflite tflite_gpu_delegate)**\r\nendif ()\r\n\r\nI can successfully build for gpu delegate. However, it still breaks when doing inference.",
"Hi @Meet-synaptics \r\n\r\nthank you for your reply. Using the prebuilt libtensorflowlite_gpu_delegate.so file, the app does get compile, but it fails on the android aarch64 target i am trying to execute it on. \r\nsomehow it doesn't build for arm64-v8a but only builds for armeabi-v7a.\r\n\r\ndo you have any suggestions on how to build it for arm64-v8a?\r\n\r\nthanks"
] | 2024-01-26T22:22:05 | 2024-03-04T20:38:33 | null |
NONE
| null | null | null |
### Issue type
Support
### Have you reproduced the bug with TensorFlow Nightly?
No
### Source
source
### TensorFlow version
2.15
### Custom code
Yes
### OS platform and distribution
Mac Big Sur
### Mobile device
aarch64 device
### Python version
_No response_
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
Hi,
I have a whisper-tflite model and android app as well sourced from https://github.com/nyadla-sys/whisper.tflite/tree/main/whisper_android which works well on CPU of an aarch64 target similar to raspberry pi.
I wanted to add support for GPU delegate and NNAPI delegate in the app source code in android studio.
To note, the app is unsupported on GPU/NNAPI (or some ops are unsupported on GPU/NNAPI). And according to my understanding, if a model op is unsupported on GPU/NNAPI, it will fallback onto CPU. So general understanding is the model should fallback and execute on CPU
When I add support for GPU delegate using the below code snippet sourced from https://www.tensorflow.org/lite/android/delegates/gpu_native#enable_gpu_acceleration,
```
// Set up interpreter
auto model = FlatBufferModel::BuildFromFile(model_path);
if (!model) return false;
ops::builtin::BuiltinOpResolver op_resolver;
std::unique_ptr<Interpreter> interpreter;
InterpreterBuilder(*model, op_resolver)(&interpreter);
// NEW: Prepare GPU delegate.
auto* delegate = TfLiteGpuDelegateV2Create(/*default options=*/nullptr);
if (interpreter->ModifyGraphWithDelegate(delegate) != kTfLiteOk) return false;
// Run inference.
WriteToInputTensor(interpreter->typed_input_tensor<float>(0));
if (interpreter->Invoke() != kTfLiteOk) return false;
ReadFromOutputTensor(interpreter->typed_output_tensor<float>(0));
// NEW: Clean up.
TfLiteGpuDelegateV2Delete(delegate);
```
I get android build error saying
**ld: error: undefined symbol: TfLiteGpuDelegateV2Create**
I have added the relevant header file to my C++ code and my gradle build file sources the cmakelists.txt file from the c++ source code directory to build the app.
My understanding is I will get the 'undefined symbol' error if the model is unsupported on the delegate. Is my understanding correct?
If the error is truly because of unsupported model, shouldn't the app still get compiled and simply run on CPU with fallback instead of erroring out at build time?
I get same error if I try to add NNAPI support as well.
Why is fallback to CPU from delegate not working during android build stage since whisper-tflite model works well with CPU
thanks
### Standalone code to reproduce the issue
```shell
// code snippet for GPU delegate addition
const TfLiteDelegateOptionsV2 options = TfLiteGpuDelegateOptionsV2Default();
TfLiteDelegate* delegate = TfLiteGpuDelegateV2Create(&options);
if (tflite::Interpreter->ModifyGraphWithDelegate(delegate) != kTfLiteOk) return "";
tflite::Interpreter->SetNumThreads(4);
if (tflite::Interpreter->Invoke() != kTfLiteOk) return "";
```
### Relevant log output
_No response_
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62853/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62853/timeline
| null | null | false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62852
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62852/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62852/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62852/events
|
https://github.com/tensorflow/tensorflow/pull/62852
| 2,102,492,699 |
PR_kwDOArmXAs5lLIzi
| 62,852 |
oneDNN ACL indirect conv patch
|
{
"login": "davsva01",
"id": 117736650,
"node_id": "U_kgDOBwSEyg",
"avatar_url": "https://avatars.githubusercontent.com/u/117736650?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/davsva01",
"html_url": "https://github.com/davsva01",
"followers_url": "https://api.github.com/users/davsva01/followers",
"following_url": "https://api.github.com/users/davsva01/following{/other_user}",
"gists_url": "https://api.github.com/users/davsva01/gists{/gist_id}",
"starred_url": "https://api.github.com/users/davsva01/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/davsva01/subscriptions",
"organizations_url": "https://api.github.com/users/davsva01/orgs",
"repos_url": "https://api.github.com/users/davsva01/repos",
"events_url": "https://api.github.com/users/davsva01/events{/privacy}",
"received_events_url": "https://api.github.com/users/davsva01/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 987666414,
"node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull",
"name": "ready to pull",
"color": "2cd643",
"default": false,
"description": "PR ready for merge process"
},
{
"id": 1104829434,
"node_id": "MDU6TGFiZWwxMTA0ODI5NDM0",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:mkl",
"name": "comp:mkl",
"color": "0052cc",
"default": false,
"description": "MKL related issues"
},
{
"id": 1169364458,
"node_id": "MDU6TGFiZWwxMTY5MzY0NDU4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:S",
"name": "size:S",
"color": "adafea",
"default": false,
"description": "CL Change Size: Small"
}
] |
closed
| false |
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).\n\nView this [failed invocation](https://github.com/tensorflow/tensorflow/pull/62852/checks?check_run_id=20907322136) of the CLA check for more information.\n\nFor the most up to date status, view the checks section at the bottom of the pull request.",
"@penpornk "
] | 2024-01-26T16:23:06 | 2024-02-05T08:17:12 | 2024-01-29T20:20:54 |
CONTRIBUTOR
| null | false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62852",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62852",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62852.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62852.patch",
"merged_at": "2024-01-29T20:20:54"
}
|
Adds a patch enabling indirect conv for lower core counts in oneDNN ACL builds. This reduces memory usage of computer vision models. Performance is also improved for these systems. Relative improvement after patch is shown here:

|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62852/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62852/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62851
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62851/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62851/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62851/events
|
https://github.com/tensorflow/tensorflow/pull/62851
| 2,102,442,813 |
PR_kwDOArmXAs5lK99i
| 62,851 |
[TFLite] Add check in Softmax reference function to ensure exponent is within valid range
|
{
"login": "tom-arm",
"id": 72802373,
"node_id": "MDQ6VXNlcjcyODAyMzcz",
"avatar_url": "https://avatars.githubusercontent.com/u/72802373?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tom-arm",
"html_url": "https://github.com/tom-arm",
"followers_url": "https://api.github.com/users/tom-arm/followers",
"following_url": "https://api.github.com/users/tom-arm/following{/other_user}",
"gists_url": "https://api.github.com/users/tom-arm/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tom-arm/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tom-arm/subscriptions",
"organizations_url": "https://api.github.com/users/tom-arm/orgs",
"repos_url": "https://api.github.com/users/tom-arm/repos",
"events_url": "https://api.github.com/users/tom-arm/events{/privacy}",
"received_events_url": "https://api.github.com/users/tom-arm/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 390482148,
"node_id": "MDU6TGFiZWwzOTA0ODIxNDg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/awaiting%20review",
"name": "awaiting review",
"color": "bc3869",
"default": false,
"description": "Pull request awaiting review"
},
{
"id": 750616506,
"node_id": "MDU6TGFiZWw3NTA2MTY1MDY=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite",
"name": "comp:lite",
"color": "0052cc",
"default": false,
"description": "TF Lite related issues"
},
{
"id": 987666414,
"node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull",
"name": "ready to pull",
"color": "2cd643",
"default": false,
"description": "PR ready for merge process"
},
{
"id": 1169364259,
"node_id": "MDU6TGFiZWwxMTY5MzY0MjU5",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS",
"name": "size:XS",
"color": "adafea",
"default": false,
"description": "CL Change Size: Extra Small"
}
] |
closed
| false |
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[] | 2024-01-26T15:50:23 | 2024-01-31T04:58:52 | 2024-01-31T04:58:52 |
CONTRIBUTOR
| null | false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62851",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62851",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62851.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62851.patch",
"merged_at": "2024-01-31T04:58:52"
}
|
* Add check to ensure the exponent does not cause an overflow in gemmlowp::RoundingDivideByPOT
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62851/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62851/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62850
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62850/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62850/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62850/events
|
https://github.com/tensorflow/tensorflow/issues/62850
| 2,101,769,846 |
I_kwDOArmXAs59RnZ2
| 62,850 |
Whisper large in SparkNlp (Message tensorflow.GraphDef exceeds maximum protobuf size of 2GB)
|
{
"login": "minhduc210196",
"id": 147492971,
"node_id": "U_kgDOCMqQaw",
"avatar_url": "https://avatars.githubusercontent.com/u/147492971?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/minhduc210196",
"html_url": "https://github.com/minhduc210196",
"followers_url": "https://api.github.com/users/minhduc210196/followers",
"following_url": "https://api.github.com/users/minhduc210196/following{/other_user}",
"gists_url": "https://api.github.com/users/minhduc210196/gists{/gist_id}",
"starred_url": "https://api.github.com/users/minhduc210196/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/minhduc210196/subscriptions",
"organizations_url": "https://api.github.com/users/minhduc210196/orgs",
"repos_url": "https://api.github.com/users/minhduc210196/repos",
"events_url": "https://api.github.com/users/minhduc210196/events{/privacy}",
"received_events_url": "https://api.github.com/users/minhduc210196/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
},
{
"id": 750616506,
"node_id": "MDU6TGFiZWw3NTA2MTY1MDY=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite",
"name": "comp:lite",
"color": "0052cc",
"default": false,
"description": "TF Lite related issues"
},
{
"id": 1661751498,
"node_id": "MDU6TGFiZWwxNjYxNzUxNDk4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TFLiteConverter",
"name": "TFLiteConverter",
"color": "bfdadc",
"default": false,
"description": "For issues related to TFLite converter"
},
{
"id": 4511033337,
"node_id": "LA_kwDOArmXAs8AAAABDODn-Q",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.10",
"name": "TF 2.10",
"color": "C15088",
"default": false,
"description": ""
}
] |
closed
| false |
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"my code in \r\nhttps://colab.research.google.com/drive/1dkIfVZf8WtQAVLKaSt8s95_29BHcLOlw#scrollTo=8xN4MqZagxCQ",
"All PyTorch model weights were used when initializing WhisperExport.\r\n\r\nAll the weights of WhisperExport were initialized from the PyTorch model.\r\nIf your task is similar to the task the model of the checkpoint was trained on, you can already use WhisperExport for predictions without further training.\r\n---------------------------------------------------------------------------\r\nValueError Traceback (most recent call last)\r\n<ipython-input-4-3156f99a4cea> in <cell line: 207>()\r\n 206 \r\n 207 model_wrapping = ModelWrapping(\r\n--> 208 whisper_model.make_encoder_serving(),\r\n 209 whisper_model.make_decoder_init_serving(),\r\n 210 whisper_model.make_decoder_serving(),\r\n\r\n11 frames\r\n/usr/local/lib/python3.10/dist-packages/tensorflow/python/framework/importer.py in _import_graph_def_internal(graph_def, input_map, return_elements, validate_colocation_constraints, name, producer_op_list)\r\n 495 # _ProcessNewOps.\r\n 496 with graph._mutation_lock(): # pylint: disable=protected-access\r\n--> 497 with c_api_util.tf_buffer(graph_def.SerializeToString()) as serialized:\r\n 498 try:\r\n 499 with graph._c_graph.get() as c_graph: # pylint: disable=protected-access\r\n\r\nValueError: Message tensorflow.GraphDef exceeds maximum protobuf size of 2GB: 2549145890",
"Please help me. Thank u very much",
"@minhduc210196,\r\nI do not have access to the link you have provided. Could you please provide the required permissions to view the files.\r\n\r\nAlso the error message **ValueError: Message tensorflow.GraphDef exceeds maximum protobuf size of 2GB** indicates that the TensorFlow GraphDef object, which is a protocol buffer exceeds the maximum allowed size of 2GB. \r\n\r\nThis can happen when the graph is too large or has too many nodes. Could you please try reducing the size of the graph by removing unnecessary nodes or operations. Additionally, you can split the graph into smaller sub-graphs and run them separately.\r\nhttps://github.com/tensorflow/tensorflow/issues/47326\r\nhttps://github.com/tensorflow/tensorflow/issues/55692\r\n\r\n\r\nThank you!",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62850\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62850\">No</a>\n"
] | 2024-01-26T08:08:36 | 2024-02-13T01:47:06 | 2024-02-13T01:47:02 |
NONE
| null | null | null |
Issue Type
Bug
Source
source
Tensorflow Version
2.10
Custom Code
No
Google colab
Mobile device
No response
Python version
3.9
Bazel version
No response
GCC/Compiler version
No response
CUDA/cuDNN version
11.4/8.1.0
GPU model and memory
A100 40GB
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62850/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62850/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62849
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62849/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62849/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62849/events
|
https://github.com/tensorflow/tensorflow/issues/62849
| 2,101,736,429 |
I_kwDOArmXAs59RfPt
| 62,849 |
keras LSTM model convert error with "'tf.TensorListReserve' op requires element_shape to be static during TF Lite transformation pass"
|
{
"login": "YuriSizuku",
"id": 15275959,
"node_id": "MDQ6VXNlcjE1Mjc1OTU5",
"avatar_url": "https://avatars.githubusercontent.com/u/15275959?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/YuriSizuku",
"html_url": "https://github.com/YuriSizuku",
"followers_url": "https://api.github.com/users/YuriSizuku/followers",
"following_url": "https://api.github.com/users/YuriSizuku/following{/other_user}",
"gists_url": "https://api.github.com/users/YuriSizuku/gists{/gist_id}",
"starred_url": "https://api.github.com/users/YuriSizuku/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/YuriSizuku/subscriptions",
"organizations_url": "https://api.github.com/users/YuriSizuku/orgs",
"repos_url": "https://api.github.com/users/YuriSizuku/repos",
"events_url": "https://api.github.com/users/YuriSizuku/events{/privacy}",
"received_events_url": "https://api.github.com/users/YuriSizuku/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
},
{
"id": 750616506,
"node_id": "MDU6TGFiZWw3NTA2MTY1MDY=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite",
"name": "comp:lite",
"color": "0052cc",
"default": false,
"description": "TF Lite related issues"
},
{
"id": 1661751498,
"node_id": "MDU6TGFiZWwxNjYxNzUxNDk4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TFLiteConverter",
"name": "TFLiteConverter",
"color": "bfdadc",
"default": false,
"description": "For issues related to TFLite converter"
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
closed
| false |
{
"login": "LakshmiKalaKadali",
"id": 149650845,
"node_id": "U_kgDOCOt9nQ",
"avatar_url": "https://avatars.githubusercontent.com/u/149650845?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/LakshmiKalaKadali",
"html_url": "https://github.com/LakshmiKalaKadali",
"followers_url": "https://api.github.com/users/LakshmiKalaKadali/followers",
"following_url": "https://api.github.com/users/LakshmiKalaKadali/following{/other_user}",
"gists_url": "https://api.github.com/users/LakshmiKalaKadali/gists{/gist_id}",
"starred_url": "https://api.github.com/users/LakshmiKalaKadali/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/LakshmiKalaKadali/subscriptions",
"organizations_url": "https://api.github.com/users/LakshmiKalaKadali/orgs",
"repos_url": "https://api.github.com/users/LakshmiKalaKadali/repos",
"events_url": "https://api.github.com/users/LakshmiKalaKadali/events{/privacy}",
"received_events_url": "https://api.github.com/users/LakshmiKalaKadali/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "LakshmiKalaKadali",
"id": 149650845,
"node_id": "U_kgDOCOt9nQ",
"avatar_url": "https://avatars.githubusercontent.com/u/149650845?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/LakshmiKalaKadali",
"html_url": "https://github.com/LakshmiKalaKadali",
"followers_url": "https://api.github.com/users/LakshmiKalaKadali/followers",
"following_url": "https://api.github.com/users/LakshmiKalaKadali/following{/other_user}",
"gists_url": "https://api.github.com/users/LakshmiKalaKadali/gists{/gist_id}",
"starred_url": "https://api.github.com/users/LakshmiKalaKadali/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/LakshmiKalaKadali/subscriptions",
"organizations_url": "https://api.github.com/users/LakshmiKalaKadali/orgs",
"repos_url": "https://api.github.com/users/LakshmiKalaKadali/repos",
"events_url": "https://api.github.com/users/LakshmiKalaKadali/events{/privacy}",
"received_events_url": "https://api.github.com/users/LakshmiKalaKadali/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi @YuriSizuku ,\r\n\r\nAdd `tf.lite.OpsSet.SELECT_TF_OPS` to the converter's target spec: ```converter.target_spec.supported_ops = [tf.lite.OpsSet.TFLITE_BUILTINS, tf.lite.OpsSet.SELECT_TF_OPS]``` to expand the range of supported operations. \r\nPlease change the following lines of code:\r\n ```\r\n converter = tf.lite.TFLiteConverter.from_keras_model( enc_model )\r\n buffer = converter.convert()\r\n open( 'enc_model.tflite' , 'wb' ).write( buffer ) \r\n```\r\nto \r\n\r\n```\r\nconverter = tf.lite.TFLiteConverter.from_keras_model( enc_model )\r\nconverter.optimizations = [tf.lite.Optimize.DEFAULT]\r\nconverter.experimental_new_converter=True\r\nconverter.target_spec.supported_ops = [tf.lite.OpsSet.TFLITE_BUILTINS,*tf.lite.OpsSet.SELECT_TF_OPS]\r\nbuffer = converter.convert()\r\nopen( 'enc_model.tflite' , 'wb' ).write( buffer ). \r\n```\r\nThe model working fine with this change. Here is the screenshot.\r\n\r\n\r\nThank You",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"The Select TF OPS command works but the problem I have been facing for a few days is deploying it in Android studio. Because of the added ops, it is giving an error of \"Cannot create an interpreter: Unsupported datatype 14 in tensor\" at just initializing the model."
] | 2024-01-26T07:40:51 | 2024-03-27T18:04:51 | 2024-02-21T01:47:04 |
NONE
| null | null | null |
### 1. System information
- OS Platform and Distribution (e.g., Linux Ubuntu 16.04): colab
- TensorFlow installation (pip package or built from source): 2.15.0
- TensorFlow library (version, if pip package or github SHA, if built from source):
### 2. Code
A simple seq2seq model with lstm.
https://colab.research.google.com/drive/1FKhOYhOz8d6BKLVVwL1YMlmoFQ2ML1DS#scrollTo=4SwY3T139l19
### 3. Failure after conversion
ConverterError Traceback (most recent call last)
[<ipython-input-11-67b7a4553e77>](https://localhost:8080/#) in <cell line: 2>()
1 converter = tf.lite.TFLiteConverter.from_keras_model(enc_model)
----> 2 buffer = converter.convert()
3 open('enc_model.tflite', 'wb').write(buffer)
4
5 converter = tf.lite.TFLiteConverter.from_keras_model(dec_model)
8 frames
[/usr/local/lib/python3.10/dist-packages/tensorflow/lite/python/convert.py](https://localhost:8080/#) in convert(model_flags, conversion_flags, input_data_str, debug_info_str, enable_mlir_converter)
364 enable_mlir_converter,
365 )
--> 366 raise converter_error
367
368 return _run_deprecated_conversion_binary(
ConverterError: /usr/lib/python3.10/runpy.py:196:1: error: 'tf.TensorListReserve' op requires element_shape to be static during TF Lite transformation pass
return _run_code(code, main_globals, None,
^
<unknown>:0: note: loc(fused["StatefulPartitionedCall:", "StatefulPartitionedCall"]): called from
/usr/lib/python3.10/runpy.py:196:1: error: failed to legalize operation 'tf.TensorListReserve' that was explicitly marked illegal
return _run_code(code, main_globals, None,
^
<unknown>:0: note: loc(fused["StatefulPartitionedCall:", "StatefulPartitionedCall"]): called from
<unknown>:0: error: Lowering tensor list ops is failed. Please consider using Select TF ops and disabling `_experimental_lower_tensor_list_ops` flag in the TFLite converter object. For example, converter.target_spec.supported_ops = [tf.lite.OpsSet.TFLITE_BUILTINS, tf.lite.OpsSet.SELECT_TF_OPS]\n converter._experimental_lower_tensor_list_ops = False
### 4. (optional) RNN conversion support
If converting TF RNN to TFLite fused RNN ops, please prefix [RNN] in the title.
### 5. (optional) Any other info / logs
Include any logs or source code that would be helpful to diagnose the problem. If including tracebacks, please include the full traceback. Large logs and files should be attached.
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62849/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62849/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62848
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62848/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62848/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62848/events
|
https://github.com/tensorflow/tensorflow/issues/62848
| 2,101,356,686 |
I_kwDOArmXAs59QCiO
| 62,848 |
Tensorflow r1.10 for Raspberry pi build fail
|
{
"login": "lida2003",
"id": 1296171,
"node_id": "MDQ6VXNlcjEyOTYxNzE=",
"avatar_url": "https://avatars.githubusercontent.com/u/1296171?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/lida2003",
"html_url": "https://github.com/lida2003",
"followers_url": "https://api.github.com/users/lida2003/followers",
"following_url": "https://api.github.com/users/lida2003/following{/other_user}",
"gists_url": "https://api.github.com/users/lida2003/gists{/gist_id}",
"starred_url": "https://api.github.com/users/lida2003/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/lida2003/subscriptions",
"organizations_url": "https://api.github.com/users/lida2003/orgs",
"repos_url": "https://api.github.com/users/lida2003/repos",
"events_url": "https://api.github.com/users/lida2003/events{/privacy}",
"received_events_url": "https://api.github.com/users/lida2003/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
}
] |
closed
| false |
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"@sushreebarsa If you're not strictly tied to TensorFlow r1.10, please consider using a newer, actively supported version for better compatibility and bug fixes. Please ensure your Docker container has stable internet access to download packages and verify that your network settings and firewalls aren't blocking access to PyPI. Could you also check that the package repositories listed in `/install/install_deb_packages.sh` are accessible and up-to-date. \r\nThank you!",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62848\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62848\">No</a>\n"
] | 2024-01-26T00:01:06 | 2024-02-13T01:47:10 | 2024-02-13T01:47:06 |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
source
### TensorFlow version
r1.10
### Custom code
No
### OS platform and distribution
Ubuntu 22.04.3 LTS
### Mobile device
Ubuntu 22.04.3 LTS
### Python version
Python 3.10.12
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
Follow
- https://github.com/tensorflow/tensorflow/issues/61506
- https://www.tensorflow.org/install/source_rpi?hl=zh-cn#build_from_source
- https://github.com/tensorflow/build/tree/master/raspberry_pi_builds#download-the-tensorflow-source-code
The documents seems quite old and not consistent with the code.
Can build tensorflow for raspberry pi from souce.
### Standalone code to reproduce the issue
```shell
$ git checkout r1.10
$ ./tensorflow/tools/ci_build/ci_build.sh pi-python3 tensorflow/tools/ci_build/pi/build_raspberry_pi.sh
```
```
### Relevant log output
```shell
$ ./tensorflow/tools/ci_build/ci_build.sh pi-python3 tensorflow/tools/ci_build/pi/build_raspberry_pi.sh
WORKSPACE: /home/daniel/Aocoda-RC/tensorflow
CI_DOCKER_EXTRA_PARAMS:
COMMAND: tensorflow/tools/ci_build/pi/build_raspberry_pi.sh
CI_COMMAND_PREFIX: ./tensorflow/tools/ci_build/builds/with_the_same_user ./tensorflow/tools/ci_build/builds/configured pi-python3
CONTAINER_TYPE: pi-python3
BUILD_TAG: tf_ci
(docker container name will be tf_ci.pi-python3)
Building container (tf_ci.pi-python3)...
DEPRECATED: The legacy builder is deprecated and will be removed in a future release.
Install the buildx component to build images with BuildKit:
https://docs.docker.com/go/buildx/
Sending build context to Docker daemon 390.7kB
Step 1/14 : FROM ubuntu:14.04
---> 13b66b487594
Step 2/14 : LABEL maintainer="Jan Prach <[email protected]>"
---> Using cache
---> 15d89ff8f639
Step 3/14 : COPY install/*.sh /install/
---> Using cache
---> 245eebe1c1e1
Step 4/14 : RUN /install/install_bootstrap_deb_packages.sh
---> Using cache
---> b2d32d7a24fd
Step 5/14 : RUN add-apt-repository -y ppa:openjdk-r/ppa && add-apt-repository -y ppa:george-edison55/cmake-3.x
---> Using cache
---> 7abfba3a4f48
Step 6/14 : RUN /install/install_deb_packages.sh
---> Using cache
---> 37eee92a1ba7
Step 7/14 : RUN /install/install_pip_packages.sh
---> Running in 90a7af672b9c
Searching for pip==9.0.3
Reading https://pypi.python.org/simple/pip/
Couldn't find index page for 'pip' (maybe misspelled?)
Scanning index of all packages (this may take a while)
Reading https://pypi.python.org/simple/
No local packages or download links found for pip==9.0.3
error: Could not find suitable distribution for Requirement.parse('pip==9.0.3')
The command '/bin/sh -c /install/install_pip_packages.sh' returned a non-zero code: 1
ERROR: docker build failed. Dockerfile is at /home/daniel/Aocoda-RC/tensorflow/tensorflow/tools/ci_build/Dockerfile.pi-python3
```
There is no Dockerfile.pi-python38 in tensorflow/tensorflow/tools/ci_build/.
```
$ tensorflow/tools/ci_build/ci_build.sh PI-PYTHON38 \
tensorflow/tools/ci_build/pi/build_raspberry_pi.sh AARCH64
Invalid Dockerfile path: "/home/daniel/Aocoda-RC/tensorflow/tensorflow/tools/ci_build/Dockerfile.pi-python38"
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62848/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62848/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62847
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62847/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62847/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62847/events
|
https://github.com/tensorflow/tensorflow/issues/62847
| 2,101,107,026 |
I_kwDOArmXAs59PFlS
| 62,847 |
[ tf-opt ] Keras Official Implementation of Stable Diffusion fails to generate stablehlo mlir
|
{
"login": "monowaranjum",
"id": 19803082,
"node_id": "MDQ6VXNlcjE5ODAzMDgy",
"avatar_url": "https://avatars.githubusercontent.com/u/19803082?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/monowaranjum",
"html_url": "https://github.com/monowaranjum",
"followers_url": "https://api.github.com/users/monowaranjum/followers",
"following_url": "https://api.github.com/users/monowaranjum/following{/other_user}",
"gists_url": "https://api.github.com/users/monowaranjum/gists{/gist_id}",
"starred_url": "https://api.github.com/users/monowaranjum/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/monowaranjum/subscriptions",
"organizations_url": "https://api.github.com/users/monowaranjum/orgs",
"repos_url": "https://api.github.com/users/monowaranjum/repos",
"events_url": "https://api.github.com/users/monowaranjum/events{/privacy}",
"received_events_url": "https://api.github.com/users/monowaranjum/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 404586594,
"node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower",
"name": "stat:awaiting tensorflower",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from tensorflower"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 1097546578,
"node_id": "MDU6TGFiZWwxMDk3NTQ2NTc4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:keras",
"name": "comp:keras",
"color": "0052cc",
"default": false,
"description": "Keras related issues"
},
{
"id": 5922361893,
"node_id": "LA_kwDOArmXAs8AAAABYQASJQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF2.14",
"name": "TF2.14",
"color": "b60205",
"default": false,
"description": "For issues related to Tensorflow 2.14.x"
}
] |
open
| false |
{
"login": "sachinprasadhs",
"id": 73069040,
"node_id": "MDQ6VXNlcjczMDY5MDQw",
"avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sachinprasadhs",
"html_url": "https://github.com/sachinprasadhs",
"followers_url": "https://api.github.com/users/sachinprasadhs/followers",
"following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}",
"gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions",
"organizations_url": "https://api.github.com/users/sachinprasadhs/orgs",
"repos_url": "https://api.github.com/users/sachinprasadhs/repos",
"events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}",
"received_events_url": "https://api.github.com/users/sachinprasadhs/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "sachinprasadhs",
"id": 73069040,
"node_id": "MDQ6VXNlcjczMDY5MDQw",
"avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sachinprasadhs",
"html_url": "https://github.com/sachinprasadhs",
"followers_url": "https://api.github.com/users/sachinprasadhs/followers",
"following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}",
"gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions",
"organizations_url": "https://api.github.com/users/sachinprasadhs/orgs",
"repos_url": "https://api.github.com/users/sachinprasadhs/repos",
"events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}",
"received_events_url": "https://api.github.com/users/sachinprasadhs/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi, is there any update on this issue? Thanks in advance.",
"Well, I checked with the latest nightly build. The issue is still there. "
] | 2024-01-25T20:19:45 | 2024-02-20T05:21:36 | null |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
source
### TensorFlow version
v2.14.0-rc1-21-g4dacf3f368e 2.14.0
### Custom code
Yes
### OS platform and distribution
Ubuntu 22.04
### Mobile device
_No response_
### Python version
3.10.12
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
After saving the diffusion model in saved_model format using the code given below, I ran the following command to convert the saved_model into an input mlir.
```
tf-mlir-translate --savedmodel-objectgraph-to-mlir --tf-savedmodel-exported-names=serving_fn ./signed-model/ -o tf_executor.mlir
```
This actually produces a large mlir file of 6.5 GB . Then I ran this:
``` tf-opt --tf-executor-graph-pruning --tf-executor-to-functional-conversion --canonicalize --tf-lower-to-mlprogram-and-hlo ./tf_executor.mlir -o stablehlo.mlir```
This process runs for a couple of minutes and ends without any error. However, in the ```stablehlo.mlir``` does not have any mlir in it. Its an empty file with the following in it: "module{}". It does not provide any error message at all.
I was expecting the second command to generate a stablehlo mlir file corresponding to the diffusion model which I could later pass on to the iree-importer for importing into iree.
### Standalone code to reproduce the issue
```shell
from keras_cv import models
from keras_cv.src.models.stable_diffusion.constants import _ALPHAS_CUMPROD
import tensorflow as tf
from keras_cv.src.backend import ops
import math
from keras_cv.models.stable_diffusion import DiffusionModel
IMG_HEIGHT = 512
IMG_WIDTH = 512
MAX_PROMPT_LENGTH = 77
ALPHAS_CUMPROD_TF = tf.constant(_ALPHAS_CUMPROD)
UNCONDITIONAL_GUIDANCE_SCALE = 7.5
HIDDEN_DIM = 768
SEED = None
signature_dict = {
"context": tf.TensorSpec(shape=[None, MAX_PROMPT_LENGTH, HIDDEN_DIM], dtype=tf.float32, name="context"),
"unconditional_context": tf.TensorSpec(
shape=[None, MAX_PROMPT_LENGTH, HIDDEN_DIM], dtype=tf.float32, name="unconditional_context"
),
"num_steps": tf.TensorSpec(shape=[], dtype=tf.int32, name="num_steps"),
"batch_size": tf.TensorSpec(shape=[], dtype=tf.int32, name="batch_size"),
}
def diffusion_model_exporter(model: tf.keras.Model):
@tf.function
def get_timestep_embedding(timestep, batch_size, dim=320, max_period=10000):
half = dim // 2
range = ops.cast(ops.arange(0, half), "float32")
freqs = ops.exp(-math.log(max_period) * range / half)
args = ops.convert_to_tensor([timestep], dtype="float32") * freqs
embedding = ops.concatenate([ops.cos(args), ops.sin(args)], 0)
embedding = ops.reshape(embedding, [1, -1])
return ops.repeat(embedding, batch_size, axis=0)
@tf.function(input_signature=[signature_dict])
def serving_fn(inputs):
img_height = tf.cast(tf.math.round(IMG_HEIGHT / 128) * 128, tf.int32)
img_width = tf.cast(tf.math.round(IMG_WIDTH / 128) * 128, tf.int32)
batch_size = inputs["batch_size"]
num_steps = inputs["num_steps"]
context = inputs["context"]
unconditional_context = inputs["unconditional_context"]
latent = tf.random.normal((batch_size, img_height // 8, img_width // 8, 4))
timesteps = tf.range(1, 1000, 1000 // num_steps)
alphas = tf.map_fn(lambda t: ALPHAS_CUMPROD_TF[t], timesteps, dtype=tf.float32)
alphas_prev = tf.concat([[1.0], alphas[:-1]], 0)
index = num_steps - 1
latent_prev = None
for timestep in timesteps[::-1]:
latent_prev = latent
t_emb = get_timestep_embedding(timestep, batch_size)
unconditional_latent = model(
[latent, t_emb, unconditional_context], training=False
)
latent = model([latent, t_emb, context], training=False)
latent = unconditional_latent + UNCONDITIONAL_GUIDANCE_SCALE * (
latent - unconditional_latent
)
a_t, a_prev = alphas[index], alphas_prev[index]
pred_x0 = (latent_prev - tf.math.sqrt(1 - a_t) * latent) / tf.math.sqrt(a_t)
latent = (
latent * tf.math.sqrt(1.0 - a_prev) + tf.math.sqrt(a_prev) * pred_x0
)
index = index - 1
return {"latent": latent}
return serving_fn
diffuser = DiffusionModel(IMG_HEIGHT, IMG_WIDTH, MAX_PROMPT_LENGTH)
tf.saved_model.save(diffuser, './stable-diffusion/signed-model', signatures={"serving_default": diffusion_model_exporter(diffuser)} )
```
### Relevant log output
_No response_
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62847/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62847/timeline
| null | null | false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62846
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62846/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62846/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62846/events
|
https://github.com/tensorflow/tensorflow/issues/62846
| 2,100,810,645 |
I_kwDOArmXAs59N9OV
| 62,846 |
test bug
|
{
"login": "venkat926",
"id": 71484818,
"node_id": "MDQ6VXNlcjcxNDg0ODE4",
"avatar_url": "https://avatars.githubusercontent.com/u/71484818?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/venkat926",
"html_url": "https://github.com/venkat926",
"followers_url": "https://api.github.com/users/venkat926/followers",
"following_url": "https://api.github.com/users/venkat926/following{/other_user}",
"gists_url": "https://api.github.com/users/venkat926/gists{/gist_id}",
"starred_url": "https://api.github.com/users/venkat926/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/venkat926/subscriptions",
"organizations_url": "https://api.github.com/users/venkat926/orgs",
"repos_url": "https://api.github.com/users/venkat926/repos",
"events_url": "https://api.github.com/users/venkat926/events{/privacy}",
"received_events_url": "https://api.github.com/users/venkat926/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 284443156,
"node_id": "MDU6TGFiZWwyODQ0NDMxNTY=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:docs-bug",
"name": "type:docs-bug",
"color": "159b2e",
"default": false,
"description": "Document issues"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
}
] |
closed
| false |
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62846\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62846\">No</a>\n"
] | 2024-01-25T16:59:51 | 2024-01-25T17:02:07 | 2024-01-25T17:02:04 |
NONE
| null | null | null |
### Issue type
Documentation Bug
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
source
### TensorFlow version
tf 2.15
### Custom code
Yes
### OS platform and distribution
_No response_
### Mobile device
_No response_
### Python version
_No response_
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
just teating
### Standalone code to reproduce the issue
```shell
tesating
```
### Relevant log output
_No response_
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62846/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62846/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62845
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62845/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62845/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62845/events
|
https://github.com/tensorflow/tensorflow/issues/62845
| 2,100,522,300 |
I_kwDOArmXAs59M208
| 62,845 |
Unsupported data type.
|
{
"login": "BenjaminWegener",
"id": 11700669,
"node_id": "MDQ6VXNlcjExNzAwNjY5",
"avatar_url": "https://avatars.githubusercontent.com/u/11700669?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/BenjaminWegener",
"html_url": "https://github.com/BenjaminWegener",
"followers_url": "https://api.github.com/users/BenjaminWegener/followers",
"following_url": "https://api.github.com/users/BenjaminWegener/following{/other_user}",
"gists_url": "https://api.github.com/users/BenjaminWegener/gists{/gist_id}",
"starred_url": "https://api.github.com/users/BenjaminWegener/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/BenjaminWegener/subscriptions",
"organizations_url": "https://api.github.com/users/BenjaminWegener/orgs",
"repos_url": "https://api.github.com/users/BenjaminWegener/repos",
"events_url": "https://api.github.com/users/BenjaminWegener/events{/privacy}",
"received_events_url": "https://api.github.com/users/BenjaminWegener/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 1661751498,
"node_id": "MDU6TGFiZWwxNjYxNzUxNDk4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TFLiteConverter",
"name": "TFLiteConverter",
"color": "bfdadc",
"default": false,
"description": "For issues related to TFLite converter"
}
] |
closed
| false |
{
"login": "SuryanarayanaY",
"id": 116063290,
"node_id": "U_kgDOBur8Og",
"avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/SuryanarayanaY",
"html_url": "https://github.com/SuryanarayanaY",
"followers_url": "https://api.github.com/users/SuryanarayanaY/followers",
"following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}",
"gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}",
"starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions",
"organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs",
"repos_url": "https://api.github.com/users/SuryanarayanaY/repos",
"events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}",
"received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "SuryanarayanaY",
"id": 116063290,
"node_id": "U_kgDOBur8Og",
"avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/SuryanarayanaY",
"html_url": "https://github.com/SuryanarayanaY",
"followers_url": "https://api.github.com/users/SuryanarayanaY/followers",
"following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}",
"gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}",
"starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions",
"organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs",
"repos_url": "https://api.github.com/users/SuryanarayanaY/repos",
"events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}",
"received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"model is converted nevertheless and runs fine, error doesn't stop conversion."
] | 2024-01-25T14:30:55 | 2024-01-25T15:12:04 | 2024-01-25T15:12:03 |
NONE
| null | null | null |
### 1. System information
- OS Platform and Distribution (e.g., Linux Ubuntu 16.04): ChomeOS linux container (fully updated) Linux penguin 6.1.60-08594-g03a802b9a072 SMP PREEMPT Fri Jan 12 18:19:39 PST 2024 aarch64 GNU/Linux (rpi5 debian stable tested also, same result)
- TensorFlow installation (pip package or built from source): pip3 Python 3.11.2 (main, Mar 13 2023, 12:18:29) [GCC 12.2.0] on linux
- TensorFlow library (version, if pip package or github SHA, if built from source): 2.15.0
### 2. Code
Provide code to help us reproduce your issues using one of the following options:
#### Option A: Reference colab notebooks
1) Reference [TensorFlow Model Colab](https://colab.research.google.com/gist/ymodak/e96a4270b953201d5362c61c1e8b78aa/tensorflow-datasets.ipynb?authuser=1): Demonstrate how to build your TF model.
https://colab.research.google.com/github/tensorflow/tensorflow/blob/master/tensorflow/lite/g3doc/examples/on_device_training/overview.ipynb
### 3. Failure after conversion
Using Colab, notebook runs as expected, running under jupyter in ChromeOS coversion fails, see section 5.
### 4. (optional) RNN conversion support
---
### 5. (optional) Any other info / logs
> INFO:tensorflow:Assets written to: saved_model/assets
INFO:tensorflow:Assets written to: saved_model/assets
WARNING:absl:Importing a function (__inference_internal_grad_fn_55651) with ops with unsaved custom gradients. Will likely fail if a gradient is requested.
WARNING:absl:Importing a function (__inference_internal_grad_fn_55678) with ops with unsaved custom gradients. Will likely fail if a gradient is requested.
2024-01-25 15:21:06.557730: W tensorflow/compiler/mlir/lite/python/tf_tfl_flatbuffer_helpers.cc:378] Ignored output_format.
2024-01-25 15:21:06.557979: W tensorflow/compiler/mlir/lite/python/tf_tfl_flatbuffer_helpers.cc:381] Ignored drop_control_dependency.
2024-01-25 15:21:06.558694: I tensorflow/cc/saved_model/reader.cc:83] Reading SavedModel from: saved_model
2024-01-25 15:21:06.564590: I tensorflow/cc/saved_model/reader.cc:51] Reading meta graph with tags { serve }
2024-01-25 15:21:06.564844: I tensorflow/cc/saved_model/reader.cc:146] Reading SavedModel debug info (if present) from: saved_model
2024-01-25 15:21:06.580002: I tensorflow/cc/saved_model/loader.cc:233] Restoring SavedModel bundle.
2024-01-25 15:21:06.698809: I tensorflow/cc/saved_model/loader.cc:217] Running initialization op on SavedModel bundle at path: saved_model
2024-01-25 15:21:06.774244: I tensorflow/cc/saved_model/loader.cc:316] SavedModel load for tags { serve }; Status: success: OK. Took 215566 microseconds.
2024-01-25 15:21:07.459350: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.459685: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.459769: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.459855: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.459911: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.459953: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.460003: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.460042: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.460088: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.460150: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.460200: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.460247: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.460293: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.460421: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.460486: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.460595: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.460646: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.460686: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.460732: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.460769: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.460846: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.460930: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.460981: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.461021: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.461066: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.461103: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.461175: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.461250: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.461293: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.461337: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.461374: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.461416: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.461451: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.461492: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
2024-01-25 15:21:07.461577: E tensorflow/compiler/mlir/lite/stablehlo/transforms/op_stat_pass.cc:119] Unsupported data type.
Summary on the non-converted ops:
---------------------------------
> * Accepted dialects: tfl, builtin, func
> * Non-Converted Ops: 33, Total Ops 198, % non-converted = 16.67 %
> * 26 ARITH ops, 6 TF ops, 1 TF_SAVED_MODEL ops
>- arith.constant: 26 occurrences (: 5, i64: 2, f32: 11, i32: 8)
>- tf.ReluGrad: 1 occurrences (f32: 1)
>- tf.Restore: 4 occurrences (f32: 4)
>- tf.Save: 1 occurrences
>- tf_saved_model.session_initializer: 1 occurrences
> (i64: 1, f32: 12)
> (f32: 6)
> (f32: 1)
> (i32: 2)
> (f32: 2)
> (i1: 2)
> (f32: 1)
> (f32: 1)
> (f32: 1)
> (f32: 10)
> (f32: 5)
> (i64: 1, f32: 24)
> (i32: 1)
> (f32: 8)
> (f32: 2)
> (f32: 1)
> (i32: 4)
> (i32: 3)
> (f32: 2)
> (f32: 1)
> (f32: 4)
> (f32: 2)
> (: 30)
>2024-01-25 15:21:07.492189: W tensorflow/compiler/mlir/lite/flatbuffer_export.cc:2921] TFLite interpreter needs to link Flex >delegate in order to run the model since it contains the following Select TFop(s):
>Flex ops: FlexReluGrad, FlexRestore, FlexSave
>Details:
> tf.ReluGrad(tensor<?x128xf32>, tensor<?x128xf32>) -> (tensor<?x128xf32>) : {device = ""}
> tf.Restore(tensor<!tf_type.string>, tensor<!tf_type.string>) -> (tensor<10xf32>) : {device = "", preferred_shard = -1 : i64}
> tf.Restore(tensor<!tf_type.string>, tensor<!tf_type.string>) -> (tensor<128x10xf32>) : {device = "", preferred_shard = -1 : i64}
> tf.Restore(tensor<!tf_type.string>, tensor<!tf_type.string>) -> (tensor<128xf32>) : {device = "", preferred_shard = -1 : i64}
> tf.Restore(tensor<!tf_type.string>, tensor<!tf_type.string>) -> (tensor<784x128xf32>) : {device = "", preferred_shard = -1 : i64}
> tf.Save(tensor<!tf_type.string>, tensor<4x!tf_type.string>, tensor<784x128xf32>, tensor<128xf32>, tensor<128x10xf32>, >tensor<10xf32>) -> () : {device = ""}
>See instructions: https://www.tensorflow.org/lite/guide/ops_select
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62845/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62845/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62844
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62844/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62844/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62844/events
|
https://github.com/tensorflow/tensorflow/pull/62844
| 2,100,210,846 |
PR_kwDOArmXAs5lDk2x
| 62,844 |
[ROCm] Tensorflow build fixes
|
{
"login": "draganmladjenovic",
"id": 37329008,
"node_id": "MDQ6VXNlcjM3MzI5MDA4",
"avatar_url": "https://avatars.githubusercontent.com/u/37329008?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/draganmladjenovic",
"html_url": "https://github.com/draganmladjenovic",
"followers_url": "https://api.github.com/users/draganmladjenovic/followers",
"following_url": "https://api.github.com/users/draganmladjenovic/following{/other_user}",
"gists_url": "https://api.github.com/users/draganmladjenovic/gists{/gist_id}",
"starred_url": "https://api.github.com/users/draganmladjenovic/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/draganmladjenovic/subscriptions",
"organizations_url": "https://api.github.com/users/draganmladjenovic/orgs",
"repos_url": "https://api.github.com/users/draganmladjenovic/repos",
"events_url": "https://api.github.com/users/draganmladjenovic/events{/privacy}",
"received_events_url": "https://api.github.com/users/draganmladjenovic/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 987666414,
"node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull",
"name": "ready to pull",
"color": "2cd643",
"default": false,
"description": "PR ready for merge process"
},
{
"id": 1097547538,
"node_id": "MDU6TGFiZWwxMDk3NTQ3NTM4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:gpu",
"name": "comp:gpu",
"color": "0052cc",
"default": false,
"description": "GPU related issues"
},
{
"id": 1169364259,
"node_id": "MDU6TGFiZWwxMTY5MzY0MjU5",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS",
"name": "size:XS",
"color": "adafea",
"default": false,
"description": "CL Change Size: Extra Small"
}
] |
closed
| false |
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[] | 2024-01-25T11:44:49 | 2024-01-30T06:39:46 | 2024-01-30T06:39:46 |
CONTRIBUTOR
| null | false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62844",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62844",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62844.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62844.patch",
"merged_at": "2024-01-30T06:39:46"
}
| null |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62844/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62844/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62843
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62843/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62843/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62843/events
|
https://github.com/tensorflow/tensorflow/issues/62843
| 2,099,924,136 |
I_kwDOArmXAs59Kkyo
| 62,843 |
TFLite Converter (MLIR) cannot correctly generate graph for Dense layer with input rank 3
|
{
"login": "hayhan",
"id": 45869898,
"node_id": "MDQ6VXNlcjQ1ODY5ODk4",
"avatar_url": "https://avatars.githubusercontent.com/u/45869898?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/hayhan",
"html_url": "https://github.com/hayhan",
"followers_url": "https://api.github.com/users/hayhan/followers",
"following_url": "https://api.github.com/users/hayhan/following{/other_user}",
"gists_url": "https://api.github.com/users/hayhan/gists{/gist_id}",
"starred_url": "https://api.github.com/users/hayhan/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/hayhan/subscriptions",
"organizations_url": "https://api.github.com/users/hayhan/orgs",
"repos_url": "https://api.github.com/users/hayhan/repos",
"events_url": "https://api.github.com/users/hayhan/events{/privacy}",
"received_events_url": "https://api.github.com/users/hayhan/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 1661751498,
"node_id": "MDU6TGFiZWwxNjYxNzUxNDk4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TFLiteConverter",
"name": "TFLiteConverter",
"color": "bfdadc",
"default": false,
"description": "For issues related to TFLite converter"
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
closed
| false |
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"@hayhan Could you verify if the values in the empty shape tensor should be [1, -1] (assuming batch size 1 and dynamic sequence length)? If so, manually setting these values after conversion might resolve the issue?\r\nAlso try to refer to custom TFLite delegates that handle rank 3 inputs for Dense layers more efficiently.\r\nThank you!",
"@sushreebarsa Thanks for your comment and suggestions. After some investigation, I realized my issue can be fixed by saving the SavedModel with signatures before the converting. I had some signature configuration issue several days ago. Now it's done. Thank you again.\r\n\r\n----------------\r\nmodel.save(path_to_model, save_format='tf', signatures=signatures)\r\ntf.lite.TFLiteConverter.from_saved_model(path_to_model)\r\ntflite_model = converter.convert()\r\n...\r\n"
] | 2024-01-25T09:16:39 | 2024-01-30T09:11:24 | 2024-01-30T09:11:23 |
NONE
| null | null | null |
### 1. System information
- OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Ubuntu 20.04
- TensorFlow installation (pip package or built from source): pip
- TensorFlow library (version, if pip package or github SHA, if built from source): 2.15.0
### 2. Code
https://gist.github.com/hayhan/7cc157f0b8542cf84b53c2bbaf014dd1
### 3. Failure after conversion
A simple example model can present the issue. See the code link above. Input with rank 2 --> Embedding layer (output rank 3) --> Dense layer. The generated node for Dense layer is broken into several raw OPs. Pay attention to the Reshape OP in the red circle. The shape tensor in this node is int32[2] **BUT no data in it**. When TFLite interpreter loads / builds tensors for the TFLite model, it thinks this shape tensor is dynamic sized and refuses to delegate the corresponding Reshape OP using XNNPACK. The 3rd vendor inference HW will do similar thing as XNNPACK does, so no HW accelerations.
I found the old Converter (TOCO) has no such issue by adding two options (in version 2.15.0) below before converting. It generates the expected graph but has deprecated warnings. See the attached snapshot.
/////////////
converter.experimental_new_converter = False
converter.experimental_new_quantizer = False
If the issue happens at the model input, e.g. rank 3 input to Dense layer at the very 1st layer, I can workaround the issue by using signature/concrete_functions (set batch size to 1) when initializing the converter. But if the issue happens at other positions in the model, e.g. BERT model, the workaround will not work.
concrete_func.inputs[0].set_shape([**1**, 5, 4])
Is this a real issue or did I miss something to correctly using the TFLite Converter (MLIR)?
**TFLite graph (MLIR, with 2.15.0)**

**TFLite graph (TOCO, with 2.15.0)**

Thanks
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62843/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62843/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62842
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62842/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62842/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62842/events
|
https://github.com/tensorflow/tensorflow/pull/62842
| 2,099,090,885 |
PR_kwDOArmXAs5k_yih
| 62,842 |
Update broken link in documentation
|
{
"login": "justindhillon",
"id": 145078271,
"node_id": "U_kgDOCKW3_w",
"avatar_url": "https://avatars.githubusercontent.com/u/145078271?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/justindhillon",
"html_url": "https://github.com/justindhillon",
"followers_url": "https://api.github.com/users/justindhillon/followers",
"following_url": "https://api.github.com/users/justindhillon/following{/other_user}",
"gists_url": "https://api.github.com/users/justindhillon/gists{/gist_id}",
"starred_url": "https://api.github.com/users/justindhillon/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/justindhillon/subscriptions",
"organizations_url": "https://api.github.com/users/justindhillon/orgs",
"repos_url": "https://api.github.com/users/justindhillon/repos",
"events_url": "https://api.github.com/users/justindhillon/events{/privacy}",
"received_events_url": "https://api.github.com/users/justindhillon/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 390482148,
"node_id": "MDU6TGFiZWwzOTA0ODIxNDg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/awaiting%20review",
"name": "awaiting review",
"color": "bc3869",
"default": false,
"description": "Pull request awaiting review"
},
{
"id": 987666414,
"node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull",
"name": "ready to pull",
"color": "2cd643",
"default": false,
"description": "PR ready for merge process"
},
{
"id": 1169364259,
"node_id": "MDU6TGFiZWwxMTY5MzY0MjU5",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS",
"name": "size:XS",
"color": "adafea",
"default": false,
"description": "CL Change Size: Extra Small"
}
] |
closed
| false |
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).\n\nView this [failed invocation](https://github.com/tensorflow/tensorflow/pull/62842/checks?check_run_id=20834329205) of the CLA check for more information.\n\nFor the most up to date status, view the checks section at the bottom of the pull request.",
"Hi @mihaimaruseac Can you please review this PR ? Thank you!"
] | 2024-01-24T20:57:35 | 2024-02-29T19:29:27 | 2024-02-29T19:29:27 |
CONTRIBUTOR
| null | false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62842",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62842",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62842.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62842.patch",
"merged_at": "2024-02-29T19:29:27"
}
|
In ```tensorflow/examples/speech_commands/train.py``` there is a broken link https://aiyprojects.withgoogle.com/open_speech_recording. According to the [internet archive](https://web.archive.org/web/20210402001315/https://aiyprojects.withgoogle.com/open_speech_recording), this has been a broken link since April 2022.
I have replaced the broken link with the Google Blog post about the dataset: https://blog.research.google/2017/08/launching-speech-commands-dataset.html/
This broken link was found with [link-inspector](https://github.com/justindhillon/link-inspector). If you find this useful, please give the repo a :star:
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62842/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62842/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62841
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62841/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62841/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62841/events
|
https://github.com/tensorflow/tensorflow/issues/62841
| 2,098,759,597 |
I_kwDOArmXAs59GIet
| 62,841 |
Build Error when installing dm-tree on Docker
|
{
"login": "mahrukhS",
"id": 66876079,
"node_id": "MDQ6VXNlcjY2ODc2MDc5",
"avatar_url": "https://avatars.githubusercontent.com/u/66876079?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/mahrukhS",
"html_url": "https://github.com/mahrukhS",
"followers_url": "https://api.github.com/users/mahrukhS/followers",
"following_url": "https://api.github.com/users/mahrukhS/following{/other_user}",
"gists_url": "https://api.github.com/users/mahrukhS/gists{/gist_id}",
"starred_url": "https://api.github.com/users/mahrukhS/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/mahrukhS/subscriptions",
"organizations_url": "https://api.github.com/users/mahrukhS/orgs",
"repos_url": "https://api.github.com/users/mahrukhS/repos",
"events_url": "https://api.github.com/users/mahrukhS/events{/privacy}",
"received_events_url": "https://api.github.com/users/mahrukhS/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 404586594,
"node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower",
"name": "stat:awaiting tensorflower",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from tensorflower"
},
{
"id": 473173351,
"node_id": "MDU6TGFiZWw0NzMxNzMzNTE=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:build/install",
"name": "type:build/install",
"color": "159b2e",
"default": false,
"description": "Build and install issues"
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
open
| false |
{
"login": "sachinprasadhs",
"id": 73069040,
"node_id": "MDQ6VXNlcjczMDY5MDQw",
"avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sachinprasadhs",
"html_url": "https://github.com/sachinprasadhs",
"followers_url": "https://api.github.com/users/sachinprasadhs/followers",
"following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}",
"gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions",
"organizations_url": "https://api.github.com/users/sachinprasadhs/orgs",
"repos_url": "https://api.github.com/users/sachinprasadhs/repos",
"events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}",
"received_events_url": "https://api.github.com/users/sachinprasadhs/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "sachinprasadhs",
"id": 73069040,
"node_id": "MDQ6VXNlcjczMDY5MDQw",
"avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sachinprasadhs",
"html_url": "https://github.com/sachinprasadhs",
"followers_url": "https://api.github.com/users/sachinprasadhs/followers",
"following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}",
"gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions",
"organizations_url": "https://api.github.com/users/sachinprasadhs/orgs",
"repos_url": "https://api.github.com/users/sachinprasadhs/repos",
"events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}",
"received_events_url": "https://api.github.com/users/sachinprasadhs/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"~~dm-tree has no 3.12 wheels right now, but~~ as the error message says, installing CMake should allow for it to be built during installation.",
"I removed **pip3 install dm-tree** from `install_pip_packages.sh` since `dockerfile.cpu` has cmake command. The build is completed, as I can see in the docker desktop build \"a completed build\". However, will removing **pip3 install dm-tree** will result in accurate sanity check?"
] | 2024-01-24T17:32:58 | 2024-01-29T17:52:11 | null |
NONE
| null | null | null |
### Issue type
Build/Install
### Have you reproduced the bug with TensorFlow Nightly?
No
### Source
binary
### TensorFlow version
2.15.0
### Custom code
No
### OS platform and distribution
Windows 11 Pro (Host), Docker container based on ubuntu:16.04
### Mobile device
_No response_
### Python version
3.11.6
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
**Steps to reproduce the error:**
1. Forked the TensorFlow master branch from the [TensorFlow GitHub repository](https://github.com/tensorflow/tensorflow).
2. Created a new branch within a GitHub workspace for making changes and running tests.
3. Attempted to run the TensorFlow Continuous Integration (CI) tests locally on a Windows machine using Docker, from the `/workspaces/tensorflow/` directory.
4. Executed the command `./tensorflow/tools/ci_build/ci_build.sh CPU ./tensorflow/tools/ci_build/ci_sanity.sh` to start the sanity check process.
5. Modified `Dockerfile.cpu` to ensure all script files use LF line endings and to set up the environment correctly.
6. Encountered errors when reaching the `RUN pip install packages` step within the `install_pip_packages.sh` script, specifically on the line `pip3 install dm-tree`.
7. Resolved several issues within `install_pip_packages.sh`, but hit a snag on installing `dm-tree`
### Standalone code to reproduce the issue
```shell
Updated `install_pip_packages.sh` as follows:
#!/usr/bin/env bash
# Copyright 2015 The TensorFlow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# ==============================================================================
set -e
# Get the latest version of pip so it recognize manylinux2010
#wget https://bootstrap.pypa.io/get-pip.py
wget https://bootstrap.pypa.io/pip/3.5/get-pip.py
python3 get-pip.py
#python3.6 get-pip.py
rm -f get-pip.py
# Install pip packages from whl files to avoid the time-consuming process of
# building from source.
# Pin wheel==0.31.1 to work around issue
# https://github.com/pypa/auditwheel/issues/102
pip3 install wheel==0.31.1
# Install last working version of setuptools. This must happen before we install
# absl-py, which uses install_requires notation introduced in setuptools 20.5.
pip3 install --upgrade setuptools==39.1.0
pip3 install virtualenv
# Install six and future.
pip3 install --upgrade six==1.12.0
pip3 install "future>=0.17.1"
# Install absl-py.
pip3 install --upgrade absl-py
# Install werkzeug.
pip3 install --upgrade werkzeug==0.11.10
# Install bleach. html5lib will be picked up as a dependency.
pip3 install --upgrade bleach==2.0.0
# Install markdown.
pip3 install --upgrade markdown==2.6.8
# Install protobuf.
pip3 install --upgrade protobuf==3.16.0
# Remove obsolete version of six, which can sometimes confuse virtualenv.
rm -rf /usr/lib/python3/dist-packages/six*
# numpy needs to be installed from source to fix segfaults. See:
# https://github.com/tensorflow/tensorflow/issues/6968
# This workaround isn't needed for Ubuntu 16.04 or later.
if $(cat /etc/*-release | grep -q 14.04); then
pip3 install --upgrade numpy==1.14.5
else
pip3 install --upgrade numpy
fi
pip3 install scipy==1.4.1
pip3 install scikit-learn==0.18.1
# pandas required by `inflow`
pip3 install pandas==0.19.2
# Benchmark tests require the following:
pip3 install psutil
pip3 install py-cpuinfo
# pylint tests require the following version. pylint==1.6.4 hangs erratically,
# thus using the updated version of 2.5.3 only for python3 as python2 is EOL
# and this version is not available.
pip3 install pylint
# pycodestyle tests require the following:
pip3 install pycodestyle
pip3 install portpicker
# TensorFlow Serving integration tests require the following:
pip3 install grpcio
# Eager-to-graph execution needs astor, gast and termcolor:
pip3 install --upgrade astor
pip3 install --upgrade gast
pip3 install --upgrade termcolor
# Keras
pip3 install keras-nightly --no-deps
pip3 install --upgrade h5py
# Tensorboard
pip3 install tb-nightly --no-deps
# Argparse
pip3 install --upgrade argparse
# tree
pip3 install dm-tree
# tf.distribute multi worker tests require the following:
# Those tests are Python3 only.
pip3 install --upgrade dill
pip3 install --upgrade tblib
```
### Relevant log output
```shell
Collecting dm-tree
Downloading dm-tree-0.1.8.tar.gz (35 kB)
ERROR: Command errored out with exit status 1:
command: /usr/bin/python3 -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-lckm23fj/dm-tree_90fde797f8754ad2a98f0dc019c4e599/setup.py'"'"'; __file__='"'"'/tmp/pip-install-lckm23fj/dm-tree_90fde797f8754ad2a98f0dc019c4e599/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-6h1yywpk
cwd: /tmp/pip-install-lckm23fj/dm-tree_90fde797f8754ad2a98f0dc019c4e599/
Complete output (6 lines):
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-install-lckm23fj/dm-tree_90fde797f8754ad2a98f0dc019c4e599/setup.py", line 81
f'CMake must be installed to build the following extensions: {ext_names}'
^
SyntaxError: invalid syntax
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/f8/6d/f1997aac42e0f550c1e952a0b920eaa0bfc4d27d0421499881b934b969fc/dm-tree-0.1.8.tar.gz#sha256=0fcaabbb14e7980377439e7140bd05552739ca5e515ecb3119f234acee4b9430 (from https://pypi.org/simple/dm-tree/). Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
Downloading dm-tree-0.1.7.tar.gz (35 kB)
ERROR: Command errored out with exit status 1:
command: /usr/bin/python3 -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-lckm23fj/dm-tree_8093f3e005e944759a173287c4759d86/setup.py'"'"'; __file__='"'"'/tmp/pip-install-lckm23fj/dm-tree_8093f3e005e944759a173287c4759d86/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-uazji85z
cwd: /tmp/pip-install-lckm23fj/dm-tree_8093f3e005e944759a173287c4759d86/
Complete output (6 lines):
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-install-lckm23fj/dm-tree_8093f3e005e944759a173287c4759d86/setup.py", line 81
f'CMake must be installed to build the following extensions: {ext_names}'
^
SyntaxError: invalid syntax
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/1c/ed/a9848a5d3dff0fc5c9c6f5120ae98c152ff47700a731958ff034a576ee27/dm-tree-0.1.7.tar.gz#sha256=30fec8aca5b92823c0e796a2f33b875b4dccd470b57e91e6c542405c5f77fd2a (from https://pypi.org/simple/dm-tree/). Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
Downloading dm-tree-0.1.6.tar.gz (33 kB)
Requirement already satisfied: six>=1.12.0 in /usr/local/lib/python3.5/dist-packages (from dm-tree) (1.12.0)
Building wheels for collected packages: dm-tree
Building wheel for dm-tree (setup.py): started
Building wheel for dm-tree (setup.py): finished with status 'error'
ERROR: Command errored out with exit status 1:
command: /usr/bin/python3 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-lckm23fj/dm-tree_70352c37b8984f0f92e3dca56fbee6a5/setup.py'"'"'; __file__='"'"'/tmp/pip-install-lckm23fj/dm-tree_70352c37b8984f0f92e3dca56fbee6a5/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d /tmp/pip-wheel-4iudh8hy
cwd: /tmp/pip-install-lckm23fj/dm-tree_70352c37b8984f0f92e3dca56fbee6a5/
Complete output (32 lines):
/usr/lib/python3.5/distutils/dist.py:261: UserWarning: Unknown distribution option: 'long_description_content_type'
warnings.warn(msg)
running bdist_wheel
running build
running build_py
creating build
creating build/lib.linux-x86_64-3.5
creating build/lib.linux-x86_64-3.5/tree
copying tree/tree_test.py -> build/lib.linux-x86_64-3.5/tree
copying tree/__init__.py -> build/lib.linux-x86_64-3.5/tree
copying tree/tree_benchmark.py -> build/lib.linux-x86_64-3.5/tree
running build_ext
bazel build //tree:_tree --symlink_prefix=build/temp.linux-x86_64-3.5/bazel- --compilation_mode=opt
Extracting Bazel installation...
Starting local Bazel server and connecting to it...
Loading:
Loading:
Loading:
Loading: 0 packages loaded
Loading: 0 packages loaded
currently loading: tree
Loading: 0 packages loaded
currently loading: tree
Analyzing: target //tree:_tree (1 packages loaded, 0 targets configured)
ERROR: /root/.cache/bazel/_bazel_root/3f0a395690e111f9618f699b5feff3a0/external/bazel_tools/platforms/BUILD:89:6: in alias rule @bazel_tools//platforms:windows: Constraints from @bazel_tools//platforms have been removed. Please use constraints from @platforms repository embedded in Bazel, or preferably declare dependency on https://github.com/bazelbuild/platforms. See https://github.com/bazelbuild/bazel/issues/8622 for details.
ERROR: /root/.cache/bazel/_bazel_root/3f0a395690e111f9618f699b5feff3a0/external/bazel_tools/platforms/BUILD:89:6: Analysis of target '@bazel_tools//platforms:windows' failed
ERROR: /tmp/pip-install-lckm23fj/dm-tree_70352c37b8984f0f92e3dca56fbee6a5/tree/BUILD:27:18: errors encountered resolving select() keys for //tree:_tree
ERROR: Analysis of target '//tree:_tree' failed; build aborted:
INFO: Elapsed time: 14.615s
INFO: 0 processes.
FAILED: Build did NOT complete successfully (6 packages loaded, 7 targets configured)
error: command 'bazel' failed with exit status 1
----------------------------------------
ERROR: Failed building wheel for dm-tree
Running setup.py clean for dm-tree
Failed to build dm-tree
Installing collected packages: dm-tree
Running setup.py install for dm-tree: started
Running setup.py install for dm-tree: finished with status 'error'
ERROR: Command errored out with exit status 1:
command: /usr/bin/python3 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-lckm23fj/dm-tree_70352c37b8984f0f92e3dca56fbee6a5/setup.py'"'"'; __file__='"'"'/tmp/pip-install-lckm23fj/dm-tree_70352c37b8984f0f92e3dca56fbee6a5/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /tmp/pip-record-09ok4qc1/install-record.txt --single-version-externally-managed --compile --install-headers /usr/local/include/python3.5/dm-tree
cwd: /tmp/pip-install-lckm23fj/dm-tree_70352c37b8984f0f92e3dca56fbee6a5/
Complete output (25 lines):
/usr/lib/python3.5/distutils/dist.py:261: UserWarning: Unknown distribution option: 'long_description_content_type'
warnings.warn(msg)
running install
running build
running build_py
creating build
creating build/lib.linux-x86_64-3.5
creating build/lib.linux-x86_64-3.5/tree
copying tree/tree_test.py -> build/lib.linux-x86_64-3.5/tree
copying tree/__init__.py -> build/lib.linux-x86_64-3.5/tree
copying tree/tree_benchmark.py -> build/lib.linux-x86_64-3.5/tree
running build_ext
bazel build //tree:_tree --symlink_prefix=build/temp.linux-x86_64-3.5/bazel- --compilation_mode=opt
Loading:
Loading:
Loading: 0 packages loaded
Analyzing: target //tree:_tree (0 packages loaded, 0 targets configured)
ERROR: /root/.cache/bazel/_bazel_root/3f0a395690e111f9618f699b5feff3a0/external/bazel_tools/platforms/BUILD:89:6: in alias rule @bazel_tools//platforms:windows: Constraints from @bazel_tools//platforms have been removed. Please use constraints from @platforms repository embedded in Bazel, or preferably declare dependency on https://github.com/bazelbuild/platforms. See https://github.com/bazelbuild/bazel/issues/8622 for details.
ERROR: /root/.cache/bazel/_bazel_root/3f0a395690e111f9618f699b5feff3a0/external/bazel_tools/platforms/BUILD:89:6: Analysis of target '@bazel_tools//platforms:windows' failed
ERROR: /tmp/pip-install-lckm23fj/dm-tree_70352c37b8984f0f92e3dca56fbee6a5/tree/BUILD:27:18: errors encountered resolving select() keys for //tree:_tree
ERROR: Analysis of target '//tree:_tree' failed; build aborted:
INFO: Elapsed time: 0.662s
INFO: 0 processes.
FAILED: Build did NOT complete successfully (0 packages loaded, 0 targets configured)
error: command 'bazel' failed with exit status 1
----------------------------------------
ERROR: Command errored out with exit status 1: /usr/bin/python3 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-lckm23fj/dm-tree_70352c37b8984f0f92e3dca56fbee6a5/setup.py'"'"'; __file__='"'"'/tmp/pip-install-lckm23fj/dm-tree_70352c37b8984f0f92e3dca56fbee6a5/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /tmp/pip-record-09ok4qc1/install-record.txt --single-version-externally-managed --compile --install-headers /usr/local/include/python3.5/dm-tree Check the logs for full command output
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62841/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62841/timeline
| null | null | false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62840
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62840/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62840/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62840/events
|
https://github.com/tensorflow/tensorflow/issues/62840
| 2,098,669,912 |
I_kwDOArmXAs59FylY
| 62,840 |
tflite RNN model invoke failed with "num_input_elements != num_output_elements (4288 != 64)Node number 18 (RESHAPE) failed to prepare.Node number 5 (WHILE) failed to invoke."
|
{
"login": "YuriSizuku",
"id": 15275959,
"node_id": "MDQ6VXNlcjE1Mjc1OTU5",
"avatar_url": "https://avatars.githubusercontent.com/u/15275959?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/YuriSizuku",
"html_url": "https://github.com/YuriSizuku",
"followers_url": "https://api.github.com/users/YuriSizuku/followers",
"following_url": "https://api.github.com/users/YuriSizuku/following{/other_user}",
"gists_url": "https://api.github.com/users/YuriSizuku/gists{/gist_id}",
"starred_url": "https://api.github.com/users/YuriSizuku/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/YuriSizuku/subscriptions",
"organizations_url": "https://api.github.com/users/YuriSizuku/orgs",
"repos_url": "https://api.github.com/users/YuriSizuku/repos",
"events_url": "https://api.github.com/users/YuriSizuku/events{/privacy}",
"received_events_url": "https://api.github.com/users/YuriSizuku/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 750616506,
"node_id": "MDU6TGFiZWw3NTA2MTY1MDY=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite",
"name": "comp:lite",
"color": "0052cc",
"default": false,
"description": "TF Lite related issues"
},
{
"id": 1661751498,
"node_id": "MDU6TGFiZWwxNjYxNzUxNDk4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TFLiteConverter",
"name": "TFLiteConverter",
"color": "bfdadc",
"default": false,
"description": "For issues related to TFLite converter"
},
{
"id": 4511033337,
"node_id": "LA_kwDOArmXAs8AAAABDODn-Q",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.10",
"name": "TF 2.10",
"color": "C15088",
"default": false,
"description": ""
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
open
| false |
{
"login": "pkgoogle",
"id": 132095473,
"node_id": "U_kgDOB9-d8Q",
"avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/pkgoogle",
"html_url": "https://github.com/pkgoogle",
"followers_url": "https://api.github.com/users/pkgoogle/followers",
"following_url": "https://api.github.com/users/pkgoogle/following{/other_user}",
"gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}",
"starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions",
"organizations_url": "https://api.github.com/users/pkgoogle/orgs",
"repos_url": "https://api.github.com/users/pkgoogle/repos",
"events_url": "https://api.github.com/users/pkgoogle/events{/privacy}",
"received_events_url": "https://api.github.com/users/pkgoogle/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "pkgoogle",
"id": 132095473,
"node_id": "U_kgDOB9-d8Q",
"avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/pkgoogle",
"html_url": "https://github.com/pkgoogle",
"followers_url": "https://api.github.com/users/pkgoogle/followers",
"following_url": "https://api.github.com/users/pkgoogle/following{/other_user}",
"gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}",
"starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions",
"organizations_url": "https://api.github.com/users/pkgoogle/orgs",
"repos_url": "https://api.github.com/users/pkgoogle/repos",
"events_url": "https://api.github.com/users/pkgoogle/events{/privacy}",
"received_events_url": "https://api.github.com/users/pkgoogle/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi @pkgoogle,\r\n\r\nI am trying to reproduce the issue, meanwhile i got a similar Runtime error related to Batch MATMUL. Here is the screenshot. Please take a look.\r\n\r\n\r\n\r\nThank You",
"I was able to replicate both (the difference is the versions), I was also able to replicate the BATCH_MATMUL issue on [tf-nightly](https://colab.sandbox.google.com/gist/pkgoogle/d121bc1945adb3e953ba322093a429e3/62840.ipynb). @yijie-yang, can you please take a look? Thanks.",
"I have encountered a similar problem. Does anyone know the reason and how to solve it? thank you.",
"Hi @YuriSizuku, we now have a PyTorch conversion library, [AI-Edge-Torch](https://github.com/google-ai-edge/ai-edge-torch), you can find more information here: [googleblog](https://developers.googleblog.com/en/ai-edge-torch-high-performance-inference-of-pytorch-models-on-mobile-devices/).\r\n\r\nI have actually created a simple script for converting an rnn model here:\r\n\r\n```py\r\nimport torch\r\nfrom torch import nn\r\nimport ai_edge_torch\r\n\r\nrnn = nn.RNN(10, 20, 2)\r\nsample_inputs = (torch.randn(5, 3, 10),)\r\n\r\nedge_model = ai_edge_torch.convert(rnn.eval(), sample_inputs)\r\nsample_outputs = edge_model(*sample_inputs)\r\nprint(sample_outputs)\r\n```\r\n\r\nexample output:\r\n```sh\r\nINFO: Created TensorFlow Lite XNNPACK delegate for CPU.\r\n[array([[[ 0.2431118 , 0.06235815, 0.00344649, 0.17776804,\r\n 0.23679167, -0.0288435 , -0.10046795, -0.15170264,\r\n 0.01992229, 0.03517441, -0.17016807, -0.07532725,\r\n -0.23639274, -0.06456912, 0.15550321, 0.08035061,\r\n 0.02570525, -0.40846297, -0.18534435, 0.16825229],\r\n [-0.18317065, 0.05966392, -0.20141582, -0.07385322,\r\n -0.28243184, 0.05996443, 0.26688445, -0.211288 ,\r\n -0.33300522, -0.04353373, -0.3800146 , 0.0406212 ,\r\n 0.05183808, 0.06664597, 0.2945734 , 0.49857348,\r\n -0.21562281, -0.25770244, -0.3131145 , -0.03460141],\r\n [-0.16695906, 0.21162465, -0.24315475, 0.00936348,\r\n -0.02764254, 0.20015398, 0.44777521, -0.21858564,\r\n 0.00373377, -0.38817146, -0.5333292 , 0.19483805,\r\n -0.16324732, -0.20361441, 0.22146665, -0.22068164,\r\n -0.24459498, -0.09547581, 0.14915003, -0.05483112]],\r\n\r\n [[-0.23323143, 0.41526547, 0.00867236, -0.06482001,\r\n -0.13521166, 0.4930158 , 0.56015074, -0.01654232,\r\n 0.28613555, -0.5156335 , -0.2693312 , -0.05591698,\r\n -0.39816546, 0.07836445, 0.1378024 , -0.09236679,\r\n -0.27620402, -0.4739875 , -0.06223845, 0.45140594],\r\n [ 0.14702684, 0.43046153, -0.18450318, 0.42295033,\r\n -0.03423792, 0.35017267, -0.05320767, -0.00685967,\r\n 0.13445464, -0.33456326, -0.30643368, -0.17181066,\r\n 0.02008791, 0.23411715, -0.00245866, -0.10255101,\r\n 0.3132771 , 0.15635973, -0.06194769, 0.49516347],\r\n [-0.19756572, 0.26787412, -0.3043269 , -0.03941626,\r\n 0.11208605, 0.23174919, 0.23688109, 0.08590817,\r\n 0.21840666, 0.03197437, 0.07209112, -0.23433073,\r\n 0.32314724, -0.05348776, 0.58448607, 0.42427984,\r\n -0.15630008, -0.29558602, -0.14623547, 0.1060374 ]],\r\n\r\n [[-0.14445083, 0.2898361 , 0.23752378, -0.26255518,\r\n 0.53153807, 0.49530193, 0.19309106, 0.0822446 ,\r\n 0.6192373 , -0.2987862 , -0.07411999, -0.0056248 ,\r\n -0.34401622, -0.02621307, 0.5500692 , -0.01893932,\r\n -0.2982351 , -0.33952028, -0.13640165, -0.02855544],\r\n [-0.00369995, 0.17526105, -0.07810821, 0.3482869 ,\r\n -0.04704977, -0.12569617, 0.5545775 , -0.21356013,\r\n 0.14047596, -0.4543471 , -0.03457044, 0.10925914,\r\n -0.09207486, -0.01040453, -0.0659247 , -0.33523113,\r\n 0.08538487, -0.1200012 , -0.33902514, 0.04560279],\r\n [-0.10175765, 0.40730628, -0.1265934 , 0.26016185,\r\n -0.12017653, -0.01349099, 0.6028484 , -0.23501587,\r\n -0.04607139, -0.5135092 , -0.38583383, 0.39900216,\r\n -0.14994566, -0.18539993, -0.15845336, -0.17449719,\r\n -0.24278656, -0.44319314, -0.0409166 , 0.30520165]],\r\n\r\n [[-0.23232898, 0.08625392, -0.07340918, 0.06319071,\r\n -0.11097958, 0.02782956, -0.03228264, -0.15964286,\r\n 0.28856406, 0.13909867, 0.38994902, -0.5045144 ,\r\n -0.06314449, -0.16901886, 0.34486222, 0.7810114 ,\r\n -0.39775494, -0.5730973 , -0.36357316, 0.14222966],\r\n [-0.04788137, 0.57239765, -0.42559105, -0.3851193 ,\r\n -0.4322731 , 0.17473899, 0.2781501 , -0.3135546 ,\r\n 0.16818762, -0.5378859 , -0.436202 , 0.24547724,\r\n -0.22671576, -0.21490538, 0.03390764, 0.33757707,\r\n -0.26851228, 0.13539045, 0.12432808, 0.17681476],\r\n [ 0.00723328, 0.45953745, -0.06097123, 0.16176198,\r\n 0.17545281, 0.04761023, 0.08551856, -0.39673173,\r\n -0.1030248 , -0.41911608, -0.36077395, 0.25994748,\r\n 0.17877859, -0.22195749, 0.20626257, 0.03892534,\r\n -0.11264925, 0.41848317, -0.00793925, 0.11859634]],\r\n\r\n [[-0.19413333, 0.25094593, 0.07414938, 0.24743508,\r\n -0.33084935, -0.06709898, 0.36981508, -0.4653449 ,\r\n -0.11439489, -0.4342906 , -0.57224137, -0.0408266 ,\r\n -0.5128257 , 0.10127501, 0.04174631, 0.45715442,\r\n -0.36309534, -0.59043044, -0.19902939, 0.09469209],\r\n [-0.02696281, 0.5366578 , -0.2641655 , 0.40929306,\r\n -0.10690639, 0.4548107 , 0.58759534, -0.4134388 ,\r\n 0.03856685, -0.32694018, -0.37587804, 0.6371258 ,\r\n -0.25595975, -0.03472416, 0.03825448, -0.03601537,\r\n -0.29256642, -0.15788952, 0.04303175, 0.50009584],\r\n [-0.2043812 , 0.20162553, -0.30228066, 0.17630152,\r\n -0.07913021, -0.07020605, -0.21900353, 0.02324237,\r\n -0.12460969, 0.08818662, 0.19243196, -0.41052923,\r\n 0.18283717, 0.09857927, 0.13043833, 0.48166376,\r\n 0.18589105, 0.18693772, -0.285601 , 0.01860644]]],\r\n dtype=float32), array([[[ 0.03736883, 0.01305096, 0.23953459, 0.35007694,\r\n -0.42613977, -0.25811744, -0.7938471 , -0.29008776,\r\n 0.25216168, -0.04332235, 0.15051644, 0.2856495 ,\r\n 0.50434947, 0.20682862, -0.15353562, -0.44327822,\r\n 0.14009207, -0.4573151 , -0.3230373 , 0.30941603],\r\n [ 0.5185348 , -0.7085531 , 0.7809766 , 0.083186 ,\r\n 0.61447036, 0.04986111, -0.04477785, 0.11479376,\r\n -0.47155038, -0.09569892, 0.45652747, 0.5076367 ,\r\n 0.33670843, 0.81528795, 0.3810344 , -0.55715615,\r\n -0.13840713, 0.0295257 , -0.400796 , 0.7569292 ],\r\n [ 0.15410309, 0.13176374, 0.537471 , -0.29153112,\r\n -0.37749422, -0.4663961 , -0.04389405, -0.70734435,\r\n 0.2729918 , 0.22016479, -0.41638312, 0.32398424,\r\n 0.24226122, -0.14321595, 0.04044551, 0.12845491,\r\n -0.5569717 , 0.49633956, 0.14523073, -0.26000744]],\r\n\r\n [[-0.19413333, 0.25094593, 0.07414938, 0.24743508,\r\n -0.33084935, -0.06709898, 0.36981508, -0.4653449 ,\r\n -0.11439489, -0.4342906 , -0.57224137, -0.0408266 ,\r\n -0.5128257 , 0.10127501, 0.04174631, 0.45715442,\r\n -0.36309534, -0.59043044, -0.19902939, 0.09469209],\r\n [-0.02696281, 0.5366578 , -0.2641655 , 0.40929306,\r\n -0.10690639, 0.4548107 , 0.58759534, -0.4134388 ,\r\n 0.03856685, -0.32694018, -0.37587804, 0.6371258 ,\r\n -0.25595975, -0.03472416, 0.03825448, -0.03601537,\r\n -0.29256642, -0.15788952, 0.04303175, 0.50009584],\r\n [-0.2043812 , 0.20162553, -0.30228066, 0.17630152,\r\n -0.07913021, -0.07020605, -0.21900353, 0.02324237,\r\n -0.12460969, 0.08818662, 0.19243196, -0.41052923,\r\n 0.18283717, 0.09857927, 0.13043833, 0.48166376,\r\n 0.18589105, 0.18693772, -0.285601 , 0.01860644]]],\r\n dtype=float32)]\r\n```\r\n\r\nIf you want to, you can actually try visualizing the result in [model-explorer](https://github.com/google-ai-edge/model-explorer) as well.\r\n\r\nPlease try them out and let us know if this resolves your issue. If you still need further help, feel free to open a new issue at the respective repo."
] | 2024-01-24T16:40:59 | 2024-06-11T22:15:02 | null |
NONE
| null | null | null |
### 1. System information
- OS Platform and Distribution (e.g., Linux Ubuntu 16.04): windows 10
- TensorFlow installation (pip package or built from source): pip install tensorflow==2.10.1
- TensorFlow library (version, if pip package or github SHA, if built from source):
### 2. Code
``` python
import numpy as np
import tensorflow as tf
outname = "simplernn1d"
tfpath = outname + ".tf"
tflitepath = outname + ".tflite"
x = np.zeros([1, 10, 3], dtype=np.float32)
h0 = np.zeros([1, 1, 64], dtype=np.float32)
# test model tf
model_tf = tf.saved_model.load(tfpath)
tf_sess = model_tf.signatures["serving_default"]
y_tf = tf_sess(input=x, h0=h0)['output'].numpy().item()
print(f"#### y_tf={y_tf}")
# convert to tflite
tflite_converter = tf.lite.TFLiteConverter.from_saved_model(outname + ".tf")
tflite_converter.optimizations = [tf.lite.Optimize.DEFAULT]
model_tflite = tflite_converter.convert()
with open(tflitepath, "wb") as fp: fp.write(model_tflite)
# test tf lite
tf.lite.experimental.Analyzer.analyze(model_path=tflitepath)
tflite_sess = tf.lite.Interpreter(model_path=tflitepath)
tflite_sess.allocate_tensors()
tflite_inputs = tflite_sess.get_input_details()
tflite_outputs = tflite_sess.get_output_details()
tflite_tensors = tflite_sess.get_tensor_details()
tflite_sess.set_tensor(tflite_inputs[0]['index'], h0)
tflite_sess.set_tensor(tflite_inputs[1]['index'], x)
# tensorflow/lite/kernels/reshape.cc:85 num_input_elements != num_output_elements (4288 != 64)Node number 18 (RESHAPE) failed to prepare.Node number 5 (WHILE) failed to invoke.
tflite_sess.invoke()
y_tflite = tflite_sess.get_tensor(tflite_outputs[0]['index'])
```
tf model: [simplernn1d.tf.zip](https://github.com/tensorflow/tensorflow/files/14041244/simplernn1d.tf.zip)
tflite model: [simplernn1d.zip](https://github.com/tensorflow/tensorflow/files/14041257/simplernn1d.zip)
### 3. Failure after conversion
The tf graph runs successfuly but tflite model can not invoke
```
INFO: Created TensorFlow Lite XNNPACK delegate for CPU.
Traceback (most recent call last):
File "test_tllite.py", line 32, in <module>
tflite_sess.invoke()
File "D:\Software\env\miniconda\lib\site-packages\tensorflow\lite\python\interpreter.py", line 917, in invoke
self._interpreter.Invoke()
RuntimeError: tensorflow/lite/kernels/reshape.cc:85 num_input_elements != num_output_elements (4288 != 64)Node number 18 (RESHAPE) failed to prepare.Node number 5 (WHILE) failed to invoke
```
### 4. (optional) RNN conversion support
If converting TF RNN to TFLite fused RNN ops, please prefix [RNN] in the title.
### 5. (optional) Any other info / logs
Include any logs or source code that would be helpful to diagnose the problem. If including tracebacks, please include the full traceback. Large logs and files should be attached.
```
2024-01-25 01:30:55.457215: I tensorflow/core/platform/cpu_feature_guard.cc:193] This TensorFlow binary is optimized with oneAPI Deep Neural Network Library (oneDNN) to use the following CPU instructions in performance-critical operations: AVX AVX2
To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags.
2024-01-25 01:30:55.710649: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1616] Created device /job:localhost/replica:0/task:0/device:GPU:0 with 13729 MB memory: -> device: 0, name: NVIDIA GeForce RTX 3080 Laptop GPU, pci bus id: 0000:01:00.0, compute capability: 8.6
2024-01-25 01:30:56.238163: W tensorflow/core/grappler/optimizers/loop_optimizer.cc:907] Skipping loop optimization for Merge node with control input: StatefulPartitionedCall/assert_equal_1/Assert/AssertGuard/branch_executed/_77
2024-01-25 01:30:56.679744: I tensorflow/stream_executor/cuda/cuda_blas.cc:1614] TensorFloat-32 will be used for the matrix multiplication. This will only be logged once.
#### y_tf=-0.02337179332971573
2024-01-25 01:30:56.789222: W tensorflow/compiler/mlir/lite/python/tf_tfl_flatbuffer_helpers.cc:362] Ignored output_format.
2024-01-25 01:30:56.789452: W tensorflow/compiler/mlir/lite/python/tf_tfl_flatbuffer_helpers.cc:365] Ignored drop_control_dependency.
2024-01-25 01:30:56.790455: I tensorflow/cc/saved_model/reader.cc:45] Reading SavedModel from: simplernn1d.tf
2024-01-25 01:30:56.791770: I tensorflow/cc/saved_model/reader.cc:89] Reading meta graph with tags { serve }
2024-01-25 01:30:56.791889: I tensorflow/cc/saved_model/reader.cc:130] Reading SavedModel debug info (if present) from: simplernn1d.tf
2024-01-25 01:30:56.796659: I tensorflow/compiler/mlir/mlir_graph_optimization_pass.cc:354] MLIR V1 optimization pass is not enabled
2024-01-25 01:30:56.797165: I tensorflow/cc/saved_model/loader.cc:229] Restoring SavedModel bundle.
2024-01-25 01:30:56.810718: I tensorflow/cc/saved_model/loader.cc:213] Running initialization op on SavedModel bundle at path: simplernn1d.tf
2024-01-25 01:30:56.818640: I tensorflow/cc/saved_model/loader.cc:305] SavedModel load for tags { serve }; Status: success: OK. Took 28182 microseconds.
2024-01-25 01:30:56.836125: I tensorflow/compiler/mlir/tensorflow/utils/dump_mlir_util.cc:268] disabling MLIR crash reproducer, set env var `MLIR_CRASH_REPRODUCER_DIRECTORY` to enable.
=== simplernn1d.tflite ===
Your TFLite model has '4' subgraph(s). In the subgraph description below,
T# represents the Tensor numbers. For example, in Subgraph#0, the CALL_ONCE op takes
as input and produces as output.
Subgraph#0 main(T#0, T#1) -> [T#27]
Op#0 CALL_ONCE(Subgraph#1) -> []
Op#1 VAR_HANDLE() -> [T#14]
Op#2 VAR_HANDLE() -> [T#15]
Op#3 STRIDED_SLICE(T#0, T#4[0, 0, 0], T#5[1, 1, 64], T#6[1, 1, 1]) -> [T#16]
Op#4 RESHAPE(T#1, T#2[10, 1, 3]) -> [T#17]
Op#5 WHILE(T#9[0], T#9[0], T#7[], T#16, T#15, T#14, T#17, Cond: Subgraph#2, Body: Subgraph#3) -> [T#18, T#19, T#20, T#21, T#22, T#23, T#24]
Op#6 RESHAPE(T#20, T#3[1, 10, 64]) -> [T#25]
Op#7 GATHER(T#25, T#11[]) -> [T#26]
Op#8 FULLY_CONNECTED(T#26, T#13[], T#12[]) -> [T#27]
Tensors of Subgraph#0
T#0(serving_default_h0:0) shape:[1, 1, 64], type:FLOAT32
T#1(serving_default_input:0) shape:[1, 10, 3], type:FLOAT32
T#2(onnx_tf_prefix_/rnn/Transpose) shape:[3], type:INT32 RO 12 bytes, data:[10, 1, 3]
T#3(onnx_tf_prefix_/rnn/Transpose_1) shape:[3], type:INT32 RO 12 bytes, data:[1, 10, 64]
T#4(RNN_300dd8be/strided_slice) shape:[3], type:INT32 RO 12 bytes, data:[0, 0, 0]
T#5(RNN_300dd8be/strided_slice1) shape:[3], type:INT32 RO 12 bytes, data:[1, 1, 64]
T#6(RNN_300dd8be/strided_slice2) shape:[3], type:INT32 RO 12 bytes, data:[1, 1, 1]
T#7(RNN_300dd8be/rnn/TensorArrayV2) shape:[10, 1, 64], type:FLOAT32 RO 2560 bytes, data:[]
T#8(ExpandDims_1/dim) shape:[], type:INT32 RO 4 bytes, data:[1]
T#9(RNN_300dd8be/rnn/time) shape:[], type:INT32 RO 4 bytes, data:[0]
T#10(RNN_300dd8be/rnn/strided_slice) shape:[], type:INT32 RO 4 bytes, data:[10]
T#11(Add) shape:[], type:INT64 RO 8 bytes, data:[]
T#12(Const) shape:[1], type:FLOAT32 RO 4 bytes, data:[]
T#13(MatMul) shape:[1, 64], type:FLOAT32 RO 256 bytes, data:[]
T#14(rnn_bias_/rnn/rnn) shape:[], type:RESOURCE
T#15(rnn_kernel_/rnn/rnn) shape:[], type:RESOURCE
T#16(RNN_300dd8be/strided_slice3) shape:[1, 64], type:FLOAT32
T#17(onnx_tf_prefix_/rnn/Transpose1) shape:[10, 1, 3], type:FLOAT32
T#18(RNN_300dd8be/rnn/while) shape:[], type:INT32
T#19(RNN_300dd8be/rnn/while1) shape:[], type:INT32
T#20(RNN_300dd8be/rnn/while2) shape:[10, 1, 64], type:FLOAT32
T#21(RNN_300dd8be/rnn/while3) shape:[1, 64], type:FLOAT32
T#22(RNN_300dd8be/rnn/while4) shape:[], type:RESOURCE
T#23(RNN_300dd8be/rnn/while5) shape:[], type:RESOURCE
T#24(RNN_300dd8be/rnn/while6) shape:[10, 1, 3], type:FLOAT32
T#25(onnx_tf_prefix_/rnn/Transpose_11) shape:[1, 10, 64], type:FLOAT32
T#26(onnx_tf_prefix_/Gather;ExpandDims_1/dim) shape:[1, 64], type:FLOAT32
T#27(StatefulPartitionedCall:0) shape:[1, 1], type:FLOAT32
Subgraph#1 NoOp() -> []
Op#0 VAR_HANDLE() -> [T#1_2]
Op#1 ASSIGN_VARIABLE(T#1_2, T#1_1[]) -> []
Op#2 VAR_HANDLE() -> [T#1_3]
Op#3 ASSIGN_VARIABLE(T#1_3, T#1_0[]) -> []
Tensors of Subgraph#1
T#1_0(arith.constant) shape:[64], type:FLOAT32 RO 256 bytes, data:[]
T#1_1(arith.constant1) shape:[1, 64], type:FLOAT32 RO 256 bytes, data:[]
T#1_2(rnn_kernel_/rnn/rnn1) shape:[], type:RESOURCE
T#1_3(rnn_bias_/rnn/rnn1) shape:[], type:RESOURCE
Subgraph#2 RNN_300dd8be/rnn/while_cond(T#2_0, T#2_1, T#2_2, T#2_3, T#2_4, T#2_5, T#2_6) -> [T#2_10]
Op#0 LESS(T#2_1, T#2_7[10]) -> [T#2_8]
Op#1 LESS(T#2_0, T#2_7[10]) -> [T#2_9]
Op#2 LOGICAL_AND(T#2_9, T#2_8) -> [T#2_10]
Tensors of Subgraph#2
T#2_0(arg0) shape:[], type:INT32
T#2_1(arg1) shape:[], type:INT32
T#2_2(arg2) shape:[10, 1, 64], type:FLOAT32
T#2_3(arg3) shape:[1, 64], type:FLOAT32
T#2_4(arg4) shape:[], type:RESOURCE
T#2_5(arg5) shape:[], type:RESOURCE
T#2_6(arg6) shape:[10, 1, 3], type:FLOAT32
T#2_7(RNN_300dd8be/rnn/strided_slice1) shape:[], type:INT32 RO 4 bytes, data:[10]
T#2_8(RNN_300dd8be/rnn/while/Less) shape:[], type:BOOL
T#2_9(RNN_300dd8be/rnn/while/Less_1) shape:[], type:BOOL
T#2_10(RNN_300dd8be/rnn/while/LogicalAnd) shape:[], type:BOOL
Subgraph#3 RNN_300dd8be/rnn/while_body(T#3_0, T#3_1, T#3_2, T#3_3, T#3_4, T#3_5, T#3_6) -> [T#3_18, T#3_17, T#3_34, T#3_26, T#3_4, T#3_5, T#3_6]
Op#0 ADD(T#3_1, T#3_9[1]) -> [T#3_17]
Op#1 ADD(T#3_0, T#3_9[1]) -> [T#3_18]
Op#2 GATHER(T#3_6, T#3_1) -> [T#3_19]
Op#3 CONCATENATION(T#3_19, T#3_3) -> [T#3_20]
Op#4 ASSIGN_VARIABLE(T#3_4, T#3_12[]) -> []
Op#5 READ_VARIABLE(T#3_4) -> [T#3_21]
Op#6 TRANSPOSE(T#3_21, T#3_16[1, 0]) -> [T#3_22]
Op#7 FULLY_CONNECTED(T#3_20, T#3_22, T#-1) -> [T#3_23]
Op#8 ASSIGN_VARIABLE(T#3_5, T#3_11[]) -> []
Op#9 READ_VARIABLE(T#3_5) -> [T#3_24]
Op#10 ADD(T#3_23, T#3_24) -> [T#3_25]
Op#11 TANH(T#3_25) -> [T#3_26]
Op#12 RESHAPE(T#3_1, T#3_10[1]) -> [T#3_27]
Op#13 CONCATENATION(T#3_27, T#3_14[-1, -1]) -> [T#3_28]
Op#14 SLICE(T#3_2, T#3_8[0, 0, 0], T#3_28) -> [T#3_29]
Op#15 RESHAPE(T#3_17, T#3_10[1]) -> [T#3_30]
Op#16 CONCATENATION(T#3_30, T#3_15[0, 0]) -> [T#3_31]
Op#17 SLICE(T#3_2, T#3_31, T#3_13[-1, -1, -1]) -> [T#3_32]
Op#18 RESHAPE(T#3_26, T#3_7[1, 1, 64]) -> [T#3_33]
Op#19 CONCATENATION(T#3_29, T#3_33, T#3_32) -> [T#3_34]
Tensors of Subgraph#3
T#3_0(arg0) shape:[], type:INT32
T#3_1(arg1) shape:[], type:INT32
T#3_2(arg2) shape:[10, 1, 64], type:FLOAT32
T#3_3(arg3) shape:[1, 64], type:FLOAT32
T#3_4(arg4) shape:[], type:RESOURCE
T#3_5(arg5) shape:[], type:RESOURCE
T#3_6(arg6) shape:[10, 1, 3], type:FLOAT32
T#3_7(RNN_300dd8be/strided_slice4) shape:[3], type:INT32 RO 12 bytes, data:[1, 1, 64]
T#3_8(RNN_300dd8be/strided_slice5) shape:[3], type:INT32 RO 12 bytes, data:[0, 0, 0]
T#3_9(ExpandDims_1/dim1) shape:[], type:INT32 RO 4 bytes, data:[1]
T#3_10(RNN_300dd8be/rnn/while/TensorArrayV2Write/TensorListSetItem) shape:[1], type:INT32 RO 4 bytes, data:[1]
T#3_11(Add1) shape:[64], type:FLOAT32 RO 256 bytes, data:[]
T#3_12(concat) shape:[67, 64], type:FLOAT32 RO 17152 bytes, data:[]
T#3_13(RNN_300dd8be/rnn/while/TensorArrayV2Write/TensorListSetItem1) shape:[3], type:INT32 RO 12 bytes, data:[-1, -1, -1]
T#3_14(RNN_300dd8be/rnn/while/TensorArrayV2Write/TensorListSetItem2) shape:[2], type:INT32 RO 8 bytes, data:[-1, -1]
T#3_15(RNN_300dd8be/rnn/while/TensorArrayV2Write/TensorListSetItem3) shape:[2], type:INT32 RO 8 bytes, data:[0, 0]
T#3_16(RNN_300dd8be/rnn/while/rnn/multi_rnn_cell/cell_0/basic_rnn_cell/MatMul1) shape:[2], type:INT32 RO 8 bytes, data:[1, 0]
T#3_17(RNN_300dd8be/rnn/while/add) shape:[], type:INT32
T#3_18(RNN_300dd8be/rnn/while/add_1) shape:[], type:INT32
T#3_19(RNN_300dd8be/rnn/while/TensorArrayV2Read/TensorListGetItem;RNN_300dd8be/rnn/time) shape:[1, 3], type:FLOAT32
T#3_20(RNN_300dd8be/rnn/while/rnn/multi_rnn_cell/cell_0/basic_rnn_cell/concat) shape:[1, 67], type:FLOAT32
T#3_21(RNN_300dd8be/rnn/while/rnn/multi_rnn_cell/cell_0/basic_rnn_cell/MatMul/ReadVariableOp) shape_signature:[-1, 64], type:FLOAT32
T#3_22(RNN_300dd8be/rnn/while/rnn/multi_rnn_cell/cell_0/basic_rnn_cell/MatMul2) shape_signature:[64, -1], type:FLOAT32
T#3_23(RNN_300dd8be/rnn/while/rnn/multi_rnn_cell/cell_0/basic_rnn_cell/MatMul3) shape:[1, 64], type:FLOAT32
T#3_24(RNN_300dd8be/rnn/while/rnn/multi_rnn_cell/cell_0/basic_rnn_cell/BiasAdd/ReadVariableOp) shape:[64], type:FLOAT32
T#3_25(RNN_300dd8be/rnn/while/rnn/multi_rnn_cell/cell_0/basic_rnn_cell/BiasAdd) shape:[1, 64], type:FLOAT32
T#3_26(RNN_300dd8be/rnn/while/rnn/multi_rnn_cell/cell_0/basic_rnn_cell/Tanh) shape:[1, 64], type:FLOAT32
T#3_27(RNN_300dd8be/rnn/while/TensorArrayV2Write/TensorListSetItem4) shape:[1], type:INT32
T#3_28(RNN_300dd8be/rnn/while/TensorArrayV2Write/TensorListSetItem5) shape:[3], type:INT32
T#3_29(RNN_300dd8be/rnn/while/TensorArrayV2Write/TensorListSetItem6) shape_signature:[-1, -1, -1], type:FLOAT32
T#3_30(RNN_300dd8be/rnn/while/TensorArrayV2Write/TensorListSetItem7) shape:[1], type:INT32
T#3_31(RNN_300dd8be/rnn/while/TensorArrayV2Write/TensorListSetItem8) shape:[3], type:INT32
T#3_32(RNN_300dd8be/rnn/while/TensorArrayV2Write/TensorListSetItem9) shape_signature:[-1, -1, -1], type:FLOAT32
T#3_33(RNN_300dd8be/rnn/while/TensorArrayV2Write/TensorListSetItem10) shape:[1, 1, 64], type:FLOAT32
T#3_34(RNN_300dd8be/rnn/while/TensorArrayV2Write/TensorListSetItem11) shape:[10, 1, 64], type:FLOAT32
---------------------------------------------------------------
Your TFLite model has '1' signature_def(s).
Signature#0 key: 'serving_default'
- Subgraph: Subgraph#0
- Inputs:
'h0' : T#0
'input' : T#1
- Outputs:
'output' : T#27
---------------------------------------------------------------
Model size: 30896 bytes
Non-data buffer size: 10160 bytes (32.88 %)
Total data buffer size: 20736 bytes (67.12 %)
- Subgraph#0 : 2900 bytes (09.39 %)
- Subgraph#1 : 512 bytes (01.66 %)
- Subgraph#2 : 4 bytes (00.01 %)
- Subgraph#3 : 17476 bytes (56.56 %)
(Zero value buffers): 2852 bytes (09.23 %)
* Buffers of TFLite model are mostly used for constant tensors.
And zero value buffers are buffers filled with zeros.
Non-data buffers area are used to store operators, subgraphs and etc.
You can find more details from https://github.com/tensorflow/tensorflow/blob/master/tensorflow/lite/schema/schema.fbs
INFO: Created TensorFlow Lite XNNPACK delegate for CPU.
Traceback (most recent call last):
File "test_tllite.py", line 32, in <module>
tflite_sess.invoke()
File "D:\Software\env\miniconda\lib\site-packages\tensorflow\lite\python\interpreter.py", line 917, in invoke
self._interpreter.Invoke()
RuntimeError: tensorflow/lite/kernels/reshape.cc:85 num_input_elements != num_output_elements (4288 != 64)Node number 18 (RESHAPE) failed to prepare.Node number 5 (WHILE) failed to invoke.
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62840/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62840/timeline
| null | null | false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62839
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62839/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62839/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62839/events
|
https://github.com/tensorflow/tensorflow/issues/62839
| 2,097,927,624 |
I_kwDOArmXAs59C9XI
| 62,839 |
Significant difference in RSS memory usage between TF1 and TF2
|
{
"login": "bergentruckung",
"id": 15092622,
"node_id": "MDQ6VXNlcjE1MDkyNjIy",
"avatar_url": "https://avatars.githubusercontent.com/u/15092622?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/bergentruckung",
"html_url": "https://github.com/bergentruckung",
"followers_url": "https://api.github.com/users/bergentruckung/followers",
"following_url": "https://api.github.com/users/bergentruckung/following{/other_user}",
"gists_url": "https://api.github.com/users/bergentruckung/gists{/gist_id}",
"starred_url": "https://api.github.com/users/bergentruckung/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/bergentruckung/subscriptions",
"organizations_url": "https://api.github.com/users/bergentruckung/orgs",
"repos_url": "https://api.github.com/users/bergentruckung/repos",
"events_url": "https://api.github.com/users/bergentruckung/events{/privacy}",
"received_events_url": "https://api.github.com/users/bergentruckung/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
},
{
"id": 1463677878,
"node_id": "MDU6TGFiZWwxNDYzNjc3ODc4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:performance",
"name": "type:performance",
"color": "159b2e",
"default": false,
"description": "Performance Issue"
},
{
"id": 5508003926,
"node_id": "LA_kwDOArmXAs8AAAABSE14Vg",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.13",
"name": "TF 2.13",
"color": "B13ACB",
"default": false,
"description": "For issues related to Tensorflow 2.13"
}
] |
closed
| false |
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"@SuryanarayanaY, please take a look at this ASAP. ",
"\r\n\r\nIf it helps, running it through `memray` and generating a flamegraph with `--leaks`, we see the above as having ~18 GB memory allocated from 27k allocations. So, likely that something is up with those.",
"Hi @bergentruckung ,\r\n\r\nYou need to call `tf.keras.backend.clear_session()` in the loop to remove the global states generated by keras. Could you please add this at the beginning of epoch and let us know.\r\n\r\nThanks!",
"Hi @SuryanarayanaY,\r\n\r\nI tried that out, but it doesn't seem to work.",
"Hi @bergentruckung ,\r\n\r\nI did replicated the behaviour with Keras3-nightly also.Attached [gist](https://colab.research.google.com/drive/1ewHE0e6PtygZYwyZiqbqNtVnEJBYB23G?resourcekey=0-UAj6TMTN-39OBfWYP3QbCw) for reference. Not sure whether this needs to be addressed in Keras repo or here itself. Could you please open an issue at [Keras](https://github.com/keras-team/keras/issues) repo also.",
"Hi @SuryanarayanaY,\r\n\r\nI think your suggested workaround may work for newer TF that has changes from https://github.com/tensorflow/tensorflow/pull/62154 pulled in. This wasn't cherry-picked onto 2.13 branch.\r\n\r\nCould you backport that PR to 2.13?",
"@bergentruckung Could you please upgrade to the latest if possible as backported changes in 2.13 may introduce new bugs or regressions. It's unlikely for older versions to receive any bug fixes except when we have security patches. \r\nThank you!",
"We're building from source. We were able to build 2.14, but that has cuBLAS open issue that's problematic for us (the fix was to go back to 2.13 and that's what we did). We couldn't find a proper closure of dependencies for 2.15, and that's why we were trying previous versions.",
"@bergentruckung Could you please let us know if you have created another issue in Keras repo as suggested [here](https://github.com/tensorflow/tensorflow/issues/62839#issuecomment-1916579409)?\r\nThank you!",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62839\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62839\">No</a>\n"
] | 2024-01-24T10:19:10 | 2024-02-19T01:47:25 | 2024-02-19T01:47:22 |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
source
### TensorFlow version
TF 2.13.1
### Custom code
Yes
### OS platform and distribution
Redhat Enterprise Linux 8.9
### Mobile device
_No response_
### Python version
3.11.4
### Bazel version
5.4.0
### GCC/compiler version
10.4
### CUDA/cuDNN version
CUDA 12.2, cuDNN 8.9.5
### GPU model and memory
A100 80GB
### Current behavior?
When running the same keras workload on TF1 vs. TF2, I'm seeing a significant increase in memory utilization per epoch. This happens when using both CPUs/GPUs. The utilization for an epoch climbs up significantly after every epoch. See below for TF1 vs. TF2:
```
# For TF2
Memory usage after epoch 0 [mem_usage = 3.41 GB]
Memory usage after epoch 1 [mem_usage = 3.88 GB]
Memory usage after epoch 2 [mem_usage = 3.88 GB]
Memory usage after epoch 3 [mem_usage = 4.32 GB]
Memory usage after epoch 4 [mem_usage = 4.81 GB]
Memory usage after epoch 5 [mem_usage = 5.26 GB]
Memory usage after epoch 6 [mem_usage = 5.70 GB]
Memory usage after epoch 7 [mem_usage = 6.14 GB]
Memory usage after epoch 8 [mem_usage = 6.70 GB]
Memory usage after epoch 9 [mem_usage = 7.15 GB]
Memory usage after epoch 10 [mem_usage = 7.36 GB]
Memory usage after epoch 11 [mem_usage = 7.36 GB]
Memory usage after epoch 12 [mem_usage = 7.36 GB]
Memory usage after epoch 13 [mem_usage = 7.37 GB]
Memory usage after epoch 14 [mem_usage = 7.37 GB]
Memory usage after epoch 15 [mem_usage = 7.37 GB]
Memory usage after epoch 16 [mem_usage = 7.37 GB]
Memory usage after epoch 17 [mem_usage = 7.59 GB]
Memory usage after epoch 18 [mem_usage = 7.81 GB]
Memory usage after epoch 19 [mem_usage = 7.81 GB]
# For TF1
Memory usage after epoch 0 [mem_usage = 5.13 GB]
Memory usage after epoch 1 [mem_usage = 5.14 GB]
Memory usage after epoch 2 [mem_usage = 5.14 GB]
Memory usage after epoch 3 [mem_usage = 5.15 GB]
Memory usage after epoch 4 [mem_usage = 5.15 GB]
Memory usage after epoch 5 [mem_usage = 5.15 GB]
Memory usage after epoch 6 [mem_usage = 5.15 GB]
Memory usage after epoch 7 [mem_usage = 5.15 GB]
Memory usage after epoch 8 [mem_usage = 5.15 GB]
Memory usage after epoch 9 [mem_usage = 5.15 GB]
Memory usage after epoch 10 [mem_usage = 5.15 GB]
Memory usage after epoch 11 [mem_usage = 5.15 GB]
Memory usage after epoch 12 [mem_usage = 5.15 GB]
Memory usage after epoch 13 [mem_usage = 5.15 GB]
Memory usage after epoch 14 [mem_usage = 5.15 GB]
Memory usage after epoch 15 [mem_usage = 5.15 GB]
Memory usage after epoch 16 [mem_usage = 5.15 GB]
Memory usage after epoch 17 [mem_usage = 5.15 GB]
Memory usage after epoch 18 [mem_usage = 5.15 GB]
Memory usage after epoch 19 [mem_usage = 5.15 GB]
```
### Standalone code to reproduce the issue
```shell
import tensorflow as tf
import psutil
import time
import os
def mem_usage_str():
process = psutil.Process(os.getpid())
gb = process.memory_info().rss / (1024.**3)
return ' [mem_usage = {:5.2f} GB]'.format(gb)
if int(tf.__version__.split('.')[0]) < 2:
"""
Patch to fix TF/numpy1.20 compatibility issue
"""
from tensorflow.math import reduce_prod
from tensorflow.python.ops import array_ops
def _constant_if_small(value, shape, dtype, name):
try:
if reduce_prod(shape) < 1000: # monkey patch
return array_ops.constant(value, shape=shape, dtype=dtype,
name=name)
except TypeError:
# Happens when shape is a Tensor, list with Tensor elements, etc.
pass
return None
array_ops._constant_if_small = _constant_if_small
"""
End of patch
"""
def build_model():
inputs = [tf.keras.layers.Input(shape=(300, 6), name='input_layer')]
current_layer = inputs[0]
current_layer = tf.keras.layers.LSTM(
50,
dropout=0.1,
recurrent_dropout=0.1,
return_sequences=False,
name='lstm',
)(current_layer)
current_layer = tf.keras.layers.Dense(1)(current_layer)
optimizer = tf.keras.optimizers.Adam(learning_rate=0.001)
model = tf.keras.models.Model(inputs=inputs, outputs=current_layer)
model.compile(loss='mse', optimizer=optimizer)
return model
def run(model, X, y, n_epochs):
tot_time = 0.
print(f'Memory usage before training' + mem_usage_str())
for i in range(n_epochs):
start = time.time()
model.fit(X, y, epochs=1, batch_size=4096, verbose=0)
tot_time += time.time() - start
print(f'Memory usage after epoch {i}' + mem_usage_str())
print(f'Avg. time = {tot_time / n_epochs} seconds')
def run_example(p, n_epochs):
import numpy as np
model = build_model()
X = np.random.randn(2 ** p, 300, 6)
y = np.random.randn(2 ** p)
run(model, X, y, n_epochs)
def main():
run_example(
16, # 2 ** 16 samples
20, # 10 epochs
)
# ------------------------------------------------------------------------------
if __name__ == "__main__":
main()
```
### Relevant log output
_No response_
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62839/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62839/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62838
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62838/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62838/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62838/events
|
https://github.com/tensorflow/tensorflow/issues/62838
| 2,097,703,849 |
I_kwDOArmXAs59CGup
| 62,838 |
Custom Loss Function can't access multiple y_true inputs.
|
{
"login": "h4ck4l1",
"id": 105937725,
"node_id": "U_kgDOBlB7PQ",
"avatar_url": "https://avatars.githubusercontent.com/u/105937725?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/h4ck4l1",
"html_url": "https://github.com/h4ck4l1",
"followers_url": "https://api.github.com/users/h4ck4l1/followers",
"following_url": "https://api.github.com/users/h4ck4l1/following{/other_user}",
"gists_url": "https://api.github.com/users/h4ck4l1/gists{/gist_id}",
"starred_url": "https://api.github.com/users/h4ck4l1/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/h4ck4l1/subscriptions",
"organizations_url": "https://api.github.com/users/h4ck4l1/orgs",
"repos_url": "https://api.github.com/users/h4ck4l1/repos",
"events_url": "https://api.github.com/users/h4ck4l1/events{/privacy}",
"received_events_url": "https://api.github.com/users/h4ck4l1/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 404586594,
"node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower",
"name": "stat:awaiting tensorflower",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from tensorflower"
},
{
"id": 473184161,
"node_id": "MDU6TGFiZWw0NzMxODQxNjE=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:support",
"name": "type:support",
"color": "159b2e",
"default": false,
"description": "Support issues"
},
{
"id": 996845227,
"node_id": "MDU6TGFiZWw5OTY4NDUyMjc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:dist-strat",
"name": "comp:dist-strat",
"color": "0052cc",
"default": false,
"description": "Distribution Strategy related issues"
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
open
| false |
{
"login": "sachinprasadhs",
"id": 73069040,
"node_id": "MDQ6VXNlcjczMDY5MDQw",
"avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sachinprasadhs",
"html_url": "https://github.com/sachinprasadhs",
"followers_url": "https://api.github.com/users/sachinprasadhs/followers",
"following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}",
"gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions",
"organizations_url": "https://api.github.com/users/sachinprasadhs/orgs",
"repos_url": "https://api.github.com/users/sachinprasadhs/repos",
"events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}",
"received_events_url": "https://api.github.com/users/sachinprasadhs/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "sachinprasadhs",
"id": 73069040,
"node_id": "MDQ6VXNlcjczMDY5MDQw",
"avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sachinprasadhs",
"html_url": "https://github.com/sachinprasadhs",
"followers_url": "https://api.github.com/users/sachinprasadhs/followers",
"following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}",
"gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions",
"organizations_url": "https://api.github.com/users/sachinprasadhs/orgs",
"repos_url": "https://api.github.com/users/sachinprasadhs/repos",
"events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}",
"received_events_url": "https://api.github.com/users/sachinprasadhs/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"I want to add some additional Info that I will be running it on TPU so I am testing it on CPU using onedevicestrategy and when I ran the above code on TPU despite of giving me an error on CPU, It gave the same error. ",
"I am currently not using masks and it gives very similar result. I want to know if there are any ways to implement multi inputs into custom loss functions. Any resources,tutorials will be helpful as I didn't come across any. ",
"Also have a similar issue."
] | 2024-01-24T08:24:36 | 2024-05-01T09:20:03 | null |
NONE
| null | null | null |
### Issue type
Support
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
source
### TensorFlow version
2.15.0
### Custom code
Yes
### OS platform and distribution
Ubuntu 22.04 LTS
### Mobile device
Google Colab
### Python version
3.10.12
### Bazel version
_No response_
### GCC/compiler version
11.4.0
### CUDA/cuDNN version
12.1
### GPU model and memory
_No response_
### Current behavior?
I am using .tfrecord files as DataInput, I made a custom function that gives 4 inputs in X and 2 inputs in y.
I am unable to access the 2nd input in y in a custom loss function.
Data Input code
```python
seq_map = {"A":1,"C":2,"G":3,"U":4,"START":4,"END":5,"EMPTY":0}
bracket_map = {"(":1,")":2,"[":3,"]":4,"{":5,"}":6,"<":7,">":8,".":9,"START":10,"END":11,"EMPTY":0}
def convert_and_pad(ex,Lmax:int=206,shift=True,sn_filter:bool=True):
l = tf.shape(ex["seq"],tf.int32)[0]
if not shift:
shift = 0
else:
shift = tf.random.uniform(shape=[1],minval=0,maxval=Lmax-l+1,dtype=tf.int32)[0]
# Sequence Processing and Mask Processing
seq = ex["seq"] + 1
mask = tf.math.greater(tf.pad(seq,[[shift+1,Lmax-l-shift+1]]),seq_map["EMPTY"])
seq = tf.pad(seq,[[1,0]],constant_values=seq_map["START"]) # seq_map["START"]
seq = tf.pad(seq,[[0,1]],constant_values=seq_map["END"]) # seq_map["END"]
seq = tf.pad(seq,[[shift,Lmax-l-shift]]) # seq_map["EMPTY"]
# Bracket Processing
brac = ex["bracket_seq"] + 1
brac = tf.pad(brac,[[1,0]],constant_values=bracket_map["START"]) # bracket_map["START"]
brac = tf.pad(brac,[[0,1]],constant_values=bracket_map["END"]) # bracket_map["END"]
brac = tf.pad(brac,[[shift,Lmax-l-shift]],constant_values=bracket_map["EMPTY"]) # bracket_map["EMPTY"]
# Reactivity Processing
reac = tf.stack([ex["reactivity_2a3"][:l],ex["reactivity_dms"][:l]],axis=-1)
reac = tf.pad(reac,[[shift+1,Lmax+1-l-shift],[0,0]],constant_values=np.nan)
# SN_filter
sn = (ex["sn_filter_2a3"] > 0) & (ex["sn_filter_dms"] > 0)
# BPPMatrix
bppm = ex["bpp_matrix"][:l,:l]
bppm = tf.pad(bppm,[[shift+1,Lmax+1-l-shift],[shift+1,Lmax+1-l-shift]])
seq.set_shape([208])
brac.set_shape([208])
if sn_filter:
return (seq,brac,sn,bppm),(reac,mask)
return (seq,brac,bppm),(reac,mask)
BATCH_SIZE = strategy.num_replicas_in_sync * 16 if (device == "TPU") else 32
def shape_set(X,y):
(seq,brac,sn,bppm),(reac,mask) = X,y
seq.set_shape([BATCH_SIZE,208])
brac.set_shape([BATCH_SIZE,208])
sn.set_shape([BATCH_SIZE])
bppm.set_shape([BATCH_SIZE,208,208])
reac.set_shape([BATCH_SIZE,208,2])
mask.set_shape([BATCH_SIZE,208])
return (seq,brac,sn,bppm),(reac,mask)
def create_train_ds(dataset,batch_size:int=BATCH_SIZE):
dataset = dataset.map(convert_and_pad,num_parallel_calls=tf.data.AUTOTUNE)
# dataset = dataset.repeat()
dataset = dataset.shuffle(20000)
dataset = dataset.batch(batch_size)
dataset = dataset.map(lambda X,y:shape_set(X,y),num_parallel_calls=tf.data.AUTOTUNE)
return dataset.prefetch(tf.data.AUTOTUNE)
def create_val_ds(dataset,batch_size:int=BATCH_SIZE):
dataset = dataset.map(convert_and_pad,num_parallel_calls=tf.data.AUTOTUNE)
dataset = dataset.batch(batch_size)
dataset = dataset.map(lambda X,y:shape_set(X,y),num_parallel_calls=tf.data.AUTOTUNE)
dataset = dataset.cache()
return dataset.prefetch(tf.data.AUTOTUNE)
def create_test_ds(dataset,batch_size:int=BATCH_SIZE):
dataset = dataset.map(convert_and_pad,num_parallel_calls=tf.data.AUTOTUNE)
dataset = dataset.batch(batch_size)
dataset = dataset.map(lambda X,y:shape_set(X,y),num_parallel_calls=tf.data.AUTOTUNE)
return dataset.prefetch(tf.data.AUTOTUNE)
train_ds = create_train_ds(train_modified_ds,batch_size=BATCH_SIZE)
valid_ds = create_val_ds(val_modified_ds,batch_size=BATCH_SIZE)
test_ds = create_test_ds(test_modified_ds,batch_size=BATCH_SIZE)
```
```python
class CustomLoss(keras.losses.Loss):
def __init__(self, **kwargs):
super(CustomLoss, self).__init__(**kwargs)
def __call__(self, y_true,y_pred,sample_weight=None):
loss_y_true,loss_y_mask = y_true
print(loss_y_true.shape,loss_y_mask.shape,y_pred.shape)
loss_y_mask = tf.cast(loss_y_mask,tf.bool)
loss_y_true = tf.clip_by_value(loss_y_true[loss_y_mask],clip_value_min=0,clip_value_max=1)
loss_y_pred = tf.clip_by_value(y_pred[loss_y_mask],clip_value_min=0,clip_value_max=1)
mae_loss = tf.math.reduce_mean(tf.math.abs(tf.math.subtract(loss_y_true,loss_y_pred)),axis=-1)
return tf.math.reduce_mean(mae_loss[~tf.math.is_nan(mae_loss)])
```
Tried looking what was actually being accessed in custom loss
apparently only reactivity (reac) is being accessed as print(y_true.shape) gave me output of (32,208,2) so only true reac values are being accessed. I want to also have access to masked input values.
### Standalone code to reproduce the issue
```shell
strategy = tf.distribute.OneDeviceStrategy("CPU")
def convert_and_pad(ex,Lmax:int=206,shift=True,sn_filter:bool=True):
l = tf.shape(ex["seq"],tf.int32)[0]
if not shift:
shift = 0
else:
shift = tf.random.uniform(shape=[1],minval=0,maxval=Lmax-l+1,dtype=tf.int32)[0]
# Sequence Processing and Mask Processing
seq = ex["seq"] + 1
mask = tf.math.greater(tf.pad(seq,[[shift+1,Lmax-l-shift+1]]),seq_map["EMPTY"])
seq = tf.pad(seq,[[1,0]],constant_values=seq_map["START"]) # seq_map["START"]
seq = tf.pad(seq,[[0,1]],constant_values=seq_map["END"]) # seq_map["END"]
seq = tf.pad(seq,[[shift,Lmax-l-shift]]) # seq_map["EMPTY"]
# Bracket Processing
brac = ex["bracket_seq"] + 1
brac = tf.pad(brac,[[1,0]],constant_values=bracket_map["START"]) # bracket_map["START"]
brac = tf.pad(brac,[[0,1]],constant_values=bracket_map["END"]) # bracket_map["END"]
brac = tf.pad(brac,[[shift,Lmax-l-shift]],constant_values=bracket_map["EMPTY"]) # bracket_map["EMPTY"]
# Reactivity Processing
reac = tf.stack([ex["reactivity_2a3"][:l],ex["reactivity_dms"][:l]],axis=-1)
reac = tf.pad(reac,[[shift+1,Lmax+1-l-shift],[0,0]],constant_values=np.nan)
# SN_filter
sn = (ex["sn_filter_2a3"] > 0) & (ex["sn_filter_dms"] > 0)
# BPPMatrix
bppm = ex["bpp_matrix"][:l,:l]
bppm = tf.pad(bppm,[[shift+1,Lmax+1-l-shift],[shift+1,Lmax+1-l-shift]])
seq.set_shape([208])
brac.set_shape([208])
if sn_filter:
return (seq,brac,sn,bppm),(reac,mask)
return (seq,brac,bppm),(reac,mask)
BATCH_SIZE = strategy.num_replicas_in_sync * 16 if (device == "TPU") else 32
def shape_set(X,y):
(seq,brac,sn,bppm),(reac,mask) = X,y
seq.set_shape([BATCH_SIZE,208])
brac.set_shape([BATCH_SIZE,208])
sn.set_shape([BATCH_SIZE])
bppm.set_shape([BATCH_SIZE,208,208])
reac.set_shape([BATCH_SIZE,208,2])
mask.set_shape([BATCH_SIZE,208])
return (seq,brac,sn,bppm),(reac,mask)
def create_train_ds(dataset,batch_size:int=BATCH_SIZE):
dataset = dataset.map(convert_and_pad,num_parallel_calls=tf.data.AUTOTUNE)
# dataset = dataset.repeat()
dataset = dataset.shuffle(20000)
dataset = dataset.batch(batch_size)
dataset = dataset.map(lambda X,y:shape_set(X,y),num_parallel_calls=tf.data.AUTOTUNE)
return dataset.prefetch(tf.data.AUTOTUNE)
def create_val_ds(dataset,batch_size:int=BATCH_SIZE):
dataset = dataset.map(convert_and_pad,num_parallel_calls=tf.data.AUTOTUNE)
dataset = dataset.batch(batch_size)
dataset = dataset.map(lambda X,y:shape_set(X,y),num_parallel_calls=tf.data.AUTOTUNE)
dataset = dataset.cache()
return dataset.prefetch(tf.data.AUTOTUNE)
def create_test_ds(dataset,batch_size:int=BATCH_SIZE):
dataset = dataset.map(convert_and_pad,num_parallel_calls=tf.data.AUTOTUNE)
dataset = dataset.batch(batch_size)
dataset = dataset.map(lambda X,y:shape_set(X,y),num_parallel_calls=tf.data.AUTOTUNE)
return dataset.prefetch(tf.data.AUTOTUNE)
train_ds = create_train_ds(train_modified_ds,batch_size=BATCH_SIZE)
valid_ds = create_val_ds(val_modified_ds,batch_size=BATCH_SIZE)
test_ds = create_test_ds(test_modified_ds,batch_size=BATCH_SIZE)
X,y = train_ds.take(1).get_single_element()
seq_input = X[0]
bracket_input = X[1]
sn_filter = X[2]
bpp_matrix = X[3]
reactivity = y[0]
mask = y[1]
print("sequence input shape: ",seq_input.shape)
print("bracket sequence input shape: ",bracket_input.shape)
print("sn filter input shape: ",sn_filter.shape)
print("Bpp matrix input shape: ",bpp_matrix.shape)
print("Reactivity input shape: ",reactivity.shape)
print("Mask input shape: ",mask.shape)
class CustomLoss(keras.losses.Loss):
def __init__(self, **kwargs):
super(CustomLoss, self).__init__(**kwargs)
def __call__(self, y_true,y_pred,sample_weight=None):
loss_y_true,loss_y_mask = y_true
print(loss_y_true.shape,loss_y_mask.shape,y_pred.shape)
loss_y_mask = tf.cast(loss_y_mask,tf.bool)
loss_y_true = tf.clip_by_value(loss_y_true[loss_y_mask],clip_value_min=0,clip_value_max=1)
loss_y_pred = tf.clip_by_value(y_pred[loss_y_mask],clip_value_min=0,clip_value_max=1)
mae_loss = tf.math.reduce_mean(tf.math.abs(tf.math.subtract(loss_y_true,loss_y_pred)),axis=-1)
return tf.math.reduce_mean(mae_loss[~tf.math.is_nan(mae_loss)])
## Testing function
cust_loss = CustomLoss()
y_pred = tf.random.uniform(shape=y[0].shape,minval=-1,maxval=2)
print("custom loss: ",cust_loss(y,y_pred).numpy())
with strategy.scope():
model = Transformer()
cust_loss = CustomLoss()
cust_metric_2a3 = CustomMetric2A3()
cust_metric_dms = CustomMetricDMS()
model.compile(
optimizer=keras.optimizers.Adam(1e-5),
loss=cust_loss,
metrics=[cust_metric_2a3,cust_metric_dms]
)
model.fit(train_ds,epochs=1)
```
### Relevant log output
```shell
sequence input shape: (32, 208)
bracket sequence input shape: (32, 208)
sn filter input shape: (32,)
Bpp matrix input shape: (32, 208, 208)
Reactivity input shape: (32, 208, 2)
Mask input shape: (32, 208)
custom loss: 0.47430646
---------------------------------------------------------------------------
OperatorNotAllowedInGraphError Traceback (most recent call last)
<ipython-input-28-669a0a768bc0> in <cell line: 11>()
9 metrics=[cust_metric_2a3,cust_metric_dms]
10 )
---> 11 model.fit(train_ds,epochs=1)
1 frames
<ipython-input-27-bd2035bac2b8> in __call__(self, y_true, y_pred, sample_weight)
50
51 def __call__(self, y_true,y_pred,sample_weight=None):
---> 52 loss_y_true,loss_y_mask = y_true
53 print(loss_y_true.shape,loss_y_mask.shape,y_pred.shape)
54 loss_y_mask = tf.cast(loss_y_mask,tf.bool)
OperatorNotAllowedInGraphError: Iterating over a symbolic `tf.Tensor` is not allowed. You can attempt the following resolutions to the problem: If you are running in Graph mode, use Eager execution mode or decorate this function with @tf.function. If you are using AutoGraph, you can try decorating this function with @tf.function. If that does not work, then you may be using an unsupported feature or your source code may not be visible to AutoGraph. See https://github.com/tensorflow/tensorflow/blob/master/tensorflow/python/autograph/g3doc/reference/limitations.md#access-to-source-code for more information.
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62838/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62838/timeline
| null | null | false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62837
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62837/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62837/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62837/events
|
https://github.com/tensorflow/tensorflow/issues/62837
| 2,097,574,614 |
I_kwDOArmXAs59BnLW
| 62,837 |
JIT compilation failed with tf.math.sqrt on GPU
|
{
"login": "tayyibgondal",
"id": 114048277,
"node_id": "U_kgDOBsw9FQ",
"avatar_url": "https://avatars.githubusercontent.com/u/114048277?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tayyibgondal",
"html_url": "https://github.com/tayyibgondal",
"followers_url": "https://api.github.com/users/tayyibgondal/followers",
"following_url": "https://api.github.com/users/tayyibgondal/following{/other_user}",
"gists_url": "https://api.github.com/users/tayyibgondal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tayyibgondal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tayyibgondal/subscriptions",
"organizations_url": "https://api.github.com/users/tayyibgondal/orgs",
"repos_url": "https://api.github.com/users/tayyibgondal/repos",
"events_url": "https://api.github.com/users/tayyibgondal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tayyibgondal/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 1097547147,
"node_id": "MDU6TGFiZWwxMDk3NTQ3MTQ3",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:ops",
"name": "comp:ops",
"color": "0052cc",
"default": false,
"description": "OPs related issues"
},
{
"id": 1097547538,
"node_id": "MDU6TGFiZWwxMDk3NTQ3NTM4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:gpu",
"name": "comp:gpu",
"color": "0052cc",
"default": false,
"description": "GPU related issues"
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
closed
| false |
{
"login": "Venkat6871",
"id": 147127861,
"node_id": "U_kgDOCMT-NQ",
"avatar_url": "https://avatars.githubusercontent.com/u/147127861?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/Venkat6871",
"html_url": "https://github.com/Venkat6871",
"followers_url": "https://api.github.com/users/Venkat6871/followers",
"following_url": "https://api.github.com/users/Venkat6871/following{/other_user}",
"gists_url": "https://api.github.com/users/Venkat6871/gists{/gist_id}",
"starred_url": "https://api.github.com/users/Venkat6871/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Venkat6871/subscriptions",
"organizations_url": "https://api.github.com/users/Venkat6871/orgs",
"repos_url": "https://api.github.com/users/Venkat6871/repos",
"events_url": "https://api.github.com/users/Venkat6871/events{/privacy}",
"received_events_url": "https://api.github.com/users/Venkat6871/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "Venkat6871",
"id": 147127861,
"node_id": "U_kgDOCMT-NQ",
"avatar_url": "https://avatars.githubusercontent.com/u/147127861?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/Venkat6871",
"html_url": "https://github.com/Venkat6871",
"followers_url": "https://api.github.com/users/Venkat6871/followers",
"following_url": "https://api.github.com/users/Venkat6871/following{/other_user}",
"gists_url": "https://api.github.com/users/Venkat6871/gists{/gist_id}",
"starred_url": "https://api.github.com/users/Venkat6871/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Venkat6871/subscriptions",
"organizations_url": "https://api.github.com/users/Venkat6871/orgs",
"repos_url": "https://api.github.com/users/Venkat6871/repos",
"events_url": "https://api.github.com/users/Venkat6871/events{/privacy}",
"received_events_url": "https://api.github.com/users/Venkat6871/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi **@tayyibgondal** ,\r\nCould you please try again? I tried with TF2.15 and I cannot reproduce the error. Please check the [gist](https://colab.sandbox.google.com/gist/Venkat6871/1df4a8d92ffb8be9c1335b21cb322a9c/62837_gpu_2-15-v.ipynb) here.\r\n\r\nThank you!",
"I think there was a cuda version mismatch. I updated my cuda drivers to version 12 using the line:\r\n\r\n`!pip install tensorflow[and-cuda]`\r\n\r\nNow it's working fine. Thanks!",
"Hi **@tayyibgondal** ,\r\n\r\nCould you please confirm if this issue is resolved for you ? Please feel free to close the issue if it is resolved.\r\n\r\nThank you!",
"Yes, it is resolved!",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62837\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62837\">No</a>\n"
] | 2024-01-24T07:05:56 | 2024-01-29T12:24:51 | 2024-01-29T12:24:47 |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
source
### TensorFlow version
tf 15.0
### Custom code
Yes
### OS platform and distribution
Linux Ubuntu 20.04
### Mobile device
_No response_
### Python version
3.11
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
11.7
### GPU model and memory
NVIDIA RTX A5000 (24 GB)
### Current behavior?
Here is my code for position embedding of gpt model:
```
class PositionalEmbedding(tf.keras.layers.Layer):
def __init__(self, vocab_size, d_model):
super().__init__()
self.d_model = d_model
self.embedding = tf.keras.layers.Embedding(vocab_size, d_model, mask_zero=True)
self.pos_encoding = positional_encoding(length=2048, depth=d_model)
def compute_mask(self, *args, **kwargs):
return self.embedding.compute_mask(*args, **kwargs)
def call(self, x):
length = tf.shape(x)[1] # No of words
x = self.embedding(x)
# This factor sets the relative scale of the embedding and positonal_encoding.
x *= tf.math.sqrt(tf.cast(self.d_model, tf.float32))
x = x + self.pos_encoding[tf.newaxis, :length, :]
return x
embed_fr = PositionalEmbedding(vocab_size=fr_vocab_size, d_model=512)
embed_en = PositionalEmbedding(vocab_size=en_vocab_size, d_model=512)
fr = tf.stack(fr_train_sequences[0:2])
en = tf.stack(en_train_sequences[0:2])
print('French input shape:', fr.shape)
fr_emb = embed_fr(fr)
print(fr_emb.shape)
```
This particular line causes the error:
`x *= tf.math.sqrt(tf.cast(self.d_model, tf.float32))`
Here is the error:

### Standalone code to reproduce the issue
```shell
import tensorflow as tf
# Create a tensor
tensor_to_sqrt = tf.constant([4.0, 9.0, 16.0], dtype=tf.float32)
# Take the square root
tensor_sqrt = tf.sqrt(tensor_to_sqrt)
# Print the original tensor and its square root
print("Original Tensor:")
print(tensor_to_sqrt.numpy())
print("\nSquare Root Tensor:")
print(tensor_sqrt.numpy())
```
### Relevant log output
```shell
{{function_node __wrapped__Sqrt_device_/job:localhost/replica:0/task:0/device:GPU:0}} JIT compilation failed. [Op:Sqrt] name:
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62837/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62837/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62836
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62836/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62836/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62836/events
|
https://github.com/tensorflow/tensorflow/issues/62836
| 2,096,656,471 |
I_kwDOArmXAs58-HBX
| 62,836 |
Can't load model with tf-nightly if the model was saved with tf 2.15
|
{
"login": "reuvenperetz",
"id": 44209964,
"node_id": "MDQ6VXNlcjQ0MjA5OTY0",
"avatar_url": "https://avatars.githubusercontent.com/u/44209964?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/reuvenperetz",
"html_url": "https://github.com/reuvenperetz",
"followers_url": "https://api.github.com/users/reuvenperetz/followers",
"following_url": "https://api.github.com/users/reuvenperetz/following{/other_user}",
"gists_url": "https://api.github.com/users/reuvenperetz/gists{/gist_id}",
"starred_url": "https://api.github.com/users/reuvenperetz/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/reuvenperetz/subscriptions",
"organizations_url": "https://api.github.com/users/reuvenperetz/orgs",
"repos_url": "https://api.github.com/users/reuvenperetz/repos",
"events_url": "https://api.github.com/users/reuvenperetz/events{/privacy}",
"received_events_url": "https://api.github.com/users/reuvenperetz/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
}
] |
closed
| false |
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Moved to keras github issues. ",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62836\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62836\">No</a>\n"
] | 2024-01-23T17:56:48 | 2024-01-23T18:11:46 | 2024-01-23T18:11:43 |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
binary
### TensorFlow version
2.15
### Custom code
No
### OS platform and distribution
_No response_
### Mobile device
_No response_
### Python version
_No response_
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
Hello,
I have a model that I saved using tf 2.15 version.
When trying to load it using tf-nightly I'm getting the following error:
ImportError: cannot import name 'is_tensor_or_tensor_list' from 'keras.src.utils.tf_utils' (/usr/local/lib/python3.10/dist-packages/keras/src/utils/tf_utils.py)
### Standalone code to reproduce the issue
Save model with **TF2.15**:
```shell
import tensorflow as tf
import keras
_in = keras.layers.Input(shape=(8, 8, 3))
_out = keras.layers.Conv2D(3, 3)(_in)
model = keras.Model(inputs=_in, outputs=_out)
modelpath = f'model.keras'
model.save(modelpath)
```
Load model with **tf-nightly**:
```
import keras
import tensorflow as tf
modelpath = f'model.keras'
loaded_model = keras.models.load_model(modelpath)
```
### Relevant log output
```shell
----> 5 loaded_model = keras.models.load_model(modelpath)
/usr/local/lib/python3.10/dist-packages/keras/src/saving/saving_api.py in load_model(filepath, custom_objects, compile, safe_mode)
174
175 if is_keras_zip:
--> 176 return saving_lib.load_model(
177 filepath,
178 custom_objects=custom_objects,
/usr/local/lib/python3.10/dist-packages/keras/src/saving/saving_lib.py in load_model(filepath, custom_objects, compile, safe_mode)
151 # Construct the model from the configuration file in the archive.
152 with ObjectSharingScope():
--> 153 model = deserialize_keras_object(
154 config_dict, custom_objects, safe_mode=safe_mode
155 )
/usr/local/lib/python3.10/dist-packages/keras/src/saving/serialization_lib.py in deserialize_keras_object(config, custom_objects, safe_mode, **kwargs)
681 return obj
682
--> 683 cls = _retrieve_class_or_fn(
684 class_name,
685 registered_name,
/usr/local/lib/python3.10/dist-packages/keras/src/saving/serialization_lib.py in _retrieve_class_or_fn(name, registered_name, module, obj_type, full_config, custom_objects)
783 # and `class_name`. Import the module, find the class.
784 try:
--> 785 mod = importlib.import_module(module)
786 except ModuleNotFoundError:
787 raise TypeError(
/usr/lib/python3.10/importlib/__init__.py in import_module(name, package)
124 break
125 level += 1
--> 126 return _bootstrap._gcd_import(name[level:], package, level)
127
128
/usr/lib/python3.10/importlib/_bootstrap.py in _gcd_import(name, package, level)
/usr/lib/python3.10/importlib/_bootstrap.py in _find_and_load(name, import_)
/usr/lib/python3.10/importlib/_bootstrap.py in _find_and_load_unlocked(name, import_)
/usr/lib/python3.10/importlib/_bootstrap.py in _load_unlocked(spec)
/usr/lib/python3.10/importlib/_bootstrap_external.py in exec_module(self, module)
/usr/lib/python3.10/importlib/_bootstrap.py in _call_with_frames_removed(f, *args, **kwds)
/usr/local/lib/python3.10/dist-packages/keras/src/engine/functional.py in <module>
24
25 from keras.src import backend
---> 26 from keras.src.dtensor import layout_map as layout_map_lib
27 from keras.src.engine import base_layer
28 from keras.src.engine import base_layer_utils
/usr/local/lib/python3.10/dist-packages/keras/src/dtensor/layout_map.py in <module>
25 from keras.src.dtensor import lazy_variable
26 from keras.src.dtensor import utils
---> 27 from keras.src.engine import base_layer
28
29 # isort: off
/usr/local/lib/python3.10/dist-packages/keras/src/engine/base_layer.py in <module>
52 # A module that only depends on `keras.layers` import these from here.
53 from keras.src.utils.generic_utils import to_snake_case # noqa: F401
---> 54 from keras.src.utils.tf_utils import is_tensor_or_tensor_list # noqa: F401
55
56 # isort: off
ImportError: cannot import name 'is_tensor_or_tensor_list' from 'keras.src.utils.tf_utils' (/usr/local/lib/python3.10/dist-packages/keras/src/utils/tf_utils.py)
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62836/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62836/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62835
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62835/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62835/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62835/events
|
https://github.com/tensorflow/tensorflow/issues/62835
| 2,096,459,676 |
I_kwDOArmXAs589W-c
| 62,835 |
mkl_remapper_test fails with TF_ENABLE_ONEDNN_OPTS=1
|
{
"login": "elfringham",
"id": 10442001,
"node_id": "MDQ6VXNlcjEwNDQyMDAx",
"avatar_url": "https://avatars.githubusercontent.com/u/10442001?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/elfringham",
"html_url": "https://github.com/elfringham",
"followers_url": "https://api.github.com/users/elfringham/followers",
"following_url": "https://api.github.com/users/elfringham/following{/other_user}",
"gists_url": "https://api.github.com/users/elfringham/gists{/gist_id}",
"starred_url": "https://api.github.com/users/elfringham/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/elfringham/subscriptions",
"organizations_url": "https://api.github.com/users/elfringham/orgs",
"repos_url": "https://api.github.com/users/elfringham/repos",
"events_url": "https://api.github.com/users/elfringham/events{/privacy}",
"received_events_url": "https://api.github.com/users/elfringham/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 404586594,
"node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower",
"name": "stat:awaiting tensorflower",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from tensorflower"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 473173351,
"node_id": "MDU6TGFiZWw0NzMxNzMzNTE=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:build/install",
"name": "type:build/install",
"color": "159b2e",
"default": false,
"description": "Build and install issues"
},
{
"id": 1104829434,
"node_id": "MDU6TGFiZWwxMTA0ODI5NDM0",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:mkl",
"name": "comp:mkl",
"color": "0052cc",
"default": false,
"description": "MKL related issues"
},
{
"id": 1205615612,
"node_id": "MDU6TGFiZWwxMjA1NjE1NjEy",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/subtype:%20ubuntu/linux",
"name": "subtype: ubuntu/linux",
"color": "b619ea",
"default": false,
"description": "Ubuntu/Linux Build/Installation Issues"
}
] |
closed
| false |
{
"login": "TensorFlow-MKL",
"id": 44416303,
"node_id": "MDQ6VXNlcjQ0NDE2MzAz",
"avatar_url": "https://avatars.githubusercontent.com/u/44416303?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/TensorFlow-MKL",
"html_url": "https://github.com/TensorFlow-MKL",
"followers_url": "https://api.github.com/users/TensorFlow-MKL/followers",
"following_url": "https://api.github.com/users/TensorFlow-MKL/following{/other_user}",
"gists_url": "https://api.github.com/users/TensorFlow-MKL/gists{/gist_id}",
"starred_url": "https://api.github.com/users/TensorFlow-MKL/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/TensorFlow-MKL/subscriptions",
"organizations_url": "https://api.github.com/users/TensorFlow-MKL/orgs",
"repos_url": "https://api.github.com/users/TensorFlow-MKL/repos",
"events_url": "https://api.github.com/users/TensorFlow-MKL/events{/privacy}",
"received_events_url": "https://api.github.com/users/TensorFlow-MKL/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "TensorFlow-MKL",
"id": 44416303,
"node_id": "MDQ6VXNlcjQ0NDE2MzAz",
"avatar_url": "https://avatars.githubusercontent.com/u/44416303?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/TensorFlow-MKL",
"html_url": "https://github.com/TensorFlow-MKL",
"followers_url": "https://api.github.com/users/TensorFlow-MKL/followers",
"following_url": "https://api.github.com/users/TensorFlow-MKL/following{/other_user}",
"gists_url": "https://api.github.com/users/TensorFlow-MKL/gists{/gist_id}",
"starred_url": "https://api.github.com/users/TensorFlow-MKL/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/TensorFlow-MKL/subscriptions",
"organizations_url": "https://api.github.com/users/TensorFlow-MKL/orgs",
"repos_url": "https://api.github.com/users/TensorFlow-MKL/repos",
"events_url": "https://api.github.com/users/TensorFlow-MKL/events{/privacy}",
"received_events_url": "https://api.github.com/users/TensorFlow-MKL/received_events",
"type": "User",
"site_admin": false
},
{
"login": "SuryanarayanaY",
"id": 116063290,
"node_id": "U_kgDOBur8Og",
"avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/SuryanarayanaY",
"html_url": "https://github.com/SuryanarayanaY",
"followers_url": "https://api.github.com/users/SuryanarayanaY/followers",
"following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}",
"gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}",
"starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions",
"organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs",
"repos_url": "https://api.github.com/users/SuryanarayanaY/repos",
"events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}",
"received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"@TensorFlow-MKL ",
"@MichaelHudgins ",
"@davsva01 ",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62835\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62835\">No</a>\n"
] | 2024-01-23T16:21:02 | 2024-01-31T20:59:34 | 2024-01-31T20:59:31 |
CONTRIBUTOR
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
source
### TensorFlow version
git HEAD
### Custom code
No
### OS platform and distribution
Ubuntu 20.04
### Mobile device
n/a
### Python version
3.9.17
### Bazel version
6.1.0
### GCC/compiler version
17.0.0
### CUDA/cuDNN version
n/a
### GPU model and memory
n/a
### Current behavior?
The unit test //tensorflow/core/grappler/optimizers:mkl_remapper_test fails when oneDNN is enabled with TF_ENABLE_ONEDNN_OPTS=1
### Standalone code to reproduce the issue
```shell
bazel test --test_env=TF_ENABLE_ONEDNN_OPTS=1 --cache_test_results=no --build_tests_only --test_env=TF2_BEHAVIOR=1 --test_size_filters=small,medium --test_output=errors --verbose_failures=true --test_keep_going --notest_verbose_timeout_warnings --test_tag_filters=--oss_serial,-no_oss,-oss_excluded,-v1only,-benchmark-test,-no_oss_py38,-no_oss_py39,-no_oss_py310 --jobs=75 -- //tensorflow/core/grappler/optimizers:mkl_remapper_test
```
### Relevant log output
```shell
==================== Test output for //tensorflow/core/grappler/optimizers:mkl_remapper_test:
2024-01-23 16:18:57.726978: I tensorflow/core/util/port.cc:113] oneDNN custom operations are on. You may see slightly different numerical results due to floating-point round-off errors from different computation orders. To turn them off, set the environment variable `TF_ENABLE_ONEDNN_OPTS=0`.
[==========] Running 81 tests from 9 test suites.
[----------] Global test environment set-up.
[----------] 54 tests from MklRemapperTest
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddN_NHWC_activationRelu_addbcastfalse
2024-01-23 16:18:57.836149: I tensorflow/core/platform/cpu_feature_guard.cc:210] This TensorFlow binary is optimized to use available CPU instructions in performance-critical operations.
To enable the following instructions: SSE3 SSE4.1 SSE4.2 AVX, in other operations, rebuild TensorFlow with the appropriate compiler flags.
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddN_NHWC_activationRelu_addbcastfalse (153 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddN_NHWC_activationRelu6_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddN_NHWC_activationRelu6_addbcastfalse (137 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddN_NHWC_activationElu_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddN_NHWC_activationElu_addbcastfalse (132 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddN_NHWC_activationLeakyRelu_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddN_NHWC_activationLeakyRelu_addbcastfalse (116 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddN_NHWC_activationNone_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddN_NHWC_activationNone_addbcastfalse (108 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddN_NCHW_activationRelu_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddN_NCHW_activationRelu_addbcastfalse (140 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddN_NCHW_activationRelu6_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddN_NCHW_activationRelu6_addbcastfalse (118 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddN_NCHW_activationElu_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddN_NCHW_activationElu_addbcastfalse (104 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddN_NCHW_activationLeakyRelu_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddN_NCHW_activationLeakyRelu_addbcastfalse (126 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddN_NCHW_activationNone_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddN_NCHW_activationNone_addbcastfalse (109 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NHWC_activationRelu_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NHWC_activationRelu_addbcastfalse (118 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NHWC_activationRelu6_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NHWC_activationRelu6_addbcastfalse (96 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NHWC_activationElu_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NHWC_activationElu_addbcastfalse (95 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NHWC_activationLeakyRelu_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NHWC_activationLeakyRelu_addbcastfalse (94 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NHWC_activationNone_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NHWC_activationNone_addbcastfalse (92 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NCHW_activationRelu_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NCHW_activationRelu_addbcastfalse (97 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NCHW_activationRelu6_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NCHW_activationRelu6_addbcastfalse (97 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NCHW_activationElu_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NCHW_activationElu_addbcastfalse (99 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NCHW_activationLeakyRelu_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NCHW_activationLeakyRelu_addbcastfalse (97 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NCHW_activationNone_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NCHW_activationNone_addbcastfalse (125 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NHWC_activationRelu_addbcasttrue
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NHWC_activationRelu_addbcasttrue (45 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NHWC_activationRelu6_addbcasttrue
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NHWC_activationRelu6_addbcasttrue (38 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NHWC_activationElu_addbcasttrue
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NHWC_activationElu_addbcasttrue (40 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NHWC_activationLeakyRelu_addbcasttrue
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NHWC_activationLeakyRelu_addbcasttrue (38 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NHWC_activationNone_addbcasttrue
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NHWC_activationNone_addbcasttrue (36 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NCHW_activationRelu_addbcasttrue
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NCHW_activationRelu_addbcasttrue (39 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NCHW_activationRelu6_addbcasttrue
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NCHW_activationRelu6_addbcasttrue (40 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NCHW_activationElu_addbcasttrue
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NCHW_activationElu_addbcasttrue (41 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NCHW_activationLeakyRelu_addbcasttrue
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NCHW_activationLeakyRelu_addbcasttrue (39 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NCHW_activationNone_addbcasttrue
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAdd_NCHW_activationNone_addbcasttrue (39 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NHWC_activationRelu_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NHWC_activationRelu_addbcastfalse (98 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NHWC_activationRelu6_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NHWC_activationRelu6_addbcastfalse (93 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NHWC_activationElu_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NHWC_activationElu_addbcastfalse (95 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NHWC_activationLeakyRelu_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NHWC_activationLeakyRelu_addbcastfalse (98 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NHWC_activationNone_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NHWC_activationNone_addbcastfalse (92 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NCHW_activationRelu_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NCHW_activationRelu_addbcastfalse (97 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NCHW_activationRelu6_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NCHW_activationRelu6_addbcastfalse (97 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NCHW_activationElu_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NCHW_activationElu_addbcastfalse (105 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NCHW_activationLeakyRelu_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NCHW_activationLeakyRelu_addbcastfalse (98 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NCHW_activationNone_addbcastfalse
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NCHW_activationNone_addbcastfalse (98 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NHWC_activationRelu_addbcasttrue
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NHWC_activationRelu_addbcasttrue (41 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NHWC_activationRelu6_addbcasttrue
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NHWC_activationRelu6_addbcasttrue (38 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NHWC_activationElu_addbcasttrue
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NHWC_activationElu_addbcasttrue (39 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NHWC_activationLeakyRelu_addbcasttrue
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NHWC_activationLeakyRelu_addbcasttrue (39 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NHWC_activationNone_addbcasttrue
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NHWC_activationNone_addbcasttrue (36 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NCHW_activationRelu_addbcasttrue
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NCHW_activationRelu_addbcasttrue (39 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NCHW_activationRelu6_addbcasttrue
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NCHW_activationRelu6_addbcasttrue (39 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NCHW_activationElu_addbcasttrue
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NCHW_activationElu_addbcasttrue (40 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NCHW_activationLeakyRelu_addbcasttrue
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NCHW_activationLeakyRelu_addbcasttrue (39 ms)
[ RUN ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NCHW_activationNone_addbcasttrue
[ OK ] MklRemapperTest.FuseConv2DWithBiasAndAddV2_NCHW_activationNone_addbcasttrue (38 ms)
[ RUN ] MklRemapperTest.FuseDepthwiseConv2DWithBiasAndActivation_DT_FLOAT
[ OK ] MklRemapperTest.FuseDepthwiseConv2DWithBiasAndActivation_DT_FLOAT (67 ms)
[ RUN ] MklRemapperTest.FuseDepthwiseConv2DWithBiasAndActivation_DT_BFLOAT16
[ OK ] MklRemapperTest.FuseDepthwiseConv2DWithBiasAndActivation_DT_BFLOAT16 (68 ms)
[ RUN ] MklRemapperTest.FuseBatchNormWithRelu
tensorflow/core/framework/tensor_testutil.cc:184: Failure
Value of: IsClose(Tx[i], Ty[i], typed_atol, typed_rtol)
Actual: false (0.51748466491699219 not close to 0.517486572265625)
Expected: true
i = 250 Tx[i] = 0.51748466491699219 Ty[i] = 0.517486572265625
tensorflow/core/framework/tensor_testutil.cc:184: Failure
Value of: IsClose(Tx[i], Ty[i], typed_atol, typed_rtol)
Actual: false (1.0251579284667969 not close to 1.0251598358154297)
Expected: true
i = 298 Tx[i] = 1.0251579284667969 Ty[i] = 1.0251598358154297
tensorflow/core/framework/tensor_testutil.cc:184: Failure
Value of: IsClose(Tx[i], Ty[i], typed_atol, typed_rtol)
Actual: false (1.2959165573120117 not close to 1.2959184646606445)
Expected: true
i = 322 Tx[i] = 1.2959165573120117 Ty[i] = 1.2959184646606445
tensorflow/core/framework/tensor_testutil.cc:184: Failure
Value of: IsClose(Tx[i], Ty[i], typed_atol, typed_rtol)
Actual: false (0.26327323913574219 not close to 0.26327705383300781)
Expected: true
i = 404 Tx[i] = 0.26327323913574219 Ty[i] = 0.26327705383300781
tensorflow/core/framework/tensor_testutil.cc:184: Failure
Value of: IsClose(Tx[i], Ty[i], typed_atol, typed_rtol)
Actual: false (0.57001495361328125 not close to 0.57001304626464844)
Expected: true
i = 419 Tx[i] = 0.57001495361328125 Ty[i] = 0.57001304626464844
tensorflow/core/framework/tensor_testutil.cc:184: Failure
Value of: IsClose(Tx[i], Ty[i], typed_atol, typed_rtol)
Actual: false (0.80478096008300781 not close to 0.80478286743164062)
Expected: true
i = 428 Tx[i] = 0.80478096008300781 Ty[i] = 0.80478286743164062
tensorflow/core/framework/tensor_testutil.cc:184: Failure
Value of: IsClose(Tx[i], Ty[i], typed_atol, typed_rtol)
Actual: false (3.8237895965576172 not close to 3.82379150390625)
Expected: true
i = 446 Tx[i] = 3.8237895965576172 Ty[i] = 3.82379150390625
tensorflow/core/framework/tensor_testutil.cc:184: Failure
Value of: IsClose(Tx[i], Ty[i], typed_atol, typed_rtol)
Actual: false (1.3237247467041016 not close to 1.3237266540527344)
Expected: true
i = 452 Tx[i] = 1.3237247467041016 Ty[i] = 1.3237266540527344
tensorflow/core/framework/tensor_testutil.cc:184: Failure
Value of: IsClose(Tx[i], Ty[i], typed_atol, typed_rtol)
Actual: false (1.53741455078125 not close to 1.5374126434326172)
Expected: true
i = 464 Tx[i] = 1.53741455078125 Ty[i] = 1.5374126434326172
tensorflow/core/framework/tensor_testutil.cc:184: Failure
Value of: IsClose(Tx[i], Ty[i], typed_atol, typed_rtol)
Actual: false (2.0006084442138672 not close to 2.0006122589111328)
Expected: true
i = 476 Tx[i] = 2.0006084442138672 Ty[i] = 2.0006122589111328
tensorflow/core/framework/tensor_testutil.cc:187: Failure
Expected: (num_failures) < (max_failures), actual: 10 vs 10
Too many mismatches (atol = 9.9999999999999995e-07 rtol = 0), giving up.
[ FAILED ] MklRemapperTest.FuseBatchNormWithRelu (77 ms)
[ RUN ] MklRemapperTest.FuseMatMulWithBiasAddAndAdd
[ OK ] MklRemapperTest.FuseMatMulWithBiasAddAndAdd (43 ms)
[----------] 54 tests from MklRemapperTest (4293 ms total)
[----------] 2 tests from RelpaceAddWithBiasAddTest
[ RUN ] RelpaceAddWithBiasAddTest.RelpaceAddWithBiasAddDepthConv2D_AddV2
[ OK ] RelpaceAddWithBiasAddTest.RelpaceAddWithBiasAddDepthConv2D_AddV2 (356 ms)
[ RUN ] RelpaceAddWithBiasAddTest.RelpaceAddWithBiasAddDepthConv2D_Add
[ OK ] RelpaceAddWithBiasAddTest.RelpaceAddWithBiasAddDepthConv2D_Add (348 ms)
[----------] 2 tests from RelpaceAddWithBiasAddTest (704 ms total)
[----------] 4 tests from FusedMatMulBiasAddAndGeluTest
[ RUN ] FusedMatMulBiasAddAndGeluTest.Float32GeluExact
[ OK ] FusedMatMulBiasAddAndGeluTest.Float32GeluExact (12 ms)
[ RUN ] FusedMatMulBiasAddAndGeluTest.BFloat16GeluExact
tensorflow/core/grappler/optimizers/mkl_remapper_test.cc:662: Skipped
Intel oneDNN with DT_BFLOAT16 is not supported, skipping FusedMatMulBiasAddAndGelu test.
[ SKIPPED ] FusedMatMulBiasAddAndGeluTest.BFloat16GeluExact (0 ms)
[ RUN ] FusedMatMulBiasAddAndGeluTest.Float32GeluExact2
[ OK ] FusedMatMulBiasAddAndGeluTest.Float32GeluExact2 (20 ms)
[ RUN ] FusedMatMulBiasAddAndGeluTest.BFloat16GeluExact2
tensorflow/core/grappler/optimizers/mkl_remapper_test.cc:662: Skipped
Intel oneDNN with DT_BFLOAT16 is not supported, skipping FusedMatMulBiasAddAndGelu test.
[ SKIPPED ] FusedMatMulBiasAddAndGeluTest.BFloat16GeluExact2 (0 ms)
[----------] 4 tests from FusedMatMulBiasAddAndGeluTest (33 ms total)
[----------] 2 tests from MklFusedBatchMatMul
[ RUN ] MklFusedBatchMatMul.MulAndAdd
tensorflow/core/grappler/optimizers/mkl_remapper_test.cc:787: Skipped
Intel oneDNN with DT_BFLOAT16 is not supported, skipping MklFusedBatchMatMul test.
tensorflow/core/grappler/optimizers/mkl_remapper_test.cc:787: Skipped
Intel oneDNN with DT_BFLOAT16 is not supported, skipping MklFusedBatchMatMul test.
tensorflow/core/grappler/optimizers/mkl_remapper_test.cc:787: Skipped
Intel oneDNN with DT_BFLOAT16 is not supported, skipping MklFusedBatchMatMul test.
tensorflow/core/grappler/optimizers/mkl_remapper_test.cc:787: Skipped
Intel oneDNN with DT_BFLOAT16 is not supported, skipping MklFusedBatchMatMul test.
[ SKIPPED ] MklFusedBatchMatMul.MulAndAdd (67 ms)
[ RUN ] MklFusedBatchMatMul.MulAndAdd2
tensorflow/core/grappler/optimizers/mkl_remapper_test.cc:883: Skipped
Intel oneDNN with DT_BFLOAT16 is not supported, skipping MklFusedBatchMatMul test.
tensorflow/core/grappler/optimizers/mkl_remapper_test.cc:883: Skipped
Intel oneDNN with DT_BFLOAT16 is not supported, skipping MklFusedBatchMatMul test.
tensorflow/core/grappler/optimizers/mkl_remapper_test.cc:883: Skipped
Intel oneDNN with DT_BFLOAT16 is not supported, skipping MklFusedBatchMatMul test.
tensorflow/core/grappler/optimizers/mkl_remapper_test.cc:883: Skipped
Intel oneDNN with DT_BFLOAT16 is not supported, skipping MklFusedBatchMatMul test.
[ SKIPPED ] MklFusedBatchMatMul.MulAndAdd2 (61 ms)
[----------] 2 tests from MklFusedBatchMatMul (129 ms total)
[----------] 2 tests from MklRemapperSwishTest
[ RUN ] MklRemapperSwishTest.F32
[ OK ] MklRemapperSwishTest.F32 (17 ms)
[ RUN ] MklRemapperSwishTest.BF16
tensorflow/core/grappler/optimizers/mkl_remapper_test.cc:999: Skipped
Intel oneDNN with DT_BFLOAT16 is not supported, skipping MklRemapperSwishTest test.
[ SKIPPED ] MklRemapperSwishTest.BF16 (0 ms)
[----------] 2 tests from MklRemapperSwishTest (18 ms total)
[----------] 2 tests from MklRemapperConv2dBiasAddSwishTest
[ RUN ] MklRemapperConv2dBiasAddSwishTest.F32
[ OK ] MklRemapperConv2dBiasAddSwishTest.F32 (16 ms)
[ RUN ] MklRemapperConv2dBiasAddSwishTest.BF16
tensorflow/core/grappler/optimizers/mkl_remapper_test.cc:1092: Skipped
Intel oneDNN with DT_BFLOAT16 is not supported, skipping MklRemapperConv2dBiasAddSwishTest test.
[ SKIPPED ] MklRemapperConv2dBiasAddSwishTest.BF16 (0 ms)
[----------] 2 tests from MklRemapperConv2dBiasAddSwishTest (16 ms total)
[----------] 1 test from MklRemapperConv2dFusedBatchNormSwishTest
[ RUN ] MklRemapperConv2dFusedBatchNormSwishTest.F32
[ OK ] MklRemapperConv2dFusedBatchNormSwishTest.F32 (18 ms)
[----------] 1 test from MklRemapperConv2dFusedBatchNormSwishTest (18 ms total)
[----------] 8 tests from MklFuseInstanceNormTest
[ RUN ] MklFuseInstanceNormTest.FuseMklInstanceNorm5D_FP32_NDHWC
[ OK ] MklFuseInstanceNormTest.FuseMklInstanceNorm5D_FP32_NDHWC (28 ms)
[ RUN ] MklFuseInstanceNormTest.FuseMklInstanceNorm5D_FP32_NCDHW
[ OK ] MklFuseInstanceNormTest.FuseMklInstanceNorm5D_FP32_NCDHW (21 ms)
[ RUN ] MklFuseInstanceNormTest.FuseMklInstanceNorm4D_FP32_NHWC
[ OK ] MklFuseInstanceNormTest.FuseMklInstanceNorm4D_FP32_NHWC (32 ms)
[ RUN ] MklFuseInstanceNormTest.FuseMklInstanceNorm4D_FP32_NCHW
[ OK ] MklFuseInstanceNormTest.FuseMklInstanceNorm4D_FP32_NCHW (22 ms)
[ RUN ] MklFuseInstanceNormTest.FuseMklInstanceNormWithActivation5D_FP32_NDHWC
[ OK ] MklFuseInstanceNormTest.FuseMklInstanceNormWithActivation5D_FP32_NDHWC (47 ms)
[ RUN ] MklFuseInstanceNormTest.FuseMklInstanceNormWithActivation5D_FP32_NCDHW
[ OK ] MklFuseInstanceNormTest.FuseMklInstanceNormWithActivation5D_FP32_NCDHW (43 ms)
[ RUN ] MklFuseInstanceNormTest.FuseMklInstanceNormWithActivation4D_FP32_NHWC
[ OK ] MklFuseInstanceNormTest.FuseMklInstanceNormWithActivation4D_FP32_NHWC (50 ms)
[ RUN ] MklFuseInstanceNormTest.FuseMklInstanceNormWithActivation4D_FP32_NCHW
[ OK ] MklFuseInstanceNormTest.FuseMklInstanceNormWithActivation4D_FP32_NCHW (46 ms)
[----------] 8 tests from MklFuseInstanceNormTest (294 ms total)
[----------] 6 tests from FusedConvBiasAddAndHardSwishTest
[ RUN ] FusedConvBiasAddAndHardSwishTest.Float32Conv2DBiasHardSwish
[ OK ] FusedConvBiasAddAndHardSwishTest.Float32Conv2DBiasHardSwish (51 ms)
[ RUN ] FusedConvBiasAddAndHardSwishTest.Float32DWConv2DBiasHardSwish
[ OK ] FusedConvBiasAddAndHardSwishTest.Float32DWConv2DBiasHardSwish (127 ms)
[ RUN ] FusedConvBiasAddAndHardSwishTest.Bfloat16Conv2DBiasHardSwish
tensorflow/core/grappler/optimizers/mkl_remapper_test.cc:1562: Skipped
Intel oneDNN with DT_BFLOAT16 is not supported, skipping FusedConvBiasAddAndHardSwishTest test.
[ SKIPPED ] FusedConvBiasAddAndHardSwishTest.Bfloat16Conv2DBiasHardSwish (0 ms)
[ RUN ] FusedConvBiasAddAndHardSwishTest.Bfloat16DWConv2DBiasHardSwish
tensorflow/core/grappler/optimizers/mkl_remapper_test.cc:1562: Skipped
Intel oneDNN with DT_BFLOAT16 is not supported, skipping FusedConvBiasAddAndHardSwishTest test.
[ SKIPPED ] FusedConvBiasAddAndHardSwishTest.Bfloat16DWConv2DBiasHardSwish (0 ms)
[ RUN ] FusedConvBiasAddAndHardSwishTest.Bfloat16Conv2DBiasHardSwishWithCast
tensorflow/core/grappler/optimizers/mkl_remapper_test.cc:1562: Skipped
Intel oneDNN with DT_BFLOAT16 is not supported, skipping FusedConvBiasAddAndHardSwishTest test.
[ SKIPPED ] FusedConvBiasAddAndHardSwishTest.Bfloat16Conv2DBiasHardSwishWithCast (0 ms)
[ RUN ] FusedConvBiasAddAndHardSwishTest.Bfloat16DWConv2DBiasHardSwishWithCast
tensorflow/core/grappler/optimizers/mkl_remapper_test.cc:1562: Skipped
Intel oneDNN with DT_BFLOAT16 is not supported, skipping FusedConvBiasAddAndHardSwishTest test.
[ SKIPPED ] FusedConvBiasAddAndHardSwishTest.Bfloat16DWConv2DBiasHardSwishWithCast (0 ms)
[----------] 6 tests from FusedConvBiasAddAndHardSwishTest (178 ms total)
[----------] Global test environment tear-down
[==========] 81 tests from 9 test suites ran. (5687 ms total)
[ PASSED ] 70 tests.
[ SKIPPED ] 10 tests, listed below:
[ SKIPPED ] FusedMatMulBiasAddAndGeluTest.BFloat16GeluExact
[ SKIPPED ] FusedMatMulBiasAddAndGeluTest.BFloat16GeluExact2
[ SKIPPED ] MklFusedBatchMatMul.MulAndAdd
[ SKIPPED ] MklFusedBatchMatMul.MulAndAdd2
[ SKIPPED ] MklRemapperSwishTest.BF16
[ SKIPPED ] MklRemapperConv2dBiasAddSwishTest.BF16
[ SKIPPED ] FusedConvBiasAddAndHardSwishTest.Bfloat16Conv2DBiasHardSwish
[ SKIPPED ] FusedConvBiasAddAndHardSwishTest.Bfloat16DWConv2DBiasHardSwish
[ SKIPPED ] FusedConvBiasAddAndHardSwishTest.Bfloat16Conv2DBiasHardSwishWithCast
[ SKIPPED ] FusedConvBiasAddAndHardSwishTest.Bfloat16DWConv2DBiasHardSwishWithCast
[ FAILED ] 1 test, listed below:
[ FAILED ] MklRemapperTest.FuseBatchNormWithRelu
1 FAILED TEST
================================================================================
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62835/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62835/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62834
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62834/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62834/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62834/events
|
https://github.com/tensorflow/tensorflow/issues/62834
| 2,095,702,000 |
I_kwDOArmXAs586d_w
| 62,834 |
TensorFlow's to_json Fails to Export Internal Structure of Subclasses in Model
|
{
"login": "pzy2000",
"id": 77827720,
"node_id": "MDQ6VXNlcjc3ODI3NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/77827720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/pzy2000",
"html_url": "https://github.com/pzy2000",
"followers_url": "https://api.github.com/users/pzy2000/followers",
"following_url": "https://api.github.com/users/pzy2000/following{/other_user}",
"gists_url": "https://api.github.com/users/pzy2000/gists{/gist_id}",
"starred_url": "https://api.github.com/users/pzy2000/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/pzy2000/subscriptions",
"organizations_url": "https://api.github.com/users/pzy2000/orgs",
"repos_url": "https://api.github.com/users/pzy2000/repos",
"events_url": "https://api.github.com/users/pzy2000/events{/privacy}",
"received_events_url": "https://api.github.com/users/pzy2000/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
},
{
"id": 1097545817,
"node_id": "MDU6TGFiZWwxMDk3NTQ1ODE3",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:apis",
"name": "comp:apis",
"color": "0052cc",
"default": false,
"description": "Highlevel API related issues"
},
{
"id": 4511033337,
"node_id": "LA_kwDOArmXAs8AAAABDODn-Q",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.10",
"name": "TF 2.10",
"color": "C15088",
"default": false,
"description": ""
}
] |
closed
| false |
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"@pzy2000 Please make sure all custom layers and classes implement the necessary attributes and methods required by to_json. You might need to override methods like get_config and from_config to enable proper serialization. Could you check the TensorFlow documentation for to_json to see specific requirements and limitations: https://www.tensorflow.org/api_docs/python/tf/io/decode_json_example.\r\nPlease use the latest TF version and let us know the update?\r\nThank you!",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62834\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62834\">No</a>\n"
] | 2024-01-23T10:01:15 | 2024-02-09T01:46:24 | 2024-02-09T01:46:21 |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
binary
### TensorFlow version
tf 2.10.0
### Custom code
Yes
### OS platform and distribution
Linux Ubuntu 20.04.4
### Mobile device
_No response_
### Python version
3.7.16
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
cuda11
### GPU model and memory
_No response_
### Current behavior?
When I used TensorFlow's to_json interface to export a json file of the model structure, I found that it couldn't export the internal structure of subclasses, which is a sad thing.
The exported json file has been attached as an attachment, as shown in the figure below

[issue1.json](https://github.com/tensorflow/tensorflow/files/14021881/issue1.json)
### Standalone code to reproduce the issue
```shell
import math
from pprint import pprint
import tensorflow as tf
from keras.models import load_model
def conv_variance_scaling_initializer(in_channel, out_channel, kernel_size):
fan_in = in_channel * kernel_size * kernel_size
scale = 1.0 / max(1., fan_in)
stddev = math.sqrt(scale)
return tf.initializers.TruncatedNormal(mean=0.0, stddev=stddev)
def _conv3x3(in_channel, out_channel, stride=1):
return tf.keras.layers.Conv2D(out_channel, kernel_size=3, strides=stride, padding='same',
kernel_initializer=conv_variance_scaling_initializer(in_channel, out_channel, 3),
use_bias=False)
def _conv1x1(in_channel, out_channel, stride=1):
return tf.keras.layers.Conv2D(out_channel, kernel_size=1, strides=stride, padding='same',
# kernel_initializer=conv_variance_scaling_initializer(in_channel, out_channel, 1),
use_bias=False)
def _conv7x7(in_channel, out_channel, stride=1):
return tf.keras.layers.Conv2D(out_channel, kernel_size=7, strides=stride, padding='same',
kernel_initializer=conv_variance_scaling_initializer(in_channel, out_channel, 7)
, use_bias=False)
def _bn(channel):
return tf.keras.layers.BatchNormalization(axis=-1, momentum=0.9, epsilon=1e-4)
def _fc(in_channel, out_channel):
return tf.keras.layers.Dense(out_channel, activation=None,
kernel_initializer=tf.keras.initializers.HeUniform())
class ResidualBlock(tf.keras.Model):
def __init__(self, in_channel, out_channel, stride=1, use_se=False, se_block=False):
super(ResidualBlock, self).__init__()
self.stride = stride
self.use_se = use_se
self.in_channel = in_channel
self.out_channel = out_channel
self.se_block = se_block
channel = self.out_channel // 4 # Assuming expansion factor is 4
self.conv1 = _conv1x1(self.in_channel, channel, stride=1)
self.bn1 = _bn(channel)
if self.use_se and self.stride != 1:
# Adjusted for TensorFlow; using Keras layers
self.e2 = tf.keras.Sequential([
_conv3x3(channel, channel, stride=1),
_bn(channel),
tf.keras.layers.ReLU(),
tf.keras.layers.MaxPool2D(pool_size=(2, 2), strides=(2, 2), padding='same')
])
else:
self.conv2 = _conv3x3(channel, channel, stride=stride)
self.bn2 = _bn(channel)
self.conv3 = _conv1x1(channel, self.out_channel, stride=1)
self.bn3 = _bn(self.out_channel)
self.relu = tf.keras.layers.ReLU()
self.down_sample = False
if stride != 1 or self.in_channel != self.out_channel:
self.down_sample = True
self.down_sample_layer = tf.keras.Sequential([
_conv1x1(in_channel, out_channel, stride),
_bn(out_channel)
])
def get_config(self):
config = super(ResidualBlock, self).get_config()
config.update({
'in_channel': self.in_channel,
'out_channel': self.out_channel,
# include other arguments if there are any
})
return config
def call(self, x, training=False):
identity = x
out = self.conv1(x)
out = self.bn1(out, training=training)
out = self.relu(out)
if self.use_se and self.stride != 1:
out = self.e2(out, training=training)
else:
out = self.conv2(out)
out = self.bn2(out, training=training)
out = self.relu(out)
out = self.conv3(out)
out = self.bn3(out, training=training)
if self.down_sample:
identity = self.down_sample_layer(identity, training=training)
out = out + identity
out = self.relu(out)
return out
# 加载模型h5文件
mmodel = load_model("/root/zmx/COMET-master/data/origin_models/resnet.h5",
custom_objects={'ResidualBlock': ResidualBlock})
mmodel.summary()
model_json = mmodel.to_json()
pprint(model_json)
f = open("issue1.json", "w")
f.write(model_json)
f.close()
```
### Relevant log output
_No response_
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62834/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62834/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62833
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62833/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62833/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62833/events
|
https://github.com/tensorflow/tensorflow/issues/62833
| 2,095,472,840 |
I_kwDOArmXAs585mDI
| 62,833 |
When convert from keras to tflite, the output is different from what it shoud be.
|
{
"login": "wbjnpu",
"id": 32902375,
"node_id": "MDQ6VXNlcjMyOTAyMzc1",
"avatar_url": "https://avatars.githubusercontent.com/u/32902375?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/wbjnpu",
"html_url": "https://github.com/wbjnpu",
"followers_url": "https://api.github.com/users/wbjnpu/followers",
"following_url": "https://api.github.com/users/wbjnpu/following{/other_user}",
"gists_url": "https://api.github.com/users/wbjnpu/gists{/gist_id}",
"starred_url": "https://api.github.com/users/wbjnpu/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/wbjnpu/subscriptions",
"organizations_url": "https://api.github.com/users/wbjnpu/orgs",
"repos_url": "https://api.github.com/users/wbjnpu/repos",
"events_url": "https://api.github.com/users/wbjnpu/events{/privacy}",
"received_events_url": "https://api.github.com/users/wbjnpu/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
},
{
"id": 750616506,
"node_id": "MDU6TGFiZWw3NTA2MTY1MDY=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite",
"name": "comp:lite",
"color": "0052cc",
"default": false,
"description": "TF Lite related issues"
},
{
"id": 1661751498,
"node_id": "MDU6TGFiZWwxNjYxNzUxNDk4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TFLiteConverter",
"name": "TFLiteConverter",
"color": "bfdadc",
"default": false,
"description": "For issues related to TFLite converter"
}
] |
closed
| false |
{
"login": "pkgoogle",
"id": 132095473,
"node_id": "U_kgDOB9-d8Q",
"avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/pkgoogle",
"html_url": "https://github.com/pkgoogle",
"followers_url": "https://api.github.com/users/pkgoogle/followers",
"following_url": "https://api.github.com/users/pkgoogle/following{/other_user}",
"gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}",
"starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions",
"organizations_url": "https://api.github.com/users/pkgoogle/orgs",
"repos_url": "https://api.github.com/users/pkgoogle/repos",
"events_url": "https://api.github.com/users/pkgoogle/events{/privacy}",
"received_events_url": "https://api.github.com/users/pkgoogle/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "pkgoogle",
"id": 132095473,
"node_id": "U_kgDOB9-d8Q",
"avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/pkgoogle",
"html_url": "https://github.com/pkgoogle",
"followers_url": "https://api.github.com/users/pkgoogle/followers",
"following_url": "https://api.github.com/users/pkgoogle/following{/other_user}",
"gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}",
"starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions",
"organizations_url": "https://api.github.com/users/pkgoogle/orgs",
"repos_url": "https://api.github.com/users/pkgoogle/repos",
"events_url": "https://api.github.com/users/pkgoogle/events{/privacy}",
"received_events_url": "https://api.github.com/users/pkgoogle/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"my problem is that \"Model produces wrong results and/or has lesser accuracy\"",
"And I find that .h5 infer is correct, but tflite is wrong. they are the same size and without any quant.",
"Hi @pkgoogle,\r\n\r\nI reproduced the code and noticed that each tflite quantized file has the size 105528 bytes like the model. Please look into the issue.\r\nThank You",
"Hi @wbjnpu, can you please upload your .h5 and .tflite file and let us know the inference value you expected vs what you saw? and how you know that the .tflite version is incorrect? Thanks for your help! Generally the more information you provide the faster we can help you.",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further."
] | 2024-01-23T08:00:58 | 2024-02-22T01:46:36 | 2024-02-22T01:46:36 |
NONE
| null | null | null |
### 1. System information
- OS Platform and Distribution (e.g., Linux Ubuntu 16.04):
- TensorFlow installation (pip package or built from source):
- TensorFlow library (version, if pip package or github SHA, if built from source):
### 2. Code
Provide code to help us reproduce your issues using one of the following options:
#### Option A: Reference colab notebooks
1) Reference [TensorFlow Model Colab](https://colab.research.google.com/gist/ymodak/e96a4270b953201d5362c61c1e8b78aa/tensorflow-datasets.ipynb?authuser=1): Demonstrate how to build your TF model.
2) Reference [TensorFlow Lite Model Colab](https://colab.research.google.com/gist/ymodak/0dfeb28255e189c5c48d9093f296e9a8/tensorflow-lite-debugger-colab.ipynb): Demonstrate how to convert your TF model to a TF Lite model (with quantization, if used) and run TFLite Inference (if possible).
```
(You can paste links or attach files by dragging & dropping them below)
- Provide links to your updated versions of the above two colab notebooks.
- Provide links to your TensorFlow model and (optionally) TensorFlow Lite Model.
```
#### Option B: Paste your code here or provide a link to a custom end-to-end colab
```
(You can paste links or attach files by dragging & dropping them below)
- Include code to invoke the TFLite Converter Python API and the errors.
- Provide links to your TensorFlow model and (optionally) TensorFlow Lite Model.
```
https://github.com/Z-yq/TensorflowASR/blob/v2/asr/models/chunk_conformer_blocks.py this file CTCdecoder is not correct,but converted tflite of conformerblock work well, and I convert it using https://github.com/TensorSpeech/TensorFlowASR . And I have control input shape when load weight. It complex me a long time. maybe because its dynamic train?
### 3. Failure after conversion
If the conversion is successful, but the generated model is wrong, then state what is wrong:
- Model produces wrong results and/or has lesser accuracy.
- Model produces correct results, but it is slower than expected.
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62833/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62833/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62832
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62832/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62832/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62832/events
|
https://github.com/tensorflow/tensorflow/issues/62832
| 2,095,206,246 |
I_kwDOArmXAs584k9m
| 62,832 |
When I install tensorflow using conda, I have the problem saying that AttributeError: module 'numpy' has no attribute 'object'. `np.object` was a deprecated alias for the builtin `object`. To avoid this error in existing code, use `object` by itself. Doing this will not modify any behavior and is safe. The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at: https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations
|
{
"login": "ABtwo",
"id": 33176666,
"node_id": "MDQ6VXNlcjMzMTc2NjY2",
"avatar_url": "https://avatars.githubusercontent.com/u/33176666?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/ABtwo",
"html_url": "https://github.com/ABtwo",
"followers_url": "https://api.github.com/users/ABtwo/followers",
"following_url": "https://api.github.com/users/ABtwo/following{/other_user}",
"gists_url": "https://api.github.com/users/ABtwo/gists{/gist_id}",
"starred_url": "https://api.github.com/users/ABtwo/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/ABtwo/subscriptions",
"organizations_url": "https://api.github.com/users/ABtwo/orgs",
"repos_url": "https://api.github.com/users/ABtwo/repos",
"events_url": "https://api.github.com/users/ABtwo/events{/privacy}",
"received_events_url": "https://api.github.com/users/ABtwo/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
},
{
"id": 1097547538,
"node_id": "MDU6TGFiZWwxMDk3NTQ3NTM4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:gpu",
"name": "comp:gpu",
"color": "0052cc",
"default": false,
"description": "GPU related issues"
},
{
"id": 3255468475,
"node_id": "MDU6TGFiZWwzMjU1NDY4NDc1",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/2.6.0",
"name": "2.6.0",
"color": "FA96B6",
"default": false,
"description": ""
}
] |
closed
| false |
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"@ABtwo,\r\nThe error you are facing **module 'numpy' has no attribute 'object'** is due to numpy version. Could you please try to install `pip install numpy==1.23.4`. Also you are trying to install tensorflow v2.6 which is older and try to follow the compatible test build configurations from the official [document](https://www.tensorflow.org/install/source_windows#gpu). Please try to update to the latest stable version. Thank you!",
"@tilakrayal I have the same issue on Windows. According to the [compatible](https://www.tensorflow.org/install/source_windows#gpu) versions table cuda 12.3 isn’t supported in the latest windows release. Is there an issue tracking the update to 12.3 cuda for windows? ",
"@skidrw,\r\nAFAIK there is no such request for the 12.3 CUDA for Windows environment. There might be a chance that the CUDA version 12.3 will be compatible in the latest tensorflow versions. Could you please feel free to raise the new feature request from [here](https://github.com/tensorflow/tensorflow/issues/new/choose) for the same. \r\n\r\nAlso GPU support on native-Windows is only available for 2.10 or earlier versions, starting in TF 2.11, CUDA build is not supported for Windows. For using TensorFlow GPU on Windows, you will need to build/install TensorFlow in WSL2 or use tensorflow-cpu with TensorFlow-DirectML-Plugin\r\n\r\nThank you!",
"@tilakrayal ,\r\nThank you so much for answering my question, \r\nAre you the official technician? I have tried this \"pip install numpy==1.23.4\" command. \r\nIt prompted me \"Successfully installed numpy-1.23.4\" but there occurred incompatible errors like that \r\n\"ERROR: pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts.\r\ntensorflow 2.6.0 requires clang~=5.0, which is not installed.\r\ntensorflow 2.6.0 requires keras>=2.4.0, which is not installed.\r\ntensorboard 2.6.0 requires google-auth<2,>=1.6.3, but you have google-auth 2.22.0 which is incompatible.\r\ntensorflow 2.6.0 requires absl-py~=0.10, but you have absl-py 1.4.0 which is incompatible.\r\ntensorflow 2.6.0 requires flatbuffers~=1.12, but you have flatbuffers 20210226132247 which is incompatible.\"\r\n\r\nSo I tried \"conda install numpy==1.23.4\" It may installed the compatible packages automatically and there were no incompatible errors. then I tried to import tensorflow,It worked correctly\r\n\r\nBefore I saw your answer, I have tried to correct the deprecated errors by changing the \"np.object\" to \"object ,\"np.bool\" to\"bool\" as it prompted me in the corresponding files. It may be worked, I have imported tensorflow correctly, and run the command \"print(tf.__version__)\" and \"print(tf.config.list_physical_devices('GPU'))\". they all made the correct output.\r\n\r\nWhat's more , I want to say when I try to install tensorflow 2.10 using \"conda create -n tf-gpu tensorflow-gpu==2.10\",It prompts me that \r\n\"Channels:\r\n - defaults\r\nPlatform: win-64\r\nCollecting package metadata (repodata.json): done\r\nSolving environment: failed\r\n\r\nPackagesNotFoundError: The following packages are not available from current channels:\r\n\r\n - tensorflow-gpu==2.10\r\n\r\nCurrent channels:\r\n\r\n - defaults\r\n\r\nTo search for alternate channels that may provide the conda package you're\r\nlooking for, navigate to\r\n\r\n https://anaconda.org\r\n\r\nand use the search bar at the top of the page.\"\r\n\r\nShould I try \"pip install tensorflow-gpu==2.10\" command in the virtual environment? Please give me some advice.\r\n\r\nThanks again for answering me\r\n\r\n\r\n",
"@ABtwo,\r\nYes, you can try to install the required tensorflow version using `pip install tensorflow-gpu==2.10` in the new virtual environment. GPU support on native-Windows is only available for 2.10 or earlier versions, starting in TF 2.11, CUDA build is not supported for Windows. For using TensorFlow GPU on Windows, you will need to build/install TensorFlow in WSL2 or use tensorflow-cpu with TensorFlow-DirectML-Plugin. Thank you!",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62832\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62832\">No</a>\n"
] | 2024-01-23T04:15:09 | 2024-02-22T01:46:40 | 2024-02-22T01:46:37 |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
source
### TensorFlow version
tensorflow-GPU 2.6
### Custom code
Yes
### OS platform and distribution
Windows10
### Mobile device
_No response_
### Python version
3.9
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
12.3 cudnn version :8.9.6
### GPU model and memory
_No response_
### Current behavior?
When I Install tensorflow-gpu by conda , I created the tf-gpu environment, but when I run this instraction"import tensorflow as tf" in python I met this problem AttributeError: module 'numpy' has no attribute 'object'.
`np.object` was a deprecated alias for the builtin `object`. To avoid this error in existing code, use `object` by itself. Doing this will not modify any behavior and is safe.
The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations
Then I tried to correct the problem by uninstall my numpy which version is 1.26.3 and install the numpy=1.19 , there was another problem like this
" error: subprocess-exited-with-error
× Preparing metadata (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [90 lines of output]
Running from numpy source directory.
<string>:460: UserWarning: Unrecognized setuptools command, proceeding with generating Cython sources and expanding templates
C:\Users\dell\AppData\Local\Temp\pip-install-_lwzhmzj\numpy_4bbed4470a5a4d1aa30ccee14c45028a\tools\cythonize.py:73: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
required_version = LooseVersion('0.29.14')
C:\Users\dell\AppData\Local\Temp\pip-install-_lwzhmzj\numpy_4bbed4470a5a4d1aa30ccee14c45028a\tools\cythonize.py:75: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
if LooseVersion(cython_version) < required_version:
performance hint: _common.pyx:275:19: Exception check after calling 'random_func' will always require the GIL to be acquired. Declare 'random_func' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:299:19: Exception check after calling 'random_func' will always require the GIL to be acquired. Declare 'random_func' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:322:50: Exception check after calling 'random_func' will always require the GIL to be acquired. Declare 'random_func' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:426:31: Exception check after calling 'f' will always require the GIL to be acquired. Declare 'f' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:465:31: Exception check after calling 'f' will always require the GIL to be acquired. Declare 'f' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:509:31: Exception check after calling 'f' will always require the GIL to be acquired. Declare 'f' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:592:36: Exception check after calling 'f0' will always require the GIL to be acquired. Declare 'f0' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:596:36: Exception check after calling 'f1' will always require the GIL to be acquired. Declare 'f1' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:600:36: Exception check after calling 'f2' will always require the GIL to be acquired. Declare 'f2' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:604:36: Exception check after calling 'f3' will always require the GIL to be acquired. Declare 'f3' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:638:31: Exception check after calling 'f' will always require the GIL to be acquired. Declare 'f' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:675:31: Exception check after calling 'f' will always require the GIL to be acquired. Declare 'f' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:712:63: Exception check after calling 'f' will always require the GIL to be acquired. Declare 'f' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:754:31: Exception check after calling 'f' will always require the GIL to be acquired. Declare 'f' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:785:31: Exception check after calling 'f' will always require the GIL to be acquired. Declare 'f' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:903:40: Exception check after calling 'f0' will always require the GIL to be acquired. Declare 'f0' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:907:40: Exception check after calling 'fd' will always require the GIL to be acquired. Declare 'fd' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:911:41: Exception check after calling 'fdd' will always require the GIL to be acquired. Declare 'fdd' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:916:40: Exception check after calling 'fi' will always require the GIL to be acquired. Declare 'fi' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:920:41: Exception check after calling 'fdi' will always require the GIL to be acquired. Declare 'fdi' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:924:38: Exception check after calling 'fiii' will always require the GIL to be acquired. Declare 'fiii' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:960:31: Exception check after calling 'f' will always require the GIL to be acquired. Declare 'f' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:1002:32: Exception check after calling 'f1' will always require the GIL to be acquired. Declare 'f1' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _generator.pyx:706:41: Exception check after calling '_shuffle_int' will always require the GIL to be acquired.
Possible solutions:
1. Declare '_shuffle_int' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
2. Use an 'int' return type on '_shuffle_int' to allow an error code to be returned.
performance hint: _generator.pyx:735:45: Exception check after calling '_shuffle_int' will always require the GIL to be acquired.
Possible solutions:
1. Declare '_shuffle_int' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
2. Use an 'int' return type on '_shuffle_int' to allow an error code to be returned.
Error compiling Cython file:
------------------------------------------------------------
...
for i in range(1, RK_STATE_LEN):
self.rng_state.key[i] = val[i]
self.rng_state.pos = i
self._bitgen.state = &self.rng_state
self._bitgen.next_uint64 = &mt19937_uint64
^
------------------------------------------------------------
_mt19937.pyx:138:35: Cannot assign type 'uint64_t (*)(void *) except? -1 nogil' to 'uint64_t (*)(void *) noexcept nogil'. Exception values are incompatible. Suggest adding 'noexcept' to type 'uint64_t (void *) except? -1 nogil'.
Processing numpy/random\_bounded_integers.pxd.in
Processing numpy/random\bit_generator.pyx
Processing numpy/random\mtrand.pyx
Processing numpy/random\_bounded_integers.pyx.in
Processing numpy/random\_common.pyx
Processing numpy/random\_generator.pyx
Processing numpy/random\_mt19937.pyx
Traceback (most recent call last):
File "C:\Users\dell\AppData\Local\Temp\pip-install-_lwzhmzj\numpy_4bbed4470a5a4d1aa30ccee14c45028a\tools\cythonize.py", line 235, in <module>
main()
File "C:\Users\dell\AppData\Local\Temp\pip-install-_lwzhmzj\numpy_4bbed4470a5a4d1aa30ccee14c45028a\tools\cythonize.py", line 231, in main
find_process_files(root_dir)
File "C:\Users\dell\AppData\Local\Temp\pip-install-_lwzhmzj\numpy_4bbed4470a5a4d1aa30ccee14c45028a\tools\cythonize.py", line 222, in find_process_files
process(root_dir, fromfile, tofile, function, hash_db)
File "C:\Users\dell\AppData\Local\Temp\pip-install-_lwzhmzj\numpy_4bbed4470a5a4d1aa30ccee14c45028a\tools\cythonize.py", line 188, in process
processor_function(fromfile, tofile)
File "C:\Users\dell\AppData\Local\Temp\pip-install-_lwzhmzj\numpy_4bbed4470a5a4d1aa30ccee14c45028a\tools\cythonize.py", line 77, in process_pyx
subprocess.check_call(
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\subprocess.py", line 373, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['D:\\WorkSpace\\Anaconda_WorkSpace\\envs\\tf-gpu\\python.exe', '-m', 'cython', '-3', '--fast-fail', '-o', '_mt19937.c', '_mt19937.pyx']' returned non-zero exit status 1.
Cythonizing sources
Traceback (most recent call last):
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 353, in <module>
main()
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 335, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 149, in prepare_metadata_for_build_wheel
return hook(metadata_directory, config_settings)
File "C:\Users\dell\AppData\Local\Temp\pip-build-env-yguajv_e\overlay\Lib\site-packages\setuptools\build_meta.py", line 366, in prepare_metadata_for_build_wheel
self.run_setup()
File "C:\Users\dell\AppData\Local\Temp\pip-build-env-yguajv_e\overlay\Lib\site-packages\setuptools\build_meta.py", line 480, in run_setup
super(_BuildMetaLegacyBackend, self).run_setup(setup_script=setup_script)
File "C:\Users\dell\AppData\Local\Temp\pip-build-env-yguajv_e\overlay\Lib\site-packages\setuptools\build_meta.py", line 311, in run_setup
exec(code, locals())
File "<string>", line 489, in <module>
File "<string>", line 469, in setup_package
File "<string>", line 274, in generate_cython
RuntimeError: Running cythonize failed!
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed
× Encountered error while generating package metadata.
╰─> See above for output.
note: This is an issue with the package mentioned above, not pip.
hint: See above for details."
### Standalone code to reproduce the issue
```shell
conda create -n tf-gpu tensorflow-gpu
conda activate tf-gpu
import tensorflow as tf
```
### Relevant log output
```shell
Python 3.9.18 (main, Sep 11 2023, 13:30:38) [MSC v.1916 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import tensorflow as tf
D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\framework\dtypes.py:585: FutureWarning: In the future `np.object` will be defined as the corresponding NumPy scalar.
np.object,
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\__init__.py", line 41, in <module>
from tensorflow.python.tools import module_util as _module_util
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\__init__.py", line 46, in <module>
from tensorflow.python import data
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\data\__init__.py", line 25, in <module>
from tensorflow.python.data import experimental
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\data\experimental\__init__.py", line 97, in <module>
from tensorflow.python.data.experimental import service
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\data\experimental\service\__init__.py", line 353, in <module>
from tensorflow.python.data.experimental.ops.data_service_ops import distribute
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\data\experimental\ops\data_service_ops.py", line 26, in <module>
from tensorflow.python.data.experimental.ops import compression_ops
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\data\experimental\ops\compression_ops.py", line 20, in <module>
from tensorflow.python.data.util import structure
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\data\util\structure.py", line 26, in <module>
from tensorflow.python.data.util import nest
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\data\util\nest.py", line 40, in <module>
from tensorflow.python.framework import sparse_tensor as _sparse_tensor
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\framework\sparse_tensor.py", line 28, in <module>
from tensorflow.python.framework import constant_op
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\framework\constant_op.py", line 29, in <module>
from tensorflow.python.eager import execute
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\eager\execute.py", line 27, in <module>
from tensorflow.python.framework import dtypes
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\framework\dtypes.py", line 585, in <module>
np.object,
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\numpy\__init__.py", line 324, in __getattr__
raise AttributeError(__former_attrs__[attr])
AttributeError: module 'numpy' has no attribute 'object'.
`np.object` was a deprecated alias for the builtin `object`. To avoid this error in existing code, use `object` by itself. Doing this will not modify any behavior and is safe.
The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations
>>> import tensorflow as tf
D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\framework\dtypes.py:627: FutureWarning: In the future `np.object` will be defined as the corresponding NumPy scalar.
np.object,
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\__init__.py", line 41, in <module>
from tensorflow.python.tools import module_util as _module_util
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\__init__.py", line 46, in <module>
from tensorflow.python import data
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\data\__init__.py", line 25, in <module>
from tensorflow.python.data import experimental
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\data\experimental\__init__.py", line 97, in <module>
from tensorflow.python.data.experimental import service
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\data\experimental\service\__init__.py", line 353, in <module>
from tensorflow.python.data.experimental.ops.data_service_ops import distribute
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\data\experimental\ops\data_service_ops.py", line 26, in <module>
from tensorflow.python.data.experimental.ops import compression_ops
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\data\experimental\ops\compression_ops.py", line 20, in <module>
from tensorflow.python.data.util import structure
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\data\util\structure.py", line 26, in <module>
from tensorflow.python.data.util import nest
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\data\util\nest.py", line 40, in <module>
from tensorflow.python.framework import sparse_tensor as _sparse_tensor
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\framework\sparse_tensor.py", line 28, in <module>
from tensorflow.python.framework import constant_op
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\framework\constant_op.py", line 29, in <module>
from tensorflow.python.eager import execute
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\eager\execute.py", line 27, in <module>
from tensorflow.python.framework import dtypes
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\framework\dtypes.py", line 627, in <module>
np.object,
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\numpy\__init__.py", line 324, in __getattr__
raise AttributeError(__former_attrs__[attr])
AttributeError: module 'numpy' has no attribute 'object'.
`np.object` was a deprecated alias for the builtin `object`. To avoid this error in existing code, use `object` by itself. Doing this will not modify any behavior and is safe.
The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations
>>> import tensorflow as tf
D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\framework\dtypes.py:637: FutureWarning: In the future `np.bool` will be defined as the corresponding NumPy scalar.
np.bool,
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\__init__.py", line 41, in <module>
from tensorflow.python.tools import module_util as _module_util
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\__init__.py", line 46, in <module>
from tensorflow.python import data
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\data\__init__.py", line 25, in <module>
from tensorflow.python.data import experimental
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\data\experimental\__init__.py", line 97, in <module>
from tensorflow.python.data.experimental import service
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\data\experimental\service\__init__.py", line 353, in <module>
from tensorflow.python.data.experimental.ops.data_service_ops import distribute
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\data\experimental\ops\data_service_ops.py", line 26, in <module>
from tensorflow.python.data.experimental.ops import compression_ops
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\data\experimental\ops\compression_ops.py", line 20, in <module>
from tensorflow.python.data.util import structure
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\data\util\structure.py", line 26, in <module>
from tensorflow.python.data.util import nest
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\data\util\nest.py", line 40, in <module>
from tensorflow.python.framework import sparse_tensor as _sparse_tensor
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\framework\sparse_tensor.py", line 28, in <module>
from tensorflow.python.framework import constant_op
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\framework\constant_op.py", line 29, in <module>
from tensorflow.python.eager import execute
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\eager\execute.py", line 27, in <module>
from tensorflow.python.framework import dtypes
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\tensorflow\python\framework\dtypes.py", line 637, in <module>
np.bool,
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\numpy\__init__.py", line 324, in __getattr__
raise AttributeError(__former_attrs__[attr])
AttributeError: module 'numpy' has no attribute 'bool'.
`np.bool` was a deprecated alias for the builtin `bool`. To avoid this error in existing code, use `bool` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.bool_` here.
The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations
>>> pip uninstall numpy
File "<stdin>", line 1
pip uninstall numpy
^
SyntaxError: invalid syntax
>>> exit()
(tf-gpu) C:\Users\dell>pip uninstall numpy
Found existing installation: numpy 1.26.3
Uninstalling numpy-1.26.3:
Would remove:
d:\workspace\anaconda_workspace\envs\tf-gpu\lib\site-packages\numpy-1.26.3.dist-info\*
d:\workspace\anaconda_workspace\envs\tf-gpu\lib\site-packages\numpy\*
d:\workspace\anaconda_workspace\envs\tf-gpu\scripts\f2py-script.py
d:\workspace\anaconda_workspace\envs\tf-gpu\scripts\f2py.exe
Proceed (Y/n)? y
Successfully uninstalled numpy-1.26.3
(tf-gpu) C:\Users\dell>pip install -U numpy==1.19
Collecting numpy==1.19
Using cached numpy-1.19.0.zip (7.3 MB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing metadata (pyproject.toml) ... error
error: subprocess-exited-with-error
× Preparing metadata (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [90 lines of output]
Running from numpy source directory.
<string>:460: UserWarning: Unrecognized setuptools command, proceeding with generating Cython sources and expanding templates
C:\Users\dell\AppData\Local\Temp\pip-install-_lwzhmzj\numpy_4bbed4470a5a4d1aa30ccee14c45028a\tools\cythonize.py:73: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
required_version = LooseVersion('0.29.14')
C:\Users\dell\AppData\Local\Temp\pip-install-_lwzhmzj\numpy_4bbed4470a5a4d1aa30ccee14c45028a\tools\cythonize.py:75: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
if LooseVersion(cython_version) < required_version:
performance hint: _common.pyx:275:19: Exception check after calling 'random_func' will always require the GIL to be acquired. Declare 'random_func' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:299:19: Exception check after calling 'random_func' will always require the GIL to be acquired. Declare 'random_func' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:322:50: Exception check after calling 'random_func' will always require the GIL to be acquired. Declare 'random_func' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:426:31: Exception check after calling 'f' will always require the GIL to be acquired. Declare 'f' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:465:31: Exception check after calling 'f' will always require the GIL to be acquired. Declare 'f' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:509:31: Exception check after calling 'f' will always require the GIL to be acquired. Declare 'f' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:592:36: Exception check after calling 'f0' will always require the GIL to be acquired. Declare 'f0' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:596:36: Exception check after calling 'f1' will always require the GIL to be acquired. Declare 'f1' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:600:36: Exception check after calling 'f2' will always require the GIL to be acquired. Declare 'f2' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:604:36: Exception check after calling 'f3' will always require the GIL to be acquired. Declare 'f3' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:638:31: Exception check after calling 'f' will always require the GIL to be acquired. Declare 'f' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:675:31: Exception check after calling 'f' will always require the GIL to be acquired. Declare 'f' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:712:63: Exception check after calling 'f' will always require the GIL to be acquired. Declare 'f' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:754:31: Exception check after calling 'f' will always require the GIL to be acquired. Declare 'f' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:785:31: Exception check after calling 'f' will always require the GIL to be acquired. Declare 'f' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:903:40: Exception check after calling 'f0' will always require the GIL to be acquired. Declare 'f0' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:907:40: Exception check after calling 'fd' will always require the GIL to be acquired. Declare 'fd' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:911:41: Exception check after calling 'fdd' will always require the GIL to be acquired. Declare 'fdd' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:916:40: Exception check after calling 'fi' will always require the GIL to be acquired. Declare 'fi' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:920:41: Exception check after calling 'fdi' will always require the GIL to be acquired. Declare 'fdi' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:924:38: Exception check after calling 'fiii' will always require the GIL to be acquired. Declare 'fiii' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:960:31: Exception check after calling 'f' will always require the GIL to be acquired. Declare 'f' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:1002:32: Exception check after calling 'f1' will always require the GIL to be acquired. Declare 'f1' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _generator.pyx:706:41: Exception check after calling '_shuffle_int' will always require the GIL to be acquired.
Possible solutions:
1. Declare '_shuffle_int' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
2. Use an 'int' return type on '_shuffle_int' to allow an error code to be returned.
performance hint: _generator.pyx:735:45: Exception check after calling '_shuffle_int' will always require the GIL to be acquired.
Possible solutions:
1. Declare '_shuffle_int' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
2. Use an 'int' return type on '_shuffle_int' to allow an error code to be returned.
Error compiling Cython file:
------------------------------------------------------------
...
for i in range(1, RK_STATE_LEN):
self.rng_state.key[i] = val[i]
self.rng_state.pos = i
self._bitgen.state = &self.rng_state
self._bitgen.next_uint64 = &mt19937_uint64
^
------------------------------------------------------------
_mt19937.pyx:138:35: Cannot assign type 'uint64_t (*)(void *) except? -1 nogil' to 'uint64_t (*)(void *) noexcept nogil'. Exception values are incompatible. Suggest adding 'noexcept' to type 'uint64_t (void *) except? -1 nogil'.
Processing numpy/random\_bounded_integers.pxd.in
Processing numpy/random\bit_generator.pyx
Processing numpy/random\mtrand.pyx
Processing numpy/random\_bounded_integers.pyx.in
Processing numpy/random\_common.pyx
Processing numpy/random\_generator.pyx
Processing numpy/random\_mt19937.pyx
Traceback (most recent call last):
File "C:\Users\dell\AppData\Local\Temp\pip-install-_lwzhmzj\numpy_4bbed4470a5a4d1aa30ccee14c45028a\tools\cythonize.py", line 235, in <module>
main()
File "C:\Users\dell\AppData\Local\Temp\pip-install-_lwzhmzj\numpy_4bbed4470a5a4d1aa30ccee14c45028a\tools\cythonize.py", line 231, in main
find_process_files(root_dir)
File "C:\Users\dell\AppData\Local\Temp\pip-install-_lwzhmzj\numpy_4bbed4470a5a4d1aa30ccee14c45028a\tools\cythonize.py", line 222, in find_process_files
process(root_dir, fromfile, tofile, function, hash_db)
File "C:\Users\dell\AppData\Local\Temp\pip-install-_lwzhmzj\numpy_4bbed4470a5a4d1aa30ccee14c45028a\tools\cythonize.py", line 188, in process
processor_function(fromfile, tofile)
File "C:\Users\dell\AppData\Local\Temp\pip-install-_lwzhmzj\numpy_4bbed4470a5a4d1aa30ccee14c45028a\tools\cythonize.py", line 77, in process_pyx
subprocess.check_call(
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\subprocess.py", line 373, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['D:\\WorkSpace\\Anaconda_WorkSpace\\envs\\tf-gpu\\python.exe', '-m', 'cython', '-3', '--fast-fail', '-o', '_mt19937.c', '_mt19937.pyx']' returned non-zero exit status 1.
Cythonizing sources
Traceback (most recent call last):
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 353, in <module>
main()
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 335, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 149, in prepare_metadata_for_build_wheel
return hook(metadata_directory, config_settings)
File "C:\Users\dell\AppData\Local\Temp\pip-build-env-yguajv_e\overlay\Lib\site-packages\setuptools\build_meta.py", line 366, in prepare_metadata_for_build_wheel
self.run_setup()
File "C:\Users\dell\AppData\Local\Temp\pip-build-env-yguajv_e\overlay\Lib\site-packages\setuptools\build_meta.py", line 480, in run_setup
super(_BuildMetaLegacyBackend, self).run_setup(setup_script=setup_script)
File "C:\Users\dell\AppData\Local\Temp\pip-build-env-yguajv_e\overlay\Lib\site-packages\setuptools\build_meta.py", line 311, in run_setup
exec(code, locals())
File "<string>", line 489, in <module>
File "<string>", line 469, in setup_package
File "<string>", line 274, in generate_cython
RuntimeError: Running cythonize failed!
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed
× Encountered error while generating package metadata.
╰─> See above for output.
note: This is an issue with the package mentioned above, not pip.
hint: See above for details.
(tf-gpu) C:\Users\dell>pip install -U numpy==1.19.2
Collecting numpy==1.19.2
Downloading numpy-1.19.2.zip (7.3 MB)
---------------------------------------- 7.3/7.3 MB 34.8 kB/s eta 0:00:00
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing metadata (pyproject.toml) ... error
error: subprocess-exited-with-error
× Preparing metadata (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [90 lines of output]
Running from numpy source directory.
setup.py:470: UserWarning: Unrecognized setuptools command, proceeding with generating Cython sources and expanding templates
run_build = parse_setuppy_commands()
performance hint: _common.pyx:275:19: Exception check after calling 'random_func' will always require the GIL to be acquired. Declare 'random_func' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:299:19: Exception check after calling 'random_func' will always require the GIL to be acquired. Declare 'random_func' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:322:50: Exception check after calling 'random_func' will always require the GIL to be acquired. Declare 'random_func' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:426:31: Exception check after calling 'f' will always require the GIL to be acquired. Declare 'f' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:465:31: Exception check after calling 'f' will always require the GIL to be acquired. Declare 'f' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:509:31: Exception check after calling 'f' will always require the GIL to be acquired. Declare 'f' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:592:36: Exception check after calling 'f0' will always require the GIL to be acquired. Declare 'f0' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:596:36: Exception check after calling 'f1' will always require the GIL to be acquired. Declare 'f1' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:600:36: Exception check after calling 'f2' will always require the GIL to be acquired. Declare 'f2' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:604:36: Exception check after calling 'f3' will always require the GIL to be acquired. Declare 'f3' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:638:31: Exception check after calling 'f' will always require the GIL to be acquired. Declare 'f' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:675:31: Exception check after calling 'f' will always require the GIL to be acquired. Declare 'f' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:712:63: Exception check after calling 'f' will always require the GIL to be acquired. Declare 'f' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:754:31: Exception check after calling 'f' will always require the GIL to be acquired. Declare 'f' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:785:31: Exception check after calling 'f' will always require the GIL to be acquired. Declare 'f' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:903:40: Exception check after calling 'f0' will always require the GIL to be acquired. Declare 'f0' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:907:40: Exception check after calling 'fd' will always require the GIL to be acquired. Declare 'fd' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:911:41: Exception check after calling 'fdd' will always require the GIL to be acquired. Declare 'fdd' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:916:40: Exception check after calling 'fi' will always require the GIL to be acquired. Declare 'fi' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:920:41: Exception check after calling 'fdi' will always require the GIL to be acquired. Declare 'fdi' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:924:38: Exception check after calling 'fiii' will always require the GIL to be acquired. Declare 'fiii' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:960:31: Exception check after calling 'f' will always require the GIL to be acquired. Declare 'f' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _common.pyx:1002:32: Exception check after calling 'f1' will always require the GIL to be acquired. Declare 'f1' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
performance hint: _generator.pyx:707:41: Exception check after calling '_shuffle_int' will always require the GIL to be acquired.
Possible solutions:
1. Declare '_shuffle_int' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
2. Use an 'int' return type on '_shuffle_int' to allow an error code to be returned.
performance hint: _generator.pyx:736:45: Exception check after calling '_shuffle_int' will always require the GIL to be acquired.
Possible solutions:
1. Declare '_shuffle_int' as 'noexcept' if you control the definition and you're sure you don't want the function to raise exceptions.
2. Use an 'int' return type on '_shuffle_int' to allow an error code to be returned.
Error compiling Cython file:
------------------------------------------------------------
...
for i in range(1, RK_STATE_LEN):
self.rng_state.key[i] = val[i]
self.rng_state.pos = i
self._bitgen.state = &self.rng_state
self._bitgen.next_uint64 = &mt19937_uint64
^
------------------------------------------------------------
_mt19937.pyx:138:35: Cannot assign type 'uint64_t (*)(void *) except? -1 nogil' to 'uint64_t (*)(void *) noexcept nogil'. Exception values are incompatible. Suggest adding 'noexcept' to type 'uint64_t (void *) except? -1 nogil'.
Processing numpy/random\_bounded_integers.pxd.in
Processing numpy/random\bit_generator.pyx
Processing numpy/random\mtrand.pyx
Processing numpy/random\_bounded_integers.pyx.in
Processing numpy/random\_common.pyx
Processing numpy/random\_generator.pyx
Processing numpy/random\_mt19937.pyx
Traceback (most recent call last):
File "C:\Users\dell\AppData\Local\Temp\pip-install-wovy_vlq\numpy_7bca60b545f04327b9b806e784a01c19\tools\cythonize.py", line 235, in <module>
main()
File "C:\Users\dell\AppData\Local\Temp\pip-install-wovy_vlq\numpy_7bca60b545f04327b9b806e784a01c19\tools\cythonize.py", line 231, in main
find_process_files(root_dir)
File "C:\Users\dell\AppData\Local\Temp\pip-install-wovy_vlq\numpy_7bca60b545f04327b9b806e784a01c19\tools\cythonize.py", line 222, in find_process_files
process(root_dir, fromfile, tofile, function, hash_db)
File "C:\Users\dell\AppData\Local\Temp\pip-install-wovy_vlq\numpy_7bca60b545f04327b9b806e784a01c19\tools\cythonize.py", line 188, in process
processor_function(fromfile, tofile)
File "C:\Users\dell\AppData\Local\Temp\pip-install-wovy_vlq\numpy_7bca60b545f04327b9b806e784a01c19\tools\cythonize.py", line 77, in process_pyx
subprocess.check_call(
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\subprocess.py", line 373, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['D:\\WorkSpace\\Anaconda_WorkSpace\\envs\\tf-gpu\\python.exe', '-m', 'cython', '-3', '--fast-fail', '-o', '_mt19937.c', '_mt19937.pyx']' returned non-zero exit status 1.
Cythonizing sources
Traceback (most recent call last):
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 353, in <module>
main()
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 335, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
File "D:\WorkSpace\Anaconda_WorkSpace\envs\tf-gpu\lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 149, in prepare_metadata_for_build_wheel
return hook(metadata_directory, config_settings)
File "C:\Users\dell\AppData\Local\Temp\pip-build-env-7cci4yxw\overlay\Lib\site-packages\setuptools\build_meta.py", line 157, in prepare_metadata_for_build_wheel
self.run_setup()
File "C:\Users\dell\AppData\Local\Temp\pip-build-env-7cci4yxw\overlay\Lib\site-packages\setuptools\build_meta.py", line 248, in run_setup
super(_BuildMetaLegacyBackend,
File "C:\Users\dell\AppData\Local\Temp\pip-build-env-7cci4yxw\overlay\Lib\site-packages\setuptools\build_meta.py", line 142, in run_setup
exec(compile(code, __file__, 'exec'), locals())
File "setup.py", line 499, in <module>
setup_package()
File "setup.py", line 479, in setup_package
generate_cython()
File "setup.py", line 274, in generate_cython
raise RuntimeError("Running cythonize failed!")
RuntimeError: Running cythonize failed!
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed
× Encountered error while generating package metadata.
╰─> See above for output.
note: This is an issue with the package mentioned above, not pip.
hint: See above for details.
(tf-gpu) C:\Users\dell>nvidia-smi
Tue Jan 23 11:21:00 2024
+---------------------------------------------------------------------------------------+
| NVIDIA-SMI 546.09 Driver Version: 546.09 CUDA Version: 12.3 |
|-----------------------------------------+----------------------+----------------------+
| GPU Name TCC/WDDM | Bus-Id Disp.A | Volatile Uncorr. ECC |
| Fan Temp Perf Pwr:Usage/Cap | Memory-Usage | GPU-Util Compute M. |
| | | MIG M. |
|=========================================+======================+======================|
| 0 NVIDIA GeForce RTX 2080 Ti WDDM | 00000000:73:00.0 Off | N/A |
| 18% 27C P8 15W / 250W | 0MiB / 11264MiB | 0% Default |
| | | N/A |
+-----------------------------------------+----------------------+----------------------+
| 1 NVIDIA GeForce RTX 2080 Ti WDDM | 00000000:A6:00.0 On | N/A |
| 18% 39C P8 18W / 250W | 1038MiB / 11264MiB | 9% Default |
| | | N/A |
+-----------------------------------------+----------------------+----------------------+
+---------------------------------------------------------------------------------------+
| Processes: |
| GPU GI CI PID Type Process name GPU Memory |
| ID ID Usage |
|=======================================================================================|
| 0 N/A N/A 33204 C ...der\Program\XMP\Program\APlayer.exe N/A |
| 1 N/A N/A 2508 C+G C:\Windows\explorer.exe N/A |
| 1 N/A N/A 7152 C+G ...3.0_x64__cv1g1gvanyjgm\WhatsApp.exe N/A |
| 1 N/A N/A 7240 C+G ...1.0_x64__8wekyb3d8bbwe\Video.UI.exe N/A |
| 1 N/A N/A 8168 C+G ..._x64__kzf8qxf38zg5c\Skype\Skype.exe N/A |
| 1 N/A N/A 8740 C+G ...1\extracted\runtime\WeChatAppEx.exe N/A |
| 1 N/A N/A 11840 C+G ..._x64__kzf8qxf38zg5c\Skype\Skype.exe N/A |
| 1 N/A N/A 12860 C+G ...pIntegrations\Grammarly.Desktop.exe N/A |
| 1 N/A N/A 14032 C+G ...2txyewy\StartMenuExperienceHost.exe N/A |
| 1 N/A N/A 15468 C+G ...t.LockApp_cw5n1h2txyewy\LockApp.exe N/A |
| 1 N/A N/A 16956 C+G ...CBS_cw5n1h2txyewy\TextInputHost.exe N/A |
| 1 N/A N/A 19276 C+G ...5n1h2txyewy\ShellExperienceHost.exe N/A |
| 1 N/A N/A 20896 C+G ...86)\Tencent\QQBrowser\QQBrowser.exe N/A |
| 1 N/A N/A 23328 C+G ...crosoft\Edge\Application\msedge.exe N/A |
| 1 N/A N/A 27128 C+G ...ogram Files\Unity Hub\Unity Hub.exe N/A |
| 1 N/A N/A 42980 C+G ....Search_cw5n1h2txyewy\SearchApp.exe N/A |
+---------------------------------------------------------------------------------------+
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62832/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62832/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62831
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62831/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62831/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62831/events
|
https://github.com/tensorflow/tensorflow/issues/62831
| 2,095,030,553 |
I_kwDOArmXAs5836EZ
| 62,831 |
Mirrored strategy model.load_weights() failure
|
{
"login": "SamKnightGit",
"id": 17261464,
"node_id": "MDQ6VXNlcjE3MjYxNDY0",
"avatar_url": "https://avatars.githubusercontent.com/u/17261464?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/SamKnightGit",
"html_url": "https://github.com/SamKnightGit",
"followers_url": "https://api.github.com/users/SamKnightGit/followers",
"following_url": "https://api.github.com/users/SamKnightGit/following{/other_user}",
"gists_url": "https://api.github.com/users/SamKnightGit/gists{/gist_id}",
"starred_url": "https://api.github.com/users/SamKnightGit/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/SamKnightGit/subscriptions",
"organizations_url": "https://api.github.com/users/SamKnightGit/orgs",
"repos_url": "https://api.github.com/users/SamKnightGit/repos",
"events_url": "https://api.github.com/users/SamKnightGit/events{/privacy}",
"received_events_url": "https://api.github.com/users/SamKnightGit/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
},
{
"id": 1097546578,
"node_id": "MDU6TGFiZWwxMDk3NTQ2NTc4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:keras",
"name": "comp:keras",
"color": "0052cc",
"default": false,
"description": "Keras related issues"
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
closed
| false |
{
"login": "SuryanarayanaY",
"id": 116063290,
"node_id": "U_kgDOBur8Og",
"avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/SuryanarayanaY",
"html_url": "https://github.com/SuryanarayanaY",
"followers_url": "https://api.github.com/users/SuryanarayanaY/followers",
"following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}",
"gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}",
"starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions",
"organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs",
"repos_url": "https://api.github.com/users/SuryanarayanaY/repos",
"events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}",
"received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "SuryanarayanaY",
"id": 116063290,
"node_id": "U_kgDOBur8Og",
"avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/SuryanarayanaY",
"html_url": "https://github.com/SuryanarayanaY",
"followers_url": "https://api.github.com/users/SuryanarayanaY/followers",
"following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}",
"gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}",
"starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions",
"organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs",
"repos_url": "https://api.github.com/users/SuryanarayanaY/repos",
"events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}",
"received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi @SamKnightGit ,\r\n\r\nThis is fixed in Keras3. Please verify the attached [gist](https://colab.research.google.com/gist/SuryanarayanaY/206895e35a67e2c6a082e0284b3c1703/62831_keras3ipynb.ipynb#scrollTo=fzlL6NqA5Hul).",
"Verified that works after upgrading to Keras3. Thanks for the help!",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62831\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62831\">No</a>\n",
"To confirm, will the fix for this come in a patch release for tf 2.15? Or will an upgrade to tf 2.16 be necessary when it is released?",
"Hi @SamKnightGit ,\r\n\r\n\r\nThis seems fixed with tf-nightly as Keras3 will be imported.I have tested with tf-nightly and used keras as tf.keras and it works fine. Please refer attached [gist](https://colab.research.google.com/gist/SuryanarayanaY/e7b4bb67b3f8f5d1312ba2b9056394dd/62831_tf-nightly_r2.ipynb).",
"Thanks @SuryanarayanaY, do you know what the timeline is for a fix for this issue? Is waiting for the tf 2.16 release (with keras 3) the only option or will there be a patch for this released to tf 2.15. Perhaps I should create a tf-keras issue detailing the bug to make a patch release for tf 2.15 possible?",
"Hi @SamKnightGit ,\r\n\r\nAs this got fixed in master,I doubt to cherry pick it as it will work with Keras3 and TF2.15v as backend also. However if you want this to cherry pick it for tf-keras=2.15v, you may raise a request at tf-keras repo and let's hear from there.",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62831\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62831\">No</a>\n"
] | 2024-01-23T00:41:46 | 2024-02-10T01:45:51 | 2024-02-10T01:45:49 |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
No -- appears to be fixed in Nightly
### Source
binary
### TensorFlow version
tf 2.15
### Custom code
Yes
### OS platform and distribution
Linux Ubuntu 23.04
### Mobile device
_No response_
### Python version
3.11
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
12.2
### GPU model and memory
_No response_
### Current behavior?
Expected:
`load_weights` succeeds when using `MirroredStrategy`
Actual:
`load_weights` raises an obscure error: "TypeError: unsupported operand type(s) for /: 'Dataset' and 'int'"
Note that this error does **not** occur when using `OneDeviceStrategy` and appears to have been fixed in `nightly` (example code runs successfully).
### Standalone code to reproduce the issue
```shell
[Colab Link](https://colab.research.google.com/drive/1EBxNuuPVq7fBEI4erxAS0ru0jiPXGTJj?usp=sharing)
Code:
import os
import tensorflow as tf
from tensorflow import keras
print("TensorFlow version:", tf.__version__)
strategy = tf.distribute.MirroredStrategy()
# strategy = tf.distribute.OneDeviceStrategy(device="/gpu:0")
MODEL_WEIGHTS_PATH = './model.weights.h5'
if os.path.exists(MODEL_WEIGHTS_PATH):
os.remove(MODEL_WEIGHTS_PATH)
with strategy.scope():
model = tf.keras.Sequential([tf.keras.layers.Dense(1, input_shape=(1,))])
model.compile(loss='mse', optimizer='sgd')
train_dataset = tf.data.Dataset.from_tensors(([1.], [1.])).repeat(100).batch(10)
val_dataset = tf.data.Dataset.from_tensors(([2.], [2.])).repeat(20).batch(10)
model.fit(
train_dataset,
epochs=10,
validation_data=val_dataset,
)
model.save_weights(MODEL_WEIGHTS_PATH)
model.load_weights(MODEL_WEIGHTS_PATH)
print("Weights loaded successfully!")
model.summary()
```
```
### Relevant log output
```shell
TypeError Traceback (most recent call last)
Cell In[8], line 25
19 model.fit(
20 train_dataset,
21 epochs=10,
22 validation_data=val_dataset,
23 )
24 model.save_weights(MODEL_WEIGHTS_PATH)
---> 25 model.load_weights(MODEL_WEIGHTS_PATH)
26 print("Weights loaded successfully!")
27 model.summary()
File ~/miniconda3/envs/tf214/lib/python3.11/site-packages/keras/src/utils/traceback_utils.py:70, in filter_traceback.<locals>.error_handler(*args, **kwargs)
67 filtered_tb = _process_traceback_frames(e.__traceback__)
68 # To get the full stack trace, call:
69 # `tf.debugging.disable_traceback_filtering()`
---> 70 raise e.with_traceback(filtered_tb) from None
71 finally:
72 del filtered_tb
File ~/miniconda3/envs/tf214/lib/python3.11/site-packages/tensorflow/python/distribute/values_util.py:214, in on_read_assign_cross_replica(var, value, read_value)
212 if var.aggregation == vs.VariableAggregation.SUM:
213 strategy = var._distribute_strategy # pylint: disable=protected-access
--> 214 tensor = math_ops.cast(tensor / strategy.num_replicas_in_sync,
215 var.dtype)
216 return assign_on_each_device(var, assign_on_device, tensor,
217 read_value)
TypeError: unsupported operand type(s) for /: 'Dataset' and 'int'
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62831/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62831/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62830
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62830/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62830/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62830/events
|
https://github.com/tensorflow/tensorflow/pull/62830
| 2,093,994,077 |
PR_kwDOArmXAs5kudIH
| 62,830 |
README.md
|
{
"login": "Shoubi007",
"id": 77432795,
"node_id": "MDQ6VXNlcjc3NDMyNzk1",
"avatar_url": "https://avatars.githubusercontent.com/u/77432795?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/Shoubi007",
"html_url": "https://github.com/Shoubi007",
"followers_url": "https://api.github.com/users/Shoubi007/followers",
"following_url": "https://api.github.com/users/Shoubi007/following{/other_user}",
"gists_url": "https://api.github.com/users/Shoubi007/gists{/gist_id}",
"starred_url": "https://api.github.com/users/Shoubi007/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Shoubi007/subscriptions",
"organizations_url": "https://api.github.com/users/Shoubi007/orgs",
"repos_url": "https://api.github.com/users/Shoubi007/repos",
"events_url": "https://api.github.com/users/Shoubi007/events{/privacy}",
"received_events_url": "https://api.github.com/users/Shoubi007/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 1169364259,
"node_id": "MDU6TGFiZWwxMTY5MzY0MjU5",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS",
"name": "size:XS",
"color": "adafea",
"default": false,
"description": "CL Change Size: Extra Small"
}
] |
closed
| false |
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).\n\nView this [failed invocation](https://github.com/tensorflow/tensorflow/pull/62830/checks?check_run_id=20729712453) of the CLA check for more information.\n\nFor the most up to date status, view the checks section at the bottom of the pull request."
] | 2024-01-22T14:04:12 | 2024-01-22T14:05:59 | 2024-01-22T14:05:59 |
NONE
| null | false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62830",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62830",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62830.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62830.patch",
"merged_at": null
}
| null |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62830/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62830/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62829
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62829/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62829/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62829/events
|
https://github.com/tensorflow/tensorflow/pull/62829
| 2,093,986,677 |
PR_kwDOArmXAs5kubgZ
| 62,829 |
Fix TOSA HardSwish Table generation for int8 inputs
|
{
"login": "jamwar01",
"id": 70524219,
"node_id": "MDQ6VXNlcjcwNTI0MjE5",
"avatar_url": "https://avatars.githubusercontent.com/u/70524219?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/jamwar01",
"html_url": "https://github.com/jamwar01",
"followers_url": "https://api.github.com/users/jamwar01/followers",
"following_url": "https://api.github.com/users/jamwar01/following{/other_user}",
"gists_url": "https://api.github.com/users/jamwar01/gists{/gist_id}",
"starred_url": "https://api.github.com/users/jamwar01/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/jamwar01/subscriptions",
"organizations_url": "https://api.github.com/users/jamwar01/orgs",
"repos_url": "https://api.github.com/users/jamwar01/repos",
"events_url": "https://api.github.com/users/jamwar01/events{/privacy}",
"received_events_url": "https://api.github.com/users/jamwar01/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 390482148,
"node_id": "MDU6TGFiZWwzOTA0ODIxNDg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/awaiting%20review",
"name": "awaiting review",
"color": "bc3869",
"default": false,
"description": "Pull request awaiting review"
},
{
"id": 1169365494,
"node_id": "MDU6TGFiZWwxMTY5MzY1NDk0",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:M",
"name": "size:M",
"color": "adafea",
"default": false,
"description": "CL Change Size: Medium"
}
] |
open
| false |
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi @jamwar01 Can you please resolve conflicts? Thank you!",
"This PR is stale because it has been open for 14 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This PR is stale because it has been open for 14 days with no activity. It will be closed if no further activity occurs. Thank you.",
"Hi @rdzhabarov Can you please review this PR ? Thank you!\r\n",
"Hi @jpienaar Can you please review this PR ? Thank you!",
"Hi @jpienaar Can you please review this PR ? Thank you!"
] | 2024-01-22T14:00:23 | 2024-06-07T16:45:30 | null |
CONTRIBUTOR
| null | false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62829",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62829",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62829.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62829.patch",
"merged_at": null
}
|
More closely match tflite kernel behaviour for integers when calculating HardSwish table
Change-Id: I32a1338fb15d3505d4bea432a8523c79d8f5da7a
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62829/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62829/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62828
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62828/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62828/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62828/events
|
https://github.com/tensorflow/tensorflow/issues/62828
| 2,093,570,204 |
I_kwDOArmXAs58yVic
| 62,828 |
Jax grad doesn't work with tfp jax module's Gram-Schmidt function because of a lax for loop
|
{
"login": "MintyMH",
"id": 139831663,
"node_id": "U_kgDOCFWpbw",
"avatar_url": "https://avatars.githubusercontent.com/u/139831663?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/MintyMH",
"html_url": "https://github.com/MintyMH",
"followers_url": "https://api.github.com/users/MintyMH/followers",
"following_url": "https://api.github.com/users/MintyMH/following{/other_user}",
"gists_url": "https://api.github.com/users/MintyMH/gists{/gist_id}",
"starred_url": "https://api.github.com/users/MintyMH/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/MintyMH/subscriptions",
"organizations_url": "https://api.github.com/users/MintyMH/orgs",
"repos_url": "https://api.github.com/users/MintyMH/repos",
"events_url": "https://api.github.com/users/MintyMH/events{/privacy}",
"received_events_url": "https://api.github.com/users/MintyMH/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473184161,
"node_id": "MDU6TGFiZWw0NzMxODQxNjE=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:support",
"name": "type:support",
"color": "159b2e",
"default": false,
"description": "Support issues"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
}
] |
closed
| false |
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"@MintyMH One workaround could be to rewrite the Gram-Schmidt function using vectorized operations and functional programming constructs like jax.map and jax.lax.cond. This avoids control flow and ensures compatibility with grad.\r\nThank you!",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62828\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62828\">No</a>\n"
] | 2024-01-22T10:18:23 | 2024-02-09T01:46:27 | 2024-02-09T01:46:23 |
NONE
| null | null | null |
### Issue type
Support
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
source
### TensorFlow version
0.24.0.dev20240121
### Custom code
Yes
### OS platform and distribution
Windows 10 Home 10.0.19045 Build 19045
### Mobile device
_No response_
### Python version
3.11.4
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
The gram-schmidt function seems to not work with jax's grad function because of a problematic lax for loop.
### Standalone code to reproduce the issue
```shell
import numpy as np
from tensorflow_probability.substrates import jax as tfp
import jax
import jax.numpy as jnp
from jax import grad, jit, vmap
from jax import config
config.update("jax_enable_x64", True)
matrices = np.random.random((20, 20, 4, 4))
def my_function(matrices):
Q = tfp.math.gram_schmidt(matrices)
return jnp.linalg.norm(Q)
temp = my_function(matrices) # runs fine
my_grad = jit(grad(my_function))
grad_temp = my_grad(matrices)
```
### Relevant log output
```shell
"name": "ValueError",
"message": "Reverse-mode differentiation does not work for lax.while_loop or lax.fori_loop with dynamic start/stop values. Try using lax.scan, or using fori_loop with static start/stop.",
"stack": "---------------------------------------------------------------------------
JaxStackTraceBeforeTransformation Traceback (most recent call last)
File <frozen runpy>:198, in _run_module_as_main()
File <frozen runpy>:88, in _run_code()
File c:\\Users\\bjmon\\anaconda3\\Lib\\site-packages\\ipykernel_launcher.py:17
15 from ipykernel import kernelapp as app
---> 17 app.launch_new_instance()
File c:\\Users\\bjmon\\anaconda3\\Lib\\site-packages\\traitlets\\config\\application.py:992, in launch_instance()
991 app.initialize(argv)
--> 992 app.start()
File c:\\Users\\bjmon\\anaconda3\\Lib\\site-packages\\ipykernel\\kernelapp.py:711, in start()
710 try:
--> 711 self.io_loop.start()
712 except KeyboardInterrupt:
File c:\\Users\\bjmon\\anaconda3\\Lib\\site-packages\\tornado\\platform\\asyncio.py:195, in start()
194 def start(self) -> None:
--> 195 self.asyncio_loop.run_forever()
File c:\\Users\\bjmon\\anaconda3\\Lib\\asyncio\\base_events.py:607, in run_forever()
606 while True:
--> 607 self._run_once()
608 if self._stopping:
File c:\\Users\\bjmon\\anaconda3\\Lib\\asyncio\\base_events.py:1922, in _run_once()
1921 else:
-> 1922 handle._run()
1923 handle = None
File c:\\Users\\bjmon\\anaconda3\\Lib\\asyncio\\events.py:80, in _run()
79 try:
---> 80 self._context.run(self._callback, *self._args)
81 except (SystemExit, KeyboardInterrupt):
File c:\\Users\\bjmon\\anaconda3\\Lib\\site-packages\\ipykernel\\kernelbase.py:510, in dispatch_queue()
509 try:
--> 510 await self.process_one()
511 except Exception:
File c:\\Users\\bjmon\\anaconda3\\Lib\\site-packages\\ipykernel\\kernelbase.py:499, in process_one()
498 return None
--> 499 await dispatch(*args)
File c:\\Users\\bjmon\\anaconda3\\Lib\\site-packages\\ipykernel\\kernelbase.py:406, in dispatch_shell()
405 if inspect.isawaitable(result):
--> 406 await result
407 except Exception:
File c:\\Users\\bjmon\\anaconda3\\Lib\\site-packages\\ipykernel\\kernelbase.py:729, in execute_request()
728 if inspect.isawaitable(reply_content):
--> 729 reply_content = await reply_content
731 # Flush output before sending the reply.
File c:\\Users\\bjmon\\anaconda3\\Lib\\site-packages\\ipykernel\\ipkernel.py:411, in do_execute()
410 if with_cell_id:
--> 411 res = shell.run_cell(
412 code,
413 store_history=store_history,
414 silent=silent,
415 cell_id=cell_id,
416 )
417 else:
File c:\\Users\\bjmon\\anaconda3\\Lib\\site-packages\\ipykernel\\zmqshell.py:531, in run_cell()
530 self._last_traceback = None
--> 531 return super().run_cell(*args, **kwargs)
File c:\\Users\\bjmon\\anaconda3\\Lib\\site-packages\\IPython\\core\\interactiveshell.py:3006, in run_cell()
3005 try:
-> 3006 result = self._run_cell(
3007 raw_cell, store_history, silent, shell_futures, cell_id
3008 )
3009 finally:
File c:\\Users\\bjmon\\anaconda3\\Lib\\site-packages\\IPython\\core\\interactiveshell.py:3061, in _run_cell()
3060 try:
-> 3061 result = runner(coro)
3062 except BaseException as e:
File c:\\Users\\bjmon\\anaconda3\\Lib\\site-packages\\IPython\\core\\async_helpers.py:129, in _pseudo_sync_runner()
128 try:
--> 129 coro.send(None)
130 except StopIteration as exc:
File c:\\Users\\bjmon\\anaconda3\\Lib\\site-packages\\IPython\\core\\interactiveshell.py:3266, in run_cell_async()
3263 interactivity = \"none\" if silent else self.ast_node_interactivity
-> 3266 has_raised = await self.run_ast_nodes(code_ast.body, cell_name,
3267 interactivity=interactivity, compiler=compiler, result=result)
3269 self.last_execution_succeeded = not has_raised
File c:\\Users\\bjmon\\anaconda3\\Lib\\site-packages\\IPython\\core\\interactiveshell.py:3445, in run_ast_nodes()
3444 asy = compare(code)
-> 3445 if await self.run_code(code, result, async_=asy):
3446 return True
File c:\\Users\\bjmon\\anaconda3\\Lib\\site-packages\\IPython\\core\\interactiveshell.py:3505, in run_code()
3504 else:
-> 3505 exec(code_obj, self.user_global_ns, self.user_ns)
3506 finally:
3507 # Reset our crash handler in place
Cell In[2], line 15
13 my_grad = jit(grad(my_function))
---> 15 grad_temp = my_grad(matrices)
Cell In[2], line 5, in my_function()
3 def my_function(matrices):
----> 5 Q = tfp.math.gram_schmidt(matrices)
7 return jnp.linalg.norm(Q)
File c:\\Users\\bjmon\\anaconda3\\Lib\\site-packages\\tensorflow_probability\\substrates\\jax\\math\\gram_schmidt.py:83, in gram_schmidt()
81 return vecs, i + 1
---> 83 vectors, _ = tf.while_loop(cond, body_fn, (vectors, tf.zeros([], tf.int32)))
84 vec_norm = tf.linalg.norm(vectors, ord=2, axis=-2, keepdims=True)
File c:\\Users\\bjmon\\anaconda3\\Lib\\site-packages\\tensorflow_probability\\python\\internal\\backend\\jax\\control_flow.py:90, in _while_loop_jax()
89 return cond(*args)
---> 90 return lax.while_loop(override_cond_fn, override_body_fn, loop_vars)
91 elif back_prop:
JaxStackTraceBeforeTransformation: ValueError: Reverse-mode differentiation does not work for lax.while_loop or lax.fori_loop with dynamic start/stop values. Try using lax.scan, or using fori_loop with static start/stop.
The preceding stack trace is the source of the JAX operation that, once transformed by JAX, triggered the following exception.
--------------------
The above exception was the direct cause of the following exception:
ValueError Traceback (most recent call last)
Cell In[2], line 15
11 print(temp)
13 my_grad = jit(grad(my_function))
---> 15 grad_temp = my_grad(matrices)
[... skipping hidden 21 frame]
File c:\\Users\\bjmon\\anaconda3\\Lib\\site-packages\\jax\\_src\\lax\\control_flow\\loops.py:1549, in _while_transpose_error(*_, **kwargs)
1548 def _while_transpose_error(*_, **kwargs):
-> 1549 raise ValueError(\"Reverse-mode differentiation does not work for \"
1550 \"lax.while_loop or lax.fori_loop with dynamic start/stop values. \"
1551 \"Try using lax.scan, or using fori_loop with static start/stop.\")
ValueError: Reverse-mode differentiation does not work for lax.while_loop or lax.fori_loop with dynamic start/stop values. Try using lax.scan, or using fori_loop with static start/stop."
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62828/reactions",
"total_count": 1,
"+1": 1,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62828/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62827
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62827/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62827/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62827/events
|
https://github.com/tensorflow/tensorflow/issues/62827
| 2,092,533,400 |
I_kwDOArmXAs58uYaY
| 62,827 |
Missing tensorflow-rocm wheel with python 3.12
|
{
"login": "bioinfornatics",
"id": 491720,
"node_id": "MDQ6VXNlcjQ5MTcyMA==",
"avatar_url": "https://avatars.githubusercontent.com/u/491720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/bioinfornatics",
"html_url": "https://github.com/bioinfornatics",
"followers_url": "https://api.github.com/users/bioinfornatics/followers",
"following_url": "https://api.github.com/users/bioinfornatics/following{/other_user}",
"gists_url": "https://api.github.com/users/bioinfornatics/gists{/gist_id}",
"starred_url": "https://api.github.com/users/bioinfornatics/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/bioinfornatics/subscriptions",
"organizations_url": "https://api.github.com/users/bioinfornatics/orgs",
"repos_url": "https://api.github.com/users/bioinfornatics/repos",
"events_url": "https://api.github.com/users/bioinfornatics/events{/privacy}",
"received_events_url": "https://api.github.com/users/bioinfornatics/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473173351,
"node_id": "MDU6TGFiZWw0NzMxNzMzNTE=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:build/install",
"name": "type:build/install",
"color": "159b2e",
"default": false,
"description": "Build and install issues"
},
{
"id": 473184161,
"node_id": "MDU6TGFiZWw0NzMxODQxNjE=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:support",
"name": "type:support",
"color": "159b2e",
"default": false,
"description": "Support issues"
},
{
"id": 1093464312,
"node_id": "MDU6TGFiZWwxMDkzNDY0MzEy",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:others",
"name": "type:others",
"color": "159b2e",
"default": false,
"description": "issues not falling in bug, perfromance, support, build and install or feature"
},
{
"id": 5206407904,
"node_id": "LA_kwDOArmXAs8AAAABNlN64A",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.12",
"name": "TF 2.12",
"color": "c5def5",
"default": false,
"description": "For issues related to Tensorflow 2.12"
}
] |
closed
| false |
{
"login": "SuryanarayanaY",
"id": 116063290,
"node_id": "U_kgDOBur8Og",
"avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/SuryanarayanaY",
"html_url": "https://github.com/SuryanarayanaY",
"followers_url": "https://api.github.com/users/SuryanarayanaY/followers",
"following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}",
"gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}",
"starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions",
"organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs",
"repos_url": "https://api.github.com/users/SuryanarayanaY/repos",
"events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}",
"received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "SuryanarayanaY",
"id": 116063290,
"node_id": "U_kgDOBur8Og",
"avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/SuryanarayanaY",
"html_url": "https://github.com/SuryanarayanaY",
"followers_url": "https://api.github.com/users/SuryanarayanaY/followers",
"following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}",
"gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}",
"starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions",
"organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs",
"repos_url": "https://api.github.com/users/SuryanarayanaY/repos",
"events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}",
"received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"3.12 doesn't seem supported even in the core of TF yet:\r\n\r\n- #62003",
"Hi @bioinfornatics ,\r\n\r\nTensorflow won't provide official pre built binaries of ROCM build. The one you are referring might be SIG builds. You can opt build from source enabling ROCM in ./configure step using the instructions [here](https://www.tensorflow.org/install/source).\r\n\r\nAlternatively you may contact [SIG](https://github.com/tensorflow/build) build repo here for any help.\r\n\r\nNote: As mentioned in above [comment](https://github.com/tensorflow/tensorflow/issues/62827#issuecomment-1902832429) Python 3.12v not yet supported by Tensorflow till Tf2.15v.Please refer [setup.py](https://github.com/tensorflow/tensorflow/blob/v2.15.0/tensorflow/tools/pip_package/setup.py) for same.\r\n\r\nThnaks!",
"thanks @johnthagen and @SuryanarayanaY , your response is very appreciated.\r\n I will take a look to the corresponding SIG.\r\nI wish you a nice day.",
"Hi @bioinfornatics ,\r\n\r\nThanks for confirmation.Please feel free to close the issue.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62827\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62827\">No</a>\n",
"any updates on this? tensorflow supports 3.12 now for more than half a year"
] | 2024-01-21T10:57:57 | 2024-06-04T12:35:26 | 2024-01-23T16:15:30 |
NONE
| null | null | null |
### Issue type
Build/Install
### Have you reproduced the bug with TensorFlow Nightly?
No
### Source
source: pypi
### TensorFlow version
2.12
### Custom code
Yes
### OS platform and distribution
Linux Fedora 39
### Mobile device
_No response_
### Python version
3.12
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
RocM
### Current behavior?
Fedora 39 provides Rocm 5.7 and python 3.12.
We can see [here](https://pypi.org/project/tensorflow-rocm/2.12.1.570/#files) that they are any wheel for python 3.12.
Could you push a wheel with python 3.12 and rocm 5.7 ?
### Standalone code to reproduce the issue
```shell
$ pip install tensorflow-rocm==2.12.1.570
ERROR: Could not find a version that satisfies the requirement tensorflow-rocm==2.12.1.570 (from versions: none)
ERROR: No matching distribution found for tensorflow-rocm==2.12.1.570
[notice] A new release of pip is available: 23.2.1 -> 23.3.2
[notice] To update, run: pip install --upgrade pip
```
```
### Relevant log output
_No response_
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62827/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62827/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62826
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62826/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62826/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62826/events
|
https://github.com/tensorflow/tensorflow/issues/62826
| 2,092,415,284 |
I_kwDOArmXAs58t7k0
| 62,826 |
add_metric method is marked as Permanently disabled
|
{
"login": "zqj2021",
"id": 91108785,
"node_id": "MDQ6VXNlcjkxMTA4Nzg1",
"avatar_url": "https://avatars.githubusercontent.com/u/91108785?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/zqj2021",
"html_url": "https://github.com/zqj2021",
"followers_url": "https://api.github.com/users/zqj2021/followers",
"following_url": "https://api.github.com/users/zqj2021/following{/other_user}",
"gists_url": "https://api.github.com/users/zqj2021/gists{/gist_id}",
"starred_url": "https://api.github.com/users/zqj2021/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/zqj2021/subscriptions",
"organizations_url": "https://api.github.com/users/zqj2021/orgs",
"repos_url": "https://api.github.com/users/zqj2021/repos",
"events_url": "https://api.github.com/users/zqj2021/events{/privacy}",
"received_events_url": "https://api.github.com/users/zqj2021/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 473173272,
"node_id": "MDU6TGFiZWw0NzMxNzMyNzI=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:feature",
"name": "type:feature",
"color": "159b2e",
"default": false,
"description": "Feature requests"
}
] |
closed
| false |
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"I changed the version from **2.15.0.post1** to **2.15.0** and this feature is supported. \r\nI wonder if the feature will be re-supported in a future release?",
"After testing, I found that this issue is caused by the introduction of keras3, and may be ready to deprecate this method in new versions of keras."
] | 2024-01-21T04:27:19 | 2024-01-22T06:00:21 | 2024-01-22T06:00:21 |
NONE
| null | null | null |
### Issue type
Feature Request
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
source
### TensorFlow version
tf 2.15
### Custom code
Yes
### OS platform and distribution
Linux Ubuntu 22
### Mobile device
_No response_
### Python version
3.11
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
Why is this method not being used, and are there any alternatives? I don't even know in which version it was retired.
### Standalone code to reproduce the issue
```shell
@keras_export(["keras.Layer", "keras.layers.Layer"])
class Layer(BackendLayer, Operation):
...
def add_metric(self):
# Permanently disabled
raise NotImplementedError
...
```
### Relevant log output
_No response_
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62826/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62826/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62825
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62825/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62825/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62825/events
|
https://github.com/tensorflow/tensorflow/issues/62825
| 2,092,204,733 |
I_kwDOArmXAs58tIK9
| 62,825 |
can't import keras 3 with tensorflow
|
{
"login": "aminaqi",
"id": 42599315,
"node_id": "MDQ6VXNlcjQyNTk5MzE1",
"avatar_url": "https://avatars.githubusercontent.com/u/42599315?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/aminaqi",
"html_url": "https://github.com/aminaqi",
"followers_url": "https://api.github.com/users/aminaqi/followers",
"following_url": "https://api.github.com/users/aminaqi/following{/other_user}",
"gists_url": "https://api.github.com/users/aminaqi/gists{/gist_id}",
"starred_url": "https://api.github.com/users/aminaqi/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/aminaqi/subscriptions",
"organizations_url": "https://api.github.com/users/aminaqi/orgs",
"repos_url": "https://api.github.com/users/aminaqi/repos",
"events_url": "https://api.github.com/users/aminaqi/events{/privacy}",
"received_events_url": "https://api.github.com/users/aminaqi/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
},
{
"id": 1097546578,
"node_id": "MDU6TGFiZWwxMDk3NTQ2NTc4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:keras",
"name": "comp:keras",
"color": "0052cc",
"default": false,
"description": "Keras related issues"
},
{
"id": 1205615612,
"node_id": "MDU6TGFiZWwxMjA1NjE1NjEy",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/subtype:%20ubuntu/linux",
"name": "subtype: ubuntu/linux",
"color": "b619ea",
"default": false,
"description": "Ubuntu/Linux Build/Installation Issues"
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
closed
| false |
{
"login": "Venkat6871",
"id": 147127861,
"node_id": "U_kgDOCMT-NQ",
"avatar_url": "https://avatars.githubusercontent.com/u/147127861?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/Venkat6871",
"html_url": "https://github.com/Venkat6871",
"followers_url": "https://api.github.com/users/Venkat6871/followers",
"following_url": "https://api.github.com/users/Venkat6871/following{/other_user}",
"gists_url": "https://api.github.com/users/Venkat6871/gists{/gist_id}",
"starred_url": "https://api.github.com/users/Venkat6871/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Venkat6871/subscriptions",
"organizations_url": "https://api.github.com/users/Venkat6871/orgs",
"repos_url": "https://api.github.com/users/Venkat6871/repos",
"events_url": "https://api.github.com/users/Venkat6871/events{/privacy}",
"received_events_url": "https://api.github.com/users/Venkat6871/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "Venkat6871",
"id": 147127861,
"node_id": "U_kgDOCMT-NQ",
"avatar_url": "https://avatars.githubusercontent.com/u/147127861?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/Venkat6871",
"html_url": "https://github.com/Venkat6871",
"followers_url": "https://api.github.com/users/Venkat6871/followers",
"following_url": "https://api.github.com/users/Venkat6871/following{/other_user}",
"gists_url": "https://api.github.com/users/Venkat6871/gists{/gist_id}",
"starred_url": "https://api.github.com/users/Venkat6871/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Venkat6871/subscriptions",
"organizations_url": "https://api.github.com/users/Venkat6871/orgs",
"repos_url": "https://api.github.com/users/Venkat6871/repos",
"events_url": "https://api.github.com/users/Venkat6871/events{/privacy}",
"received_events_url": "https://api.github.com/users/Venkat6871/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi **@aminaqi** ,\r\nCould you please try with again? I tried with TF2.15 and I cannot reproduce the error. Please check the [gist](https://colab.sandbox.google.com/gist/Venkat6871/2b00ef47cc7b79be1a6ea5190fbef10e/62825_2-15.ipynb) here.\r\nThank you!",
"> Hi **@aminaqi** , Could you please try with again? I tried with TF2.15 and I cannot reproduce the error. Please check the [gist](https://colab.sandbox.google.com/gist/Venkat6871/2b00ef47cc7b79be1a6ea5190fbef10e/62825_2-15.ipynb) here. Thank you!\r\n\r\ndid you try:\r\npip install -q --upgrade keras\r\npip install -q --upgrade keras-nlp\r\n",
"> > Hi **@aminaqi** , Could you please try with again? I tried with TF2.15 and I cannot reproduce the error. Please check the [gist](https://colab.sandbox.google.com/gist/Venkat6871/2b00ef47cc7b79be1a6ea5190fbef10e/62825_2-15.ipynb) here. Thank you!\r\n> \r\n> did you try: pip install -q --upgrade keras pip install -q --upgrade keras-nlp\r\n\r\n\r\n",
"> > > Hi **@aminaqi** , Could you please try with again? I tried with TF2.15 and I cannot reproduce the error. Please check the [gist](https://colab.sandbox.google.com/gist/Venkat6871/2b00ef47cc7b79be1a6ea5190fbef10e/62825_2-15.ipynb) here. Thank you!\r\n> > \r\n> > \r\n> > did you try: pip install -q --upgrade keras pip install -q --upgrade keras-nlp\r\n> \r\n> \r\n\r\nyou can also try import keras",
"Hi **@aminaqi** ,\r\n\r\nCurrently some of the compatible issues keras 3 is not importing in the tensorflow 2.15. But it is working fine with tf-nightly \r\ncould you please use tf-nightly. I am adding [gist](https://colab.sandbox.google.com/gist/Venkat6871/1d5b7a8d6fdb6a820149d34604c17387/62825_2-15-nightly-v.ipynb) here for your reference.\r\n\r\nThank you!",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62825\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62825\">No</a>\n"
] | 2024-01-20T18:59:49 | 2024-02-14T01:47:14 | 2024-02-14T01:47:11 |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
No
### Source
source
### TensorFlow version
2.15.01post
### Custom code
Yes
### OS platform and distribution
Linux Ubuntu 20.04
### Mobile device
_No response_
### Python version
_No response_
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
WARNING: Running pip as the 'root' user can result in broken permissions and conflicting behaviour with the system package manager. It is recommended to use a virtual environment instead: https://pip.pypa.io/warnings/venv
WARNING: Running pip as the 'root' user can result in broken permissions and conflicting behaviour with the system package manager. It is recommended to use a virtual environment instead: https://pip.pypa.io/warnings/venv
ERROR: pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts.
tensorflow 2.15.0.post1 requires keras<2.16,>=2.15.0, but you have keras 3.0.3 which is incompatible.
WARNING: Running pip as the 'root' user can result in broken permissions and conflicting behaviour with the system package manager. It is recommended to use a virtual environment instead: https://pip.pypa.io/warnings/venv
### Standalone code to reproduce the issue
```shell
!pip install -q --upgrade keras-nlp
!pip install -q --upgrade keras # Upgrade to Keras 3.
```
### Relevant log output
_No response_
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62825/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62825/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62824
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62824/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62824/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62824/events
|
https://github.com/tensorflow/tensorflow/issues/62824
| 2,092,191,195 |
I_kwDOArmXAs58tE3b
| 62,824 |
Panic when loading a keras LSTM model
|
{
"login": "rcostu",
"id": 994194,
"node_id": "MDQ6VXNlcjk5NDE5NA==",
"avatar_url": "https://avatars.githubusercontent.com/u/994194?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/rcostu",
"html_url": "https://github.com/rcostu",
"followers_url": "https://api.github.com/users/rcostu/followers",
"following_url": "https://api.github.com/users/rcostu/following{/other_user}",
"gists_url": "https://api.github.com/users/rcostu/gists{/gist_id}",
"starred_url": "https://api.github.com/users/rcostu/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/rcostu/subscriptions",
"organizations_url": "https://api.github.com/users/rcostu/orgs",
"repos_url": "https://api.github.com/users/rcostu/repos",
"events_url": "https://api.github.com/users/rcostu/events{/privacy}",
"received_events_url": "https://api.github.com/users/rcostu/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 1097546578,
"node_id": "MDU6TGFiZWwxMDk3NTQ2NTc4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:keras",
"name": "comp:keras",
"color": "0052cc",
"default": false,
"description": "Keras related issues"
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
closed
| false |
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"@rcostu,\r\nThank you for raising the issue. As this issue is related to keras Could you please post this issue on [keras-team/keras repo](https://github.com/keras-team/keras/issues). Thank you!",
"Thank you @tilakrayal for your prompt response.\r\n\r\nLeaving the link to the [opened issue](https://github.com/keras-team/keras/issues/19085) here as a reference.",
"@rcostu,\r\nCould you please feel free to move this issue to closed status, as it has been tracking in the Keras repo. Thank you!",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62824\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62824\">No</a>\n"
] | 2024-01-20T18:18:48 | 2024-01-30T10:58:14 | 2024-01-30T10:58:11 |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
binary
### TensorFlow version
v2.15.0-rc1-8-g6887368d6d4 2.15.0
### Custom code
Yes
### OS platform and distribution
Mac OS Sonoma 14.2.1
### Mobile device
_No response_
### Python version
Python 3.11
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
Hi,
Redirected this ticket from tfgo repository [Issue #88](https://github.com/galeone/tfgo/issues/88) as the problem seems to be in tensorflow library. The problem documented here happens exactly the same using either tfgo LoadModel function or tf LoadSavedModel function.
I have developed a model that makes a time series forecast receiving data from the last 60 days as floats and returns one float. I am training the model in Python and saving it with the export function as stated in the tf documentation for keras models.
I have tried anything that I have come up to but I didn't found any solution. There seems to be a reproduction of the very same scenario found on [#9169](https://github.com/tensorflow/tensorflow/issues/9169) from 2017 that was solved.
Any help is more than welcomed.
Thanks in advance!
### Standalone code to reproduce the issue
Model definition in python looks like this:
```shell
self.model= Sequential()
self.model.add(LSTM(50,return_sequences=True, input_shape= (x_train.shape[1],1)))
self.model.add(LSTM(50,return_sequences= False))
self.model.add(Dense(25))
self.model.add(Dense(25))
self.model.add(Dense(1))
#compile the model
self.model.compile(optimizer='adam',loss='mean_squared_error')
self.model.fit(x_train, y_train, batch_size=1, epochs=1, verbose=self.config.VERBOSE)
self.model.export("/Users/rcostumero/Downloads/test_model_go")
```
The saved_model_cli show has this output:
```shell
saved_model_cli show --all --dir /Users/rcostumero//Downloads/test_model_go
2024-01-09 21:09:48.934198: I tensorflow/core/platform/cpu_feature_guard.cc:182] This TensorFlow binary is optimized to use available CPU instructions in performance-critical operations.
To enable the following instructions: AVX2 FMA, in other operations, rebuild TensorFlow with the appropriate compiler flags.
MetaGraphDef with tag-set: 'serve' contains the following SignatureDefs:
signature_def['__saved_model_init_op']:
The given SavedModel SignatureDef contains the following input(s):
The given SavedModel SignatureDef contains the following output(s):
outputs['__saved_model_init_op'] tensor_info:
dtype: DT_INVALID
shape: unknown_rank
name: NoOp
Method name is:
signature_def['serve']:
The given SavedModel SignatureDef contains the following input(s):
inputs['lstm_2_input'] tensor_info:
dtype: DT_FLOAT
shape: (-1, 60, 1)
name: serve_lstm_2_input:0
The given SavedModel SignatureDef contains the following output(s):
outputs['output_0'] tensor_info:
dtype: DT_FLOAT
shape: (-1, 1)
name: StatefulPartitionedCall:0
Method name is: tensorflow/serving/predict
signature_def['serving_default']:
The given SavedModel SignatureDef contains the following input(s):
inputs['lstm_2_input'] tensor_info:
dtype: DT_FLOAT
shape: (-1, 60, 1)
name: serving_default_lstm_2_input:0
The given SavedModel SignatureDef contains the following output(s):
outputs['output_0'] tensor_info:
dtype: DT_FLOAT
shape: (-1, 1)
name: StatefulPartitionedCall_1:0
Method name is: tensorflow/serving/predict
The MetaGraph with tag set ['serve'] contains the following ops: {'DisableCopyOnRead', 'AssignVariableOp', 'Tanh', 'ShardedFilename', 'StridedSlice', 'MergeV2Checkpoints', 'Split', 'Mul', 'VarHandleOp', 'Placeholder', 'MatMul', 'BiasAdd', 'StatelessWhile', 'Const', 'Pack', 'Fill', 'Transpose', 'TensorListFromTensor', 'ReadVariableOp', 'Identity', 'TensorListStack', 'StaticRegexFullMatch', 'Select', 'RestoreV2', 'SaveV2', 'StringJoin', 'TensorListReserve', 'StatefulPartitionedCall', 'AddV2', 'Sigmoid', 'PartitionedCall', 'Shape', 'NoOp'}
Concrete Functions:
Function Name: 'serve'
Option #1
Callable with:
Argument #1
lstm_2_input: TensorSpec(shape=(None, 60, 1), dtype=tf.float32, name='lstm_2_input')
```
And the saved_model_cli run with this command is running as expected.
```shell
`saved_model_cli run --dir /Users/rcostumero//Downloads/test_model_go --tag_set serve --signature_def serve --input_exprs='lstm_2_input=[[[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1],[1]]]'`
```
However, when running the go code as in the example given it panics when loading the model. The code looks like this:
```shell
package main
import (
"fmt"
tf "github.com/galeone/tensorflow/tensorflow/go"
tg "github.com/galeone/tfgo"
)
func main() {
fmt.Println("starting")
model := tg.LoadModel("/Users/rcostumero/Downloads/test_model_go", []string{"serve"}, nil)
fmt.Println("model", model)
fakeInput, _ := tf.NewTensor([1][60][1]float32{})
fmt.Println("input:", fakeInput)
results := model.Exec([]tf.Output{
model.Op("StatefulPartitionedCall", 0),
}, map[tf.Output]*tf.Tensor{
model.Op("lstm_2_input", 0): fakeInput,
})
fmt.Println("results", results)
predictions := results[0]
fmt.Println(predictions.Value())
}
```
### Relevant log output
```shell
And the panic shows this error:
starting
2024-01-09 21:04:40.539502: I tensorflow/cc/saved_model/reader.cc:83] Reading SavedModel from: /Users/rcostumero/Downloads/test_model_go
2024-01-09 21:04:40.544963: I tensorflow/cc/saved_model/reader.cc:51] Reading meta graph with tags { serve }
2024-01-09 21:04:40.545008: I tensorflow/cc/saved_model/reader.cc:146] Reading SavedModel debug info (if present) from: /Users/rcostumero/Downloads/test_model_go
2024-01-09 21:04:40.545080: I tensorflow/core/platform/cpu_feature_guard.cc:182] This TensorFlow binary is optimized to use available CPU instructions in performance-critical operations.
To enable the following instructions: AVX AVX2 FMA, in other operations, rebuild TensorFlow with the appropriate compiler flags.
2024-01-09 21:04:40.572116: I tensorflow/compiler/mlir/mlir_graph_optimization_pass.cc:388] MLIR V1 optimization pass is not enabled
2024-01-09 21:04:40.578214: I tensorflow/cc/saved_model/loader.cc:233] Restoring SavedModel bundle.
SIGSEGV: segmentation violation
PC=0x1273c5e5d m=0 sigcode=1
signal arrived during cgo execution
goroutine 1 [syscall]:
runtime.cgocall(0x1001e1580, 0xc0000ed998)
/usr/local/opt/go/libexec/src/runtime/cgocall.go:157 +0x4b fp=0xc0000ed970 sp=0xc0000ed938 pc=0x100007fab
github.com/galeone/tensorflow/tensorflow/go._Cfunc_TF_LoadSessionFromSavedModel(0x7f7c88081d70, 0x0, 0x7f7c88081090, 0xc0000ae030, 0x1, 0x7f7c8781c600, 0x7f7c8777ae20, 0x7f7c8807ec40)
_cgo_gotypes.go:1000 +0x4c fp=0xc0000ed998 sp=0xc0000ed970 pc=0x1001cb7ac
github.com/galeone/tensorflow/tensorflow/go.LoadSavedModel.func2(0x7f7c88081d70, 0x5?, 0xc0000edb38, 0x1000a5de0?, 0x1?, 0xc0000c0000?)
/Users/rcostumero/src/go/pkg/mod/github.com/galeone/tensorflow/tensorflow/[email protected]/saved_model.go:72 +0x14d fp=0xc0000eda20 sp=0xc0000ed998 pc=0x1001d85ad
github.com/galeone/tensorflow/tensorflow/go.LoadSavedModel({0x1002a58f8, 0x29}, {0xc0000eddc0, 0x1, 0x9?}, 0xc0000b2680?)
/Users/rcostumero/src/go/pkg/mod/github.com/galeone/tensorflow/tensorflow/[email protected]/saved_model.go:72 +0x2b7 fp=0xc0000edbd0 sp=0xc0000eda20 pc=0x1001d7e97
github.com/galeone/tfgo.LoadModel({0x1002a58f8, 0x29}, {0xc0000eddc0, 0x1, 0x1}, 0x0?)
/Users/rcostumero/src/go/pkg/mod/github.com/galeone/[email protected]/model.go:36 +0x65 fp=0xc0000edc20 sp=0xc0000edbd0 pc=0x1001dfe05
main.main()
/Users/rcostumero/Developer/go/pkg/darwin_amd64/quadro/app.go:39 +0xaf fp=0xc0000edf40 sp=0xc0000edc20 pc=0x1001e026f
runtime.main()
/usr/local/opt/go/libexec/src/runtime/proc.go:267 +0x2bb fp=0xc0000edfe0 sp=0xc0000edf40 pc=0x100038e9b
runtime.goexit()
/usr/local/opt/go/libexec/src/runtime/asm_amd64.s:1650 +0x1 fp=0xc0000edfe8 sp=0xc0000edfe0 pc=0x100065101
goroutine 2 [force gc (idle)]:
runtime.gopark(0x0?, 0x0?, 0x0?, 0x0?, 0x0?)
/usr/local/opt/go/libexec/src/runtime/proc.go:398 +0xce fp=0xc000050fa8 sp=0xc000050f88 pc=0x1000392ee
runtime.goparkunlock(...)
/usr/local/opt/go/libexec/src/runtime/proc.go:404
runtime.forcegchelper()
/usr/local/opt/go/libexec/src/runtime/proc.go:322 +0xb3 fp=0xc000050fe0 sp=0xc000050fa8 pc=0x100039173
runtime.goexit()
/usr/local/opt/go/libexec/src/runtime/asm_amd64.s:1650 +0x1 fp=0xc000050fe8 sp=0xc000050fe0 pc=0x100065101
created by runtime.init.6 in goroutine 1
/usr/local/opt/go/libexec/src/runtime/proc.go:310 +0x1a
goroutine 3 [GC sweep wait]:
runtime.gopark(0x0?, 0x0?, 0x0?, 0x0?, 0x0?)
/usr/local/opt/go/libexec/src/runtime/proc.go:398 +0xce fp=0xc000051778 sp=0xc000051758 pc=0x1000392ee
runtime.goparkunlock(...)
/usr/local/opt/go/libexec/src/runtime/proc.go:404
runtime.bgsweep(0x0?)
/usr/local/opt/go/libexec/src/runtime/mgcsweep.go:280 +0x94 fp=0xc0000517c8 sp=0xc000051778 pc=0x1000261b4
runtime.gcenable.func1()
/usr/local/opt/go/libexec/src/runtime/mgc.go:200 +0x25 fp=0xc0000517e0 sp=0xc0000517c8 pc=0x10001b345
runtime.goexit()
/usr/local/opt/go/libexec/src/runtime/asm_amd64.s:1650 +0x1 fp=0xc0000517e8 sp=0xc0000517e0 pc=0x100065101
created by runtime.gcenable in goroutine 1
/usr/local/opt/go/libexec/src/runtime/mgc.go:200 +0x66
goroutine 4 [GC scavenge wait]:
runtime.gopark(0xc00002c230?, 0x1002e0538?, 0x1?, 0x0?, 0xc0000071e0?)
/usr/local/opt/go/libexec/src/runtime/proc.go:398 +0xce fp=0xc000051f70 sp=0xc000051f50 pc=0x1000392ee
runtime.goparkunlock(...)
/usr/local/opt/go/libexec/src/runtime/proc.go:404
runtime.(*scavengerState).park(0x100516c00)
/usr/local/opt/go/libexec/src/runtime/mgcscavenge.go:425 +0x49 fp=0xc000051fa0 sp=0xc000051f70 pc=0x100023a69
runtime.bgscavenge(0x0?)
/usr/local/opt/go/libexec/src/runtime/mgcscavenge.go:653 +0x3c fp=0xc000051fc8 sp=0xc000051fa0 pc=0x100023ffc
runtime.gcenable.func2()
/usr/local/opt/go/libexec/src/runtime/mgc.go:201 +0x25 fp=0xc000051fe0 sp=0xc000051fc8 pc=0x10001b2e5
runtime.goexit()
/usr/local/opt/go/libexec/src/runtime/asm_amd64.s:1650 +0x1 fp=0xc000051fe8 sp=0xc000051fe0 pc=0x100065101
created by runtime.gcenable in goroutine 1
/usr/local/opt/go/libexec/src/runtime/mgc.go:201 +0xa5
goroutine 18 [finalizer wait]:
runtime.gopark(0x198?, 0x10029b2c0?, 0x1?, 0xa4?, 0x0?)
/usr/local/opt/go/libexec/src/runtime/proc.go:398 +0xce fp=0xc000050620 sp=0xc000050600 pc=0x1000392ee
runtime.runfinq()
/usr/local/opt/go/libexec/src/runtime/mfinal.go:193 +0x107 fp=0xc0000507e0 sp=0xc000050620 pc=0x10001a367
runtime.goexit()
/usr/local/opt/go/libexec/src/runtime/asm_amd64.s:1650 +0x1 fp=0xc0000507e8 sp=0xc0000507e0 pc=0x100065101
created by runtime.createfing in goroutine 1
/usr/local/opt/go/libexec/src/runtime/mfinal.go:163 +0x3d
rax 0x7f7c87839a68
rbx 0x12c412970
rcx 0x7f7c897e5598
rdx 0x55
rdi 0x12c8baa00
rsi 0x7f7c897ffce0
rbp 0x7ff7bfefca10
rsp 0x7ff7bfefca10
r8 0x0
r9 0x3
r10 0x1
r11 0xfffffffffffffdb8
r12 0x7ff7bfefcb20
r13 0x7f7c897e5598
r14 0x7f7c897ecb40
r15 0x7ff7bfefcb00
rip 0x1273c5e5d
rflags 0x10202
cs 0x2b
fs 0x0
gs 0x0
exit status 2
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62824/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62824/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62823
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62823/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62823/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62823/events
|
https://github.com/tensorflow/tensorflow/issues/62823
| 2,092,114,927 |
I_kwDOArmXAs58syPv
| 62,823 |
Build a handwritten digit classifier app with TensorFlow Lite, step 3 - FAIL
|
{
"login": "jsonslim",
"id": 20793480,
"node_id": "MDQ6VXNlcjIwNzkzNDgw",
"avatar_url": "https://avatars.githubusercontent.com/u/20793480?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/jsonslim",
"html_url": "https://github.com/jsonslim",
"followers_url": "https://api.github.com/users/jsonslim/followers",
"following_url": "https://api.github.com/users/jsonslim/following{/other_user}",
"gists_url": "https://api.github.com/users/jsonslim/gists{/gist_id}",
"starred_url": "https://api.github.com/users/jsonslim/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/jsonslim/subscriptions",
"organizations_url": "https://api.github.com/users/jsonslim/orgs",
"repos_url": "https://api.github.com/users/jsonslim/repos",
"events_url": "https://api.github.com/users/jsonslim/events{/privacy}",
"received_events_url": "https://api.github.com/users/jsonslim/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473184161,
"node_id": "MDU6TGFiZWw0NzMxODQxNjE=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:support",
"name": "type:support",
"color": "159b2e",
"default": false,
"description": "Support issues"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
},
{
"id": 750616506,
"node_id": "MDU6TGFiZWw3NTA2MTY1MDY=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite",
"name": "comp:lite",
"color": "0052cc",
"default": false,
"description": "TF Lite related issues"
},
{
"id": 4989164230,
"node_id": "LA_kwDOArmXAs8AAAABKWCaxg",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/Android",
"name": "Android",
"color": "e99695",
"default": false,
"description": ""
}
] |
closed
| false |
{
"login": "pkgoogle",
"id": 132095473,
"node_id": "U_kgDOB9-d8Q",
"avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/pkgoogle",
"html_url": "https://github.com/pkgoogle",
"followers_url": "https://api.github.com/users/pkgoogle/followers",
"following_url": "https://api.github.com/users/pkgoogle/following{/other_user}",
"gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}",
"starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions",
"organizations_url": "https://api.github.com/users/pkgoogle/orgs",
"repos_url": "https://api.github.com/users/pkgoogle/repos",
"events_url": "https://api.github.com/users/pkgoogle/events{/privacy}",
"received_events_url": "https://api.github.com/users/pkgoogle/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "pkgoogle",
"id": 132095473,
"node_id": "U_kgDOB9-d8Q",
"avatar_url": "https://avatars.githubusercontent.com/u/132095473?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/pkgoogle",
"html_url": "https://github.com/pkgoogle",
"followers_url": "https://api.github.com/users/pkgoogle/followers",
"following_url": "https://api.github.com/users/pkgoogle/following{/other_user}",
"gists_url": "https://api.github.com/users/pkgoogle/gists{/gist_id}",
"starred_url": "https://api.github.com/users/pkgoogle/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/pkgoogle/subscriptions",
"organizations_url": "https://api.github.com/users/pkgoogle/orgs",
"repos_url": "https://api.github.com/users/pkgoogle/repos",
"events_url": "https://api.github.com/users/pkgoogle/events{/privacy}",
"received_events_url": "https://api.github.com/users/pkgoogle/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi @pkgoogle,\r\n\r\nI have reproduced the issue on window10 machine, the same error resulted. Could you please take a look.\r\n\r\nThank You",
"Hi @jsonslim, this repo is intended to be used with https://developer.android.com/codelabs/digit-classifier-tflite. Have you tried specifically following all the steps in that tutorial? If you are still running into problems, then let us know after which steps you failed (after you ensured you followed all the prior steps). That message is there, b/c that is the wrong build.gradle file, as noted in the comment there is an individual module's build.gradle file where you should make that edit. Thanks for your help!",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62823\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62823\">No</a>\n",
"Same issuein macOS Sonoma. Even following the step by step instructions of the codelab.",
"Fixed it by updating `kotlin_version` to `1.9.23`, `com.android.tools.build:gradle` to `8.3.1` and adding the `namespace` to the module's `android` block.",
"> Fixed it by updating `kotlin_version` to `1.9.23`, `com.android.tools.build:gradle` to `8.3.1` and adding the `namespace` to the module's `android` block.\r\n\r\nthank you this worked only thing different with com.android.tools.build:gradle 8.2.2 "
] | 2024-01-20T15:46:40 | 2024-05-20T20:15:27 | 2024-02-23T01:46:47 |
NONE
| null | null | null |
When I try import the project to Android studio from the lite/codelabs/digit_classifier/android/start/
I get the following error message:
```
"Failed to notify dependency resolution listener.
'void org.gradle.api.artifacts.DependencySubstitutions$Substitution.with(org.gradle.api.artifacts.component.ComponentSelector)'"
```

Also in the tutorial this step says:

But in Android studio in the build.grable the commented line says the opposite:

Like - don't do it.
Seems like the project is broken. I tried it in Windows10 machine and in Ubuntu 20
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62823/reactions",
"total_count": 1,
"+1": 1,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62823/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62822
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62822/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62822/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62822/events
|
https://github.com/tensorflow/tensorflow/issues/62822
| 2,092,082,233 |
I_kwDOArmXAs58sqQ5
| 62,822 |
import graph with a lower producer version or update graph to newer version
|
{
"login": "singersbalm",
"id": 122386799,
"node_id": "U_kgDOB0t5bw",
"avatar_url": "https://avatars.githubusercontent.com/u/122386799?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/singersbalm",
"html_url": "https://github.com/singersbalm",
"followers_url": "https://api.github.com/users/singersbalm/followers",
"following_url": "https://api.github.com/users/singersbalm/following{/other_user}",
"gists_url": "https://api.github.com/users/singersbalm/gists{/gist_id}",
"starred_url": "https://api.github.com/users/singersbalm/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/singersbalm/subscriptions",
"organizations_url": "https://api.github.com/users/singersbalm/orgs",
"repos_url": "https://api.github.com/users/singersbalm/repos",
"events_url": "https://api.github.com/users/singersbalm/events{/privacy}",
"received_events_url": "https://api.github.com/users/singersbalm/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473184161,
"node_id": "MDU6TGFiZWw0NzMxODQxNjE=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:support",
"name": "type:support",
"color": "159b2e",
"default": false,
"description": "Support issues"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
},
{
"id": 1097545817,
"node_id": "MDU6TGFiZWwxMDk3NTQ1ODE3",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:apis",
"name": "comp:apis",
"color": "0052cc",
"default": false,
"description": "Highlevel API related issues"
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
closed
| false |
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"I am trying to get this old project running in the latest version of TensorFlow so I can start migrating it to v2. Before I replace each function I want to get it running the the v1 api",
"@singersbalm To use the existing graph saved with the older TensorFlow version in your current session with a newer version. However, some functionality might be limited or compatibility issues might arise.\r\nTo do this, simply use the `import_graph_def `function with the `producer_version` argument explicitly set to the older version. We recommend you to use the latest TF version by referring to the migration . If you still have any concern on TF v1, please post the issue on TF [Forum](https://discuss.tensorflow.org/). Thank you!",
"there is no producer_version argument in [import_graph_def](https://www.tensorflow.org/api_docs/python/tf/graph_util/import_graph_def). the import attribute is of type GraphDef and not a path",
"@singersbalm In order to expedite the trouble-shooting process, please provide the code snippet to reproduce the issue reported here. Thank you!",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62822\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62822\">No</a>\n"
] | 2024-01-20T14:52:56 | 2024-02-10T01:45:55 | 2024-02-10T01:45:51 |
NONE
| null | null | null |
### Issue type
Support
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
source
### TensorFlow version
2.15
### Custom code
Yes
### OS platform and distribution
macOS
### Mobile device
_No response_
### Python version
3.9
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
can't restore because file structure changed. the .index file starts with CB1/ML/biases.
### Standalone code to reproduce the issue
```shell
restore = tf.train.import_meta_graph('./Train.meta')
restore.restore(self.sess, tf.train.latest_checkpoint('./'))
```
### Relevant log output
```shell
2024-01-20 15:40:22.083387: W tensorflow/core/common_runtime/graph_constructor.cc:1583] Importing a graph with a lower producer version 38 into an existing graph with producer version 1645. Shape inference will have run different parts of the graph with different producer versions.
2024-01-20 15:40:35.939842: W tensorflow/core/framework/op_kernel.cc:1839] OP_REQUIRES failed at save_restore_v2_ops.cc:233 : NOT_FOUND: Key CB1/ML/bias not found in checkpoint
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62822/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62822/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62821
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62821/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62821/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62821/events
|
https://github.com/tensorflow/tensorflow/issues/62821
| 2,091,771,652 |
I_kwDOArmXAs58recE
| 62,821 |
tf.data.Options not affecting autotune parallelism behavior
|
{
"login": "franklsf95",
"id": 2411818,
"node_id": "MDQ6VXNlcjI0MTE4MTg=",
"avatar_url": "https://avatars.githubusercontent.com/u/2411818?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/franklsf95",
"html_url": "https://github.com/franklsf95",
"followers_url": "https://api.github.com/users/franklsf95/followers",
"following_url": "https://api.github.com/users/franklsf95/following{/other_user}",
"gists_url": "https://api.github.com/users/franklsf95/gists{/gist_id}",
"starred_url": "https://api.github.com/users/franklsf95/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/franklsf95/subscriptions",
"organizations_url": "https://api.github.com/users/franklsf95/orgs",
"repos_url": "https://api.github.com/users/franklsf95/repos",
"events_url": "https://api.github.com/users/franklsf95/events{/privacy}",
"received_events_url": "https://api.github.com/users/franklsf95/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 1097547147,
"node_id": "MDU6TGFiZWwxMDk3NTQ3MTQ3",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:ops",
"name": "comp:ops",
"color": "0052cc",
"default": false,
"description": "OPs related issues"
},
{
"id": 5922361893,
"node_id": "LA_kwDOArmXAs8AAAABYQASJQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF2.14",
"name": "TF2.14",
"color": "b60205",
"default": false,
"description": "For issues related to Tensorflow 2.14.x"
}
] |
closed
| false |
{
"login": "Venkat6871",
"id": 147127861,
"node_id": "U_kgDOCMT-NQ",
"avatar_url": "https://avatars.githubusercontent.com/u/147127861?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/Venkat6871",
"html_url": "https://github.com/Venkat6871",
"followers_url": "https://api.github.com/users/Venkat6871/followers",
"following_url": "https://api.github.com/users/Venkat6871/following{/other_user}",
"gists_url": "https://api.github.com/users/Venkat6871/gists{/gist_id}",
"starred_url": "https://api.github.com/users/Venkat6871/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Venkat6871/subscriptions",
"organizations_url": "https://api.github.com/users/Venkat6871/orgs",
"repos_url": "https://api.github.com/users/Venkat6871/repos",
"events_url": "https://api.github.com/users/Venkat6871/events{/privacy}",
"received_events_url": "https://api.github.com/users/Venkat6871/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "Venkat6871",
"id": 147127861,
"node_id": "U_kgDOCMT-NQ",
"avatar_url": "https://avatars.githubusercontent.com/u/147127861?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/Venkat6871",
"html_url": "https://github.com/Venkat6871",
"followers_url": "https://api.github.com/users/Venkat6871/followers",
"following_url": "https://api.github.com/users/Venkat6871/following{/other_user}",
"gists_url": "https://api.github.com/users/Venkat6871/gists{/gist_id}",
"starred_url": "https://api.github.com/users/Venkat6871/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Venkat6871/subscriptions",
"organizations_url": "https://api.github.com/users/Venkat6871/orgs",
"repos_url": "https://api.github.com/users/Venkat6871/repos",
"events_url": "https://api.github.com/users/Venkat6871/events{/privacy}",
"received_events_url": "https://api.github.com/users/Venkat6871/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"@franklsf95 Experiment with different values and observe the impact on parallelism. If needed, you can manually set num_parallel_calls based on your observations for better control.```\nimport time\nimport os\n\nimport tensorflow as tf\n\ntf.get_logger().setLevel(\"DEBUG\")\n\nos.environ[\"TF_CPP_MIN_LOG_LEVEL\"] = \"0\"\nos.environ[\"TF_CPP_MIN_VLOG_LEVEL\"] = \"0\"\n\ndef foo(i):\n for _ in range(20_000_000):\n i += 1\n return i\n\nstart = time.perf_counter()\n\noptions = tf.data.Options()\noptions.autotune.cpu_budget = 1\n\nds = tf.data.Dataset.range(16).with_options(options)\nds = ds.map(\n lambda item: tf.numpy_function(\n foo,\n [item],\n Tout=tf.int64,\n ),\n num_parallel_calls=1, # Set this explicitly\n)\n\nret = 0\nfor row in ds:\n print(time.perf_counter() - start, row)\n ret += row\n\n```. Try this if it works. ",
"Hi **@franklsf95** ,\r\nI tried to run your code on Colab using TF v2.15 and nightly versions, Please find the [gist](https://colab.sandbox.google.com/gist/Venkat6871/e0fc92b9013619228113cc07146f96fb/62821.ipynb) here for reference. \r\n\r\nThank you!",
"OK I was able to make tensorflow to start from parallelism=1 to respect the limit. By default, it starts with parallelism=<number of cores on your machine> which in my case was 16, so it just blasted through everything.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62821\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62821\">No</a>\n"
] | 2024-01-20T00:47:42 | 2024-01-30T01:58:59 | 2024-01-30T01:58:55 |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
No
### Source
source
### TensorFlow version
v2.14.0-rc1-21-g4dacf3f368e 2.14.0
### Custom code
No
### OS platform and distribution
_No response_
### Mobile device
_No response_
### Python version
3.10.13
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
My understanding is that by setting `options.autotune.cpu_budget = 1`, the autotuner won't use more than 1 CPU for the map tasks when using the autotuned parallelism (`num_parallel_calls=tf.data.experimental.AUTOTUNE`). However, the log shows that the tasks returned in 2 batches, one around 8 seconds, and one around 13 seconds. This is likely a parallelism of 8 (I have 8 cores on my machine). My questions are:
1. What can I do to ask tf.data to respect the CPU budget?
2. Is there a way to debug the autotuner? E.g. how can I find out what parallelism the autotuner chose?
### Standalone code to reproduce the issue
```python
import time
import os
import tensorflow as tf
tf.get_logger().setLevel("DEBUG")
os.environ["TF_CPP_MIN_LOG_LEVEL"] = "0"
os.environ["TF_CPP_MIN_VLOG_LEVEL"] = "0"
def foo(i):
for _ in range(20_000_000):
i += 1
return i
start = time.perf_counter()
options = tf.data.Options()
options.autotune.cpu_budget = 1
ds = tf.data.Dataset.range(16).with_options(options)
ds = ds.map(
lambda item: tf.numpy_function(
foo,
[item],
Tout=tf.int64,
),
# num_parallel_calls=1,
num_parallel_calls=tf.data.experimental.AUTOTUNE,
)
ret = 0
for row in ds:
print(time.perf_counter() - start, row)
ret += row
```
### Relevant log output
```shell
# With manually specified num_parallel_calls=1:
0.9090110249817371 tf.Tensor(20000000, shape=(), dtype=int64)
1.7222977789351717 tf.Tensor(20000001, shape=(), dtype=int64)
2.547924594953656 tf.Tensor(20000002, shape=(), dtype=int64)
3.3709740849444643 tf.Tensor(20000003, shape=(), dtype=int64)
4.167228076024912 tf.Tensor(20000004, shape=(), dtype=int64)
4.973599593038671 tf.Tensor(20000005, shape=(), dtype=int64)
5.799614907009527 tf.Tensor(20000006, shape=(), dtype=int64)
6.618450765963644 tf.Tensor(20000007, shape=(), dtype=int64)
7.427832546993159 tf.Tensor(20000008, shape=(), dtype=int64)
8.226964170928113 tf.Tensor(20000009, shape=(), dtype=int64)
9.045983245014213 tf.Tensor(20000010, shape=(), dtype=int64)
9.841567247989587 tf.Tensor(20000011, shape=(), dtype=int64)
10.652729655965231 tf.Tensor(20000012, shape=(), dtype=int64)
11.432073520030826 tf.Tensor(20000013, shape=(), dtype=int64)
12.26768407295458 tf.Tensor(20000014, shape=(), dtype=int64)
13.078245428041555 tf.Tensor(20000015, shape=(), dtype=int64)
# With num_parallel_calls=tf.data.experimental.AUTOTUNE:
7.32448233210016 tf.Tensor(20000000, shape=(), dtype=int64)
7.346081388066523 tf.Tensor(20000001, shape=(), dtype=int64)
7.39306910301093 tf.Tensor(20000002, shape=(), dtype=int64)
7.404705744003877 tf.Tensor(20000003, shape=(), dtype=int64)
7.452494919067249 tf.Tensor(20000004, shape=(), dtype=int64)
8.152240323019214 tf.Tensor(20000005, shape=(), dtype=int64)
8.226954131037928 tf.Tensor(20000006, shape=(), dtype=int64)
8.243354345089756 tf.Tensor(20000007, shape=(), dtype=int64)
11.689252487034537 tf.Tensor(20000008, shape=(), dtype=int64)
12.99928606802132 tf.Tensor(20000009, shape=(), dtype=int64)
13.021037437021732 tf.Tensor(20000010, shape=(), dtype=int64)
13.037309881066903 tf.Tensor(20000011, shape=(), dtype=int64)
13.363138618064113 tf.Tensor(20000012, shape=(), dtype=int64)
13.37413718609605 tf.Tensor(20000013, shape=(), dtype=int64)
13.395835493109189 tf.Tensor(20000014, shape=(), dtype=int64)
13.50603799300734 tf.Tensor(20000015, shape=(), dtype=int64)
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62821/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62821/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62820
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62820/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62820/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62820/events
|
https://github.com/tensorflow/tensorflow/issues/62820
| 2,091,695,637 |
I_kwDOArmXAs58rL4V
| 62,820 |
Numpy Based Indexing and Updates in Tensors
|
{
"login": "Impure-King",
"id": 99410452,
"node_id": "U_kgDOBeziFA",
"avatar_url": "https://avatars.githubusercontent.com/u/99410452?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/Impure-King",
"html_url": "https://github.com/Impure-King",
"followers_url": "https://api.github.com/users/Impure-King/followers",
"following_url": "https://api.github.com/users/Impure-King/following{/other_user}",
"gists_url": "https://api.github.com/users/Impure-King/gists{/gist_id}",
"starred_url": "https://api.github.com/users/Impure-King/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Impure-King/subscriptions",
"organizations_url": "https://api.github.com/users/Impure-King/orgs",
"repos_url": "https://api.github.com/users/Impure-King/repos",
"events_url": "https://api.github.com/users/Impure-King/events{/privacy}",
"received_events_url": "https://api.github.com/users/Impure-King/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473173272,
"node_id": "MDU6TGFiZWw0NzMxNzMyNzI=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:feature",
"name": "type:feature",
"color": "159b2e",
"default": false,
"description": "Feature requests"
},
{
"id": 1097545817,
"node_id": "MDU6TGFiZWwxMDk3NTQ1ODE3",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:apis",
"name": "comp:apis",
"color": "0052cc",
"default": false,
"description": "Highlevel API related issues"
}
] |
closed
| false |
{
"login": "sachinprasadhs",
"id": 73069040,
"node_id": "MDQ6VXNlcjczMDY5MDQw",
"avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sachinprasadhs",
"html_url": "https://github.com/sachinprasadhs",
"followers_url": "https://api.github.com/users/sachinprasadhs/followers",
"following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}",
"gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions",
"organizations_url": "https://api.github.com/users/sachinprasadhs/orgs",
"repos_url": "https://api.github.com/users/sachinprasadhs/repos",
"events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}",
"received_events_url": "https://api.github.com/users/sachinprasadhs/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "sachinprasadhs",
"id": 73069040,
"node_id": "MDQ6VXNlcjczMDY5MDQw",
"avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sachinprasadhs",
"html_url": "https://github.com/sachinprasadhs",
"followers_url": "https://api.github.com/users/sachinprasadhs/followers",
"following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}",
"gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions",
"organizations_url": "https://api.github.com/users/sachinprasadhs/orgs",
"repos_url": "https://api.github.com/users/sachinprasadhs/repos",
"events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}",
"received_events_url": "https://api.github.com/users/sachinprasadhs/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"or at least support this type of indexing after ``experimental_enable_numpy_behavior`` has been applied.",
"Are there any updates or plan for this feature?",
"@Impure-King,\r\nHave you got the chance to test the code with `tf.tensor_scatter_nd_update`, where I can see that replacing the specific index value of a tensor using the mentioned API.\r\n\r\n```\r\narray = tf.constant([1, 2, 3, 4])\r\nvalue = 1\r\nindices = [1]\r\n\r\nnew_array = tf.tensor_scatter_nd_update(array, [indices], [value])\r\nprint(new_array)\r\n```\r\n\r\nThank you!",
"I have, but the reason I added this as a ``feature request`` is because a function is a bit verbose to replace standard indexing. I was wondering if it was possible to add standard index update instead, since it would make ease use better.",
"Hi as of now, you can do the update using the following method.\r\n\r\n```python\r\nfrom tensorflow.compiler.tf2xla.python import xla\r\n\r\noutput = xla.dynamic_update_slice(input, update, indices)\r\n```\r\n\r\nThere has been an RFC proposed, but there is not much progress on it so far.\r\n\r\nYou can close this issue and track the progress in the on going discussion here \r\nhttps://github.com/tensorflow/tensorflow/issues/33131\r\n\r\nAnd here is the RFC for more details. https://github.com/tensorflow/community/pull/433",
"I see."
] | 2024-01-19T23:43:07 | 2024-01-24T23:55:55 | 2024-01-24T23:55:54 |
NONE
| null | null | null |
### Issue type
Feature Request
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
binary
### TensorFlow version
2.15
### Custom code
Yes
### OS platform and distribution
WSL Ubuntu 22.04.3 LTS
### Mobile device
N/A
### Python version
3.11
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
N/A
### GPU model and memory
_No response_
### Current behavior?
Can eager tensors finally get support for numpy indexing? Since eager mode is design to reduce programming fatigue, it personally makes no sense to index using a function like ``tf.scatter_nd``. It also makes the code less readable, when implementing SOTA models and considering the expectations of modern frameworks, it might be better to overhaul the immutability.
### Standalone code to reproduce the issue
```shell
This code should ideally work:
import tensorflow as tf
from tensorflow import keras
array = tf.constant([1, 2, 3, 4])
array[1] = 1
print(array) # [1, 1, 3, 4]
```
### Relevant log output
_No response_
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62820/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62820/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62819
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62819/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62819/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62819/events
|
https://github.com/tensorflow/tensorflow/pull/62819
| 2,091,438,173 |
PR_kwDOArmXAs5kl7Ps
| 62,819 |
[oneDNN][Bug Fix]Fix a pooling ops primitive caching problem
|
{
"login": "gzmkl",
"id": 29215195,
"node_id": "MDQ6VXNlcjI5MjE1MTk1",
"avatar_url": "https://avatars.githubusercontent.com/u/29215195?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gzmkl",
"html_url": "https://github.com/gzmkl",
"followers_url": "https://api.github.com/users/gzmkl/followers",
"following_url": "https://api.github.com/users/gzmkl/following{/other_user}",
"gists_url": "https://api.github.com/users/gzmkl/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gzmkl/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gzmkl/subscriptions",
"organizations_url": "https://api.github.com/users/gzmkl/orgs",
"repos_url": "https://api.github.com/users/gzmkl/repos",
"events_url": "https://api.github.com/users/gzmkl/events{/privacy}",
"received_events_url": "https://api.github.com/users/gzmkl/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 390482148,
"node_id": "MDU6TGFiZWwzOTA0ODIxNDg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/awaiting%20review",
"name": "awaiting review",
"color": "bc3869",
"default": false,
"description": "Pull request awaiting review"
},
{
"id": 987666414,
"node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull",
"name": "ready to pull",
"color": "2cd643",
"default": false,
"description": "PR ready for merge process"
},
{
"id": 1104829434,
"node_id": "MDU6TGFiZWwxMTA0ODI5NDM0",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:mkl",
"name": "comp:mkl",
"color": "0052cc",
"default": false,
"description": "MKL related issues"
},
{
"id": 1169364259,
"node_id": "MDU6TGFiZWwxMTY5MzY0MjU5",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS",
"name": "size:XS",
"color": "adafea",
"default": false,
"description": "CL Change Size: Extra Small"
}
] |
closed
| false |
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "penpornk",
"id": 38085909,
"node_id": "MDQ6VXNlcjM4MDg1OTA5",
"avatar_url": "https://avatars.githubusercontent.com/u/38085909?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/penpornk",
"html_url": "https://github.com/penpornk",
"followers_url": "https://api.github.com/users/penpornk/followers",
"following_url": "https://api.github.com/users/penpornk/following{/other_user}",
"gists_url": "https://api.github.com/users/penpornk/gists{/gist_id}",
"starred_url": "https://api.github.com/users/penpornk/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/penpornk/subscriptions",
"organizations_url": "https://api.github.com/users/penpornk/orgs",
"repos_url": "https://api.github.com/users/penpornk/repos",
"events_url": "https://api.github.com/users/penpornk/events{/privacy}",
"received_events_url": "https://api.github.com/users/penpornk/received_events",
"type": "User",
"site_admin": false
},
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[] | 2024-01-19T21:19:14 | 2024-01-23T21:31:24 | 2024-01-23T21:31:23 |
CONTRIBUTOR
| null | false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62819",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62819",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62819.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62819.patch",
"merged_at": "2024-01-23T21:31:23"
}
|
This PR fixes a problem which is related to oneDNN pooling ops primitive caching.
Related ticket is: https://github.com/tensorflow/tensorflow/issues/61482
The problem occurs when running the max (applicable to avg) pooling op twice with same input sizes
1. first time is with NCHW format
2. the other is with NHWC format.
The fix is done by adding src format into caching key.
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62819/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62819/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62818
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62818/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62818/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62818/events
|
https://github.com/tensorflow/tensorflow/pull/62818
| 2,091,175,348 |
PR_kwDOArmXAs5klCI9
| 62,818 |
Testing commit
|
{
"login": "ChiuenHuh",
"id": 107969724,
"node_id": "U_kgDOBm98vA",
"avatar_url": "https://avatars.githubusercontent.com/u/107969724?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/ChiuenHuh",
"html_url": "https://github.com/ChiuenHuh",
"followers_url": "https://api.github.com/users/ChiuenHuh/followers",
"following_url": "https://api.github.com/users/ChiuenHuh/following{/other_user}",
"gists_url": "https://api.github.com/users/ChiuenHuh/gists{/gist_id}",
"starred_url": "https://api.github.com/users/ChiuenHuh/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/ChiuenHuh/subscriptions",
"organizations_url": "https://api.github.com/users/ChiuenHuh/orgs",
"repos_url": "https://api.github.com/users/ChiuenHuh/repos",
"events_url": "https://api.github.com/users/ChiuenHuh/events{/privacy}",
"received_events_url": "https://api.github.com/users/ChiuenHuh/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 1169364259,
"node_id": "MDU6TGFiZWwxMTY5MzY0MjU5",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS",
"name": "size:XS",
"color": "adafea",
"default": false,
"description": "CL Change Size: Extra Small"
},
{
"id": 1593512946,
"node_id": "MDU6TGFiZWwxNTkzNTEyOTQ2",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/invalid",
"name": "invalid",
"color": "db6f57",
"default": true,
"description": "Hacktoberfest spam PR"
}
] |
closed
| true |
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).\n\nView this [failed invocation](https://github.com/tensorflow/tensorflow/pull/62818/checks?check_run_id=20669956708) of the CLA check for more information.\n\nFor the most up to date status, view the checks section at the bottom of the pull request."
] | 2024-01-19T19:09:09 | 2024-01-20T21:40:39 | 2024-01-19T19:12:21 |
NONE
|
spam
| false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62818",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62818",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62818.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62818.patch",
"merged_at": null
}
|
Initial testing.
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62818/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62818/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62817
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62817/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62817/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62817/events
|
https://github.com/tensorflow/tensorflow/pull/62817
| 2,091,044,247 |
PR_kwDOArmXAs5kkuLW
| 62,817 |
[onednn] Enable auto_mixed_precision for fp16 on cpu
|
{
"login": "gaurides",
"id": 42224728,
"node_id": "MDQ6VXNlcjQyMjI0NzI4",
"avatar_url": "https://avatars.githubusercontent.com/u/42224728?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gaurides",
"html_url": "https://github.com/gaurides",
"followers_url": "https://api.github.com/users/gaurides/followers",
"following_url": "https://api.github.com/users/gaurides/following{/other_user}",
"gists_url": "https://api.github.com/users/gaurides/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gaurides/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gaurides/subscriptions",
"organizations_url": "https://api.github.com/users/gaurides/orgs",
"repos_url": "https://api.github.com/users/gaurides/repos",
"events_url": "https://api.github.com/users/gaurides/events{/privacy}",
"received_events_url": "https://api.github.com/users/gaurides/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 1097545273,
"node_id": "MDU6TGFiZWwxMDk3NTQ1Mjcz",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:grappler",
"name": "comp:grappler",
"color": "0052cc",
"default": false,
"description": "Grappler related issues"
},
{
"id": 1169365494,
"node_id": "MDU6TGFiZWwxMTY5MzY1NDk0",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:M",
"name": "size:M",
"color": "adafea",
"default": false,
"description": "CL Change Size: Medium"
}
] |
closed
| false |
{
"login": "penpornk",
"id": 38085909,
"node_id": "MDQ6VXNlcjM4MDg1OTA5",
"avatar_url": "https://avatars.githubusercontent.com/u/38085909?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/penpornk",
"html_url": "https://github.com/penpornk",
"followers_url": "https://api.github.com/users/penpornk/followers",
"following_url": "https://api.github.com/users/penpornk/following{/other_user}",
"gists_url": "https://api.github.com/users/penpornk/gists{/gist_id}",
"starred_url": "https://api.github.com/users/penpornk/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/penpornk/subscriptions",
"organizations_url": "https://api.github.com/users/penpornk/orgs",
"repos_url": "https://api.github.com/users/penpornk/repos",
"events_url": "https://api.github.com/users/penpornk/events{/privacy}",
"received_events_url": "https://api.github.com/users/penpornk/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "penpornk",
"id": 38085909,
"node_id": "MDQ6VXNlcjM4MDg1OTA5",
"avatar_url": "https://avatars.githubusercontent.com/u/38085909?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/penpornk",
"html_url": "https://github.com/penpornk",
"followers_url": "https://api.github.com/users/penpornk/followers",
"following_url": "https://api.github.com/users/penpornk/following{/other_user}",
"gists_url": "https://api.github.com/users/penpornk/gists{/gist_id}",
"starred_url": "https://api.github.com/users/penpornk/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/penpornk/subscriptions",
"organizations_url": "https://api.github.com/users/penpornk/orgs",
"repos_url": "https://api.github.com/users/penpornk/repos",
"events_url": "https://api.github.com/users/penpornk/events{/privacy}",
"received_events_url": "https://api.github.com/users/penpornk/received_events",
"type": "User",
"site_admin": false
},
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi @reedwm @penpornk : can you please let me know if there are any comments I can address? Thanks!",
"Looks like there was a failure on Windows:\r\n\r\n```\r\nFAIL: //tensorflow/core/grappler/optimizers:auto_mixed_precision_test_cpu\r\n\r\n[==========] Running 38 tests from 3 test suites.\r\n[----------] Global test environment set-up.\r\n[----------] 2 tests from AutoMixedPrecisionCpuTest\r\n[ RUN ] AutoMixedPrecisionCpuTest.Simple\r\n2024-02-21 08:25:59.082520: I tensorflow/core/grappler/clusters/single_machine.cc:361] Starting new session\r\n2024-02-21 08:25:59.084137: I tensorflow/core/platform/cpu_feature_guard.cc:210] This TensorFlow binary is optimized to use available CPU instructions in performance-critical operations.\r\nTo enable the following instructions: SSE SSE2 SSE3 SSE4.1 SSE4.2 AVX AVX2 FMA, in other operations, rebuild TensorFlow with the appropriate compiler flags.\r\n2024-02-21 08:25:59.159407: I tensorflow/core/grappler/optimizers/auto_mixed_precision.cc:2260] Converted 0/12 nodes to float16 precision using 4 cast(s) to float16 (excluding Const and Variable casts)\r\nexternal/com_google_googletest/googletest/src/gtest-port.cc(828): error: Failed\r\nSyntax error at index 53 in simple regular expression \"^clr2-0-CastToFp16-0-AutoMixedPrecision-0-CastToFp32-[0-9]-AutoMixedPrecision$\": '[' is unsupported.\r\nexternal/com_google_googletest/googletest/src/gtest-port.cc(828): error: Failed\r\nSyntax error at index 57 in simple regular expression \"^clr2-0-CastToFp16-0-AutoMixedPrecision-0-CastToFp32-[0-9]-AutoMixedPrecision$\": ']' is unsupported.\r\ntensorflow/core/grappler/optimizers/auto_mixed_precision_test.cc(1339): error: Value of: edge.src.node->name()\r\nExpected: contains regular expression \"^clr2-0-CastToFp16-0-AutoMixedPrecision-0-CastToFp32-[0-9]-AutoMixedPrecision$\"\r\n Actual: \"clr2-0-CastToFp16-0-AutoMixedPrecision-0-CastToFp32-1-AutoMixedPrecision\"\r\nexternal/com_google_googletest/googletest/src/gtest-port.cc(828): error: Failed\r\nSyntax error at index 53 in simple regular expression \"^clr2-0-CastToFp16-0-AutoMixedPrecision-0-CastToFp32-[0-9]-AutoMixedPrecision$\": '[' is unsupported.\r\nexternal/com_google_googletest/googletest/src/gtest-port.cc(828): error: Failed\r\nSyntax error at index 57 in simple regular expression \"^clr2-0-CastToFp16-0-AutoMixedPrecision-0-CastToFp32-[0-9]-AutoMixedPrecision$\": ']' is unsupported.\r\ntensorflow/core/grappler/optimizers/auto_mixed_precision_test.cc(1339): error: Value of: edge.src.node->name()\r\nExpected: contains regular expression \"^clr2-0-CastToFp16-0-AutoMixedPrecision-0-CastToFp32-[0-9]-AutoMixedPrecision$\"\r\n Actual: \"clr2-0-CastToFp16-0-AutoMixedPrecision-0-CastToFp32-0-AutoMixedPrecision\"\r\nexternal/com_google_googletest/googletest/src/gtest-port.cc(828): error: Failed\r\nSyntax error at index 21 in simple regular expression \"^allow1-0-CastToFp16-[0-9]-AutoMixedPrecision$\": '[' is unsupported.\r\nexternal/com_google_googletest/googletest/src/gtest-port.cc(828): error: Failed\r\nSyntax error at index 25 in simple regular expression \"^allow1-0-CastToFp16-[0-9]-AutoMixedPrecision$\": ']' is unsupported.\r\ntensorflow/core/grappler/optimizers/auto_mixed_precision_test.cc(1347): error: Value of: edge.dst.node->name()\r\nExpected: contains regular expression \"^allow1-0-CastToFp16-[0-9]-AutoMixedPrecision$\"\r\n Actual: \"allow1-0-CastToFp16-0-AutoMixedPrecision\"\r\n[ FAILED ] AutoMixedPrecisionCpuTest.Simple (80 ms)\r\n```",
"> Looks like there was a failure on Windows:\r\n\r\nThanks @cantonios for pointing me the issue and the error log. I have fixed it. That test shouldn't be running on CPU, like on master.",
"@cantonios : I see \"feedback/copybara\" has internal failure. Please let me know if anything I can fix. Thanks.",
"> @cantonios : I see \"feedback/copybara\" has internal failure. Please let me know if anything I can fix. Thanks.\r\n\r\nI think we're okay... it looks like there are some preexisting failures at Google.",
"@cantonios - Is it ok to close this PR since the changes are already merged into master?",
"> @cantonios - Is it ok to close this PR since the changes are already merged into master?\r\n\r\nYes, this was merged in 21e9d7292d90db23805585e6f1846693692c0b83. I'm not sure why this PR isn't marked as merged. @kanglant do you know why?\r\n"
] | 2024-01-19T18:11:39 | 2024-03-27T19:55:58 | 2024-03-27T19:55:54 |
CONTRIBUTOR
| null | false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62817",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62817",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62817.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62817.patch",
"merged_at": null
}
|
This PR enables AMP FP16 on supporting Intel Xeon CPUs. If there is no GPU available to run FP16, it checks if FP16 can be executed on CPU.
Use config `auto_mixed_precision` to enable FP16 on CPUs.
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62817/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62817/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62816
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62816/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62816/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62816/events
|
https://github.com/tensorflow/tensorflow/pull/62816
| 2,090,356,253 |
PR_kwDOArmXAs5kiXDI
| 62,816 |
fix: minor change to unit validation in tf.keras.layers.Dense
|
{
"login": "kiraksi",
"id": 111136730,
"node_id": "U_kgDOBp_P2g",
"avatar_url": "https://avatars.githubusercontent.com/u/111136730?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/kiraksi",
"html_url": "https://github.com/kiraksi",
"followers_url": "https://api.github.com/users/kiraksi/followers",
"following_url": "https://api.github.com/users/kiraksi/following{/other_user}",
"gists_url": "https://api.github.com/users/kiraksi/gists{/gist_id}",
"starred_url": "https://api.github.com/users/kiraksi/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/kiraksi/subscriptions",
"organizations_url": "https://api.github.com/users/kiraksi/orgs",
"repos_url": "https://api.github.com/users/kiraksi/repos",
"events_url": "https://api.github.com/users/kiraksi/events{/privacy}",
"received_events_url": "https://api.github.com/users/kiraksi/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 1097546578,
"node_id": "MDU6TGFiZWwxMDk3NTQ2NTc4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:keras",
"name": "comp:keras",
"color": "0052cc",
"default": false,
"description": "Keras related issues"
},
{
"id": 1169364259,
"node_id": "MDU6TGFiZWwxMTY5MzY0MjU5",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS",
"name": "size:XS",
"color": "adafea",
"default": false,
"description": "CL Change Size: Extra Small"
}
] |
closed
| false |
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"It doesn't seem that this file follows python style guides as pylint and black were showing me suggested changes, do you usually run lint tests in your python files here or should I skip it?",
"Thank you for the PR.\r\n\r\nUnfortunately, you are touching Keras code, which I think now should be done in the Keras repositories https://github.com/keras-team/keras as Keras 3.0 is multiframework, not just a component of TF. Can you make a copy of this PR in that repository (and/or in https://github.com/keras-team/tf-keras) and then revisit this one once the Keras one(s) merge? Thank you\r\n\r\nPS: We do have some linting done internally at Google, which will happen once the PR gets imported into the internal system (that's the TF configuration, unsure about the configuration on the Keras repositories)",
"Hi @kiraksi This PR relates to the Keras component, it will be created in the github.com/keras-team/keras repository instead. As @mihaimaruseac suggested, I can see you have created PR[#721](https://github.com/keras-team/tf-keras/pull/721) in the Keras repository. Hence closing this PR. Thank you for your contribution! \r\n@fchollet, @qlzh727"
] | 2024-01-19T11:40:36 | 2024-01-23T08:36:37 | 2024-01-23T03:30:50 |
NONE
| null | false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62816",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62816",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62816.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62816.patch",
"merged_at": null
}
|
Fixes: #62432
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62816/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62816/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62815
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62815/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62815/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62815/events
|
https://github.com/tensorflow/tensorflow/issues/62815
| 2,090,204,060 |
I_kwDOArmXAs58lfuc
| 62,815 |
Running quantized tflite model in "full" tensorflow
|
{
"login": "luikaire",
"id": 152705986,
"node_id": "U_kgDOCRobwg",
"avatar_url": "https://avatars.githubusercontent.com/u/152705986?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/luikaire",
"html_url": "https://github.com/luikaire",
"followers_url": "https://api.github.com/users/luikaire/followers",
"following_url": "https://api.github.com/users/luikaire/following{/other_user}",
"gists_url": "https://api.github.com/users/luikaire/gists{/gist_id}",
"starred_url": "https://api.github.com/users/luikaire/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/luikaire/subscriptions",
"organizations_url": "https://api.github.com/users/luikaire/orgs",
"repos_url": "https://api.github.com/users/luikaire/repos",
"events_url": "https://api.github.com/users/luikaire/events{/privacy}",
"received_events_url": "https://api.github.com/users/luikaire/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473184161,
"node_id": "MDU6TGFiZWw0NzMxODQxNjE=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:support",
"name": "type:support",
"color": "159b2e",
"default": false,
"description": "Support issues"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
},
{
"id": 750616506,
"node_id": "MDU6TGFiZWw3NTA2MTY1MDY=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite",
"name": "comp:lite",
"color": "0052cc",
"default": false,
"description": "TF Lite related issues"
}
] |
closed
| false |
{
"login": "LakshmiKalaKadali",
"id": 149650845,
"node_id": "U_kgDOCOt9nQ",
"avatar_url": "https://avatars.githubusercontent.com/u/149650845?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/LakshmiKalaKadali",
"html_url": "https://github.com/LakshmiKalaKadali",
"followers_url": "https://api.github.com/users/LakshmiKalaKadali/followers",
"following_url": "https://api.github.com/users/LakshmiKalaKadali/following{/other_user}",
"gists_url": "https://api.github.com/users/LakshmiKalaKadali/gists{/gist_id}",
"starred_url": "https://api.github.com/users/LakshmiKalaKadali/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/LakshmiKalaKadali/subscriptions",
"organizations_url": "https://api.github.com/users/LakshmiKalaKadali/orgs",
"repos_url": "https://api.github.com/users/LakshmiKalaKadali/repos",
"events_url": "https://api.github.com/users/LakshmiKalaKadali/events{/privacy}",
"received_events_url": "https://api.github.com/users/LakshmiKalaKadali/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "LakshmiKalaKadali",
"id": 149650845,
"node_id": "U_kgDOCOt9nQ",
"avatar_url": "https://avatars.githubusercontent.com/u/149650845?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/LakshmiKalaKadali",
"html_url": "https://github.com/LakshmiKalaKadali",
"followers_url": "https://api.github.com/users/LakshmiKalaKadali/followers",
"following_url": "https://api.github.com/users/LakshmiKalaKadali/following{/other_user}",
"gists_url": "https://api.github.com/users/LakshmiKalaKadali/gists{/gist_id}",
"starred_url": "https://api.github.com/users/LakshmiKalaKadali/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/LakshmiKalaKadali/subscriptions",
"organizations_url": "https://api.github.com/users/LakshmiKalaKadali/orgs",
"repos_url": "https://api.github.com/users/LakshmiKalaKadali/repos",
"events_url": "https://api.github.com/users/LakshmiKalaKadali/events{/privacy}",
"received_events_url": "https://api.github.com/users/LakshmiKalaKadali/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi @luikaire,\r\n\r\nCould you please confirm that your code used delegates?. If not, use gpu delegates to accelerate the inference. Refer the[ link](https://www.tensorflow.org/lite/performance/gpu) for reference.\r\n\r\nThank You\r\n",
"I use the tensorflow-rocm pip package downloaded from the official installation page (tensorflow-2.13.0.570+rocm-5.7.2) on a linux machine (ubuntu-22.04)\r\n\r\nwith this installation gpu support in \"full\" tensorflow/keras models works out of the box\r\n\r\nbut when running the tflite model file through tf.lite.Interpreter , only cpu is used. This means the tflite file, despite being a lot smaller (23 Mb) vs the keras .h5 model (91 Mb) runs slower\r\n\r\nAre gpu delegates available for this setup (ubuntu linux+amd rocm)? If so, how can I force tflite to use gpu delegates?\r\n\r\nThe link you referred doesn't seem to have information about linux machines..\r\n\r\n\r\nAn earlier issue (https://github.com/tensorflow/tensorflow/issues/44129#issuecomment-712487197) mentions that GPU delegates are only available for android/ios\r\nIs that still the case with the latest tensorflow as well?",
"Hi @luikaire,\r\n\r\nThe link provided in the earlier comment exactly refers to gpu delegates for android and ios only. In your usecase, the gpu deligates may be build on linux through Bazel. Could you please try to follow these steps :\r\n1. Install Bazel:\r\n ```wget https://github.com/bazelbuild/bazel/releases/download/6.1.0/bazel-6.1.0-installer-linux-x86_64.sh```\r\n2. Clone Tensorflow Repository\r\n ``` git clone https://github.com/tensorflow/tensorflow.git tensorflow_src```\r\n3. ```apt get install mesa-common-dev libgl1-mesa-dev libgles2-mesa-dev ocl-icd-opencl-dev```\r\n4. Run ./configure\r\n5. Run ```bazel build -c opt --copt -DMESA_EGL_NO_X11_HEADERS --copt -DEGL_NO_X11 \r\n tensorflow/lite/delegates/gpu:gl_delegate```.\r\n\r\nhttps://github.com/tensorflow/tensorflow/issues/46498, https://github.com/tensorflow/tensorflow/issues/46498\r\n\r\nThank You\r\n\r\n\r\n \r\n\r\n\r\n",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62815\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62815\">No</a>\n"
] | 2024-01-19T10:28:45 | 2024-02-16T01:47:02 | 2024-02-16T01:46:59 |
NONE
| null | null | null |
I quantized a full tensorflow model and got a smaller tflite file
This runs well using tf.lite.Interpreter. However, on my machine, tflite can only use CPU, while "full" tensorflow is much faster as it can use GPU as well
Because of CPU-only execution, the smaller quantized model runs slower in tf.lite.Interpreter than the larger/original model on "full" tensorflow
So I would like to know if there's any way to run the quantized tflite model (which is saved as a .tflite file on disk) in "full" tensorflow (via load_model for example) so that GPU acceleration can be used
thanks
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62815/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62815/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62814
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62814/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62814/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62814/events
|
https://github.com/tensorflow/tensorflow/issues/62814
| 2,089,376,390 |
I_kwDOArmXAs58iVqG
| 62,814 |
Link error when using both TensorFlowLiteSelectTfOps.framework and TensorFlowLiteC.framework on iOS
|
{
"login": "w3sip",
"id": 4392548,
"node_id": "MDQ6VXNlcjQzOTI1NDg=",
"avatar_url": "https://avatars.githubusercontent.com/u/4392548?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/w3sip",
"html_url": "https://github.com/w3sip",
"followers_url": "https://api.github.com/users/w3sip/followers",
"following_url": "https://api.github.com/users/w3sip/following{/other_user}",
"gists_url": "https://api.github.com/users/w3sip/gists{/gist_id}",
"starred_url": "https://api.github.com/users/w3sip/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/w3sip/subscriptions",
"organizations_url": "https://api.github.com/users/w3sip/orgs",
"repos_url": "https://api.github.com/users/w3sip/repos",
"events_url": "https://api.github.com/users/w3sip/events{/privacy}",
"received_events_url": "https://api.github.com/users/w3sip/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
},
{
"id": 750616506,
"node_id": "MDU6TGFiZWw3NTA2MTY1MDY=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite",
"name": "comp:lite",
"color": "0052cc",
"default": false,
"description": "TF Lite related issues"
},
{
"id": 5922361893,
"node_id": "LA_kwDOArmXAs8AAAABYQASJQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF2.14",
"name": "TF2.14",
"color": "b60205",
"default": false,
"description": "For issues related to Tensorflow 2.14.x"
}
] |
closed
| false |
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Oh, and I've also attempted to build the Select framework with `bazel build --config=ios_fat -c opt --copt -Os --cpu=ios_arm64 --apple_platform_type=ios --cxxopt=-std=c++17 --host_cxxopt=-std=c++17 //tensorflow/lite/ios:TensorFlowLiteSelectTfOps_framework --define tflite_with_xnnpack_enabled=false` ... didn't make a difference.",
"@w3sip Could you try to temporarily disable the XNNPack delegate during the build of one of the frameworks.\r\nThis can be done by modifying the build settings or configuration options. Also experiment with linker flags like \r\n`-force_load` or `-undefined dynamic_lookup` to control symbol visibility. Please use the latest TF version and let us know?\r\nThank you!",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"@sushreebarsa -- thanks, yes disabling XNNPack is the route I went and it worked, once I've fixed the incorrect way to set the parameter above.\r\n\r\nAnother question I have -- is there a way to only use/build a subset of `TensorFlowLiteSelectTfOps_framework` ? It's a very large binary by default; prohibitive for an iOS app.",
"@w3sip While there's no direct way to build a subset of TensorFlowLiteSelectTfOps_framework, here are effective approaches to reduce its size for iOS apps: such as follows;\r\n1. Identify Essential Ops: Analyze your model to determine the specific ops it utilizes.\r\n2. Register Only Needed Ops: Employ tflite::MutableOpResolver to register only those essential ops, excluding unnecessary ones.\r\n\r\nThank you!",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62814\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62814\">No</a>\n",
"> @w3sip While there's no direct way to build a subset of TensorFlowLiteSelectTfOps_framework, here are effective approaches to reduce its size for iOS apps: such as follows;\r\n> \r\n> 1. Identify Essential Ops: Analyze your model to determine the specific ops it utilizes.\r\n> \r\n> 2. Register Only Needed Ops: Employ tflite::MutableOpResolver to register only those essential ops, excluding unnecessary ones.\r\n> \r\n> \r\n> Thank you!\r\n\r\n\r\n\r\n@sushreebarsa Do you mind if you could list down the detailed steps to achieve the above suggestion you made?"
] | 2024-01-19T01:18:56 | 2024-05-24T01:43:26 | 2024-02-16T01:47:00 |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
No
### Source
source
### TensorFlow version
2.14.1
### Custom code
Yes
### OS platform and distribution
iOS
### Mobile device
_No response_
### Python version
_No response_
### Bazel version
6.1.10
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
TFLite is built using bazel commands:
`bazel build --config=ios_fat -c opt --copt -Os --cpu=ios_arm64 --apple_platform_type=ios --cxxopt=-std=c++17 --host_cxxopt=-std=c++17 //tensorflow/lite/ios:TensorFlowLiteSelectTfOps_framework`
`bazel build --config=ios_fat -c opt --cxxopt=-std=c++17 --host_cxxopt=-std=c++17 //tensorflow/lite/ios:TensorFlowLiteC_framework`
When trying to build a framework linking to both resulting frameworks above, seeing the following errors:
```
duplicate symbol '_TfLiteXNNPackDelegateWeightsCacheFinalizeHard' in:
TensorFlowLiteC.framework/TensorFlowLiteC
TensorFlowLiteSelectTfOps.framework/TensorFlowLiteSelectTfOps[arm64][961](xnnpack_delegate.o)
```
(same errors repeat for pretty much every XNNPack method).
### Standalone code to reproduce the issue
```shell
See above. Any framework linking to both of the resulting frameworks will do.
```
### Relevant log output
_No response_
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62814/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62814/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62813
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62813/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62813/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62813/events
|
https://github.com/tensorflow/tensorflow/pull/62813
| 2,089,296,311 |
PR_kwDOArmXAs5keqjn
| 62,813 |
Show a bit more work in custom_gradient docstring
|
{
"login": "bpcreech",
"id": 35012922,
"node_id": "MDQ6VXNlcjM1MDEyOTIy",
"avatar_url": "https://avatars.githubusercontent.com/u/35012922?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/bpcreech",
"html_url": "https://github.com/bpcreech",
"followers_url": "https://api.github.com/users/bpcreech/followers",
"following_url": "https://api.github.com/users/bpcreech/following{/other_user}",
"gists_url": "https://api.github.com/users/bpcreech/gists{/gist_id}",
"starred_url": "https://api.github.com/users/bpcreech/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/bpcreech/subscriptions",
"organizations_url": "https://api.github.com/users/bpcreech/orgs",
"repos_url": "https://api.github.com/users/bpcreech/repos",
"events_url": "https://api.github.com/users/bpcreech/events{/privacy}",
"received_events_url": "https://api.github.com/users/bpcreech/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 390482148,
"node_id": "MDU6TGFiZWwzOTA0ODIxNDg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/awaiting%20review",
"name": "awaiting review",
"color": "bc3869",
"default": false,
"description": "Pull request awaiting review"
},
{
"id": 987666414,
"node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull",
"name": "ready to pull",
"color": "2cd643",
"default": false,
"description": "PR ready for merge process"
},
{
"id": 1097547147,
"node_id": "MDU6TGFiZWwxMDk3NTQ3MTQ3",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:ops",
"name": "comp:ops",
"color": "0052cc",
"default": false,
"description": "OPs related issues"
},
{
"id": 1169364259,
"node_id": "MDU6TGFiZWwxMTY5MzY0MjU5",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS",
"name": "size:XS",
"color": "adafea",
"default": false,
"description": "CL Change Size: Extra Small"
}
] |
closed
| false |
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[] | 2024-01-18T23:47:32 | 2024-01-19T04:21:07 | 2024-01-19T04:21:07 |
CONTRIBUTOR
| null | false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62813",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62813",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62813.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62813.patch",
"merged_at": "2024-01-19T04:21:07"
}
|
It took me a minute to understand the equivalence used in the example, so I thought it would help other readers if we show a tiny bit more of the work.
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62813/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62813/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62812
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62812/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62812/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62812/events
|
https://github.com/tensorflow/tensorflow/pull/62812
| 2,088,861,449 |
PR_kwDOArmXAs5kdKKG
| 62,812 |
[oneDNN]: Added fp16 support for some training ops
|
{
"login": "bhavani-subramanian",
"id": 28113241,
"node_id": "MDQ6VXNlcjI4MTEzMjQx",
"avatar_url": "https://avatars.githubusercontent.com/u/28113241?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/bhavani-subramanian",
"html_url": "https://github.com/bhavani-subramanian",
"followers_url": "https://api.github.com/users/bhavani-subramanian/followers",
"following_url": "https://api.github.com/users/bhavani-subramanian/following{/other_user}",
"gists_url": "https://api.github.com/users/bhavani-subramanian/gists{/gist_id}",
"starred_url": "https://api.github.com/users/bhavani-subramanian/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/bhavani-subramanian/subscriptions",
"organizations_url": "https://api.github.com/users/bhavani-subramanian/orgs",
"repos_url": "https://api.github.com/users/bhavani-subramanian/repos",
"events_url": "https://api.github.com/users/bhavani-subramanian/events{/privacy}",
"received_events_url": "https://api.github.com/users/bhavani-subramanian/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 390482148,
"node_id": "MDU6TGFiZWwzOTA0ODIxNDg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/awaiting%20review",
"name": "awaiting review",
"color": "bc3869",
"default": false,
"description": "Pull request awaiting review"
},
{
"id": 987666414,
"node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull",
"name": "ready to pull",
"color": "2cd643",
"default": false,
"description": "PR ready for merge process"
},
{
"id": 1169364458,
"node_id": "MDU6TGFiZWwxMTY5MzY0NDU4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:S",
"name": "size:S",
"color": "adafea",
"default": false,
"description": "CL Change Size: Small"
},
{
"id": 1478826728,
"node_id": "MDU6TGFiZWwxNDc4ODI2NzI4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:core",
"name": "comp:core",
"color": "024391",
"default": false,
"description": "issues related to core part of tensorflow"
}
] |
closed
| false |
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "penpornk",
"id": 38085909,
"node_id": "MDQ6VXNlcjM4MDg1OTA5",
"avatar_url": "https://avatars.githubusercontent.com/u/38085909?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/penpornk",
"html_url": "https://github.com/penpornk",
"followers_url": "https://api.github.com/users/penpornk/followers",
"following_url": "https://api.github.com/users/penpornk/following{/other_user}",
"gists_url": "https://api.github.com/users/penpornk/gists{/gist_id}",
"starred_url": "https://api.github.com/users/penpornk/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/penpornk/subscriptions",
"organizations_url": "https://api.github.com/users/penpornk/orgs",
"repos_url": "https://api.github.com/users/penpornk/repos",
"events_url": "https://api.github.com/users/penpornk/events{/privacy}",
"received_events_url": "https://api.github.com/users/penpornk/received_events",
"type": "User",
"site_admin": false
},
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[] | 2024-01-18T18:43:37 | 2024-01-23T21:42:31 | 2024-01-23T21:42:31 |
CONTRIBUTOR
| null | false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62812",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62812",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62812.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62812.patch",
"merged_at": "2024-01-23T21:42:31"
}
|
This PR adds fp16 support for some backprop ops needed for training (ex. ResNet-50).
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62812/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62812/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62811
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62811/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62811/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62811/events
|
https://github.com/tensorflow/tensorflow/issues/62811
| 2,087,680,045 |
I_kwDOArmXAs58b3gt
| 62,811 |
Is it possible to combile TensofrFlow & ARKit in Swift 5
|
{
"login": "vnanaware111",
"id": 156997549,
"node_id": "U_kgDOCVuXrQ",
"avatar_url": "https://avatars.githubusercontent.com/u/156997549?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/vnanaware111",
"html_url": "https://github.com/vnanaware111",
"followers_url": "https://api.github.com/users/vnanaware111/followers",
"following_url": "https://api.github.com/users/vnanaware111/following{/other_user}",
"gists_url": "https://api.github.com/users/vnanaware111/gists{/gist_id}",
"starred_url": "https://api.github.com/users/vnanaware111/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/vnanaware111/subscriptions",
"organizations_url": "https://api.github.com/users/vnanaware111/orgs",
"repos_url": "https://api.github.com/users/vnanaware111/repos",
"events_url": "https://api.github.com/users/vnanaware111/events{/privacy}",
"received_events_url": "https://api.github.com/users/vnanaware111/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473184161,
"node_id": "MDU6TGFiZWw0NzMxODQxNjE=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:support",
"name": "type:support",
"color": "159b2e",
"default": false,
"description": "Support issues"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
}
] |
closed
| false |
{
"login": "Venkat6871",
"id": 147127861,
"node_id": "U_kgDOCMT-NQ",
"avatar_url": "https://avatars.githubusercontent.com/u/147127861?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/Venkat6871",
"html_url": "https://github.com/Venkat6871",
"followers_url": "https://api.github.com/users/Venkat6871/followers",
"following_url": "https://api.github.com/users/Venkat6871/following{/other_user}",
"gists_url": "https://api.github.com/users/Venkat6871/gists{/gist_id}",
"starred_url": "https://api.github.com/users/Venkat6871/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Venkat6871/subscriptions",
"organizations_url": "https://api.github.com/users/Venkat6871/orgs",
"repos_url": "https://api.github.com/users/Venkat6871/repos",
"events_url": "https://api.github.com/users/Venkat6871/events{/privacy}",
"received_events_url": "https://api.github.com/users/Venkat6871/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "Venkat6871",
"id": 147127861,
"node_id": "U_kgDOCMT-NQ",
"avatar_url": "https://avatars.githubusercontent.com/u/147127861?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/Venkat6871",
"html_url": "https://github.com/Venkat6871",
"followers_url": "https://api.github.com/users/Venkat6871/followers",
"following_url": "https://api.github.com/users/Venkat6871/following{/other_user}",
"gists_url": "https://api.github.com/users/Venkat6871/gists{/gist_id}",
"starred_url": "https://api.github.com/users/Venkat6871/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Venkat6871/subscriptions",
"organizations_url": "https://api.github.com/users/Venkat6871/orgs",
"repos_url": "https://api.github.com/users/Venkat6871/repos",
"events_url": "https://api.github.com/users/Venkat6871/events{/privacy}",
"received_events_url": "https://api.github.com/users/Venkat6871/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi **@vnanaware111** ,\r\n\r\nSorry for the late reply, Yes it is possible to use tensorflow and ARKit together, they serve different purposes in the context of developing applications.\r\n\r\nThank you!",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62811\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62811\">No</a>\n"
] | 2024-01-18T07:26:03 | 2024-02-07T01:46:25 | 2024-02-07T01:46:22 |
NONE
| null | null | null |
### Issue type
Support
### Have you reproduced the bug with TensorFlow Nightly?
No
### Source
source
### TensorFlow version
0.0.1
### Custom code
Yes
### OS platform and distribution
_No response_
### Mobile device
_No response_
### Python version
_No response_
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
Is it possible to use Tensorflow & ARKit combinely.
### Standalone code to reproduce the issue
```shell
Is it possible to use Tensorflow & ARKit combinely.
```
### Relevant log output
_No response_
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62811/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62811/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62810
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62810/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62810/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62810/events
|
https://github.com/tensorflow/tensorflow/issues/62810
| 2,087,588,819 |
I_kwDOArmXAs58bhPT
| 62,810 |
Can not force TF 2.10 to use CPU only (uses GPU)
|
{
"login": "marcusobrien",
"id": 3989070,
"node_id": "MDQ6VXNlcjM5ODkwNzA=",
"avatar_url": "https://avatars.githubusercontent.com/u/3989070?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/marcusobrien",
"html_url": "https://github.com/marcusobrien",
"followers_url": "https://api.github.com/users/marcusobrien/followers",
"following_url": "https://api.github.com/users/marcusobrien/following{/other_user}",
"gists_url": "https://api.github.com/users/marcusobrien/gists{/gist_id}",
"starred_url": "https://api.github.com/users/marcusobrien/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/marcusobrien/subscriptions",
"organizations_url": "https://api.github.com/users/marcusobrien/orgs",
"repos_url": "https://api.github.com/users/marcusobrien/repos",
"events_url": "https://api.github.com/users/marcusobrien/events{/privacy}",
"received_events_url": "https://api.github.com/users/marcusobrien/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
},
{
"id": 1097547538,
"node_id": "MDU6TGFiZWwxMDk3NTQ3NTM4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:gpu",
"name": "comp:gpu",
"color": "0052cc",
"default": false,
"description": "GPU related issues"
},
{
"id": 4511033337,
"node_id": "LA_kwDOArmXAs8AAAABDODn-Q",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.10",
"name": "TF 2.10",
"color": "C15088",
"default": false,
"description": ""
}
] |
closed
| false |
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hello, @marcusobrien :]\r\n\r\nInstead of the `tf.config.experimental.list_physical_devices()`, do this instead early on:\r\n```\r\nimport os\r\n\r\nos.environ[\"CUDA_VISIBLE_DEVICES\"] = \"-1\"\r\n```\r\n\r\nThat way, TF will not find any GPUs to allocate on. If it didn't. You are likely doing this too late in the code. You should be doing this, before you do any ops that will allocate GPU memory, like compiling your model, or similar. In some projects, I even do it before I import `tensorflow`, but that's up to you.\r\n\r\n---\r\nEDIT: You can check if it solved the issue, running `nvidia-smi` in a Linux terminal.\r\n\r\nFor Windows, you can use the task manager to monitor GPU utilisation.",
"@marcusobrien,\r\nAs mentioned you can try using `os.environ[\"CUDA_VISIBLE_DEVICES\"] = \"-1\"` and also I tried with the code mentioned and it was executed without any issues, Kindly find the gist of it [here](https://colab.research.google.com/gist/tilakrayal/fee822f29fe5346ccf00696d9f72c4e8/untitled1671.ipynb).\r\n\r\nAlso tensorflow v2.10 is an older version, please upgrade to latest stable v2.15 for the better performance on both GPU and CPU. Thank you!",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62810\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62810\">No</a>\n"
] | 2024-01-18T06:16:14 | 2024-02-03T01:46:26 | 2024-02-03T01:46:23 |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
binary
### TensorFlow version
v2.10.0-rc3-6-g359c3cdfc5f 2.10.0
### Custom code
No
### OS platform and distribution
Windows 10
### Mobile device
_No response_
### Python version
3.10.9
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
I want to use TF 2.10 with CPU only, as currently TF defaults to using my GPU.
I tried the advice on this issue https://github.com/tensorflow/tensorflow/issues/31135
But the above can not be used in Jupyter Labs due to this error message
"RuntimeError: Visible devices cannot be modified after being initialized"
So is there any other way to force tensorflow to use CPU to perform all calculations ?
### Standalone code to reproduce the issue
```shell
import tensorflow as tf
print(tf.__version__)
# Set CPU as available physical device
my_devices = tf.config.experimental.list_physical_devices(device_type='CPU')
tf.config.experimental.set_visible_devices(devices= my_devices, device_type='CPU')
Error in msg below
```
### Relevant log output
```shell
---------------------------------------------------------------------------
RuntimeError Traceback (most recent call last)
Cell In[42], line 6
4 # Set CPU as available physical device
5 my_devices = tf.config.experimental.list_physical_devices(device_type='CPU')
----> 6 tf.config.experimental.set_visible_devices(devices= my_devices, device_type='CPU')
File U:\Miniconda3\envs\MLTF_CPU_2024\lib\site-packages\tensorflow\python\framework\config.py:528, in set_visible_devices(devices, device_type)
495 @tf_export('config.set_visible_devices',
496 'config.experimental.set_visible_devices')
497 @deprecation.deprecated_endpoints('config.experimental.set_visible_devices')
498 def set_visible_devices(devices, device_type=None):
499 """Set the list of visible devices.
500
501 Specifies which `PhysicalDevice` objects are visible to the runtime.
(...)
526 RuntimeError: Runtime is already initialized.
527 """
--> 528 context.context().set_visible_devices(devices, device_type)
File U:\Miniconda3\envs\MLTF_CPU_2024\lib\site-packages\tensorflow\python\eager\context.py:1621, in Context.set_visible_devices(self, devices, device_type)
1618 return
1620 if self._context_handle is not None:
-> 1621 raise RuntimeError(
1622 "Visible devices cannot be modified after being initialized")
1624 self._visible_device_list = visible_device_list
RuntimeError: Visible devices cannot be modified after being initialized
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62810/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62810/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62809
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62809/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62809/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62809/events
|
https://github.com/tensorflow/tensorflow/issues/62809
| 2,087,378,784 |
I_kwDOArmXAs58at9g
| 62,809 |
Tensorflow model save/load broken after tensorflow updated.
|
{
"login": "ludiusvox",
"id": 9891291,
"node_id": "MDQ6VXNlcjk4OTEyOTE=",
"avatar_url": "https://avatars.githubusercontent.com/u/9891291?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/ludiusvox",
"html_url": "https://github.com/ludiusvox",
"followers_url": "https://api.github.com/users/ludiusvox/followers",
"following_url": "https://api.github.com/users/ludiusvox/following{/other_user}",
"gists_url": "https://api.github.com/users/ludiusvox/gists{/gist_id}",
"starred_url": "https://api.github.com/users/ludiusvox/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/ludiusvox/subscriptions",
"organizations_url": "https://api.github.com/users/ludiusvox/orgs",
"repos_url": "https://api.github.com/users/ludiusvox/repos",
"events_url": "https://api.github.com/users/ludiusvox/events{/privacy}",
"received_events_url": "https://api.github.com/users/ludiusvox/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
},
{
"id": 1093464312,
"node_id": "MDU6TGFiZWwxMDkzNDY0MzEy",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:others",
"name": "type:others",
"color": "159b2e",
"default": false,
"description": "issues not falling in bug, perfromance, support, build and install or feature"
},
{
"id": 3255468475,
"node_id": "MDU6TGFiZWwzMjU1NDY4NDc1",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/2.6.0",
"name": "2.6.0",
"color": "FA96B6",
"default": false,
"description": ""
}
] |
closed
| false |
{
"login": "SuryanarayanaY",
"id": 116063290,
"node_id": "U_kgDOBur8Og",
"avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/SuryanarayanaY",
"html_url": "https://github.com/SuryanarayanaY",
"followers_url": "https://api.github.com/users/SuryanarayanaY/followers",
"following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}",
"gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}",
"starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions",
"organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs",
"repos_url": "https://api.github.com/users/SuryanarayanaY/repos",
"events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}",
"received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "SuryanarayanaY",
"id": 116063290,
"node_id": "U_kgDOBur8Og",
"avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/SuryanarayanaY",
"html_url": "https://github.com/SuryanarayanaY",
"followers_url": "https://api.github.com/users/SuryanarayanaY/followers",
"following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}",
"gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}",
"starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions",
"organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs",
"repos_url": "https://api.github.com/users/SuryanarayanaY/repos",
"events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}",
"received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi @ludiusvox ,\r\n\r\nGoogle colab is not supporting TF versions <=2.7 versions. \r\n\r\nWith latest versions of Tensorflow you need `tf_keras` package and set os.environ[\"TF_USE_LEGACY_KERAS\"] = \"1\".\r\n\r\nAlso you can test with keras 3.x version package by installing `pip install keras --upgrade` and `import keras` directly instead of `from tensorflow import keras `.\r\n\r\nPlease try both the approaches and let us know the outcome. Thanks!\r\n\r\n",
"Thanks for the advice I will work on it. Let me save this for later.",
"Also if I am working off of Google collab and on my local machube my GPU needs specific version of TF for the 4080GTX cannot use brand new CUDA or CuDNN and therefore the models portability is in question.",
"For each specific version of tensorflow we have tested configurations which can be found [here](https://www.tensorflow.org/install/source#gpu). Thanks.",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62809\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62809\">No</a>\n"
] | 2024-01-18T02:55:16 | 2024-02-03T01:46:59 | 2024-02-03T01:46:56 |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
source
### TensorFlow version
2.6
### Custom code
Yes
### OS platform and distribution
google collab
### Mobile device
_No response_
### Python version
_No response_
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
I saved my models from early december as "FullDataModel.keras", when I tried to load in mid january it couldn't compile and google collab I noticed a about a week ago that there was an update in tensorflow. So to get my models to load, I had to load a current version of the google colab backend and retrain, and then save the model, and reload. Why is the keras.load_model("") not backwards compatible, why is there no try/catch blocks in loading and saving models to load different models from different versions of tensorflow.
### Standalone code to reproduce the issue
```shell
Try to load an older TF model into a recent (Jan 2024) that was saved in 2023 of a CNN.
```
### Relevant log output
```shell
---------------------------------------------------------------------------
ValueError Traceback (most recent call last)
<ipython-input-8-06e83b693b52> in <cell line: 54>()
52
53 # Load the model
---> 54 model = load_model(model_path)
55
56
6 frames
/usr/local/lib/python3.10/dist-packages/keras/src/engine/base_layer.py in load_own_variables(self, store)
3529 all_vars = self._trainable_weights + self._non_trainable_weights
3530 if len(store.keys()) != len(all_vars):
-> 3531 raise ValueError(
3532 f"Layer '{self.name}' expected {len(all_vars)} variables, "
3533 "but received "
ValueError: Layer 'conv2d' expected 2 variables, but received 0 variables during loading. Expected: ['conv2d/kernel:0', 'conv2d/bias:0']
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62809/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62809/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62808
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62808/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62808/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62808/events
|
https://github.com/tensorflow/tensorflow/issues/62808
| 2,087,125,380 |
I_kwDOArmXAs58ZwGE
| 62,808 |
Convolution much slower when activating JIT compile
|
{
"login": "khatchad",
"id": 2048831,
"node_id": "MDQ6VXNlcjIwNDg4MzE=",
"avatar_url": "https://avatars.githubusercontent.com/u/2048831?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/khatchad",
"html_url": "https://github.com/khatchad",
"followers_url": "https://api.github.com/users/khatchad/followers",
"following_url": "https://api.github.com/users/khatchad/following{/other_user}",
"gists_url": "https://api.github.com/users/khatchad/gists{/gist_id}",
"starred_url": "https://api.github.com/users/khatchad/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/khatchad/subscriptions",
"organizations_url": "https://api.github.com/users/khatchad/orgs",
"repos_url": "https://api.github.com/users/khatchad/repos",
"events_url": "https://api.github.com/users/khatchad/events{/privacy}",
"received_events_url": "https://api.github.com/users/khatchad/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 404586594,
"node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower",
"name": "stat:awaiting tensorflower",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from tensorflower"
},
{
"id": 1463677878,
"node_id": "MDU6TGFiZWwxNDYzNjc3ODc4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:performance",
"name": "type:performance",
"color": "159b2e",
"default": false,
"description": "Performance Issue"
},
{
"id": 2691123225,
"node_id": "MDU6TGFiZWwyNjkxMTIzMjI1",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:tf.function",
"name": "comp:tf.function",
"color": "0052cc",
"default": false,
"description": "tf.function related issues"
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
open
| false |
{
"login": "sachinprasadhs",
"id": 73069040,
"node_id": "MDQ6VXNlcjczMDY5MDQw",
"avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sachinprasadhs",
"html_url": "https://github.com/sachinprasadhs",
"followers_url": "https://api.github.com/users/sachinprasadhs/followers",
"following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}",
"gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions",
"organizations_url": "https://api.github.com/users/sachinprasadhs/orgs",
"repos_url": "https://api.github.com/users/sachinprasadhs/repos",
"events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}",
"received_events_url": "https://api.github.com/users/sachinprasadhs/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "sachinprasadhs",
"id": 73069040,
"node_id": "MDQ6VXNlcjczMDY5MDQw",
"avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sachinprasadhs",
"html_url": "https://github.com/sachinprasadhs",
"followers_url": "https://api.github.com/users/sachinprasadhs/followers",
"following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}",
"gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions",
"organizations_url": "https://api.github.com/users/sachinprasadhs/orgs",
"repos_url": "https://api.github.com/users/sachinprasadhs/repos",
"events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}",
"received_events_url": "https://api.github.com/users/sachinprasadhs/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Related to #62378.",
"@SuryanarayanaY I was able to replicate this issue. Please find the gist [here](https://colab.research.google.com/gist/sushreebarsa/c31ad5c4c338709c4fd9b4b543f54149/62808.ipynb#scrollTo=E1RMCCE5u1L4).\r\nThank you!"
] | 2024-01-17T22:35:29 | 2024-01-30T18:50:26 | null |
NONE
| null | null | null |
### Issue type
Performance
### Have you reproduced the bug with TensorFlow Nightly?
No
### Source
binary
### TensorFlow version
2.14.0 and 2.15.0
### Custom code
Yes
### OS platform and distribution
Ubuntu 23.04
### Mobile device
_No response_
### Python version
3.10
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
The code at https://github.com/ponder-lab/samples/blob/bc487180eec5b576054e04dc6add2bc2e26e7a3e/tensorflow_custom_convolution/tensorflow_custom_convolution.py runs much slower when using the `jit_compile=True` argument to `tf.function`. With either `jit_compile=False` or no argument at all, it runs much faster.
### Standalone code to reproduce the issue
```shell
#!/usr/bin/env python
import time
import numpy as np
import tensorflow as tf
print("TensorFlow version:", tf.__version__)
assert(tf.__version__ == "2.15.0")
class MyConv2D(tf.keras.layers.Layer):
def __init__(self, filters, kernel_size, strides=(1, 1), padding="VALID",
*args, **kwargs):
super().__init__(*args, **kwargs)
self.filters = filters
self.kernel_size = kernel_size
self.strides = strides
self.padding = padding
def build(self, input_shape):
weights_shape = (self.filters,
self.kernel_size[0] * self.kernel_size[1] * input_shape[-1])
w = tf.random.normal(weights_shape, stddev=0.01)
self.w = self.add_weight(shape=w.shape, trainable=True)
self.w.assign(w)
b = tf.zeros((self.filters))
self.b = self.add_weight(shape=b.shape, trainable=True)
self.b.assign(b)
super().build(input_shape)
@tf.function(jit_compile=True)
def call(self, inputs):
# Extract patch
# patches dim: (batch, h, w, kernel_size[0]*kernel_size[1]*ich)
patch_sizes = (1,) + self.kernel_size + (1,)
patch_strides = (1,) + self.strides + (1,)
patches = tf.image.extract_patches(inputs, sizes=patch_sizes,
strides=patch_strides,
rates=(1, 1, 1, 1),
padding=self.padding)
# Multiply weights
mul = self.w * tf.expand_dims(patches, 3)
madd = tf.reduce_sum(mul, axis=-1)
maddb = madd + self.b
return maddb
def get_model_normal(input_shape):
input_node = tf.keras.Input(input_shape)
x = input_node
x = tf.keras.layers.Conv2D(32, (3, 3), padding="same")(x)
x = tf.keras.layers.Activation("relu")(x)
x = tf.keras.layers.MaxPooling2D()(x)
x = tf.keras.layers.Conv2D(32, (3, 3), padding="valid")(x)
x = tf.keras.layers.Activation("relu")(x)
x = tf.keras.layers.MaxPooling2D()(x)
x = tf.keras.layers.Conv2D(32, (3, 3), padding="same")(x)
x = tf.keras.layers.Activation("relu")(x)
x = tf.keras.layers.MaxPooling2D()(x)
x = tf.keras.layers.Conv2D(32, (3, 3), padding="valid")(x)
x = tf.keras.layers.Activation("relu")(x)
x = tf.keras.layers.Flatten()(x)
x = tf.keras.layers.Dense(10)(x)
x = tf.keras.layers.Activation("softmax")(x)
output_node = x
return tf.keras.models.Model(input_node, output_node)
def get_model_myconv(input_shape):
input_node = tf.keras.Input(input_shape)
x = input_node
x = MyConv2D(32, (3, 3), padding="SAME")(x)
x = tf.keras.layers.Activation("relu")(x)
x = tf.keras.layers.MaxPooling2D()(x)
x = MyConv2D(32, (3, 3), padding="VALID")(x)
x = tf.keras.layers.Activation("relu")(x)
x = tf.keras.layers.MaxPooling2D()(x)
x = MyConv2D(32, (3, 3), padding="SAME")(x)
x = tf.keras.layers.Activation("relu")(x)
x = tf.keras.layers.MaxPooling2D()(x)
x = MyConv2D(32, (3, 3), padding="VALID")(x)
x = tf.keras.layers.Activation("relu")(x)
x = tf.keras.layers.Flatten()(x)
x = tf.keras.layers.Dense(10)(x)
x = tf.keras.layers.Activation("softmax")(x)
output_node = x
return tf.keras.models.Model(input_node, output_node)
(x_train, y_train), _ = tf.keras.datasets.mnist.load_data()
x_train = x_train.astype(np.float32)[..., None] / 255
model = get_model_myconv(x_train[0].shape)
model.compile(optimizer='adam', loss='sparse_categorical_crossentropy', metrics=['accuracy'])
model.summary()
model(x_train[:2])
myconv_start = time.time()
model.fit(x_train, y_train,
batch_size=100, epochs=1, verbose=1,
validation_split=0.1)
myconv_end = time.time()
del model
model = get_model_normal(x_train[0].shape)
model.compile(optimizer='adam', loss='sparse_categorical_crossentropy', metrics=['accuracy'])
model.summary()
model(x_train[:2])
normal_start = time.time()
model.fit(x_train, y_train,
batch_size=100, epochs=1, verbose=1,
validation_split=0.1)
normal_end = time.time()
print("Normal convolution: %f[sec]" % (normal_end - normal_start))
print("My convolution: %f[sec]" % (myconv_end - myconv_start))
```
### Relevant log output
_No response_
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62808/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62808/timeline
| null | null | false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62807
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62807/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62807/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62807/events
|
https://github.com/tensorflow/tensorflow/pull/62807
| 2,085,929,584 |
PR_kwDOArmXAs5kTJ2N
| 62,807 |
Validate argument minvalue of tf.random.uniform
|
{
"login": "SuryanarayanaY",
"id": 116063290,
"node_id": "U_kgDOBur8Og",
"avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/SuryanarayanaY",
"html_url": "https://github.com/SuryanarayanaY",
"followers_url": "https://api.github.com/users/SuryanarayanaY/followers",
"following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}",
"gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}",
"starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions",
"organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs",
"repos_url": "https://api.github.com/users/SuryanarayanaY/repos",
"events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}",
"received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 987666414,
"node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull",
"name": "ready to pull",
"color": "2cd643",
"default": false,
"description": "PR ready for merge process"
},
{
"id": 1097547147,
"node_id": "MDU6TGFiZWwxMDk3NTQ3MTQ3",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:ops",
"name": "comp:ops",
"color": "0052cc",
"default": false,
"description": "OPs related issues"
},
{
"id": 1169364259,
"node_id": "MDU6TGFiZWwxMTY5MzY0MjU5",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS",
"name": "size:XS",
"color": "adafea",
"default": false,
"description": "CL Change Size: Extra Small"
}
] |
open
| false |
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi @cantonios Can you please review this PR ? Thank you!"
] | 2024-01-17T10:53:41 | 2024-06-05T08:18:13 | null |
COLLABORATOR
| null | false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62807",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62807",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62807.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62807.patch",
"merged_at": null
}
|
At present the API, `tf.random.uniform` raises `InvalidArgumentError` if `minval` >= `maxval` for `int` dtype only. This check happens in C++ backend for `int` data type only.
However same is not true for `float` datatype. It will not raise an error and It is ignoring min and max values in this case considering the range only.
The behaviour should be same for `int` and `float` dtypes. Hence for uniformity, I am adding validation for same at python level itself.
Attaching gist for same.
This is effecting `keras.initializers.RandomUniform` also which was discussed in tf-kears repo at #[449](https://github.com/keras-team/tf-keras/issues/449)
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62807/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62807/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62806
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62806/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62806/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62806/events
|
https://github.com/tensorflow/tensorflow/issues/62806
| 2,085,476,541 |
I_kwDOArmXAs58Tdi9
| 62,806 |
Alteryx Predict (11) : Unexpected Error Occur In Plugin
|
{
"login": "2302187",
"id": 156883036,
"node_id": "U_kgDOCVnYXA",
"avatar_url": "https://avatars.githubusercontent.com/u/156883036?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/2302187",
"html_url": "https://github.com/2302187",
"followers_url": "https://api.github.com/users/2302187/followers",
"following_url": "https://api.github.com/users/2302187/following{/other_user}",
"gists_url": "https://api.github.com/users/2302187/gists{/gist_id}",
"starred_url": "https://api.github.com/users/2302187/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/2302187/subscriptions",
"organizations_url": "https://api.github.com/users/2302187/orgs",
"repos_url": "https://api.github.com/users/2302187/repos",
"events_url": "https://api.github.com/users/2302187/events{/privacy}",
"received_events_url": "https://api.github.com/users/2302187/received_events",
"type": "User",
"site_admin": false
}
|
[] |
closed
| false |
{
"login": "Venkat6871",
"id": 147127861,
"node_id": "U_kgDOCMT-NQ",
"avatar_url": "https://avatars.githubusercontent.com/u/147127861?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/Venkat6871",
"html_url": "https://github.com/Venkat6871",
"followers_url": "https://api.github.com/users/Venkat6871/followers",
"following_url": "https://api.github.com/users/Venkat6871/following{/other_user}",
"gists_url": "https://api.github.com/users/Venkat6871/gists{/gist_id}",
"starred_url": "https://api.github.com/users/Venkat6871/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Venkat6871/subscriptions",
"organizations_url": "https://api.github.com/users/Venkat6871/orgs",
"repos_url": "https://api.github.com/users/Venkat6871/repos",
"events_url": "https://api.github.com/users/Venkat6871/events{/privacy}",
"received_events_url": "https://api.github.com/users/Venkat6871/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "Venkat6871",
"id": 147127861,
"node_id": "U_kgDOCMT-NQ",
"avatar_url": "https://avatars.githubusercontent.com/u/147127861?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/Venkat6871",
"html_url": "https://github.com/Venkat6871",
"followers_url": "https://api.github.com/users/Venkat6871/followers",
"following_url": "https://api.github.com/users/Venkat6871/following{/other_user}",
"gists_url": "https://api.github.com/users/Venkat6871/gists{/gist_id}",
"starred_url": "https://api.github.com/users/Venkat6871/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Venkat6871/subscriptions",
"organizations_url": "https://api.github.com/users/Venkat6871/orgs",
"repos_url": "https://api.github.com/users/Venkat6871/repos",
"events_url": "https://api.github.com/users/Venkat6871/events{/privacy}",
"received_events_url": "https://api.github.com/users/Venkat6871/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi **@2302187** ,\r\nWe see that the issue [template](https://github.com/tensorflow/tensorflow/issues/new/choose) has not been filled, could you please do so as it helps us analyze the issue [tf version, steps followed before you ran into this error or stand alone code/colab gist to reproduce the issue faced.\r\n\r\nThank you!",
"I am not really sure how to fill up the issue template as I do not know the details. I have uploaded some screenshots of the error. I would appreciate if someone could help me solve it \r\n\r\n<img width=\"1003\" alt=\"Error png 69\" src=\"https://github.com/tensorflow/tensorflow/assets/156883036/f337445b-4fa7-4658-a51c-7e044c8be2cc\">\r\n<img width=\"1003\" alt=\"Screenshot 2024-01-16 at 3 00 48 PM\" src=\"https://github.com/tensorflow/tensorflow/assets/156883036/0356956e-6c7f-4ff2-b158-9efd612eebb7\">\r\n",
"Hi **@2302187** ,\r\nIn order to expedite the trouble-shooting process, please provide a code snippet to reproduce the issue reported here.\r\n\r\nThank you!",
"Hi,\r\n\r\nThe issue has been resolved by Alteryx support team.\r\n\r\nThank you for your assistance!\r\n\r\nGet Outlook for iOS<https://aka.ms/o0ukef>\r\n________________________________\r\nFrom: Venkat6871 ***@***.***>\r\nSent: Monday, January 22, 2024 5:07:26 PM\r\nTo: tensorflow/tensorflow ***@***.***>\r\nCc: JASLYN ONG CHING WEN ***@***.***>; Mention ***@***.***>\r\nSubject: Re: [tensorflow/tensorflow] Alteryx Predict (11) : Unexpected Error Occur In Plugin (Issue #62806)\r\n\r\n\r\nCAUTION: This email originated from outside of SIT. Do not click links or open attachments unless you recognise the sender and know the content is safe.\r\n\r\n\r\nHi @2302187<https://github.com/2302187> ,\r\nIn order to expedite the trouble-shooting process, please provide a code snippet to reproduce the issue reported here.\r\n\r\nThank you!\r\n\r\n—\r\nReply to this email directly, view it on GitHub<https://github.com/tensorflow/tensorflow/issues/62806#issuecomment-1903544221>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/BFM5QXCLEP5KV6PONDZDN73YPYT45AVCNFSM6AAAAABB57PRW6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSMBTGU2DIMRSGE>.\r\nYou are receiving this because you were mentioned.Message ID: ***@***.***>\r\n\r\n________________________________\r\n\r\nNotice: This e-mail may contain confidential and/or privileged information. If you are not the intended recipient or have received this e-mail in error, please notify the sender immediately and destroy this e-mail. Any unauthorized copying, disclosure or distribution of the material in this e-mail is strictly forbidden.\r\nSingapore Institute of Technology, Co. Reg. No. 200917667D.\r\n",
"Hi **@2302187** ,\r\n\r\nCould you please confirm if this issue is resolved for you ? Please feel free to close the issue if it is resolved.\r\n\r\nThank you!",
"Hi,\r\n\r\nThe problem has been resolved\r\n\r\nGet Outlook for iOS<https://aka.ms/o0ukef>\r\n________________________________\r\nFrom: Venkat6871 ***@***.***>\r\nSent: Monday, February 26, 2024 5:04:19 PM\r\nTo: tensorflow/tensorflow ***@***.***>\r\nCc: JASLYN ONG CHING WEN ***@***.***>; Mention ***@***.***>\r\nSubject: Re: [tensorflow/tensorflow] Alteryx Predict (11) : Unexpected Error Occur In Plugin (Issue #62806)\r\n\r\n\r\nCAUTION: This email originated from outside of SIT. Do not click links or open attachments unless you recognise the sender and know the content is safe.\r\n\r\n\r\nHi @2302187<https://github.com/2302187> ,\r\n\r\nCould you please confirm if this issue is resolved for you ? Please feel free to close the issue if it is resolved.\r\n\r\nThank you!\r\n\r\n—\r\nReply to this email directly, view it on GitHub<https://github.com/tensorflow/tensorflow/issues/62806#issuecomment-1963623605>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/BFM5QXGK2ZAFLHJLIADJ4XTYVRFZHAVCNFSM6AAAAABB57PRW6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSNRTGYZDGNRQGU>.\r\nYou are receiving this because you were mentioned.Message ID: ***@***.***>\r\n\r\n________________________________\r\n\r\nNotice: This e-mail may contain confidential and/or privileged information. If you are not the intended recipient or have received this e-mail in error, please notify the sender immediately and destroy this e-mail. Any unauthorized copying, disclosure or distribution of the material in this e-mail is strictly forbidden.\r\nSingapore Institute of Technology, Co. Reg. No. 200917667D.\r\n",
"Thanks for your response!"
] | 2024-01-17T06:25:01 | 2024-03-14T08:48:33 | 2024-03-14T08:48:33 |
NONE
| null | null | null |
[Predict11.log](https://github.com/tensorflow/tensorflow/files/13959432/Predict11.log)
Please help to solve this issue as I am a student who is stuck in this process for my school work.
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62806/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62806/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62805
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62805/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62805/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62805/events
|
https://github.com/tensorflow/tensorflow/issues/62805
| 2,084,434,076 |
I_kwDOArmXAs58PfCc
| 62,805 |
NonMatchingChecksumError while downloading Caltech Birds 2011 dataset
|
{
"login": "aditya02shah",
"id": 106942573,
"node_id": "U_kgDOBl_QbQ",
"avatar_url": "https://avatars.githubusercontent.com/u/106942573?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/aditya02shah",
"html_url": "https://github.com/aditya02shah",
"followers_url": "https://api.github.com/users/aditya02shah/followers",
"following_url": "https://api.github.com/users/aditya02shah/following{/other_user}",
"gists_url": "https://api.github.com/users/aditya02shah/gists{/gist_id}",
"starred_url": "https://api.github.com/users/aditya02shah/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/aditya02shah/subscriptions",
"organizations_url": "https://api.github.com/users/aditya02shah/orgs",
"repos_url": "https://api.github.com/users/aditya02shah/repos",
"events_url": "https://api.github.com/users/aditya02shah/events{/privacy}",
"received_events_url": "https://api.github.com/users/aditya02shah/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 1114343535,
"node_id": "MDU6TGFiZWwxMTE0MzQzNTM1",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:data",
"name": "comp:data",
"color": "0052cc",
"default": false,
"description": "tf.data related issues"
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
closed
| false |
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"@aditya02shah,\r\nI was able to reproduce the issue on tensorflow v2.15. Could you please allow the developer team to deep dive into the issue and resolve the error. Thank you!",
"@tilakrayal Thank your for confirming and looking into the issue! Let me know if you need more details.",
"@aditya02shah,\r\nApologies for the delay. As per the [documentation](https://www.tensorflow.org/datasets/overview#fixing_nonmatchingchecksumerror), **NonMatchingChecksumError** is raised due to the reasons below.\r\nThe website may be down, original datasets files may have been updated or Drive sometimes rejects downloads when too many people access the same URL.\r\n\r\nAs the workaround you can try to download from the [link](https://drive.usercontent.google.com/corp/download?id=1hbzc_P1FuxMkcabkgn9ZKinBwW683j45&export=download&authuser=0) and also request to check in [datasets](https://github.com/tensorflow/datasets/issues) repository for the quick resolution.\r\n\r\nhttps://github.com/tensorflow/datasets/blob/master/tensorflow_datasets/image_classification/caltech_birds.py#L227\r\n\r\nhttps://github.com/tensorflow/datasets/issues/1482\r\n\r\nThank you!\r\n\r\n",
"@tilakrayal Thanks for the assistance!",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62805\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62805\">No</a>\n"
] | 2024-01-16T16:54:21 | 2024-02-28T14:51:38 | 2024-02-28T14:51:35 |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
binary
### TensorFlow version
tf 2.15
### Custom code
Yes
### OS platform and distribution
Google Colab
### Mobile device
_No response_
### Python version
3.10
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
I am encountering a `Non-Matching Checksum error` while attempting to download the `caltech_birds2011` dataset.
The error persists even when using the `tfds-nightly` package.
### Standalone code to reproduce the issue
```shell
Code to reproduce the error:
import tensorflow_datasets as tfds
dataset = tfds.load('caltech_birds2011', split='train')
Colab:https://colab.research.google.com/drive/1jrI02VQ7ETw0oEL5RRk4vD-AQH07ZtIw?usp=sharing
```
### Relevant log output
```shell
Downloading and preparing dataset 1.11 GiB (download: 1.11 GiB, generated: 1.11 GiB, total: 2.22 GiB) to /root/tensorflow_datasets/caltech_birds2011/0.1.1...
Dl Completed...: 100%
1/1 [00:00<00:00, 1.21 url/s]
Dl Size...:
0/0 [00:00<?, ? MiB/s]
---------------------------------------------------------------------------
NonMatchingChecksumError Traceback (most recent call last)
<ipython-input-2-b0dbf98bec1b> in <cell line: 3>()
1 import tensorflow_datasets as tfds
2 print("Version",tfds.__version__)
----> 3 dataset = tfds.load('caltech_birds2011', split='train')
19 frames
/usr/local/lib/python3.10/dist-packages/tensorflow_datasets/core/download/download_manager.py in _validate_checksums(url, path, computed_url_info, expected_url_info, force_checksums_validation)
807 'https://www.tensorflow.org/datasets/overview#fixing_nonmatchingchecksumerror'
808 )
--> 809 raise NonMatchingChecksumError(msg)
810
811
NonMatchingChecksumError: Artifact https://drive.google.com/uc?export=download&id=1hbzc_P1FuxMkcabkgn9ZKinBwW683j45, downloaded to /root/tensorflow_datasets/downloads/ucexport_download_id_1hbzc_P1FuxMkcabkgn9ZKinBw1sbZS_7v82APqMiPk0wej8WzZ5MmtVy61NUy-F6708.tmp.2f1a547e76e047aa9c2c734021a5bd45/download, has wrong checksum:
* Expected: UrlInfo(size=1.07 GiB, checksum='0c685df5597a8b24909f6a7c9db6d11e008733779a671760afef78feb49bf081', filename='CUB_200_2011.tgz')
* Got: UrlInfo(size=2.37 KiB, checksum='90974fd9547262b60bca7e22993f85c62ea79200cfee1bf4bef26e0334a0a7fc', filename='download')
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62805/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62805/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62804
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62804/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62804/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62804/events
|
https://github.com/tensorflow/tensorflow/issues/62804
| 2,084,374,842 |
I_kwDOArmXAs58PQk6
| 62,804 |
Neural network always outputs the average of target values no matter the input
|
{
"login": "flexorcist",
"id": 143087967,
"node_id": "U_kgDOCIdZXw",
"avatar_url": "https://avatars.githubusercontent.com/u/143087967?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/flexorcist",
"html_url": "https://github.com/flexorcist",
"followers_url": "https://api.github.com/users/flexorcist/followers",
"following_url": "https://api.github.com/users/flexorcist/following{/other_user}",
"gists_url": "https://api.github.com/users/flexorcist/gists{/gist_id}",
"starred_url": "https://api.github.com/users/flexorcist/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/flexorcist/subscriptions",
"organizations_url": "https://api.github.com/users/flexorcist/orgs",
"repos_url": "https://api.github.com/users/flexorcist/repos",
"events_url": "https://api.github.com/users/flexorcist/events{/privacy}",
"received_events_url": "https://api.github.com/users/flexorcist/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473184161,
"node_id": "MDU6TGFiZWw0NzMxODQxNjE=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:support",
"name": "type:support",
"color": "159b2e",
"default": false,
"description": "Support issues"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
},
{
"id": 4511033337,
"node_id": "LA_kwDOArmXAs8AAAABDODn-Q",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.10",
"name": "TF 2.10",
"color": "C15088",
"default": false,
"description": ""
}
] |
closed
| false |
{
"login": "SuryanarayanaY",
"id": 116063290,
"node_id": "U_kgDOBur8Og",
"avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/SuryanarayanaY",
"html_url": "https://github.com/SuryanarayanaY",
"followers_url": "https://api.github.com/users/SuryanarayanaY/followers",
"following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}",
"gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}",
"starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions",
"organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs",
"repos_url": "https://api.github.com/users/SuryanarayanaY/repos",
"events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}",
"received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "SuryanarayanaY",
"id": 116063290,
"node_id": "U_kgDOBur8Og",
"avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/SuryanarayanaY",
"html_url": "https://github.com/SuryanarayanaY",
"followers_url": "https://api.github.com/users/SuryanarayanaY/followers",
"following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}",
"gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}",
"starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions",
"organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs",
"repos_url": "https://api.github.com/users/SuryanarayanaY/repos",
"events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}",
"received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Also, I checked the weights and biases of a recently trained model. Almost in all layers weights look like this:\r\n```\r\n-4.1277455e-33 1.9695687e-33 4.1031190e-23 ... -1.5578026e-20\r\n -8.8301270e-33 -1.5537877e-20\r\n```\r\n \r\nAnd biases look like this:\r\n\r\n ```\r\n -4.0955161e-05 4.0955088e-05 -4.0955132e-05 -4.0955088e-05\r\n -4.0955088e-05 -4.0955132e-05 -4.0955132e-05 -4.0955088e-05\r\n```",
"Hi @flexorcist ,\r\n\r\nThis seems to be a support issue not a bug. FOr support issues please post the issue at tensorflow [forum](https://discuss.tensorflow.org/) for help.\r\n\r\nAs you confirmed most of your Y_train data having range of 0.4-0.6 which means your data seems biased.Data Augmentation might help for your case.\r\n\r\nThanks!",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62804\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62804\">No</a>\n"
] | 2024-01-16T16:20:54 | 2024-02-02T01:47:01 | 2024-02-02T01:46:58 |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
source
### TensorFlow version
2.10
### Custom code
Yes
### OS platform and distribution
Windows 11
### Mobile device
_No response_
### Python version
_No response_
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
I have a linear regression neural network made with Keras with a numerical input and a text input converted to encoded integers. It consistently outputs the same value no matter the input. The reason I think it outputs average of the entire Y-train array, which consists of normalized values mostly between 0.4-0.6, is that my model's loss is decreasing during training to really small values like 0.02 though the output is always the same. Training accuracy always stays the same and model is able to accurately predict exactly one entry. I checked which value does it predict correctly every epoch and it is always quite similar to average. Also the output of a trained model is almost identical to the average.
Firstly I tried training the model with 3 different optimizers and 2 loss functions (6 models in total), each model produced its own output, they were different, but in terms of 1 model it was again, same no matter the input. I was searching for a solution for a long time, and I found plenty of methods that should've helped. I implemented weight regularization and initialization, early stopping and dropout (against overfitting), I scaled all the inputs and outputs, but still it didn't help. Then I found a question describing similar problem, and people were telling that the model was just not complex enough and that it was increasing its biases and decreasing its weights in the training phase, which sounded reasonable. I checked my model and actually my biases were something like 0.05 while weights were about 1-e10. So I coded in Zero bias initializers, quite strong regularizers for them, changed activation fucntions to LeakyReLU (against dead neurons), made an increased complexity model, all which resulted in the code below. I tried training it several times while tweaking learning rates from values like 0.003 to 1e-6 during each epoch and still output stays the same. Loss was higher during most of the training because of bias regularization I think, but the result was the same - model with 0.02-0.03 loss which outputs the same average value of Y_train no matter the input. Also, I consider my training data as good as it can be because the amount of time I spent searching for mistakes in it, improving preprocessing and quadruple-checking it all is insane.
### Standalone code to reproduce the issue
```shell
def regDense(a):
return layers.Dense(a, activation=LeakyReLU(), kernel_initializer=initializers_v2.HeNormal(),
kernel_regularizer=l2(0.001), bias_initializer=initializers_v2.Zeros(),
bias_regularizer=l1_l2(0.003, 0.02))
def regLSTM(a):
return layers.LSTM(a, kernel_regularizer=l1_l2(0.0001, 0.0003),
kernel_initializer=initializers_v2.GlorotNormal(),
bias_initializer=initializers_v2.Zeros(),
return_sequences=True,
bias_regularizer=l1_l2(0.0002, 0.002))
num_inp = keras.Input(shape=(30, 3, 1), name='nums')
text_inp = keras.Input(shape=(30, 7, 3208), name='text')
embed = layers.Embedding(vocabsize, output_dim=152)(text_inp)
tlstm1 = layers.TimeDistributed(layers.TimeDistributed(regLSTM(256)))(embed)
tdrop1 = layers.Dropout(0.2)(tlstm1)
nlstm1 = layers.TimeDistributed(regLSTM(256))(num_inp)
ndrop1 = layers.Dropout(0.2)(nlstm1)
tlstm2 = layers.TimeDistributed(layers.TimeDistributed(regLSTM(256)))(tdrop1)
tdrop2 = layers.Dropout(0.2)(tlstm2)
nlstm2 = layers.TimeDistributed(regLSTM(256))(ndrop1)
ndrop2 = layers.Dropout(0.2)(nlstm2)
tlstm3 = layers.TimeDistributed(layers.TimeDistributed(regLSTM(256)))(tdrop2)
tdrop3 = layers.Dropout(0.2)(tlstm3)
ndense1 = regDense(213)(ndrop2)
ndrop3 = layers.Dropout(0.5)(ndense1)
tdense1 = regDense(200)(tdrop3)
tdrop4 = layers.Dropout(0.5)(tdense1)
ndense2 = regDense(170)(ndrop3)
ndrop4 = layers.Dropout(0.5)(ndense2)
tdense2 = regDense(144)(tdrop4)
tpool2 = layers.MaxPooling3D((1, 1, 401), padding='same')(tdense2)
trsp1 = layers.Reshape((30, 1152, 7))(tpool2)
tpool3 = layers.MaxPooling2D((1, 3), padding='same')(trsp1)
trsp2 = layers.Reshape((2688, 30))(tpool3)
tpool4 = layers.MaxPooling1D(7, padding='same')(trsp2)
trsp3 = layers.Reshape((30, 384))(tpool4)
tdrop5 = layers.Dropout(0.5)(trsp3)
ndense3 = regDense(128)(ndrop4)
nrsp = layers.Reshape((30, 384))(ndense3)
ndrop5 = layers.Dropout(0.5)(nrsp)
concat = layers.concatenate([tdrop5, ndrop5])
prc1 = regDense(384)(concat)
pdrop1 = layers.Dropout(0.5)(prc1)
prc2 = regDense(192)(pdrop1)
pdrop2 = layers.Dropout(0.5)(prc2)
prc3 = regDense(96)(pdrop2)
pdrop3 = layers.Dropout(0.5)(prc3)
prc4 = regDense(48)(pdrop3)
pdrop4 = layers.Dropout(0.5)(prc4)
prc5 = regDense(24)(pdrop4)
pdrop5 = layers.Dropout(0.3)(prc5)
prc6 = regDense(12)(pdrop5)
lastpool = layers.GlobalAveragePooling1D()(prc6)
last = layers.Dense(1, activation='relu', kernel_regularizer=l2(0.0008),
kernel_initializer=initializers_v2.HeNormal(),
bias_initializer=initializers_v2.Zeros(),
bias_regularizer=l1_l2(0.003, 0.02),
name='output')(lastpool)
model = keras.Model(inputs=[num_inp, text_inp], outputs=last)
model.compile(optimizer='adam', loss=losses.MeanSquaredError(), metrics=['accuracy'])
model.fit(
{"nums": X1_train, "text": X2_train},
{"output": y_train}, validation_data=({'nums':X1_test, 'text':X2_test}, y_test),
epochs=9, callbacks=[callbacks.EarlyStopping(monitor='val_loss', patience=1, restore_best_weights=True), callbacks.LearningRateScheduler(schedule=scheduler, verbose=1)],
batch_size=1)
```
### Relevant log output
_No response_
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62804/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62804/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62803
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62803/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62803/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62803/events
|
https://github.com/tensorflow/tensorflow/issues/62803
| 2,084,240,915 |
I_kwDOArmXAs58Ov4T
| 62,803 |
tflite-runtime 2.15.0 pip link
|
{
"login": "acode-x",
"id": 91404478,
"node_id": "MDQ6VXNlcjkxNDA0NDc4",
"avatar_url": "https://avatars.githubusercontent.com/u/91404478?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/acode-x",
"html_url": "https://github.com/acode-x",
"followers_url": "https://api.github.com/users/acode-x/followers",
"following_url": "https://api.github.com/users/acode-x/following{/other_user}",
"gists_url": "https://api.github.com/users/acode-x/gists{/gist_id}",
"starred_url": "https://api.github.com/users/acode-x/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/acode-x/subscriptions",
"organizations_url": "https://api.github.com/users/acode-x/orgs",
"repos_url": "https://api.github.com/users/acode-x/repos",
"events_url": "https://api.github.com/users/acode-x/events{/privacy}",
"received_events_url": "https://api.github.com/users/acode-x/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473184161,
"node_id": "MDU6TGFiZWw0NzMxODQxNjE=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:support",
"name": "type:support",
"color": "159b2e",
"default": false,
"description": "Support issues"
},
{
"id": 750616506,
"node_id": "MDU6TGFiZWw3NTA2MTY1MDY=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite",
"name": "comp:lite",
"color": "0052cc",
"default": false,
"description": "TF Lite related issues"
}
] |
closed
| false |
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"@acode-x Please try to build the tflite-runtime library from source for your desired version. Kindly refer to the official TensorFlow Lite instructions for building from source: https://www.tensorflow.org/lite/guide/build_cmake\r\nThank you!",
"Thanks for quick support.\r\nIf I understand correctly, from v2.15.0 onwards we have to build from source?\r\nCan I also use tflite-runtime-nightly ?\r\n",
"@acode-x Yes, building from source is generally required for TensorFlow versions 2.15.0 and newer. This is due to changes in the build process and dependencies. Pre-built binaries might be available on systems like Anaconda or Google Colab. Nightly builds might be less stable than official releases. \r\nThank you!",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62803\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62803\">No</a>\n"
] | 2024-01-16T15:17:40 | 2024-01-17T09:40:30 | 2024-01-17T09:40:27 |
NONE
| null | null | null |
Hi,
Could you guide me where I can download pip3 packages for `tflite-runtime` v2.15.0.
I see only v2.14.0 in PyPi (https://pypi.org/project/tflite-runtime/)
Thanks
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62803/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62803/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62802
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62802/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62802/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62802/events
|
https://github.com/tensorflow/tensorflow/pull/62802
| 2,083,757,361 |
PR_kwDOArmXAs5kLs7B
| 62,802 |
Encode data for bitcast in LE for BE systems
|
{
"login": "yasiribmcon",
"id": 107119183,
"node_id": "U_kgDOBmKCTw",
"avatar_url": "https://avatars.githubusercontent.com/u/107119183?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/yasiribmcon",
"html_url": "https://github.com/yasiribmcon",
"followers_url": "https://api.github.com/users/yasiribmcon/followers",
"following_url": "https://api.github.com/users/yasiribmcon/following{/other_user}",
"gists_url": "https://api.github.com/users/yasiribmcon/gists{/gist_id}",
"starred_url": "https://api.github.com/users/yasiribmcon/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/yasiribmcon/subscriptions",
"organizations_url": "https://api.github.com/users/yasiribmcon/orgs",
"repos_url": "https://api.github.com/users/yasiribmcon/repos",
"events_url": "https://api.github.com/users/yasiribmcon/events{/privacy}",
"received_events_url": "https://api.github.com/users/yasiribmcon/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 390482148,
"node_id": "MDU6TGFiZWwzOTA0ODIxNDg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/awaiting%20review",
"name": "awaiting review",
"color": "bc3869",
"default": false,
"description": "Pull request awaiting review"
},
{
"id": 750616506,
"node_id": "MDU6TGFiZWw3NTA2MTY1MDY=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite",
"name": "comp:lite",
"color": "0052cc",
"default": false,
"description": "TF Lite related issues"
},
{
"id": 1169364458,
"node_id": "MDU6TGFiZWwxMTY5MzY0NDU4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:S",
"name": "size:S",
"color": "adafea",
"default": false,
"description": "CL Change Size: Small"
}
] |
open
| false |
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi @Ferev Can you please review this PR ? Thank you very much!\r\ncc @gbaned ",
"Hi @Ferev Can you please review this PR ? Thank you!",
"Hi @Ferev Can you please review this PR ? Thank you!",
"Hi @Ferev Can you please review this PR ? Thank you!"
] | 2024-01-16T11:50:08 | 2024-06-07T16:45:11 | null |
CONTRIBUTOR
| null | false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62802",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62802",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62802.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62802.patch",
"merged_at": null
}
|
After introducing [commit](https://github.com/tensorflow/tensorflow/commit/ace44332389423ac161c4b04e1b1ca9ca5ce8898) to add builtin op bitcast for TFLite, below test cases started failing for s390x(BE systems):
```
//tensorflow/lite/testing:zip_test_bitcast
//tensorflow/lite/testing:zip_test_bitcast_forward-compat
//tensorflow/lite/testing:zip_test_bitcast_forward-compat_xnnpack
//tensorflow/lite/testing:zip_test_bitcast_mlir-quant
//tensorflow/lite/testing:zip_test_bitcast_mlir-quant_xnnpack
//tensorflow/lite/testing:zip_test_bitcast_with-flex
//tensorflow/lite/testing:zip_test_bitcast_with-flex_xnnpack
//tensorflow/lite/testing:zip_test_bitcast_xnnpack
```
Reason for the failure is zip_test_bitcast is comparing Bitcast operation output from TF with builtin Bitcast tflite operation output.
As per tf.bitcast [documentation](https://www.tensorflow.org/api_docs/python/tf/bitcast#:~:text=Bitcast%20is%20implemented%20as%20a%20low%2Dlevel%20cast%2C%20so%20machines%20with%20different%20endian%20orderings%20will%20give%20different%20results.%20A%20copy%20from%20input%20buffer%20to%20output%20buffer%20is%20made%20on%20BE%20machines%20when%20types%20are%20of%20different%20sizes%20in%20order%20to%20get%20the%20same%20casting%20results%20as%20on%20LE%20machines.), bitcast output should be encoded in LE for BE machines.
Since the builtin Bitcast op is providing native output(BE for BE machines), it is not consistent w.r.t tf.bitcast behaviour.
After this PR, bitcast operation will be consistent across TF and TFLite, rectifying above mentioned test cases for s390x.
These changes will not cause any regression on LE/BE platforms.
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62802/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62802/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62801
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62801/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62801/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62801/events
|
https://github.com/tensorflow/tensorflow/pull/62801
| 2,083,598,683 |
PR_kwDOArmXAs5kLJNv
| 62,801 |
Rectify in-memory buffer model loading for s390x
|
{
"login": "yasiribmcon",
"id": 107119183,
"node_id": "U_kgDOBmKCTw",
"avatar_url": "https://avatars.githubusercontent.com/u/107119183?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/yasiribmcon",
"html_url": "https://github.com/yasiribmcon",
"followers_url": "https://api.github.com/users/yasiribmcon/followers",
"following_url": "https://api.github.com/users/yasiribmcon/following{/other_user}",
"gists_url": "https://api.github.com/users/yasiribmcon/gists{/gist_id}",
"starred_url": "https://api.github.com/users/yasiribmcon/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/yasiribmcon/subscriptions",
"organizations_url": "https://api.github.com/users/yasiribmcon/orgs",
"repos_url": "https://api.github.com/users/yasiribmcon/repos",
"events_url": "https://api.github.com/users/yasiribmcon/events{/privacy}",
"received_events_url": "https://api.github.com/users/yasiribmcon/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 390482148,
"node_id": "MDU6TGFiZWwzOTA0ODIxNDg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/awaiting%20review",
"name": "awaiting review",
"color": "bc3869",
"default": false,
"description": "Pull request awaiting review"
},
{
"id": 750616506,
"node_id": "MDU6TGFiZWw3NTA2MTY1MDY=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite",
"name": "comp:lite",
"color": "0052cc",
"default": false,
"description": "TF Lite related issues"
},
{
"id": 1169364259,
"node_id": "MDU6TGFiZWwxMTY5MzY0MjU5",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS",
"name": "size:XS",
"color": "adafea",
"default": false,
"description": "CL Change Size: Extra Small"
}
] |
open
| false |
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi @Ferev Can you please review this PR ? Thank you very much!\r\ncc @gbaned ",
"Hi @Ferev Can you please review this PR ? Thank you!",
"Hi @Ferev Can you please review this PR ? Thank you!",
"Hi @Ferev Can you please review this PR ? Thank you!"
] | 2024-01-16T10:38:04 | 2024-06-07T16:44:54 | null |
CONTRIBUTOR
| null | false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62801",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62801",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62801.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62801.patch",
"merged_at": null
}
|
After introducing [commit](https://github.com/tensorflow/tensorflow/commit/38a44709efd6e51421a58bfb7df32cf9f7af8fff) to add in-memory model support for mini-benchmark, below test cases started to fail on s390x(BE machines) :
```
//tensorflow/lite/experimental/acceleration/mini_benchmark:validator_runner_impl_test
//tensorflow/lite/experimental/acceleration/mini_benchmark:blocking_validator_runner_test
```
Reason for the failures is because TFLite buffers in buffer model are being loaded in LE format.
After this PR, buffer model will be loading TFLite buffers in BE format for BE plaforms, rectifying above mentioned test cases for s390x.
These changes will not cause any regression on LE/BE platforms.
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62801/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62801/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62800
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62800/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62800/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62800/events
|
https://github.com/tensorflow/tensorflow/pull/62800
| 2,083,328,664 |
PR_kwDOArmXAs5kKM7l
| 62,800 |
Modif TP4
|
{
"login": "WonderMad51",
"id": 116158973,
"node_id": "U_kgDOBuxx_Q",
"avatar_url": "https://avatars.githubusercontent.com/u/116158973?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/WonderMad51",
"html_url": "https://github.com/WonderMad51",
"followers_url": "https://api.github.com/users/WonderMad51/followers",
"following_url": "https://api.github.com/users/WonderMad51/following{/other_user}",
"gists_url": "https://api.github.com/users/WonderMad51/gists{/gist_id}",
"starred_url": "https://api.github.com/users/WonderMad51/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/WonderMad51/subscriptions",
"organizations_url": "https://api.github.com/users/WonderMad51/orgs",
"repos_url": "https://api.github.com/users/WonderMad51/repos",
"events_url": "https://api.github.com/users/WonderMad51/events{/privacy}",
"received_events_url": "https://api.github.com/users/WonderMad51/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 1169364259,
"node_id": "MDU6TGFiZWwxMTY5MzY0MjU5",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS",
"name": "size:XS",
"color": "adafea",
"default": false,
"description": "CL Change Size: Extra Small"
}
] |
closed
| false |
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).\n\nView this [failed invocation](https://github.com/tensorflow/tensorflow/pull/62800/checks?check_run_id=20520774674) of the CLA check for more information.\n\nFor the most up to date status, view the checks section at the bottom of the pull request."
] | 2024-01-16T08:44:06 | 2024-01-16T08:53:13 | 2024-01-16T08:53:13 |
NONE
| null | false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62800",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62800",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62800.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62800.patch",
"merged_at": null
}
| null |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62800/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62800/timeline
| null | null | true |
https://api.github.com/repos/tensorflow/tensorflow/issues/62799
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62799/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62799/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62799/events
|
https://github.com/tensorflow/tensorflow/issues/62799
| 2,083,206,405 |
I_kwDOArmXAs58KzUF
| 62,799 |
Building TFLite for Android with CMake cannot find -lpthread
|
{
"login": "lhchg",
"id": 35790637,
"node_id": "MDQ6VXNlcjM1NzkwNjM3",
"avatar_url": "https://avatars.githubusercontent.com/u/35790637?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/lhchg",
"html_url": "https://github.com/lhchg",
"followers_url": "https://api.github.com/users/lhchg/followers",
"following_url": "https://api.github.com/users/lhchg/following{/other_user}",
"gists_url": "https://api.github.com/users/lhchg/gists{/gist_id}",
"starred_url": "https://api.github.com/users/lhchg/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/lhchg/subscriptions",
"organizations_url": "https://api.github.com/users/lhchg/orgs",
"repos_url": "https://api.github.com/users/lhchg/repos",
"events_url": "https://api.github.com/users/lhchg/events{/privacy}",
"received_events_url": "https://api.github.com/users/lhchg/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473173351,
"node_id": "MDU6TGFiZWw0NzMxNzMzNTE=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:build/install",
"name": "type:build/install",
"color": "159b2e",
"default": false,
"description": "Build and install issues"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
},
{
"id": 750616506,
"node_id": "MDU6TGFiZWw3NTA2MTY1MDY=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:lite",
"name": "comp:lite",
"color": "0052cc",
"default": false,
"description": "TF Lite related issues"
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
closed
| false |
{
"login": "LakshmiKalaKadali",
"id": 149650845,
"node_id": "U_kgDOCOt9nQ",
"avatar_url": "https://avatars.githubusercontent.com/u/149650845?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/LakshmiKalaKadali",
"html_url": "https://github.com/LakshmiKalaKadali",
"followers_url": "https://api.github.com/users/LakshmiKalaKadali/followers",
"following_url": "https://api.github.com/users/LakshmiKalaKadali/following{/other_user}",
"gists_url": "https://api.github.com/users/LakshmiKalaKadali/gists{/gist_id}",
"starred_url": "https://api.github.com/users/LakshmiKalaKadali/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/LakshmiKalaKadali/subscriptions",
"organizations_url": "https://api.github.com/users/LakshmiKalaKadali/orgs",
"repos_url": "https://api.github.com/users/LakshmiKalaKadali/repos",
"events_url": "https://api.github.com/users/LakshmiKalaKadali/events{/privacy}",
"received_events_url": "https://api.github.com/users/LakshmiKalaKadali/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "LakshmiKalaKadali",
"id": 149650845,
"node_id": "U_kgDOCOt9nQ",
"avatar_url": "https://avatars.githubusercontent.com/u/149650845?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/LakshmiKalaKadali",
"html_url": "https://github.com/LakshmiKalaKadali",
"followers_url": "https://api.github.com/users/LakshmiKalaKadali/followers",
"following_url": "https://api.github.com/users/LakshmiKalaKadali/following{/other_user}",
"gists_url": "https://api.github.com/users/LakshmiKalaKadali/gists{/gist_id}",
"starred_url": "https://api.github.com/users/LakshmiKalaKadali/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/LakshmiKalaKadali/subscriptions",
"organizations_url": "https://api.github.com/users/LakshmiKalaKadali/orgs",
"repos_url": "https://api.github.com/users/LakshmiKalaKadali/repos",
"events_url": "https://api.github.com/users/LakshmiKalaKadali/events{/privacy}",
"received_events_url": "https://api.github.com/users/LakshmiKalaKadali/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi @lhchg,\r\n\r\nPlease try with the commit [00122c2](https://github.com/tensorflow/tensorflow/commit/00122c2341466bc1af8aab6e7f0cb607829a40bd).\r\n\r\nThank You",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62799\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62799\">No</a>\n"
] | 2024-01-16T07:45:25 | 2024-02-05T01:47:52 | 2024-02-05T01:47:49 |
NONE
| null | null | null |
**Issue type**
Build/Install
**Have you reproduced the bug with TensorFlow Nightly?**
Yes
**Source**
source
**TensorFlow version**
2.15
**Custom code**
Yes
**OS platform and distribution**
Ubuntu 22.04
**Mobile device**
No response
**Python version**
No response
**Bazel version**
No response
**GCC/compiler version**
cmake version 3.28.0-rc4
**CUDA/cuDNN version**
No response
**GPU model and memory**
No response
**Current behavior?**
Building label_image with CMake with GPU delegate
**Standalone code to reproduce the issue**
```
cmake -DCMAKE_TOOLCHAIN_FILE=${android-ndk-r22}/build/cmake/android.toolchain.cmake -DANDROID_ABI=arm64-v8a -DANDROID_PLATFORM="26" -DTFLITE_ENABLE_GPU=ON -DCMAKE_BUILD_TYPE=Debug ../tensorflow-2.15.0/tensorflow/lite/
make label_image -j32
```
**Relevant log output**
```
[ 60%] Built target absl_flags_reflection
[ 60%] Built target absl_status
[ 60%] Built target absl_flags
[ 95%] Built target tensorflow-lite
[ 95%] Linking CXX executable label_image
ld: error: unable to find library -lpthread
clang++: error: linker command failed with exit code 1 (use -v to see invocation)
make[3]: *** [examples/label_image/CMakeFiles/label_image.dir/build.make:424: examples/label_image/label_image] Error 1
make[2]: *** [CMakeFiles/Makefile2:7481: examples/label_image/CMakeFiles/label_image.dir/all] Error 2
make[1]: *** [CMakeFiles/Makefile2:7488: examples/label_image/CMakeFiles/label_image.dir/rule] Error 2
make: *** [Makefile:2522: label_image] Error 2
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62799/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62799/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62798
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62798/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62798/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62798/events
|
https://github.com/tensorflow/tensorflow/issues/62798
| 2,082,854,150 |
I_kwDOArmXAs58JdUG
| 62,798 |
Having Problems While Doing Digit Recognition in OpenCV Using Tensorflow Mnist
|
{
"login": "deringezgin",
"id": 100523166,
"node_id": "U_kgDOBf3cng",
"avatar_url": "https://avatars.githubusercontent.com/u/100523166?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/deringezgin",
"html_url": "https://github.com/deringezgin",
"followers_url": "https://api.github.com/users/deringezgin/followers",
"following_url": "https://api.github.com/users/deringezgin/following{/other_user}",
"gists_url": "https://api.github.com/users/deringezgin/gists{/gist_id}",
"starred_url": "https://api.github.com/users/deringezgin/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/deringezgin/subscriptions",
"organizations_url": "https://api.github.com/users/deringezgin/orgs",
"repos_url": "https://api.github.com/users/deringezgin/repos",
"events_url": "https://api.github.com/users/deringezgin/events{/privacy}",
"received_events_url": "https://api.github.com/users/deringezgin/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473184161,
"node_id": "MDU6TGFiZWw0NzMxODQxNjE=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:support",
"name": "type:support",
"color": "159b2e",
"default": false,
"description": "Support issues"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
},
{
"id": 1097546578,
"node_id": "MDU6TGFiZWwxMDk3NTQ2NTc4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:keras",
"name": "comp:keras",
"color": "0052cc",
"default": false,
"description": "Keras related issues"
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
closed
| false |
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"@deringezgin I would recommend using a `Convolutional Neural Network(CNN)` based architecture for your digit classifier. It should boost your performance by extracting better spatial features. A good [tutorial](https://www.tensorflow.org/tutorials/images/cnn) for getting started with CNN's.</br> Let me know if you have any other questions!",
"> @deringezgin I would recommend using a `Convolutional Neural Network(CNN)` based architecture for your digit classifier. It should boost your performance by extracting better spatial features. A good [tutorial](https://www.tensorflow.org/tutorials/images/cnn) for getting started with CNN's.</br> Let me know if you have any other questions!\n\nHi, Thank you for your response. Maybe a beginner question but how can I train the network with number images? When I checked the link you provided, I can only see other objects like car, plane etc.",
"@deringezgin CNN's are highly versatile and work with all kinds of image data .</br>Just ensure your CNN is adapted to handle your resized 28 x 28 images. You can find many `Digit Classifier` Tutorials on the [Internet](https://machinelearningmastery.com/how-to-develop-a-convolutional-neural-network-from-scratch-for-mnist-handwritten-digit-classification/)<br/>Hope this helps!",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"@deringezgin,\r\nConvolutional Neural Networks (CNNs) are the good choice for image recognition tasks. Use convolutional layers to extract features from the images and Add pooling layers for dimensionality reduction. Also employ fully-connected layers for final classification or regression.\r\n\r\nCould you please refer to this official document for the reference.\r\nhttps://www.tensorflow.org/tutorials/images/cnn\r\n\r\nThank you!\r\n\r\n",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62798\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62798\">No</a>\n"
] | 2024-01-16T00:56:16 | 2024-02-10T01:45:58 | 2024-02-10T01:45:53 |
NONE
| null | null | null |
### Issue type
Support
### Have you reproduced the bug with TensorFlow Nightly?
No
### Source
source
### TensorFlow version
2.15.0
### Custom code
Yes
### OS platform and distribution
MacOS Sonoma 14.2.1
### Mobile device
_No response_
### Python version
3.11.7
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
Apple M2 Max
### Current behavior?
Currently I'm learning OpenCV and decided to make a project to practice my skills. In my project, I'm aiming to read a sudoku table, divide it into individual cells, and recognize the numbers. The rest is mostly sudoku solving.
Right now, I'm stuck on recognizing the numbers part. I decided to use mnist dataset to train the model. For a reason that I couldn't figure out, the program always recognizes the digit wrong.
[First form of my Image](https://i.stack.imgur.com/9bHhp.png)
[My image after rescaling](https://i.stack.imgur.com/qOb0C.png)
I thought that the problem was with the way that I trained the model. Because I transformed my huge image to 28x28, it blurred the image a lot. I thought that that was the problem. The code that I added below trains the model in 300x300 form. It's definitely slower but I thought that It's more safe. Unfortunately, the result didn't change.
The code below also outputs the probability for every class. I input an image (which I gave the link to) with the number 6, but it doesn't work. and the model guesses it as 8. I don't know to source of the problem. I hope that you can help me.
### Standalone code to reproduce the issue
```shell
sample = splitted_blocks[0][0][6]
size = 300
(ds_train, ds_test), ds_info = tfds.load(
'mnist',
split=['train', 'test'],
shuffle_files=True,
as_supervised=True,
with_info=True,
)
def resize_img(image, label):
return tf.image.resize(image, (size, size)), label
ds_train = ds_train.map(resize_img, num_parallel_calls=tf.data.AUTOTUNE)
ds_test = ds_test.map(resize_img, num_parallel_calls=tf.data.AUTOTUNE)
def normalize_img(image, label):
"""Normalizes images: `uint8` -> `float32`."""
return tf.cast(image, tf.float32) / 255., label
ds_train = ds_train.map(normalize_img, num_parallel_calls=tf.data.AUTOTUNE)
ds_train = ds_train.cache()
ds_train = ds_train.shuffle(ds_info.splits['train'].num_examples)
ds_train = ds_train.batch(128)
ds_train = ds_train.prefetch(tf.data.AUTOTUNE)
ds_test = ds_test.map(normalize_img, num_parallel_calls=tf.data.AUTOTUNE)
ds_test = ds_test.batch(128)
ds_test = ds_test.cache()
ds_test = ds_test.prefetch(tf.data.AUTOTUNE)
model = tf.keras.models.Sequential([
tf.keras.layers.Flatten(input_shape=(size, size, 1)),
tf.keras.layers.Dense(128, activation='relu'),
tf.keras.layers.Dense(10)
])
model.compile(
optimizer=tf.keras.optimizers.legacy.Adam(0.001),
loss=tf.keras.losses.SparseCategoricalCrossentropy(from_logits=True),
metrics=[tf.keras.metrics.SparseCategoricalAccuracy()],
)
model.fit(
ds_train,
epochs=6,
validation_data=ds_test,
)
sample = cv.cvtColor(sample, cv.COLOR_BGR2GRAY)
sample = cv.resize(sample, (size, size))
view_image(sample)
sample = np.invert(np.array([sample]))
prediction = model.predict(sample)
print(np.argmax(prediction))
for class_index, prob in enumerate(prediction[0]):
print(f'Class {class_index}: Probability {prob}')
sample = np.invert(np.array([sample])).reshape((size, size, 1))
cv.imshow("test", sample)
cv.waitKey(0)
```
### Relevant log output
```shell
Epoch 1/6
469/469 [==============================] - 20s 36ms/step - loss: 0.3859 - sparse_categorical_accuracy: 0.9090 - val_loss: 0.1917 - val_sparse_categorical_accuracy: 0.9432
Epoch 2/6
469/469 [==============================] - 17s 37ms/step - loss: 0.1866 - sparse_categorical_accuracy: 0.9472 - val_loss: 0.1665 - val_sparse_categorical_accuracy: 0.9530
Epoch 3/6
469/469 [==============================] - 17s 37ms/step - loss: 0.1414 - sparse_categorical_accuracy: 0.9585 - val_loss: 0.1636 - val_sparse_categorical_accuracy: 0.9548
Epoch 4/6
469/469 [==============================] - 17s 37ms/step - loss: 0.1215 - sparse_categorical_accuracy: 0.9642 - val_loss: 0.1735 - val_sparse_categorical_accuracy: 0.9563
Epoch 5/6
469/469 [==============================] - 17s 37ms/step - loss: 0.1060 - sparse_categorical_accuracy: 0.9676 - val_loss: 0.1444 - val_sparse_categorical_accuracy: 0.9615
Epoch 6/6
469/469 [==============================] - 17s 37ms/step - loss: 0.1040 - sparse_categorical_accuracy: 0.9688 - val_loss: 0.1410 - val_sparse_categorical_accuracy: 0.9630
1/1 [==============================] - 0s 59ms/step
8
Class 0: Probability 144.3349151611328
Class 1: Probability 2138.992431640625
Class 2: Probability 4751.95068359375
Class 3: Probability 4140.23583984375
Class 4: Probability -2975.758544921875
Class 5: Probability 2814.78662109375
Class 6: Probability 1327.113525390625
Class 7: Probability 2143.239990234375
Class 8: Probability 4821.7548828125
Class 9: Probability -3011.857666015625
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62798/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62798/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62797
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62797/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62797/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62797/events
|
https://github.com/tensorflow/tensorflow/issues/62797
| 2,082,265,203 |
I_kwDOArmXAs58HNhz
| 62,797 |
Grad Cam Returning None
|
{
"login": "04samuel",
"id": 66639047,
"node_id": "MDQ6VXNlcjY2NjM5MDQ3",
"avatar_url": "https://avatars.githubusercontent.com/u/66639047?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/04samuel",
"html_url": "https://github.com/04samuel",
"followers_url": "https://api.github.com/users/04samuel/followers",
"following_url": "https://api.github.com/users/04samuel/following{/other_user}",
"gists_url": "https://api.github.com/users/04samuel/gists{/gist_id}",
"starred_url": "https://api.github.com/users/04samuel/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/04samuel/subscriptions",
"organizations_url": "https://api.github.com/users/04samuel/orgs",
"repos_url": "https://api.github.com/users/04samuel/repos",
"events_url": "https://api.github.com/users/04samuel/events{/privacy}",
"received_events_url": "https://api.github.com/users/04samuel/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
},
{
"id": 1097547147,
"node_id": "MDU6TGFiZWwxMDk3NTQ3MTQ3",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:ops",
"name": "comp:ops",
"color": "0052cc",
"default": false,
"description": "OPs related issues"
},
{
"id": 3797168204,
"node_id": "LA_kwDOArmXAs7iVDBM",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.8",
"name": "TF 2.8",
"color": "5DC9D0",
"default": false,
"description": ""
}
] |
closed
| false |
{
"login": "SuryanarayanaY",
"id": 116063290,
"node_id": "U_kgDOBur8Og",
"avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/SuryanarayanaY",
"html_url": "https://github.com/SuryanarayanaY",
"followers_url": "https://api.github.com/users/SuryanarayanaY/followers",
"following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}",
"gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}",
"starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions",
"organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs",
"repos_url": "https://api.github.com/users/SuryanarayanaY/repos",
"events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}",
"received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "SuryanarayanaY",
"id": 116063290,
"node_id": "U_kgDOBur8Og",
"avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/SuryanarayanaY",
"html_url": "https://github.com/SuryanarayanaY",
"followers_url": "https://api.github.com/users/SuryanarayanaY/followers",
"following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}",
"gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}",
"starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions",
"organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs",
"repos_url": "https://api.github.com/users/SuryanarayanaY/repos",
"events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}",
"received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi @04samuel ,\r\n\r\nCould you please submit a minimal reproducible code snippet. Attached code has some dependencies missing and not able to reproduce reported behaviour due to missing dependencies.Attached [gist](https://colab.sandbox.google.com/gist/SuryanarayanaY/ea90926547f50d910ba119bc0c63470e/62797.ipynb).",
"```\r\nimport tensorflow as tf\r\nfrom tensorflow.keras.models import Model\r\nimport numpy as np\r\nimport matplotlib.pyplot as plt\r\nfrom PIL import Image\r\n\r\n# Define a simple model for demonstration\r\ndef create_simple_model(input_shape):\r\n model = tf.keras.Sequential([\r\n tf.keras.layers.Conv2D(64, (3, 3), activation='relu', input_shape=input_shape, name='conv2d_1'),\r\n tf.keras.layers.MaxPooling2D((2, 2)),\r\n tf.keras.layers.Conv2D(64, (3, 3), activation='relu', name='conv2d_2'),\r\n tf.keras.layers.MaxPooling2D((2, 2)),\r\n tf.keras.layers.Flatten(),\r\n tf.keras.layers.Dense(64, activation='tanh'),\r\n tf.keras.layers.Dropout(0.2),\r\n tf.keras.layers.Dense(50),\r\n tf.keras.layers.Dropout(0.2),\r\n tf.keras.layers.Reshape((50,))\r\n ])\r\n return model\r\n\r\n# Load and preprocess a sample image for Grad-CAM\r\ndef load_and_preprocess_image_for_grad_cam(image_path):\r\n # Replace this with your actual image loading code\r\n image = Image.fromarray(np.random.randint(0, 255, size=(217, 306)).astype('uint8'))\r\n image_array = np.array(image).reshape((217, 306, 1)).astype('float32') / 255.0\r\n return image_array\r\n\r\n# Create a simple model\r\ninput_shape = (217, 306, 1)\r\nmodel = create_simple_model(input_shape)\r\n\r\n# Load a sample image for Grad-CAM\r\nimage_array = load_and_preprocess_image_for_grad_cam('sample_image')\r\n\r\n# Function to generate Grad-CAM\r\ndef generate_grad_cam(model, img_array):\r\n grad_model = Model(inputs=model.input, outputs=model.get_layer('conv2d_2').output)\r\n\r\n with tf.GradientTape() as tape:\r\n last_conv_output = grad_model(img_array[np.newaxis, ...])\r\n tape.watch(last_conv_output)\r\n\r\n preds = model(img_array[np.newaxis, ...])\r\n\r\n # Get the top predicted class index\r\n top_class_index = tf.argmax(preds[0])\r\n\r\n grads = tape.gradient(preds[:, top_class_index], last_conv_output)\r\n\r\n # Compute the average gradient over each feature map channel\r\n pooled_grads = tf.reduce_mean(grads, axis=(0, 1))\r\n\r\n # Multiply each feature map by its importance score (obtained from the gradients)\r\n last_conv_output = last_conv_output.numpy()[0]\r\n heatmap = np.mean(last_conv_output * pooled_grads[..., np.newaxis], axis=-1)\r\n\r\n # Normalize the heatmap\r\n heatmap = np.maximum(heatmap, 0)\r\n heatmap /= np.max(heatmap)\r\n\r\n return heatmap\r\n\r\n# Generate and display Grad-CAM\r\nheatmap = generate_grad_cam(model, image_array)\r\n\r\n# Display the original image and Grad-CAM side by side\r\nplt.subplot(1, 2, 1)\r\nplt.imshow(image_array.squeeze(), cmap='gray')\r\nplt.title('Original Image')\r\n\r\nplt.subplot(1, 2, 2)\r\nplt.imshow(heatmap, cmap='viridis')\r\nplt.title('Grad-CAM')\r\n\r\nplt.show()\r\n\r\n```",
"Hi @04samuel,\r\n\r\nThe code `grads = tape.gradient(preds[:, top_class_index], last_conv_output)` returns `None` since the two arguments are not connected and there is no differentiable path connecting these args.Please refer this [source](https://www.tensorflow.org/api_docs/python/tf/UnconnectedGradients) for more details.\r\n\r\nIf you change the above line of code by adding the parameter `unconnected_gradients=tf.UnconnectedGradients.ZERO`\r\nit will return ZERO tensor instead of None. Please refer [gist](https://colab.research.google.com/gist/SuryanarayanaY/7c1db2364079f5f38a06a3ed6f1edccb/62797.ipynb#scrollTo=8_h1FOBCWBjc).\r\n\r\n```\r\ngrads = tape.gradient(preds[:, top_class_index], last_conv_output,\r\n unconnected_gradients=tf.UnconnectedGradients.ZERO)\r\n```\r\n\r\nThis is just to prove that the `target` and `sources` passed to gradient function is not connected and hence the problem.\r\nPlease rewrite the code by referring this [tutorial](https://keras.io/examples/vision/grad_cam/).\r\n\r\nThanks!",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62797\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62797\">No</a>\n"
] | 2024-01-15T15:32:47 | 2024-02-03T01:47:02 | 2024-02-03T01:46:58 |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
No
### Source
source
### TensorFlow version
2.8
### Custom code
Yes
### OS platform and distribution
_No response_
### Mobile device
_No response_
### Python version
3.10
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
I am using Gradient Tape to perform Grad Cam analysis on my CNN however grads returns None
Please see my code below, I have looked through pervious issues but nothing seems to work
```
@dataclass
class M:
train = True
results = True
sensitivity = False
filepath = str(pathlib.Path(__file__).parent.resolve())
verbose = 1 # 1)Lots 3) Few
Start = -300
End = 51
pixel_width = 334
pixel_height = 217
pixel_horizontal_padding = 14
target_size = (pixel_height, pixel_width-(2*pixel_horizontal_padding), 1)
##########################################################################################
def main():
train_profiles, train_x, train_y, train_images, validation_profiles, validation_x, validation_y, validation_images, test_profiles, test_x, test_y, test_images, input_shape, output_shape = load_dataset()
# model, earlyStopping, reduceLR = Model_Compiler(input_shape, output_shape)
# model, history = Model_Trainer(model, train_images, validation_images, train_y, validation_y, earlyStopping, reduceLR)
# histroy_plots(history)
# save_model(model)
model = load_model()
model.summary()
image_array = test_images[0]
#prediction = Prediction(model, test_images)
plt.imshow(image_array, cmap='gray')
print(image_array.shape)
grad_cam(model, image_array)
def load_and_preprocess_image(image_path):
image = Image.open(f'Images/{image_path}.png')
width, height = image.size
image = image.crop((M.pixel_horizontal_padding, 0, (width - M.pixel_horizontal_padding), height))
image = image.convert('L')
image_array = np.array(image)
image_array = image_array.reshape(M.target_size)
image_array = image_array.astype('float32') / 255.0
return image_array
def load_dataset():
df = pd.read_csv('Coordinates.csv')
images = [load_and_preprocess_image(i) for i in range(len(df))]
profiles = df.iloc[:, 0].tolist()
x_coordinates = df.iloc[:, 1:302].values.tolist()
y_coordinates = df.iloc[:, -50:].values.tolist()
data = list(zip(profiles, x_coordinates, y_coordinates, images))
train_data, test_data = train_test_split(data, test_size=0.3, random_state=42)
train_data, validation_data = train_test_split(train_data, test_size=0.5, random_state=42)
train_profiles, train_x, train_y, train_images = zip(*train_data)
validation_profiles, validation_x, validation_y, validation_images = zip(*validation_data)
test_profiles, test_x, test_y, test_images = zip(*test_data)
train_profiles, train_x, train_y, train_images = np.array(train_profiles), np.array(train_x), np.array(train_y), np.array(train_images)
validation_profiles, validation_x, validation_y, validation_images = np.array(validation_profiles), np.array(validation_x), np.array(validation_y), np.array(validation_images)
test_profiles, test_x, test_y, test_images = np.array(test_profiles), np.array(test_x), np.array(test_y), np.array(test_images)
input_shape = train_images.shape[1:]
output_shape = train_y.shape[1:]
return (
train_profiles, train_x, train_y, train_images,
validation_profiles, validation_x, validation_y, validation_images,
test_profiles, test_x, test_y, test_images, input_shape, output_shape
)
def Model_Compiler(input_shape, output_shape):
checkpoint = ModelCheckpoint(M.filepath , monitor='val_loss', verbose=1, save_best_only=True, mode='auto')
earlyStopping = EarlyStopping(
monitor="val_loss",
patience=10,
restore_best_weights=True
)
reduceLR = ReduceLROnPlateau(monitor='val_loss', factor=0.2,
patience=3, min_lr=0.00001)
model = models.Sequential()
model.add(layers.Conv2D(128, (3, 3), activation='relu', input_shape=input_shape))
model.add(layers.BatchNormalization())
model.add(layers.MaxPooling2D((2, 2)))
model.add(layers.Conv2D(64, (3, 3), activation='relu'))
model.add(layers.BatchNormalization())
model.add(layers.MaxPooling2D((2, 2)))
model.add(layers.Conv2D(64, (3, 3), activation='relu'))
model.add(layers.BatchNormalization())
model.add(layers.Flatten())
model.add(layers.Dense(64, activation='tanh'))
model.add(layers.Dropout(0.2))
model.add(layers.Dense(np.prod(output_shape)))
model.add(layers.Dropout(0.2)) # Output layer with number of neurons corresponding to output shape
model.add(layers.Reshape(output_shape)) # Reshape output to the target size
model.compile(optimizer='adam', loss='mse')
return model, earlyStopping, reduceLR
def Model_Trainer(model, x_train, x_val, y_train, y_val, earlyStopping, reduceLR):
history = model.fit(
x=x_train
, y=y_train
, validation_data=(x_val,y_val)
, batch_size=4
, epochs= 10000
, callbacks=[earlyStopping, reduceLR]
, verbose=M.verbose
)
return model, history
def Prediction(model, x_test):
model.summary()
prediction = model.predict(x_test)
return prediction
def data_saver(prediction):
for i in range (len(test_df)):
predicted_values = pred_df[i]
real_values = test_df[i]
with open('CNN_2D_Results.csv', 'a', newline='') as f:
writer = csv.writer(f)
writer.writerow(x_values)
writer.writerow(predicted_values)
writer.writerow(x_values)
writer.writerow(real_values)
def display_images_in_loop(image_list):
for index, image in enumerate(image_list):
plt.imshow(image, cmap='gray') # Set cmap to 'gray' for grayscale
plt.axis('off')
plt.title(f'Image {index + 1}')
plt.show()
input("Press Enter to continue...")
def histroy_plots(history):
print(history.history.keys())
# plt.plot(history.history['accuracy'])
# plt.plot(history.history['val_accuracy'])
# plt.title('model accuracy')
# plt.ylabel('accuracy')
# plt.xlabel('epoch')
# plt.legend(['train', 'test'], loc='upper left')
# plt.show()
# summarize history for loss
plt.plot(history.history['loss'])
plt.plot(history.history['val_loss'])
plt.title('model loss')
plt.ylabel('loss')
plt.xlabel('epoch')
plt.legend(['train', 'test'], loc='upper left')
plt.show()
def save_model(model):
model_json = model.to_json()
with open("model.json", "w") as json_file:
json_file.write(model_json)
model.save_weights("model.h5")
print("Saved model to disk")
def load_model():
# load json and create model
json_file = open('model.json', 'r')
loaded_model_json = json_file.read()
json_file.close()
model = model_from_json(loaded_model_json)
# load weights into new model
model.load_weights("model.h5")
print("Loaded model from disk")
return model
def grad_cam(model, img_array):
grad_model = Model(inputs=model.input, outputs=model.get_layer('conv2d_5').output)
with tf.GradientTape() as tape:
last_conv_output = grad_model(img_array[np.newaxis, ...])
tape.watch(last_conv_output)
preds = model(img_array[np.newaxis, ...])
# Get the top predicted class index
top_class_index = tf.argmax(preds[0])
grads = tape.gradient(preds[:, top_class_index], last_conv_output)
# Compute the average gradient over each feature map channel
pooled_grads = tf.reduce_mean(grads, axis=(0, 1))
# Multiply each feature map by its importance score (obtained from the gradients)
last_conv_output = last_conv_output.numpy()[0]
heatmap = np.mean(last_conv_output * pooled_grads[..., np.newaxis], axis=-1)
# Normalize the heatmap
heatmap = np.maximum(heatmap, 0)
heatmap /= np.max(heatmap)
return heatmap
if __name__ == "__main__":
main()
```
### Standalone code to reproduce the issue
```shell
File ~\AppData\Local\anaconda3\envs\tf\lib\site-packages\spyder_kernels\py3compat.py:356 in compat_exec
exec(code, globals, locals)
File c:\users\str24\documents\neural networks\gwithian\99 2dcnn\cnn_2d_model_grad_cam.py:262
main()
File c:\users\str24\documents\neural networks\gwithian\99 2dcnn\cnn_2d_model_grad_cam.py:64 in main
grad_cam(model, image_array)
File c:\users\str24\documents\neural networks\gwithian\99 2dcnn\cnn_2d_model_grad_cam.py:241 in grad_cam
pooled_grads = tf.reduce_mean(grads, axis=(0, 1))
File ~\AppData\Local\anaconda3\envs\tf\lib\site-packages\tensorflow\python\util\traceback_utils.py:153 in error_handler
raise e.with_traceback(filtered_tb) from None
File ~\AppData\Local\anaconda3\envs\tf\lib\site-packages\tensorflow\python\framework\constant_op.py:102 in convert_to_eager_tensor
return ops.EagerTensor(value, ctx.device_name, dtype)
ValueError: Attempt to convert a value (None) with an unsupported type (<class 'NoneType'>) to a Tensor.
```
### Relevant log output
_No response_
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62797/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62797/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62796
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62796/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62796/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62796/events
|
https://github.com/tensorflow/tensorflow/issues/62796
| 2,082,199,520 |
I_kwDOArmXAs58G9fg
| 62,796 |
Multi-GPU training with gradient propagation in FP16 with XLA fails.
|
{
"login": "cyanic-selkie",
"id": 32219669,
"node_id": "MDQ6VXNlcjMyMjE5NjY5",
"avatar_url": "https://avatars.githubusercontent.com/u/32219669?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/cyanic-selkie",
"html_url": "https://github.com/cyanic-selkie",
"followers_url": "https://api.github.com/users/cyanic-selkie/followers",
"following_url": "https://api.github.com/users/cyanic-selkie/following{/other_user}",
"gists_url": "https://api.github.com/users/cyanic-selkie/gists{/gist_id}",
"starred_url": "https://api.github.com/users/cyanic-selkie/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/cyanic-selkie/subscriptions",
"organizations_url": "https://api.github.com/users/cyanic-selkie/orgs",
"repos_url": "https://api.github.com/users/cyanic-selkie/repos",
"events_url": "https://api.github.com/users/cyanic-selkie/events{/privacy}",
"received_events_url": "https://api.github.com/users/cyanic-selkie/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 404586594,
"node_id": "MDU6TGFiZWw0MDQ1ODY1OTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20tensorflower",
"name": "stat:awaiting tensorflower",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from tensorflower"
},
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 996845227,
"node_id": "MDU6TGFiZWw5OTY4NDUyMjc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:dist-strat",
"name": "comp:dist-strat",
"color": "0052cc",
"default": false,
"description": "Distribution Strategy related issues"
},
{
"id": 5922361893,
"node_id": "LA_kwDOArmXAs8AAAABYQASJQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF2.14",
"name": "TF2.14",
"color": "b60205",
"default": false,
"description": "For issues related to Tensorflow 2.14.x"
}
] |
open
| false |
{
"login": "sachinprasadhs",
"id": 73069040,
"node_id": "MDQ6VXNlcjczMDY5MDQw",
"avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sachinprasadhs",
"html_url": "https://github.com/sachinprasadhs",
"followers_url": "https://api.github.com/users/sachinprasadhs/followers",
"following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}",
"gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions",
"organizations_url": "https://api.github.com/users/sachinprasadhs/orgs",
"repos_url": "https://api.github.com/users/sachinprasadhs/repos",
"events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}",
"received_events_url": "https://api.github.com/users/sachinprasadhs/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "sachinprasadhs",
"id": 73069040,
"node_id": "MDQ6VXNlcjczMDY5MDQw",
"avatar_url": "https://avatars.githubusercontent.com/u/73069040?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sachinprasadhs",
"html_url": "https://github.com/sachinprasadhs",
"followers_url": "https://api.github.com/users/sachinprasadhs/followers",
"following_url": "https://api.github.com/users/sachinprasadhs/following{/other_user}",
"gists_url": "https://api.github.com/users/sachinprasadhs/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sachinprasadhs/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sachinprasadhs/subscriptions",
"organizations_url": "https://api.github.com/users/sachinprasadhs/orgs",
"repos_url": "https://api.github.com/users/sachinprasadhs/repos",
"events_url": "https://api.github.com/users/sachinprasadhs/events{/privacy}",
"received_events_url": "https://api.github.com/users/sachinprasadhs/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"@cyanic-selkie The error in the outcome would be because of the following reasons;\r\na. Incorrect loss scaling factor leading to overflows or underflow.\r\nb. Incompatible data types between layers or operations.\r\nc. Casting issues between FP16 and FP32 during gradient propagation.\r\nPlease check if XLA not enabled or not being used for all relevant operations?\r\nThank you!\r\n",
"Hi, @sushreebarsa. How do I check that?",
"@cyanic-selkie To check if XLA is enabled or not please use , `tf.config.list_logical_devices()'\r\n If XLA is disabled, you won't see any XLA devices listed in the output.\r\n```\r\nimport tensorflow as tf\r\n\r\nprint(tf.config.list_logical_devices())\r\n```\r\n@sachinprasadhs Please have a look at this issue.\r\nThank you!",
"Sorry for the delayed response, here is the result @sachinprasadhs:\r\n\r\n```\r\n[LogicalDevice(name='/job:worker/replica:0/task:0/device:CPU:0', device_type='CPU'), LogicalDevice(name='/job:worker/replica:0/task:0/device:GPU:0', device_type='GPU'), LogicalDevice(name='/job:worker/replica:0/task:1/device:CPU:0', device_type='CPU'), LogicalDevice(name='/job:worker/replica:0/task:1/device:GPU:0', device_type='GPU')]\r\n```",
"Hi. I have the same problem when using Mirrored strategy for ditributed training and jit compiling some functions called inside the training loop step. Any news regarding this @cyanic-selkie @sushreebarsa ?",
"@andremfreitas Unfortunately, no. In fact, all of my opened issues ultimately went unanswered. It's no secret that TF is internally deprecated, and I would suggest switching to PyTorch or JAX/Flax, perhaps using Keras 3 as a stepping stone if legacy code is a big issue for you."
] | 2024-01-15T14:56:06 | 2024-04-29T14:14:22 | null |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
Yes
### Source
binary
### TensorFlow version
tf 2.14
### Custom code
Yes
### OS platform and distribution
_No response_
### Mobile device
_No response_
### Python version
3.11
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
11.8/8.7
### GPU model and memory
A100 40GB (20GB MiG)
### Current behavior?
Following advice given [here](https://www.youtube.com/watch?v=6ovfZW8pepo), I implemented gradient propagation in FP16 and concurrent backpropagation with gradient propagation. I am using mixed precision with XLA enabled.
The custom training step works fine when XLA is not enabled. However, when I enable it, I get the error that you can see in the log.
This is run on 2 GPUs using MultiWorkerMirroredStrategy.
### Standalone code to reproduce the issue
```python
import json
import os
import tensorflow as tf
def get_replica_hostnames():
...
def get_replica_id():
...
def set_multiworker_env_config():
hostnames = get_replica_hostnames()
replica_index = get_replica_id()
os.environ["TF_CONFIG"] = json.dumps(
{
"cluster": {
"worker": hostnames,
},
"task": {"type": "worker", "index": replica_index},
}
)
class Model(tf.keras.models.Model):
def __init__(self, *args: Any, **kwargs: Any) -> None:
super().__init__(*args, **kwargs)
self._embedder = tf.keras.Sequential(
[
tf.keras.layers.Conv2D(
filters=8,
kernel_size=3,
padding="same",
activation=tf.keras.activations.relu,
use_bias=False,
),
tf.keras.layers.BatchNormalization(),
tf.keras.layers.Conv2D(
filters=8,
kernel_size=3,
padding="same",
activation=tf.keras.activations.relu,
use_bias=False,
),
tf.keras.layers.BatchNormalization(),
tf.keras.layers.MaxPool2D(),
tf.keras.layers.GlobalAveragePooling2D(),
]
)
self._classifier = tf.keras.layers.Dense(550)
def call(self, x: tf.Tensor) -> tf.Tensor:
x = self._embedder(x)
x = self._classifier(x)
x = tf.keras.layers.Activation("linear", dtype="float32")(x)
return x
def train_step(self, data):
x, y, sample_weight = tf.keras.utils.unpack_x_y_sample_weight(data)
# Run forward pass.
with tf.GradientTape() as tape:
y_pred = self(x, training=True)
loss = self.compute_loss(x, y, y_pred, sample_weight)
loss = self.optimizer.get_scaled_loss(loss)
self._validate_target_and_loss(y, loss)
# Run backward pass.
grads = tape.gradient(loss, self.trainable_variables)
grads = [tf.cast(grad, "float16") for grad in grads]
all_reduced_grads = tf.distribute.get_replica_context().all_reduce(
tf.distribute.ReduceOp.SUM,
grads,
tf.distribute.experimental.CommunicationOptions(
bytes_per_pack=50 * 1024 * 1024,
),
)
all_reduced_grads = [tf.cast(grad, "float32") for grad in all_reduced_grads]
all_reduced_grads = self.optimizer.get_unscaled_gradients(all_reduced_grads)
self.optimizer.apply_gradients(
zip(all_reduced_grads, self.trainable_variables),
skip_gradients_aggregations=True,
)
return self.compute_metrics(x, y, y_pred, sample_weight)
def create_dummy_dataset(batch_size: int) -> tf.data.Dataset:
X = np.random.rand(batch_size, 384, 640, 1)
y = np.random.randint(550, size=batch_size)
return tf.data.Dataset.from_tensor_slices((X, y)).batch(batch_size, True).repeat()
def train():
tf.keras.mixed_precision.set_global_policy("mixed_float16")
set_multiworker_env_config()
strategy = tf.distribute.MultiWorkerMirroredStrategy()
num_replicas = strategy.num_replicas_in_sync
batch_size = 384 * num_replicas
dataset = create_dummy_dataset(batch_size)
dataset = strategy.experimental_distribute_dataset(dataset)
with strategy.scope():
model = Model()
model.compile(
loss=tf.keras.losses.SparseCategoricalCrossentropy(
from_logits=True,
),
optimizer=tf.keras.optimizers.Adam(
learning_rate=1e-3,
weight_decay=1e-5,
),
metrics=[
"accuracy",
],
jit_compile=True,
)
model.fit(
dataset,
epochs=10,
steps_per_epoch=100,
)
if __name__ == "__main__":
train()
```
### Relevant log output
```shell
2024-01-15 14:06:48.704206: E tensorflow/compiler/xla/stream_executor/cuda/cuda_dnn.cc:9342] Unable to register cuDNN factory: Attempting to register factory for plugin cuDNN when one has already been registered
2024-01-15 14:06:48.704294: E tensorflow/compiler/xla/stream_executor/cuda/cuda_fft.cc:609] Unable to register cuFFT factory: Attempting to register factory for plugin cuFFT when one has already been registered
2024-01-15 14:06:48.704350: E tensorflow/compiler/xla/stream_executor/cuda/cuda_blas.cc:1518] Unable to register cuBLAS factory: Attempting to register factory for plugin cuBLAS when one has already been registered
2024-01-15 14:06:48.712047: I tensorflow/core/platform/cpu_feature_guard.cc:182] This TensorFlow binary is optimized to use available CPU instructions in performance-critical operations.
To enable the following instructions: AVX2 FMA, in other operations, rebuild TensorFlow with the appropriate compiler flags.
2024-01-15 14:06:49.711421: W tensorflow/compiler/tf2tensorrt/utils/py_utils.cc:38] TF-TRT Warning: Could not find TensorRT
2024-01-15 14:06:51.459926: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1886] Created device /job:localhost/replica:0/task:0/device:GPU:0 with 18184 MB memory: -> device: 0, name: NVIDIA A100-SXM4-40GB MIG 3g.20gb, pci bus id: 0000:01:00.0, compute capability: 8.0
2024-01-15 14:06:51.469378: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1886] Created device /job:worker/replica:0/task:0/device:GPU:0 with 18184 MB memory: -> device: 0, name: NVIDIA A100-SXM4-40GB MIG 3g.20gb, pci bus id: 0000:01:00.0, compute capability: 8.0
2024-01-15 14:06:51.490217: I tensorflow/core/distributed_runtime/rpc/grpc_server_lib.cc:457] Started server with target: grpc://gen-svc-82ee2ab7-aae8-44b2-a5ab-1f9fd0401075:80
2024-01-15 14:06:51.495668: I tensorflow/tsl/distributed_runtime/coordination/coordination_service.cc:551] /job:worker/replica:0/task:0 has connected to coordination service. Incarnation: 3072789976930509670
2024-01-15 14:06:51.495948: I tensorflow/tsl/distributed_runtime/coordination/coordination_service_agent.cc:299] Coordination agent has successfully connected.
2024-01-15 14:06:52.263966: I tensorflow/tsl/distributed_runtime/coordination/coordination_service.cc:551] /job:worker/replica:0/task:1 has connected to coordination service. Incarnation: 14088291762770279744
2024-01-15 14:07:16.278224: W tensorflow/tsl/framework/cpu_allocator_impl.cc:83] Allocation of 1509949440 exceeds 10% of free system memory.
2024-01-15 14:07:17.178980: W tensorflow/tsl/framework/cpu_allocator_impl.cc:83] Allocation of 1509949440 exceeds 10% of free system memory.
2024-01-15 14:07:17.905980: W tensorflow/tsl/framework/cpu_allocator_impl.cc:83] Allocation of 1509949440 exceeds 10% of free system memory.
2024-01-15 14:07:22.444540: W tensorflow/tsl/framework/cpu_allocator_impl.cc:83] Allocation of 1509949440 exceeds 10% of free system memory.
Epoch 1/10
2024-01-15 14:07:24.533902: W tensorflow/tsl/framework/cpu_allocator_impl.cc:83] Allocation of 1509949440 exceeds 10% of free system memory.
2024-01-15 14:07:27.793986: I tensorflow/compiler/xla/service/service.cc:168] XLA service 0x7f080000c190 initialized for platform CUDA (this does not guarantee that XLA will be used). Devices:
2024-01-15 14:07:27.794120: I tensorflow/compiler/xla/service/service.cc:176] StreamExecutor device (0): NVIDIA A100-SXM4-40GB MIG 3g.20gb, Compute Capability 8.0
2024-01-15 14:07:28.936911: I tensorflow/compiler/mlir/tensorflow/utils/dump_mlir_util.cc:269] disabling MLIR crash reproducer, set env var `MLIR_CRASH_REPRODUCER_DIRECTORY` to enable.
2024-01-15 14:07:30.163125: I tensorflow/compiler/xla/stream_executor/cuda/cuda_dnn.cc:442] Loaded cuDNN version 8906
2024-01-15 14:08:24.307063: I tensorflow/compiler/xla/stream_executor/gpu/asm_compiler.cc:328] ptxas warning : Registers are spilled to local memory in function 'triton_gemm_dot_232', 12 bytes spill stores, 12 bytes spill loads
2024-01-15 14:08:24.726556: I tensorflow/compiler/xla/stream_executor/gpu/asm_compiler.cc:328] ptxas warning : Registers are spilled to local memory in function 'triton_gemm_dot_232', 12 bytes spill stores, 12 bytes spill loads
2024-01-15 14:08:24.789581: I tensorflow/compiler/xla/stream_executor/gpu/asm_compiler.cc:328] ptxas warning : Registers are spilled to local memory in function 'triton_gemm_dot_232', 8 bytes spill stores, 8 bytes spill loads
2024-01-15 14:08:26.317751: I tensorflow/compiler/xla/stream_executor/gpu/asm_compiler.cc:328] ptxas warning : Registers are spilled to local memory in function 'triton_gemm_dot_392', 92 bytes spill stores, 92 bytes spill loads
2024-01-15 14:08:26.687122: W tensorflow/core/framework/op_kernel.cc:1839] OP_REQUIRES failed at xla_ops.cc:624 : UNKNOWN: <unknown>:0: error: loc("all-reduce-start.1"): 'lmhlo_gpu.all_reduce_start' op requires the same element type for all operands
<unknown>:0: note: loc("all-reduce-start.1"): see current operation:
%225 = "lmhlo_gpu.all_reduce_start"(%222, %8, %224, %18, %220, %222, %8, %224, %18, %220) ({
^bb0(%arg58: tensor<f32>, %arg59: tensor<f32>):
%251 = "mhlo.add"(%arg58, %arg59) : (tensor<f32>, tensor<f32>) -> tensor<f32>
"mhlo.return"(%251) : (tensor<f32>) -> ()
}) {channel_id = #mhlo.channel_handle<handle = 4294967300, type = 0>, constrain_layout = false, is_sync = true, replica_groups = dense<> : tensor<0x0xi64>, use_global_device_ids = false} : (memref<1xf32>, memref<1xf32>, memref<1xf32>, memref<1xf32>, memref<5630xf16>, memref<1xf32>, memref<1xf32>, memref<1xf32>, memref<1xf32>, memref<5630xf16>) -> !mhlo.token
2024-01-15 14:08:26.687331: I tensorflow/core/framework/local_rendezvous.cc:421] Local rendezvous recv item cancelled. Key hash: 10204104846648882243
2024-01-15 14:08:26.687358: I tensorflow/core/framework/local_rendezvous.cc:421] Local rendezvous recv item cancelled. Key hash: 5394287870414942276
2024-01-15 14:08:26.687399: I tensorflow/core/framework/local_rendezvous.cc:421] Local rendezvous recv item cancelled. Key hash: 8969947325169437454
Traceback (most recent call last):
File "/kirax_source/train.py", line 133, in <module>
train()
File "/kirax_source/train.py", line 125, in train
model.fit(
File "/usr/local/lib/python3.11/dist-packages/keras/src/utils/traceback_utils.py", line 70, in error_handler
raise e.with_traceback(filtered_tb) from None
File "/usr/local/lib/python3.11/dist-packages/tensorflow/python/eager/execute.py", line 60, in quick_execute
tensors = pywrap_tfe.TFE_Py_Execute(ctx._handle, device_name, op_name,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
tensorflow.python.framework.errors_impl.UnknownError: Graph execution error:
Detected at node StatefulPartitionedCall defined at (most recent call last):
File "/usr/lib/python3.11/threading.py", line 1002, in _bootstrap
File "/usr/lib/python3.11/threading.py", line 1045, in _bootstrap_inner
Detected at node StatefulPartitionedCall defined at (most recent call last):
File "/usr/lib/python3.11/threading.py", line 1002, in _bootstrap
File "/usr/lib/python3.11/threading.py", line 1045, in _bootstrap_inner
2 root error(s) found.
(0) UNKNOWN: <unknown>:0: error: loc("all-reduce-start.1"): 'lmhlo_gpu.all_reduce_start' op requires the same element type for all operands
<unknown>:0: note: loc("all-reduce-start.1"): see current operation:
%225 = "lmhlo_gpu.all_reduce_start"(%222, %8, %224, %18, %220, %222, %8, %224, %18, %220) ({
^bb0(%arg58: tensor<f32>, %arg59: tensor<f32>):
%251 = "mhlo.add"(%arg58, %arg59) : (tensor<f32>, tensor<f32>) -> tensor<f32>
"mhlo.return"(%251) : (tensor<f32>) -> ()
}) {channel_id = #mhlo.channel_handle<handle = 4294967300, type = 0>, constrain_layout = false, is_sync = true, replica_groups = dense<> : tensor<0x0xi64>, use_global_device_ids = false} : (memref<1xf32>, memref<1xf32>, memref<1xf32>, memref<1xf32>, memref<5630xf16>, memref<1xf32>, memref<1xf32>, memref<1xf32>, memref<1xf32>, memref<5630xf16>) -> !mhlo.token
[[{{node StatefulPartitionedCall}}]]
[[Reshape_3/_24]]
(1) UNKNOWN: <unknown>:0: error: loc("all-reduce-start.1"): 'lmhlo_gpu.all_reduce_start' op requires the same element type for all operands
<unknown>:0: note: loc("all-reduce-start.1"): see current operation:
%225 = "lmhlo_gpu.all_reduce_start"(%222, %8, %224, %18, %220, %222, %8, %224, %18, %220) ({
^bb0(%arg58: tensor<f32>, %arg59: tensor<f32>):
%251 = "mhlo.add"(%arg58, %arg59) : (tensor<f32>, tensor<f32>) -> tensor<f32>
"mhlo.return"(%251) : (tensor<f32>) -> ()
}) {channel_id = #mhlo.channel_handle<handle = 4294967300, type = 0>, constrain_layout = false, is_sync = true, replica_groups = dense<> : tensor<0x0xi64>, use_global_device_ids = false} : (memref<1xf32>, memref<1xf32>, memref<1xf32>, memref<1xf32>, memref<5630xf16>, memref<1xf32>, memref<1xf32>, memref<1xf32>, memref<1xf32>, memref<5630xf16>) -> !mhlo.token
[[{{node StatefulPartitionedCall}}]]
0 successful operations.
0 derived errors ignored. [Op:__inference_train_function_2528]
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62796/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62796/timeline
| null | null | false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62795
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62795/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62795/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62795/events
|
https://github.com/tensorflow/tensorflow/issues/62795
| 2,081,943,381 |
I_kwDOArmXAs58F-9V
| 62,795 |
Automating Transfer Learning: Gradual fine-tuning of a TensorFlow model produces: “ValueError: Unknown metric function: val_loss.” exception during the fit method of the fine-tuning stage.
|
{
"login": "john-james-ai",
"id": 20120789,
"node_id": "MDQ6VXNlcjIwMTIwNzg5",
"avatar_url": "https://avatars.githubusercontent.com/u/20120789?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/john-james-ai",
"html_url": "https://github.com/john-james-ai",
"followers_url": "https://api.github.com/users/john-james-ai/followers",
"following_url": "https://api.github.com/users/john-james-ai/following{/other_user}",
"gists_url": "https://api.github.com/users/john-james-ai/gists{/gist_id}",
"starred_url": "https://api.github.com/users/john-james-ai/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/john-james-ai/subscriptions",
"organizations_url": "https://api.github.com/users/john-james-ai/orgs",
"repos_url": "https://api.github.com/users/john-james-ai/repos",
"events_url": "https://api.github.com/users/john-james-ai/events{/privacy}",
"received_events_url": "https://api.github.com/users/john-james-ai/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 473172988,
"node_id": "MDU6TGFiZWw0NzMxNzI5ODg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:bug",
"name": "type:bug",
"color": "159b2e",
"default": false,
"description": "Bug"
},
{
"id": 3797168204,
"node_id": "LA_kwDOArmXAs7iVDBM",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.8",
"name": "TF 2.8",
"color": "5DC9D0",
"default": false,
"description": ""
}
] |
closed
| false |
{
"login": "Venkat6871",
"id": 147127861,
"node_id": "U_kgDOCMT-NQ",
"avatar_url": "https://avatars.githubusercontent.com/u/147127861?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/Venkat6871",
"html_url": "https://github.com/Venkat6871",
"followers_url": "https://api.github.com/users/Venkat6871/followers",
"following_url": "https://api.github.com/users/Venkat6871/following{/other_user}",
"gists_url": "https://api.github.com/users/Venkat6871/gists{/gist_id}",
"starred_url": "https://api.github.com/users/Venkat6871/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Venkat6871/subscriptions",
"organizations_url": "https://api.github.com/users/Venkat6871/orgs",
"repos_url": "https://api.github.com/users/Venkat6871/repos",
"events_url": "https://api.github.com/users/Venkat6871/events{/privacy}",
"received_events_url": "https://api.github.com/users/Venkat6871/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "Venkat6871",
"id": 147127861,
"node_id": "U_kgDOCMT-NQ",
"avatar_url": "https://avatars.githubusercontent.com/u/147127861?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/Venkat6871",
"html_url": "https://github.com/Venkat6871",
"followers_url": "https://api.github.com/users/Venkat6871/followers",
"following_url": "https://api.github.com/users/Venkat6871/following{/other_user}",
"gists_url": "https://api.github.com/users/Venkat6871/gists{/gist_id}",
"starred_url": "https://api.github.com/users/Venkat6871/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Venkat6871/subscriptions",
"organizations_url": "https://api.github.com/users/Venkat6871/orgs",
"repos_url": "https://api.github.com/users/Venkat6871/repos",
"events_url": "https://api.github.com/users/Venkat6871/events{/privacy}",
"received_events_url": "https://api.github.com/users/Venkat6871/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi **@john-james-ai**,\r\nI was able to reproduce the issue on Colab using TF v2.15, Please find the [gist](https://colab.sandbox.google.com/gist/Venkat6871/1703c6e7ac97fabcbbb14e9f40003299/62795_2-15.ipynb) here for reference.\r\n\r\nThank you!",
"Hi @Venkat6871 \r\nThanks so much for the quick response. I saw the gist and it appears to give a different error in Tf v2.15. In either event, I'm running TF 2.8 because my computer was manufactured in the Mesozoic before AVX was invented. What are your thoughts on the next steps or recommendations?\r\n\r\np.s. I'm using the DenseNet201",
"@Venkat6871 \r\nI think I owe you a coffee! It turns out that val_loss actually isn't an acceptable metric in the compile method; although, it can be used as a monitor metric in the EarlyStopping callback. I've tested it with other metrics and it seems to be working fine. I'll go ahead and close this. Thanks again mate! \r\n\r\nj2 ",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62795\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62795\">No</a>\n"
] | 2024-01-15T12:32:34 | 2024-01-19T05:23:02 | 2024-01-19T05:22:58 |
NONE
| null | null | null |
## Current behavior?
I’m attempting to automate transfer learning fine-tuning using iterative, gradual thawing of an underlying pre-trained and frozen base network. A compiled model containing the underlying, pre-trained, and frozen base network architecture is fed into an X4Learner class. The class exposes two methods: feature_extraction, and fine_tuning. The feature extraction method fits the model for a designated number of epochs and stores the last epoch as an instance variable. The fine_tuning method operates on the ‘feature_extracted’ model and performs an iterative fine-tuning process in which each iteration thaws some number of layers in the underlying base model, then recompiles it. During fine-tuning, the fit method produces the following exception.
ValueError: Unknown metric function: val_loss. Please ensure this object is passed to the `custom_objects` argument.
A reproducible test case can be found [here](https://colab.research.google.com/drive/1B3kngb1hQr8zrnBOUoDtSuC3QKU-KeWB?usp=sharing)
I've included the code below for convenience.
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
No
### TensorFlow version
v2.8.0-0-g3f878cff5b6 2.8.0
### Custom code
Yes
### OS platform and distribution
Windows Subsystem for Linux: Ubuntu 22.04.2 LTS
### Python version
3.10..12
### Standalone code to reproduce the issue
```shell
from typing import Union
import os
import numpy as np
import pandas as pd
import tensorflow as tf
# ------------------------------------------------------------------------------------------------ #
class X4LearnerLite:
"""Performs transfer learning of a TensorFlow model containing a pre-trained base model.
Two methods are exposed: extract_features, and fine_tune. The extract_features method trains
the model on the given data using the designated learning rate. The fine_tune method
thaws one or more layers in the model, then trains it on a decayed learning rate. Each
fine tuning session decays the learning rate by a learning_rate_decay factor to mitigate
catastrophic forgetting.
Args:
model (tf.keras.Model): Model containing a frozen, pre-trained base model.
train_ds (tf.data.Dataset): TensorFlow training dataset.
val_ds (tf.data.Dataset): TensorFlow validation dataset.
base_model_layer (int): Index for the base model layer for thawing.
learning_rate (float): The learning rate for feature extraction. Default = 0.0001
metric (str): The metric used to evaluate model fit performance. Default = 'val_loss'
loss (str): The loss function. Default = 'binary_crossentropy'.
activation (str): Activation function. Default = 'sigmoid'.
"""
def __init__(
self,
model: tf.keras.Model,
base_model_layer: int,
train_ds: tf.data.Dataset,
val_ds: tf.data.Dataset,
learning_rate: float = 0.0001,
metric: str = "val_loss",
loss: str = "binary_crossentropy",
activation: str = "sigmoid",
) -> None:
self._model = model
self._base_model_layer = base_model_layer
self._train_ds = train_ds
self._val_ds = val_ds
self._learning_rate = learning_rate
self._metric = metric
self._loss = loss
self._activation = activation
# Used during the thawing process to determine number of layers to thaw as proportion of
# total number of layers in the underlying base model.
self._n_layers = len(self._model.layers[self._base_model_layer].layers)
self._initial_epoch = None
# ------------------------------------------------------------------------------------------------ #
def extract_features(self, epochs: int = 5) -> None:
"""Performs the feature extraction phase of transfer learning
Args:
epochs (int): Number of epochs to execute
"""
history = self._model.fit(
self._train_ds,
epochs=epochs,
validation_data=self._val_ds,
)
# Save the last feature extraction epoch for fine tune phase
self._initial_epoch = history.epoch[-1]
# ------------------------------------------------------------------------------------------------ #
def fine_tune(
self,
epochs: int = 10,
sessions: int = 10,
learning_rate_decay_factory: float = 0.1,
thaw_rate: Union[float, int] = 0.05,
) -> None:
"""Performs iterative fine tuning using gradual unfreezing of the base model.
Args:
epochs (int): Number of epochs per session. Default = 10
sessions (int): Number of fine tuning sessions to execute. Default is 10
learning_rate_decay_factor (float): Factor by which the learning rate is reduced each session.
thaw_rate (Union[float, int]): Rate by which layers are thawed. This can be a raw
integer or a float proportion of base model layers. Default = 0.05.
"""
session = 0
learning_rate = self._learning_rate
initial_epoch = self._initial_epoch
while session < sessions:
session += 1
learning_rate *= learning_rate_decay_factory
# Thaw the top n layers of the base model according to the following
n = max(int(self._n_layers * thaw_rate * session),1)
self._model.layers[self._base_model_layer].trainable = True
for layer in self._model.layers[self._base_model_layer].layers[:-n]:
layer.trainable = False
self._model.compile(
loss=self._loss,
optimizer=tf.keras.optimizers.Adam(learning_rate=learning_rate),
metrics=[self._metric],
)
total_epochs = epochs + initial_epoch
history = self._model.fit(
self._train_ds,
epochs=total_epochs,
validation_data=self._val_ds,
initial_epoch=initial_epoch,
)
initial_epoch = history.epochs[-1]
```
### Relevant log output
ValueError: in user code:
File "/home/john/anaconda3/envs/bcd/lib/python3.10/site-packages/keras/engine/training.py", line 1021, in train_function *
return step_function(self, iterator)
File "/home/john/anaconda3/envs/bcd/lib/python3.10/site-packages/keras/engine/training.py", line 1010, in step_function **
outputs = model.distribute_strategy.run(run_step, args=(data,))
File "/home/john/anaconda3/envs/bcd/lib/python3.10/site-packages/keras/engine/training.py", line 1000, in run_step **
outputs = model.train_step(data)
File "/home/john/anaconda3/envs/bcd/lib/python3.10/site-packages/keras/engine/training.py", line 864, in train_step
return self.compute_metrics(x, y, y_pred, sample_weight)
File "/home/john/anaconda3/envs/bcd/lib/python3.10/site-packages/keras/engine/training.py", line 957, in compute_metrics
self.compiled_metrics.update_state(y, y_pred, sample_weight)
File "/home/john/anaconda3/envs/bcd/lib/python3.10/site-packages/keras/engine/compile_utils.py", line 438, in update_state
self.build(y_pred, y_true)
File "/home/john/anaconda3/envs/bcd/lib/python3.10/site-packages/keras/engine/compile_utils.py", line 358, in build
self._metrics = tf.__internal__.nest.map_structure_up_to(y_pred, self._get_metric_objects,
File "/home/john/anaconda3/envs/bcd/lib/python3.10/site-packages/keras/engine/compile_utils.py", line 484, in _get_metric_objects
return [self._get_metric_object(m, y_t, y_p) for m in metrics]
File "/home/john/anaconda3/envs/bcd/lib/python3.10/site-packages/keras/engine/compile_utils.py", line 484, in <listcomp>
return [self._get_metric_object(m, y_t, y_p) for m in metrics]
File "/home/john/anaconda3/envs/bcd/lib/python3.10/site-packages/keras/engine/compile_utils.py", line 503, in _get_metric_object
metric_obj = metrics_mod.get(metric)
File "/home/john/anaconda3/envs/bcd/lib/python3.10/site-packages/keras/metrics.py", line 4262, in get
return deserialize(str(identifier))
File "/home/john/anaconda3/envs/bcd/lib/python3.10/site-packages/keras/metrics.py", line 4218, in deserialize
return deserialize_keras_object(
File "/home/john/anaconda3/envs/bcd/lib/python3.10/site-packages/keras/utils/generic_utils.py", line 709, in deserialize_keras_object
raise ValueError(
ValueError: Unknown metric function: val_loss. Please ensure this object is passed to the `custom_objects` argument. See https://www.tensorflow.org/guide/keras/save_and_serialize#registering_the_custom_object for details
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62795/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62795/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62794
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62794/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62794/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62794/events
|
https://github.com/tensorflow/tensorflow/issues/62794
| 2,081,771,342 |
I_kwDOArmXAs58FU9O
| 62,794 |
Load models through bytes (by memory)
|
{
"login": "joseangel-mm",
"id": 85619872,
"node_id": "MDQ6VXNlcjg1NjE5ODcy",
"avatar_url": "https://avatars.githubusercontent.com/u/85619872?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/joseangel-mm",
"html_url": "https://github.com/joseangel-mm",
"followers_url": "https://api.github.com/users/joseangel-mm/followers",
"following_url": "https://api.github.com/users/joseangel-mm/following{/other_user}",
"gists_url": "https://api.github.com/users/joseangel-mm/gists{/gist_id}",
"starred_url": "https://api.github.com/users/joseangel-mm/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/joseangel-mm/subscriptions",
"organizations_url": "https://api.github.com/users/joseangel-mm/orgs",
"repos_url": "https://api.github.com/users/joseangel-mm/repos",
"events_url": "https://api.github.com/users/joseangel-mm/events{/privacy}",
"received_events_url": "https://api.github.com/users/joseangel-mm/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473184161,
"node_id": "MDU6TGFiZWw0NzMxODQxNjE=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:support",
"name": "type:support",
"color": "159b2e",
"default": false,
"description": "Support issues"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
}
] |
closed
| false |
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "tilakrayal",
"id": 81610181,
"node_id": "MDQ6VXNlcjgxNjEwMTgx",
"avatar_url": "https://avatars.githubusercontent.com/u/81610181?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/tilakrayal",
"html_url": "https://github.com/tilakrayal",
"followers_url": "https://api.github.com/users/tilakrayal/followers",
"following_url": "https://api.github.com/users/tilakrayal/following{/other_user}",
"gists_url": "https://api.github.com/users/tilakrayal/gists{/gist_id}",
"starred_url": "https://api.github.com/users/tilakrayal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tilakrayal/subscriptions",
"organizations_url": "https://api.github.com/users/tilakrayal/orgs",
"repos_url": "https://api.github.com/users/tilakrayal/repos",
"events_url": "https://api.github.com/users/tilakrayal/events{/privacy}",
"received_events_url": "https://api.github.com/users/tilakrayal/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"@joseangel-mm,\r\nTensorFlow doesn't have direct **load from bytes** api, but there is an alternative approach to achieve loading from byte-like objects\r\n\r\nCould you please try saving and loading weights and then use the loaded weights from bytes like **model.load_weights(weights_bytes)** or saving and loading the Model (SavedModel format) and load the model from bytes as below\r\n\r\n```\r\nwith io.BytesIO(bytes_data) as f:\r\n loaded_model = tf.keras.models.load_model(f)\r\n```\r\n\r\n\r\nAlso try to load the savedModel from the buffer (TensorFlow Serving)\r\n```\r\nfrom tensorflow.saved_model import loader\r\nbundle = loader.load(io.BytesIO(saved_model_bytes))\r\n```\r\n\r\nThank you!",
"> ng weights\r\n\r\nThanks @tilakrayal, it seems the second alternative would fit better for our case.",
"@joseangel-mm,\r\nGlad the suggestion worked for you to resolve the issue, Could you please feel free to move this to closed status. Thank you!",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62794\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62794\">No</a>\n"
] | 2024-01-15T10:49:46 | 2024-02-01T01:48:11 | 2024-02-01T01:48:08 |
NONE
| null | null | null |
In my team, we wonder if it is possible to load the models directly by bytes. In the following example, I explain better:
Right now, we have in Golang the following to load the model:
`tf.LoadSavedModel(ModelPath, tags, nil)`
To do the previous step we use this [library](https://github.com/wamuir/graft).
What we want is to load the model directly from memory, something like the following:
`tf.LoadSavedModelFromMemory(ModelInbytes, tags, nil)`
We know we are using a binding for Golang which is the one that creates the API functions, but researching the TensorFlow code we discovered there is no alternative to it, so we wonder if there is any fork that does it, if so we could create or change the binding.
Thanks in advance.
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62794/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62794/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62793
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62793/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62793/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62793/events
|
https://github.com/tensorflow/tensorflow/issues/62793
| 2,081,224,498 |
I_kwDOArmXAs58DPcy
| 62,793 |
Gradients with tf.math.expm and complex inputs generates casting warning
|
{
"login": "aplund",
"id": 1369436,
"node_id": "MDQ6VXNlcjEzNjk0MzY=",
"avatar_url": "https://avatars.githubusercontent.com/u/1369436?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/aplund",
"html_url": "https://github.com/aplund",
"followers_url": "https://api.github.com/users/aplund/followers",
"following_url": "https://api.github.com/users/aplund/following{/other_user}",
"gists_url": "https://api.github.com/users/aplund/gists{/gist_id}",
"starred_url": "https://api.github.com/users/aplund/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/aplund/subscriptions",
"organizations_url": "https://api.github.com/users/aplund/orgs",
"repos_url": "https://api.github.com/users/aplund/repos",
"events_url": "https://api.github.com/users/aplund/events{/privacy}",
"received_events_url": "https://api.github.com/users/aplund/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 1093464312,
"node_id": "MDU6TGFiZWwxMDkzNDY0MzEy",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:others",
"name": "type:others",
"color": "159b2e",
"default": false,
"description": "issues not falling in bug, perfromance, support, build and install or feature"
},
{
"id": 1097547147,
"node_id": "MDU6TGFiZWwxMDk3NTQ3MTQ3",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/comp:ops",
"name": "comp:ops",
"color": "0052cc",
"default": false,
"description": "OPs related issues"
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
open
| false |
{
"login": "SuryanarayanaY",
"id": 116063290,
"node_id": "U_kgDOBur8Og",
"avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/SuryanarayanaY",
"html_url": "https://github.com/SuryanarayanaY",
"followers_url": "https://api.github.com/users/SuryanarayanaY/followers",
"following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}",
"gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}",
"starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions",
"organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs",
"repos_url": "https://api.github.com/users/SuryanarayanaY/repos",
"events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}",
"received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "SuryanarayanaY",
"id": 116063290,
"node_id": "U_kgDOBur8Og",
"avatar_url": "https://avatars.githubusercontent.com/u/116063290?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/SuryanarayanaY",
"html_url": "https://github.com/SuryanarayanaY",
"followers_url": "https://api.github.com/users/SuryanarayanaY/followers",
"following_url": "https://api.github.com/users/SuryanarayanaY/following{/other_user}",
"gists_url": "https://api.github.com/users/SuryanarayanaY/gists{/gist_id}",
"starred_url": "https://api.github.com/users/SuryanarayanaY/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/SuryanarayanaY/subscriptions",
"organizations_url": "https://api.github.com/users/SuryanarayanaY/orgs",
"repos_url": "https://api.github.com/users/SuryanarayanaY/repos",
"events_url": "https://api.github.com/users/SuryanarayanaY/events{/privacy}",
"received_events_url": "https://api.github.com/users/SuryanarayanaY/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"Hi @aplund ,\r\n\r\nThis is intended. The API warns you that when casting a complex number to `float`, it will ignore the imaginary part which is the behaviour of the casting op. Please refer this part of source code.\r\n\r\nhttps://github.com/tensorflow/tensorflow/blob/4c288453087edd9610dba9e94822044ddafc568f/tensorflow/python/ops/math_ops.py#L1011-L1017",
"I'm trying to see where in the code snippet a cast to a real number is indicated. Are you able to point to the line where it happens?",
"Hi @aplund ,\r\n\r\nIt seems cast being called internally by the `tf.GradientTape().jacobian` method. Hard to trace though. \r\n\r\nOne approach could be cloning the TF repo locally and changing the `logging.warning(\".....\")` to `raise TypeError(\"...\")` in `cast` op API `python/ops/math.py` file and adding `tf.debugging.disable_traceback_filtering` after tensorflow import might probably raise complete error stack. I appreciate if you can able to check this if you have bandwidth.",
"I'm not sure I fully understand how to run tensorflow from within the build tree, so I just changed the python file in the venv and generated the trace that way.\r\n\r\n[tmpout.txt](https://github.com/tensorflow/tensorflow/files/13996817/tmpout.txt)\r\n",
"Hello, I'd like to work on this issue. Can I contribute? ",
"Hi @zahed327 , Please feel free to contribute if you want. ",
"@SuryanarayanaY I am facing issues regarding bazel build in tensorflow while building from source. Is there a way to resolve the issue so that I can test the code.\r\n\r\nEdit : I opened an issue regarding this https://github.com/tensorflow/tensorflow/issues/63002"
] | 2024-01-15T04:24:51 | 2024-02-20T19:22:42 | null |
NONE
| null | null | null |
### Issue type
Bug
### Have you reproduced the bug with TensorFlow Nightly?
No
### Source
binary
### TensorFlow version
2.15.0
### Custom code
No
### OS platform and distribution
Archlinux
### Mobile device
_No response_
### Python version
_No response_
### Bazel version
_No response_
### GCC/compiler version
_No response_
### CUDA/cuDNN version
_No response_
### GPU model and memory
_No response_
### Current behavior?
Computing gradients using tf.linalg.expm with complex types gives warnings about casting to real types.
### Standalone code to reproduce the issue
```shell
import tensorflow as tf
x=tf.Variable(0, dtype=tf.complex128)
A = tf.constant(
[[0,0,0,0,0],
[0,0+1.0j,0,0,0],
[0,0,-2,0,0],
[0,0,0,-3.0j,0],
[0,0,0,0,4]]
,tf.complex128)
with tf.GradientTape() as g:
g.watch(x)
out = tf.linalg.expm(x*A)
display(g.jacobian(out, x))
```
### Relevant log output
```shell
WARNING:tensorflow:You are casting an input of type complex128 to an incompatible dtype float64. This will discard the imaginary part and may not be what you intended.
<tf.Tensor: shape=(5, 5), dtype=complex128, numpy=
array([[ 0.+0.j, 0.+0.j, 0.+0.j, 0.+0.j, 0.+0.j],
[ 0.+0.j, 0.-1.j, 0.+0.j, 0.+0.j, 0.+0.j],
[ 0.+0.j, 0.+0.j, -2.+0.j, 0.+0.j, 0.+0.j],
[ 0.+0.j, 0.+0.j, 0.+0.j, 0.+3.j, 0.+0.j],
[ 0.+0.j, 0.+0.j, 0.+0.j, 0.+0.j, 4.+0.j]])>
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62793/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62793/timeline
| null | null | false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62792
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62792/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62792/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62792/events
|
https://github.com/tensorflow/tensorflow/issues/62792
| 2,081,116,347 |
I_kwDOArmXAs58C1C7
| 62,792 |
The c api 2.15 zip for windows does not have required files, but the linux version contains all the required files
|
{
"login": "arwhirang",
"id": 2763565,
"node_id": "MDQ6VXNlcjI3NjM1NjU=",
"avatar_url": "https://avatars.githubusercontent.com/u/2763565?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/arwhirang",
"html_url": "https://github.com/arwhirang",
"followers_url": "https://api.github.com/users/arwhirang/followers",
"following_url": "https://api.github.com/users/arwhirang/following{/other_user}",
"gists_url": "https://api.github.com/users/arwhirang/gists{/gist_id}",
"starred_url": "https://api.github.com/users/arwhirang/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/arwhirang/subscriptions",
"organizations_url": "https://api.github.com/users/arwhirang/orgs",
"repos_url": "https://api.github.com/users/arwhirang/repos",
"events_url": "https://api.github.com/users/arwhirang/events{/privacy}",
"received_events_url": "https://api.github.com/users/arwhirang/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 386191887,
"node_id": "MDU6TGFiZWwzODYxOTE4ODc=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stat:awaiting%20response",
"name": "stat:awaiting response",
"color": "f4b400",
"default": false,
"description": "Status - Awaiting response from author"
},
{
"id": 473173351,
"node_id": "MDU6TGFiZWw0NzMxNzMzNTE=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/type:build/install",
"name": "type:build/install",
"color": "159b2e",
"default": false,
"description": "Build and install issues"
},
{
"id": 474725938,
"node_id": "MDU6TGFiZWw0NzQ3MjU5Mzg=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/stale",
"name": "stale",
"color": "d4c5f9",
"default": false,
"description": "This label marks the issue/pr stale - to be closed automatically if no activity"
},
{
"id": 1188421838,
"node_id": "MDU6TGFiZWwxMTg4NDIxODM4",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/subtype:windows",
"name": "subtype:windows",
"color": "b619ea",
"default": false,
"description": "Windows Build/Installation Issues"
},
{
"id": 6218999181,
"node_id": "LA_kwDOArmXAs8AAAABcq5ljQ",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/TF%202.15",
"name": "TF 2.15",
"color": "9162CB",
"default": false,
"description": "For issues related to 2.15.x"
}
] |
closed
| false |
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "sushreebarsa",
"id": 84765720,
"node_id": "MDQ6VXNlcjg0NzY1NzIw",
"avatar_url": "https://avatars.githubusercontent.com/u/84765720?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/sushreebarsa",
"html_url": "https://github.com/sushreebarsa",
"followers_url": "https://api.github.com/users/sushreebarsa/followers",
"following_url": "https://api.github.com/users/sushreebarsa/following{/other_user}",
"gists_url": "https://api.github.com/users/sushreebarsa/gists{/gist_id}",
"starred_url": "https://api.github.com/users/sushreebarsa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sushreebarsa/subscriptions",
"organizations_url": "https://api.github.com/users/sushreebarsa/orgs",
"repos_url": "https://api.github.com/users/sushreebarsa/repos",
"events_url": "https://api.github.com/users/sushreebarsa/events{/privacy}",
"received_events_url": "https://api.github.com/users/sushreebarsa/received_events",
"type": "User",
"site_admin": false
}
] | null |
[
"@arwhirang TensorFlow 2.10 was the last TensorFlow release that supported GPUs on native-Windows. Please refer to this [doc](https://www.tensorflow.org/install/pip) for more information on this. Could you please let us know what are the steps you followed and the issue you are facing? Thank you!",
"This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.",
"This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further.",
"Are you satisfied with the resolution of your issue?\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62792\">Yes</a>\n<a href=\"https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62792\">No</a>\n"
] | 2024-01-15T02:07:37 | 2024-02-02T01:47:06 | 2024-02-02T01:47:03 |
NONE
| null | null | null |
### Issue type
Build/Install
### Have you reproduced the bug with TensorFlow Nightly?
No
### Source
source
### TensorFlow version
tf 2.15
### Custom code
No
### OS platform and distribution
Windows and linux
### Mobile device
None
### Python version
Doesn't matter
### Bazel version
Doesn't matter
### GCC/compiler version
Doesn't matter
### CUDA/cuDNN version
Doesn't matter
### GPU model and memory
Doesn't matter
### Current behavior?
The "Download and extract" section of the webpage "Install Tensorflow for C" has several links.
The c api 2.15 zip for windows does not have required files, but the linux version contains all the required files.
### Standalone code to reproduce the issue
```shell
Not applicable.
```
### Relevant log output
```shell
Not applicable.
```
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62792/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62792/timeline
| null |
completed
| false |
https://api.github.com/repos/tensorflow/tensorflow/issues/62791
|
https://api.github.com/repos/tensorflow/tensorflow
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62791/labels{/name}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62791/comments
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62791/events
|
https://github.com/tensorflow/tensorflow/pull/62791
| 2,080,817,609 |
PR_kwDOArmXAs5kBwxT
| 62,791 |
fixed typo
|
{
"login": "Cassini-chris",
"id": 34183942,
"node_id": "MDQ6VXNlcjM0MTgzOTQy",
"avatar_url": "https://avatars.githubusercontent.com/u/34183942?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/Cassini-chris",
"html_url": "https://github.com/Cassini-chris",
"followers_url": "https://api.github.com/users/Cassini-chris/followers",
"following_url": "https://api.github.com/users/Cassini-chris/following{/other_user}",
"gists_url": "https://api.github.com/users/Cassini-chris/gists{/gist_id}",
"starred_url": "https://api.github.com/users/Cassini-chris/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Cassini-chris/subscriptions",
"organizations_url": "https://api.github.com/users/Cassini-chris/orgs",
"repos_url": "https://api.github.com/users/Cassini-chris/repos",
"events_url": "https://api.github.com/users/Cassini-chris/events{/privacy}",
"received_events_url": "https://api.github.com/users/Cassini-chris/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"id": 987666414,
"node_id": "MDU6TGFiZWw5ODc2NjY0MTQ=",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/ready%20to%20pull",
"name": "ready to pull",
"color": "2cd643",
"default": false,
"description": "PR ready for merge process"
},
{
"id": 1169364259,
"node_id": "MDU6TGFiZWwxMTY5MzY0MjU5",
"url": "https://api.github.com/repos/tensorflow/tensorflow/labels/size:XS",
"name": "size:XS",
"color": "adafea",
"default": false,
"description": "CL Change Size: Extra Small"
}
] |
closed
| false |
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
|
[
{
"login": "gbaned",
"id": 48215717,
"node_id": "MDQ6VXNlcjQ4MjE1NzE3",
"avatar_url": "https://avatars.githubusercontent.com/u/48215717?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/gbaned",
"html_url": "https://github.com/gbaned",
"followers_url": "https://api.github.com/users/gbaned/followers",
"following_url": "https://api.github.com/users/gbaned/following{/other_user}",
"gists_url": "https://api.github.com/users/gbaned/gists{/gist_id}",
"starred_url": "https://api.github.com/users/gbaned/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gbaned/subscriptions",
"organizations_url": "https://api.github.com/users/gbaned/orgs",
"repos_url": "https://api.github.com/users/gbaned/repos",
"events_url": "https://api.github.com/users/gbaned/events{/privacy}",
"received_events_url": "https://api.github.com/users/gbaned/received_events",
"type": "User",
"site_admin": false
}
] | null |
[] | 2024-01-14T17:11:21 | 2024-01-15T09:08:44 | 2024-01-15T09:08:44 |
CONTRIBUTOR
| null | false |
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/pulls/62791",
"html_url": "https://github.com/tensorflow/tensorflow/pull/62791",
"diff_url": "https://github.com/tensorflow/tensorflow/pull/62791.diff",
"patch_url": "https://github.com/tensorflow/tensorflow/pull/62791.patch",
"merged_at": "2024-01-15T09:08:44"
}
|
fixed typo ("untill")
|
{
"url": "https://api.github.com/repos/tensorflow/tensorflow/issues/62791/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
}
|
https://api.github.com/repos/tensorflow/tensorflow/issues/62791/timeline
| null | null | true |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.